From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=192.55.52.115; helo=mga14.intel.com; envelope-from=michael.d.kinney@intel.com; receiver=edk2-devel@lists.01.org Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) (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 619ED21959CB2 for ; Fri, 8 Feb 2019 10:00:52 -0800 (PST) X-Amp-Result: SKIPPED(no attachment in message) X-Amp-File-Uploaded: False Received: from orsmga005.jf.intel.com ([10.7.209.41]) by fmsmga103.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 08 Feb 2019 10:00:51 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.58,348,1544515200"; d="scan'208";a="298275860" Received: from orsmsx107.amr.corp.intel.com ([10.22.240.5]) by orsmga005.jf.intel.com with ESMTP; 08 Feb 2019 10:00:50 -0800 Received: from orsmsx151.amr.corp.intel.com (10.22.226.38) by ORSMSX107.amr.corp.intel.com (10.22.240.5) with Microsoft SMTP Server (TLS) id 14.3.408.0; Fri, 8 Feb 2019 10:00:50 -0800 Received: from orsmsx113.amr.corp.intel.com ([169.254.9.97]) by ORSMSX151.amr.corp.intel.com ([169.254.7.44]) with mapi id 14.03.0415.000; Fri, 8 Feb 2019 10:00:50 -0800 From: "Kinney, Michael D" To: Andrew Fish , galla rao , "edk2-devel@lists.01.org" , "Kinney, Michael D" Thread-Topic: [edk2] Hello Andrew query on BdsSetMemoryTypeInformationVariable Thread-Index: AQHUv9TUjn/FGUfHpki3ZIOV3AyVp6XWMLZQ Date: Fri, 8 Feb 2019 18:00:49 +0000 Message-ID: References: In-Reply-To: Accept-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: dlp-product: dlpe-windows dlp-version: 11.0.400.15 dlp-reaction: no-action x-originating-ip: [10.22.254.139] MIME-Version: 1.0 Subject: Re: Hello Andrew query on BdsSetMemoryTypeInformationVariable X-BeenThere: edk2-devel@lists.01.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: EDK II Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 08 Feb 2019 18:00:52 -0000 Content-Language: en-US Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable You can avoid the reboot on the first boot if the HOB is initialized with sizes that match the usage on that specific platform. If you look at the boot logs, you will see messages that show the memory type information table. You can use that information after a couple of boots to see the memory usage and adjust the values used to produce the HOB in PEI. Then rebuild with those new values and the extra reset on first boot should go away. The only time a reboot is required is if the memory usage changes significantly. Mike > -----Original Message----- > From: edk2-devel [mailto:edk2-devel- > bounces@lists.01.org] On Behalf Of Andrew Fish via > edk2-devel > Sent: Friday, February 8, 2019 9:36 AM > To: galla rao ; edk2- > devel@lists.01.org > Subject: Re: [edk2] Hello Andrew query on > BdsSetMemoryTypeInformationVariable >=20 > Forwarding to the edk2 list .... >=20 > > On Feb 8, 2019, at 8:28 AM, galla rao > wrote: > > > > Hi Andrew, > > > > Am sorry for direct message! > > > > There is a function > BdsSetMemoryTypeInformationVariable which causes a > reset > > when i enabled Secureboot related drivers > > > > Any clue why this function is added in EDK2? > > >=20 > Yea it writes a variable that records how many pages of > each memory type are used. This variable is read in PEI > and used to pass a HOB into the DXE Core. The DXE Core > uses these memory buckets to preallocate ranges for > each memory type. This scheme prevents memory > fragmentation and makes sure the runtime memory regions > are in the same location when the system does an S4 > resume from disk. >=20 >=20 > > is this a serious error, making the > PcdResetOnMemoryTypeInformationChange to FALSE will > resolve and boots to OS > > >=20 > I think the idea behind that reboot, is the memory map > could be different on the next boot and if that was an > S4 the S4 could fail. >=20 > Thanks, >=20 > Andrew Fish >=20 >=20 > > shed some knowledge if you are aware of this feature > > > > Thanks & Regards > > Galla >=20 > _______________________________________________ > edk2-devel mailing list > edk2-devel@lists.01.org > https://lists.01.org/mailman/listinfo/edk2-devel