From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received-SPF: Pass (sender SPF authorized) identity=mailfrom; client-ip=209.132.183.28; helo=mx1.redhat.com; envelope-from=lersek@redhat.com; receiver=edk2-devel@lists.01.org Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) (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 BF90921139F70 for ; Mon, 17 Sep 2018 09:38:23 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 47087317C3E8; Mon, 17 Sep 2018 16:38:23 +0000 (UTC) Received: from lacos-laptop-7.usersys.redhat.com (ovpn-120-227.rdu2.redhat.com [10.10.120.227]) by smtp.corp.redhat.com (Postfix) with ESMTP id 3FBBF17C5F; Mon, 17 Sep 2018 16:38:21 +0000 (UTC) To: "Duran, Leo" , "Ni, Ruiyu" , "edk2-devel@lists.01.org" Cc: "Dong, Eric" References: <1536680498-6554-1-git-send-email-leo.duran@amd.com> <1536680498-6554-2-git-send-email-leo.duran@amd.com> <17c6d6d1-2655-fe06-a8b9-f48141bfb0d7@redhat.com> <610eaa55-c87b-5e0c-4f87-5c1e79ffc5ba@redhat.com> <12abd990-3b08-9159-e7a9-ffd7eb7282b3@redhat.com> <734D49CCEBEEF84792F5B80ED585239D5BE07168@SHSMSX104.ccr.corp.intel.com> <981751ac-68a0-ea2c-7985-2562d1916560@Intel.com> From: Laszlo Ersek Message-ID: <85b907c0-1d7d-98f1-6e86-6bb3a3f86ffb@redhat.com> Date: Mon, 17 Sep 2018 18:38:20 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.41]); Mon, 17 Sep 2018 16:38:23 +0000 (UTC) Subject: Re: [PATCH] UefiCpuPkg/MtrrLib: Add flag to skip disabling MTRRs prior to MTRR change. 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: Mon, 17 Sep 2018 16:38:23 -0000 Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit On 09/17/18 18:20, Duran, Leo wrote: > >> -----Original Message----- >> From: Ni, Ruiyu >> Sent: Thursday, September 13, 2018 11:44 PM >> To: Duran, Leo ; Laszlo Ersek ; >> edk2-devel@lists.01.org >> Cc: Dong, Eric >> Subject: Re: [edk2] [PATCH] UefiCpuPkg/MtrrLib: Add flag to skip disabling >> MTRRs prior to MTRR change. >> >> On 9/14/2018 3:31 AM, Duran, Leo wrote: >>> >>> >>>> -----Original Message----- >>>> From: Ni, Ruiyu >>>> Sent: Wednesday, September 12, 2018 9:39 PM >>>> To: Duran, Leo ; Laszlo Ersek >> ; >>>> edk2-devel@lists.01.org >>>> Cc: Dong, Eric >>>> Subject: RE: [PATCH] UefiCpuPkg/MtrrLib: Add flag to skip disabling >>>> MTRRs prior to MTRR change. >>>> >>>> Leo, >>>> Sorry I was in leave yesterday so didn't see the mail. >>>> Which MSRs are shared? Only the >> MSR_IA32_MTRR_DEF_TYPE_REGISTER? >>>> Or all the MSRs that configures the CPU MTRR setting? >>>> >>> >>> Hi Ray, >>> The MTTR config MSRs are also shared by threads within a core. >>> >> >> Hi Leo, >> Do you think that fixing the caller is more proper? > > Hi Ray, > Actually, > The proposed PCD is the simplest solution, as that works for us and does not change the existing (default) flow. > > That is, > I'd prefer making a decision about the PCD in platform-specific code, rather than introducing complex detection and heuristics at the caller level in EDK2 (just for AMD). > > So, please approve the PCD. - From my side, if it works for you, it works for me. (The general trend has been to avoid adding more PCDs to the "core" package DEC files, but I'm 100% neutral on that.) Laszlo