From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) (using TLSv1 with cipher CAMELLIA256-SHA (256/256 bits)) (No client certificate requested) by ml01.01.org (Postfix) with ESMTPS id 6B4CE1A1E6B for ; Wed, 19 Oct 2016 18:50:48 -0700 (PDT) Received: from fmsmga005.fm.intel.com ([10.253.24.32]) by orsmga102.jf.intel.com with ESMTP; 19 Oct 2016 18:50:48 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.31,516,1473145200"; d="scan'208";a="21541746" Received: from fmsmsx108.amr.corp.intel.com ([10.18.124.206]) by fmsmga005.fm.intel.com with ESMTP; 19 Oct 2016 18:50:48 -0700 Received: from fmsmsx123.amr.corp.intel.com (10.18.125.38) by FMSMSX108.amr.corp.intel.com (10.18.124.206) with Microsoft SMTP Server (TLS) id 14.3.248.2; Wed, 19 Oct 2016 18:50:47 -0700 Received: from shsmsx103.ccr.corp.intel.com (10.239.4.69) by fmsmsx123.amr.corp.intel.com (10.18.125.38) with Microsoft SMTP Server (TLS) id 14.3.248.2; Wed, 19 Oct 2016 18:50:47 -0700 Received: from shsmsx102.ccr.corp.intel.com ([169.254.2.206]) by SHSMSX103.ccr.corp.intel.com ([169.254.4.139]) with mapi id 14.03.0248.002; Thu, 20 Oct 2016 09:50:45 +0800 From: "Zeng, Star" To: "Kinney, Michael D" , Andrew Fish , Sean Brogan , "Kinney, Michael D" CC: "edk2-devel@lists.01.org" , "Zhu, Yonghong" , "Gao, Liming" , "Zeng, Star" Thread-Topic: [edk2] question about a compressed Ffs3 file inside FFS2 filesystem Thread-Index: AdIqXbpOUluo4wLNRc25Lw1FgoagF///go0AgAAFngCAAANbgIAAAPGA//9gpGA= Date: Thu, 20 Oct 2016 01:50:44 +0000 Message-ID: <0C09AFA07DD0434D9E2A0C6AEB0483103958F7B0@shsmsx102.ccr.corp.intel.com> References: <35C6824F-AF9E-45D2-B380-17E9547411F1@apple.com> In-Reply-To: Accept-Language: zh-CN, en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [10.239.127.40] MIME-Version: 1.0 Subject: Re: question about a compressed Ffs3 file inside FFS2 filesystem X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 20 Oct 2016 01:50:48 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable As I remember, the parent FV file system type will inherit the file system = type of child file or even child FV in guided section. See r2612 at https://svn.code.sf.net/p/edk2-buildtools/code/trunk/BaseTools= / that is the original BaseTools development trunk. Which revision of BaseTools is being used? The behavior has been changed re= cently? Thanks, Star -----Original Message----- From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of Kinn= ey, Michael D Sent: Thursday, October 20, 2016 8:15 AM To: Andrew Fish ; Sean Brogan ;= Kinney, Michael D Cc: edk2-devel@lists.01.org Subject: Re: [edk2] question about a compressed Ffs3 file inside FFS2 files= ystem Sean, I agree this seems like a reasonable scenario. Looks like the BaseTools allows generation of this content and the FW code = does not support unwrapping it, so there is a mismatch. Please enter a Bugzilla issue for this and we can investigate further. Mike > -----Original Message----- > From: edk2-devel [mailto:edk2-devel-bounces@lists.01.org] On Behalf Of=20 > Andrew Fish > Sent: Thursday, October 20, 2016 8:12 AM > To: Sean Brogan > Cc: edk2-devel@lists.01.org > Subject: Re: [edk2] question about a compressed Ffs3 file inside FFS2=20 > filesystem >=20 >=20 > > On Oct 19, 2016, at 4:59 PM, Sean Brogan wr= ote: > > > > Yes. I think the challenge in the code is the compressed section is=20 > > a guided > section and the decompression is all handled transparently. > > One solution might be that once a section was processed that had=20 > > attributes of > EFI_GUIDED_SECTION_PROCESSING_REQUIRED then the check for filesystems=20 > should no longer be performed. > > >=20 > That seems reasonable. Lets see what other people think. >=20 > We can also, independently, bring it up at the UEFI Forum to see if we=20 > need to clarify the PI spec. >=20 > Thanks, >=20 > Andrew Fish >=20 > > Thanks > > Sean > > > > > >> -----Original Message----- > >> From: afish@apple.com [mailto:afish@apple.com] > >> Sent: Wednesday, October 19, 2016 4:40 PM > >> To: Sean Brogan > >> Cc: edk2-devel@lists.01.org > >> Subject: Re: [edk2] question about a compressed Ffs3 file inside=20 > >> FFS2 filesystem > >> > >> > >>> On Oct 19, 2016, at 4:09 PM, Sean Brogan=20 > >>> > >> wrote: > >>> > >>> We have a condition that occurs when we boot where we see the=20 > >>> following > >> message and our boot fails because of it. > >>> DEBUG ((EFI_D_ERROR, "Found a FFS3 formatted section in a non-FFS3=20 > >>> formatted FV.\n")); > >>> > >>> Which is on line 773 of FwVol.c ( > >>> > >> https://github.com/tianocore/edk2/blob/master/MdeModulePkg/Core/Pei > >> / > >> Fw > >>> Vol/FwVol.c ) > >>> > >>> The condition is caused by a large firmware volume (greater than=20 > >>> 16mb) > >> that is compressed and put into a smaller FV (less than 16mb). My=20 > >> question is why isn't this allowed (seems like a valid scenario). =20 > >> Volinfo supports this and decodes binary fine. The PI Vol 3 spec=20 > >> has a section 3.2.2 EFI_FIRMWARE_FILE_SYSTEM3_GUID which says=20 > >> FileSystem2 doesn't support large files but it seems that the code=20 > >> is not taking into account that the section is compressed and=20 > >> therefore you can have a large file inside a compressed section inside= a FV with File System2. > >>> > >>> Feedback/thoughts/comments/Bug? > >>> > >> > >> Sean, > >> > >> If I understand correctly you are stating that the contents of an=20 > >> Encapsulation section should not have any restrictions on content=20 > >> type. The only error checking should be that the raw encapsulation=20 > >> section data needs to fit into the file type. That seems reasonable=20 > >> to me? I'm not sure if the PI spec makes some statement that the=20 > >> code is enforcing, or I guess the PI spec could be vague and people ar= e interpreting it differently. > >> > >> Thanks, > >> > >> Andrew Fish > >> > >>> Here are some details of my scenario. > >>> Compressed FV has filesystem =3D=3D=20 > >>> 8c8ce578-8a3d-4f1c-9935-896185c32dd3 > >>> (ffs3) Non compressed FV has filesystem =3D=3D=20 > >>> 5473c07a-3dcb-4dca-bd6f-1e9689e7349a (ffs2) > >>> > >>> VolInfo dump of the Non Compressed FV showing the=20 > >>> nested/compressed > >> FV inside. > >>> > >>> Decoding > >>> VolInfo Version 1.0 Build Build 20909 > >>> Signature: _FVH (4856465F) > >>> Attributes: 4FEFF > >>> EFI_FVB2_READ_DISABLED_CAP > >>> EFI_FVB2_READ_ENABLED_CAP > >>> EFI_FVB2_READ_STATUS > >>> EFI_FVB2_WRITE_DISABLED_CAP > >>> EFI_FVB2_WRITE_ENABLED_CAP > >>> EFI_FVB2_WRITE_STATUS > >>> EFI_FVB2_LOCK_CAP > >>> EFI_FVB2_LOCK_STATUS > >>> EFI_FVB2_STICKY_WRITE > >>> EFI_FVB2_MEMORY_MAPPED > >>> EFI_FVB2_ERASE_POLARITY > >>> EFI_FVB2_READ_LOCK_CAP > >>> EFI_FVB2_READ_LOCK_STATUS > >>> EFI_FVB2_WRITE_LOCK_CAP > >>> EFI_FVB2_WRITE_LOCK_STATUS > >>> EFI_FVB2_ALIGNMENT_16 > >>> EFI_FVB2_ALIGNMENT_32 > >>> EFI_FVB2_ALIGNMENT_64 > >>> EFI_FVB2_ALIGNMENT_128 > >>> EFI_FVB2_ALIGNMENT_4K > >>> EFI_FVB2_ALIGNMENT_8K > >>> EFI_FVB2_ALIGNMENT_16K > >>> EFI_FVB2_ALIGNMENT_32K > >>> EFI_FVB2_ALIGNMENT_1M > >>> EFI_FVB2_ALIGNMENT_2M > >>> EFI_FVB2_ALIGNMENT_4M > >>> EFI_FVB2_ALIGNMENT_8M > >>> EFI_FVB2_ALIGNMENT_256M > >>> EFI_FVB2_ALIGNMENT_512M > >>> EFI_FVB2_ALIGNMENT_1G > >>> EFI_FVB2_ALIGNMENT_2G > >>> Header Length: 0x00000048 > >>> File System ID: 5473c07a-3dcb-4dca-bd6f-1e9689e7349a > >>> Revision: 0x0002 > >>> Number of Blocks: 0x00000028 > >>> Block Length: 0x00010000 > >>> Total Volume Size: 0x00280000 > >>> > >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > >> =3D=3D > >>> File Name: 9E21FD93-9C72-4C15-8C4B-E77F1DB2D792 > >>> File Offset: 0x00000048 > >>> File Length: 0x001F3FFD > >>> File Attributes: 0x00 > >>> File State: 0xF8 > >>> EFI_FILE_DATA_VALID > >>> File Type: 0x0B EFI_FV_FILETYPE_FIRMWARE_VOLUME_IMAGE > >>> ------------------------------------------------------------ > >>> Type: EFI_SECTION_GUID_DEFINED > >>> Size: 0x001F3FE5 > >>> SectionDefinitionGuid: ee4e5898-3914-4259-9d6e-dc7bd79403cf > >>> > >>> DataOffset: 0x0018 > >>> Attributes: 0x0001 > >>> ------------------------------------------------------------ > >>> Type: EFI_SECTION_RAW > >>> Size: 0x00000FF8 > >>> ------------------------------------------------------------ > >>> Type: EFI_SECTION_FIRMWARE_VOLUME_IMAGE > >>> Size: 0x01010008 > >>> > >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D > >> =3D=3D > >>> > >>> Thanks > >>> Sean > >>> _______________________________________________ > >>> edk2-devel mailing list > >>> edk2-devel@lists.01.org > >>> https://lists.01.org/mailman/listinfo/edk2-devel > > > > _______________________________________________ > > edk2-devel mailing list > > edk2-devel@lists.01.org > > https://lists.01.org/mailman/listinfo/edk2-devel >=20 > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel _______________________________________________ edk2-devel mailing list edk2-devel@lists.01.org https://lists.01.org/mailman/listinfo/edk2-devel