[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH v3] x86/amd: Address AMD erratum #1485
- To: Andrew Cooper <andrew.cooper3@xxxxxxxxxx>
- From: Roger Pau Monné <roger.pau@xxxxxxxxxx>
- Date: Tue, 17 Oct 2023 11:13:39 +0200
- Arc-authentication-results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=citrix.com; dmarc=pass action=none header.from=citrix.com; dkim=pass header.d=citrix.com; arc=none
- Arc-message-signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=94uc5/wpCD3aYoQUZNORvAEM7NXrlohsKtpfDYHQohE=; b=XsaTwxOefF5kY+8u8Dz4x9YMZDC0qM/i58xP+XIl0LvGI8rLFhWo2G37vKfMxvNhWjIPQsAlXfmFa7EGIj4K0VluU+PNR5vkc6DTPqSxd6erO/oEdq3liJ+O/3K5HQ8RoVRJ5Es5cQ/lzIANh8ZAPy7RydBe97KSrGkzrHVhR2HPnz17R/N/4y4pkQd50WTSOWm4l3apL6+IaBzk5Il0Pc1hU5ygLRZl0Uyvut1C8DoWcyliOVTJI7t6drOICMe6ZZ4UKmcFtXa6CrA7L/KbyjpBRXcQDHvCGdlWoqXMom/camP9a4tuE5E1xsgJNDoWcmsF9sLvWJDYdV1tAVyK8w==
- Arc-seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=THK2niNKsNT80q6Gj22duidAOHuBTR+HMCj9M8T3mUE14d+uwjDk8TBRBP2Uzi0Y57Hfe8J2iKR+2t19ZOMZ8hjcD/cd860zHmVEdelOHBKtKQngLPC4SNEsiFnmoyWj2+0S21zrukx9z2XWETE4llUWKefoxE+kd0OK1XbtgJVDmmwSQennDzU3YQNJ9cj7IAVfh+tWTifQ3ybDmF+2NbPGuhqRFDJUi91u10p6DsR0H6icx/zcFuEA6BpkscCa/UhjHd4TrwxCAp/JFxUvUVVphpbUKuHken40DqGHFupcXGNuqxBQ/5hMHB5vPkZgFYy2kDeJ5r4T8zhaw+MXmQ==
- Authentication-results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=citrix.com;
- Cc: Jan Beulich <jbeulich@xxxxxxxx>, Alejandro Vallejo <alejandro.vallejo@xxxxxxxxx>, Wei Liu <wl@xxxxxxx>, Henry Wang <Henry.Wang@xxxxxxx>, Xen-devel <xen-devel@xxxxxxxxxxxxxxxxxxxx>
- Delivery-date: Tue, 17 Oct 2023 09:14:09 +0000
- Ironport-data: A9a23:LLq8OqxcZ2b74zTGSyJ6t+fhxyrEfRIJ4+MujC+fZmUNrF6WrkUFy zFLXD+EbviIYmT2LtElPd6/9R8FsJ+Gn4BhHAJr+SAxQypGp/SeCIXCJC8cHc8wwu7rFxs7s ppEOrEsCOhuExcwcz/0auCJQUFUjPzOHvykTrecZkidfCc8IA85kxVvhuUltYBhhNm9Emult Mj75sbSIzdJ4RYtWo4vw/zF8EgHUMja4mtC5QVmPK8T5TcyqlFOZH4hDfDpR5fHatE88t6SH 47r0Ly/92XFyBYhYvvNfmHTKxBirhb6ZGBiu1IOM0SQqkEqSh8ai87XAME0e0ZP4whlqvgqo Dl7WT5cfi9yVkHEsLx1vxC1iEiSN4UekFPMCSDXXcB+UyQq2pYjqhljJBheAGEWxgp4KU9Ur OYXJT49VU2KxL687JupGtFCg+12eaEHPKtH0p1h5RfwKK58BLrlGuDN79Ie2yosjMdTG/qYf 9AedTdkcBXHZVtIJ0sTD5U92uyvgxETcRUB8A7T+fVxvjGVkFUZPLvFabI5fvSQQspYhACAr 3/u9GXlGBAKcteYzFJp91r13LKRwnqhAtp6+LuQxPlwqlO49zMpUj4OX3i3n+iTm2WMRIcKQ 6AT0m90xUQoz2SpRNTgWxyzoFafowURHdFXFoUS4QWAyKPS7xyeQHYNSjpMatsOv8sxWDBs3 ViM9/v2ARR/vbvTTmiSnp+0oDWoKG4qJGkNTSYeSE0O5NyLiJE+iFfDQ8huFIaxj8bpAnfgz jaSti88ir4Py8kR2M2GEUvvhjutot3DSFcz7wCPBGa9tFslPciiepCi7kXd4bBYNoGFQ1Kdv X8C3c+D8OQJCpLLnyuIKAkQIIyUCz++GGW0qTZS81MJrlxBJ1bLkVhs3QxD
- Ironport-hdrordr: A9a23:VV+FCaEO5d7bVPFSpLqE5seALOsnbusQ8zAXPiFKJSC9F/byqy nAppsmPHPP5gr5OktBpTnwAsi9qBrnnPYejLX5Vo3SPzUO1lHYSb1K3M/PxCDhBj271sM179 YFT0GmMqyTMWRH
- List-id: Xen developer discussion <xen-devel.lists.xenproject.org>
On Tue, Oct 17, 2023 at 08:50:45AM +0100, Andrew Cooper wrote:
> On 17/10/2023 8:44 am, Jan Beulich wrote:
> > On 13.10.2023 17:38, Alejandro Vallejo wrote:
> >> Fix adapted off Linux's mailing list:
> >>
> >> https://lore.kernel.org/lkml/D99589F4-BC5D-430B-87B2-72C20370CF57@xxxxxxxxxxxxx/T/#u
> > Why reference the bug report when there's a proper commit (f454b18e07f5)
> > now?
> > Plus in any event a short summary of the erratum would help if put right
> > here
> > (without needing to look up any documents or follow any links).
>
> That is not public information yet. The erratum number alone is the
> best we can do at this juncture.
> >> --- a/xen/arch/x86/cpu/amd.c
> >> +++ b/xen/arch/x86/cpu/amd.c
> >> @@ -1004,6 +1004,28 @@ static void cf_check zen2_disable_c6(void *arg)
> >> wrmsrl(MSR_AMD_CSTATE_CFG, val & mask);
> >> }
> >>
> >> +static void amd_check_erratum_1485(void)
> >> +{
> >> + uint64_t val, chickenbit = (1 << 5);
> > Linux gives the bit a name. Any reason you don't?
>
> There are multiple different names depending on where you look, and none
> are particularly relevant here.
Could we make chickenbit const static?
I would also use ULL just to be on the safe side, because we then copy
this for a different bit and it explodes.
(not strong requirements, but if a resend is needed it would be nice
to have).
Thanks, Roger.
|