Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754035AbbEAOyb (ORCPT ); Fri, 1 May 2015 10:54:31 -0400 Received: from mail-by2on0141.outbound.protection.outlook.com ([207.46.100.141]:46080 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753824AbbEAOy2 (ORCPT ); Fri, 1 May 2015 10:54:28 -0400 Authentication-Results: spf=none (sender IP is 165.204.84.222) smtp.mailfrom=amd.com; alien8.de; dkim=none (message not signed) header.d=none; X-WSS-ID: 0NNOEQL-08-VEP-02 X-M-MSG: Message-ID: <5543939B.9020507@amd.com> Date: Fri, 1 May 2015 09:54:19 -0500 From: Aravind Gopalakrishnan User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:31.0) Gecko/20100101 Thunderbird/31.6.0 MIME-Version: 1.0 To: Borislav Petkov CC: , , , , , , , , , , , , , , , , , , , , , , Subject: Re: [PATCH 1/4] x86/mce: Define 'SUCCOR' cpuid bit References: <1430405365-4473-1-git-send-email-Aravind.Gopalakrishnan@amd.com> <1430405365-4473-2-git-send-email-Aravind.Gopalakrishnan@amd.com> <20150501102508.GL10239@pd.tnic> In-Reply-To: <20150501102508.GL10239@pd.tnic> Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [10.180.168.240] X-EOPAttributedMessage: 0 X-Forefront-Antispam-Report: CIP:165.204.84.222;CTRY:US;IPV:NLI;EFV:NLI;SFV:NSPM;SFS:(10019020)(6009001)(428002)(189002)(24454002)(377454003)(199003)(51704005)(479174004)(164054003)(47776003)(62966003)(87936001)(76176999)(54356999)(65816999)(99136001)(64126003)(36756003)(50986999)(50466002)(105586002)(106466001)(86362001)(77156002)(77096005)(33656002)(101416001)(80316001)(83506001)(46102003)(23676002)(5001920100001)(65956001)(120886001)(92566002)(110136002)(2950100001)(59896002)(4580500001);DIR:OUT;SFP:1102;SCL:1;SRVR:BY1PR02MB1115;H:atltwp02.amd.com;FPR:;SPF:None;MLV:sfv;MX:1;A:1;LANG:en; X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY1PR02MB1115;UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY1PR02MB1161; X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(5005006)(3002001);SRVR:BY1PR02MB1115;BCL:0;PCL:0;RULEID:;SRVR:BY1PR02MB1115; X-Forefront-PRVS: 0563F2E8B7 X-MS-Exchange-CrossTenant-OriginalArrivalTime: 01 May 2015 14:54:23.8074 (UTC) X-MS-Exchange-CrossTenant-Id: fde4dada-be84-483f-92cc-e026cbee8e96 X-MS-Exchange-CrossTenant-OriginalAttributedTenantConnectingIp: TenantId=fde4dada-be84-483f-92cc-e026cbee8e96;Ip=[165.204.84.222];Helo=[atltwp02.amd.com] X-MS-Exchange-CrossTenant-FromEntityHeader: HybridOnPrem X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR02MB1115 X-OriginatorOrg: amd4.onmicrosoft.com Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1456 Lines: 45 On 5/1/2015 5:25 AM, Borislav Petkov wrote: > On Thu, Apr 30, 2015 at 09:49:22AM -0500, Aravind Gopalakrishnan wrote: >> SUCCOR stands for S/W UnCorrectable error COntainment and Recovery. >> It indicates support for data poisoning in HW and deferred error >> interrupts. >> >> >> >> struct mce_vendor_flags { >> __u64 overflow_recov : 1, /* cpuid_ebx(80000007) */ >> - __reserved_0 : 63; >> + succor : 1, > Please add that CPUID bit definition from the commit message here too so > that we know what it means. Will do. Shall I beef up comment regarding 'overflow_recov' too? Something like 'overflow recovery cpuid bit indicates that overflow conditions are not fatal' would provide a better indication of the usage of the bit IMHO. >> case X86_VENDOR_AMD: >> mce_amd_feature_init(c); >> mce_flags.overflow_recov = cpuid_ebx(0x80000007) & 0x1; >> + mce_flags.succor = (cpuid_ebx(0x80000007) & 0x2) ? 1 : 0; > mce_flags.succor = !!(cpuid_ebx(0x80000007) & BIT(1)); > > is a common way of assigning truth values from bits in the kernel. > > You can change the above one to use BIT(0) too, while at it, and > vertically align the assignments. > > Ok, Will do. Thanks, -Aravind. -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/