From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mail-in23.apple.com (mail-out23.apple.com [17.171.2.33]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id D0C5B20945B60 for ; Wed, 20 Sep 2017 10:43:12 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; d=apple.com; s=mailout2048s; c=relaxed/simple; q=dns/txt; i=@apple.com; t=1505929578; h=From:Sender:Reply-To:Subject:Date:Message-id:To:Cc:MIME-version:Content-type: Content-transfer-encoding:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-reply-to:References:List-Id: List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=jhIasOwqrWafNG/vJdxXakNXbzsYwt9xkbYXxApKKX0=; b=KxZKVuUZLQ7TNRFzQEUXUqhGmDkd2enii6fItg7sAEPM/8sztoPFBobpcYtcP/Oe SZ8l+T08XoQBZpVI3o2XbP3UKlYE7Lgu9ZWpcYcPBWjFBjAqCPqYeL2CwDpXGP96 xSx7UrXebhShgf6GH73ylERhI1Aot1Ip0i4npCfo7RNl5Dl1kJM/094edF5VbWTE EzNpi8YXbTkD2NFo6a1Q2JkhV4iedTdcvYF5GcdzGJfgP553vTgKLnGVb0GVYSm1 pXj2vaCe1uZqHNtNSwBQ/Wm773yfw2smGyjsycBSx2YD6jYRmhiguex0V6Csa3Kg +f4Tb5oZWvCVCLl7a6o3EA==; Received: from relay22.apple.com (relay22.apple.com [17.171.128.103]) (using TLS with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mail-in23.apple.com (Apple Secure Mail Relay) with SMTP id 53.A6.06084.A69A2C95; Wed, 20 Sep 2017 10:46:18 -0700 (PDT) X-AuditID: 11ab0217-85cf99c0000017c4-4f-59c2a96a7b10 Received: from ma1-mmpp-sz11.apple.com (ma1-mmpp-sz11.apple.com [17.171.128.33]) by relay22.apple.com (Apple SCV relay) with SMTP id 19.0A.07334.A69A2C95; Wed, 20 Sep 2017 10:46:18 -0700 (PDT) MIME-version: 1.0 Received: from [17.234.221.13] by ma1-mmpp-sz11.apple.com (Oracle Communications Messaging Server 8.0.1.3.20170825 64bit (built Aug 25 2017)) with ESMTPSA id <0OWL00CK4AP24T70@ma1-mmpp-sz11.apple.com>; Wed, 20 Sep 2017 10:46:18 -0700 (PDT) Sender: afish@apple.com From: Andrew Fish In-reply-to: Date: Wed, 20 Sep 2017 10:46:14 -0700 Cc: Udit Kumar , "edk2-devel@lists.01.org" , "Olivier.Martin@arm.com" , Vladimir Olovyannikov Message-id: <7B611C7B-2DC3-4419-9840-926A4B253E9F@apple.com> References: <4CC33CC2-86D1-490E-A67E-12D751745121@apple.com> To: Ard Biesheuvel X-Mailer: Apple Mail (2.3273) X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFrrJLMWRmVeSWpSXmKPExsUiuLohXTdr5aFIgz8TOSz+f9jNaLHn0FFm i6PrvrBbrFhyiM3i/eLjzA6sHmvmrWH0mHX/LJvHnWt72Dy6Z/9j8dj4bgdTAGsUl01Kak5m WWqRvl0CV8bJyRoFHwQqOtpOMTYw7uPtYuTkkBAwkZizqIm5i5GLQ0hgPZNE391WdpjEozO3 2CAShxgldsybwAyS4BUQlPgx+R5LFyMHB7OAvMTB87IgYWYBLYnvj1pZIOq/MkosnPGaDSQh LCAu8e7MJmYI21bix5YeFhCbTUBZYsX8D+wgczgFgiU2vPECCbMIqEp8+toLdhCzwFlGiYY/ P9gg9tpIfNk4DerS0+wSs+88AGsWEdCTaOkygzhaVuLW7EtgNRICG9gkdt/7wziBUXgWkrtn Idw9C8ndCxiZVzEK5yZm5uhm5hkZ6yUWFOSk6iXn525iBMcFk/gOxs+vDQ8xCnAwKvHwBlgd jBRiTSwrrsw9xCjNwaIkzrv3H1BIID2xJDU7NbUgtSi+qDQntfgQIxMHp1QD4/K/2ywULjNF J/c1tR34+XHPwesqf8R+CXKnBqvtvvSmq/fqhY/HVz0sX3p92xHHeNXvRp8mHCvRqMpMn85v X6n9TZv72d6yoL26MbYBNdPS+UyjH3vm/Fh0b3rGi/2Xfb/5L5dqapXQ/NLmVnY8/5zHdqa4 2k9XF+zMT0s1y7odnPcunMVhixJLcUaioRZzUXEiAJXl2sxsAgAA X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrDLMWRmVeSWpSXmKPExsUiuLpBUTdr5aFIg6ZTrBb/P+xmtNhz6Ciz xdF1X9gtViw5xGbxfvFxZgdWjzXz1jB6zLp/ls3jzrU9bB7ds/+xeGx8t4MpgDWKyyYlNSez LLVI3y6BK+PkZI2CDwIVHW2nGBsY9/F2MXJySAiYSDw6c4uti5GLQ0jgEKPEjnkTmEESvAKC Ej8m32PpYuTgYBaQlzh4XhYkzCygJfH9USsLRP1XRomFM16zgSSEBcQl3p3ZxAxh20r82NLD AmKzCShLrJj/gR1kDqdAsMSGN14gYRYBVYlPX3uZQeYwC5xllGj484MNYq+NxJeN05ghFpxm l5h95wFYs4iAnkRLlxnE0bISt2ZfYp7AKDALyamzEE6dheTUBYzMqxgFi1JzEiuNjPQSCwpy UvWS83M3MULCOH0H45GbZocYBTgYlXh4A6wORgqxJpYVV+YCA4ODWUmE9+SKQ5FCvCmJlVWp RfnxRaU5qcWHGKU5WJTEeYVnAlULpCeWpGanphakFsFkmTg4pRoY47cF1T9/t3aLzwHNu4Fb VnXoZv6VTPDcJLeHkev62q4q+fATGVXbGxsOX7/l4ZHdkM7oLXTsuvrL9985jFett//h8yFh +qsDsrdbn6+y1J1y6PP2qZ6mKamrjzwSn81snyQTadXr+vThXKkvP6ftn/YzpnrO9qUnOexe n+xkqc+R+BIVfXffQyWW4oxEQy3mouJEAOYqvbtfAgAA Subject: Re: Storing Non volatile variables on SD/NAND X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.22 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 20 Sep 2017 17:43:13 -0000 Content-transfer-encoding: 7BIT Content-type: text/plain; CHARSET=US-ASCII > On Sep 20, 2017, at 10:39 AM, Ard Biesheuvel wrote: > > On 20 September 2017 at 10:39, Ard Biesheuvel wrote: >> On 20 September 2017 at 10:34, Udit Kumar wrote: >>> >>> When we want to have UEFI and OS accessing same media , >>> Possibilities I see >>> >>> 1- Patch OS For status check of media (diversion from generic OS), Good case will be modify low level driver. >>> But we may end up some surprises on synchronization. >>> >>> 2- no runtime service for OS . I guess this will not be possible >>> >>> 3- Way the Vladimir implemented for eMMC, This has risk of losing data in case of AC power off. >>> >>> 4- update hardware with dual view (Ard suggestion) >>> >> >> 5 - abstract direct block device access into a firmware service that >> is exposed via a DXE_RUNTIME_DRIVER. >> >> The UEFI spec allows you to expose entry points into a >> DXE_RUNTIME_DRIVER module via a UEFI configuration table, and the OS >> can use a driver that uses the abstracted device rather than the real >> device. Performance is going to be terrible, probably, and lots of >> things that are specific to SD/MMC will no longer work, but it is a >> possibility nonetheless. > > BTW this would go beyond the UEFI spec, and would effectively be a > PI/UEFI dependent feature. The concept of a runtime EFI driver is in the UEFI spec, but the issue is there is no way to tell the OS to not bind it's driver for that device that is universal. If you boot an unmodified OS it is going to conflict with the EFI runtime service. My gut feel is if the OS has a driver for the device it may be better to make the media format the architectural point. That way the OS can read/write it via a driver/app. There could be an UEFI Services Table entry that implies what scheme is being used. That way there is only every one owner of the hardware device. I assume #3 is like this? Thanks, Andrew Fish > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel