Received: by 2002:a89:48b:0:b0:1f5:f2ab:c469 with SMTP id a11csp1145234lqd; Thu, 25 Apr 2024 07:15:36 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCWabmIFcF2sKGH20D2aS2UiszMhuB9sCVZIawrdjLrbTTyglSJ92DRM5t2l5FSKldb9Vq106EjF9L5b2h2bxrP2YiDCwDElCbF3Xacf0A== X-Google-Smtp-Source: AGHT+IHqDcn9FCaxYWsFiWSr92Koaz+BsPf3sVorTeChlnoPZ1vONIKQdBbMAn3E6rIhDjDig/bl X-Received: by 2002:a17:902:d489:b0:1ea:c933:4d95 with SMTP id c9-20020a170902d48900b001eac9334d95mr1677675plg.10.1714054536213; Thu, 25 Apr 2024 07:15:36 -0700 (PDT) Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [139.178.88.99]) by mx.google.com with ESMTPS id e14-20020a170902784e00b001e90418be66si9852582pln.600.2024.04.25.07.15.35 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 25 Apr 2024 07:15:36 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-158669-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) client-ip=139.178.88.99; Authentication-Results: mx.google.com; dkim=pass header.i=@amd.com header.s=selector1 header.b=cbF74ojF; arc=fail (signature failed); spf=pass (google.com: domain of linux-kernel+bounces-158669-linux.lists.archive=gmail.com@vger.kernel.org designates 139.178.88.99 as permitted sender) smtp.mailfrom="linux-kernel+bounces-158669-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amd.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id DDDEC2851F2 for ; Thu, 25 Apr 2024 14:13:26 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 75B92149E0F; Thu, 25 Apr 2024 14:12:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b="cbF74ojF" Received: from NAM12-BN8-obe.outbound.protection.outlook.com (mail-bn8nam12on2068.outbound.protection.outlook.com [40.107.237.68]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 91306149C72; Thu, 25 Apr 2024 14:12:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=fail smtp.client-ip=40.107.237.68 ARC-Seal:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714054374; cv=fail; b=IUR4ZI2x96uXPxfStNnIPfWw5Po28m5CT/vglpdKvhg1yv/gU8uDiPsSzSqWeUgAJVwOGp/C97W6SiicSoCdrHMfy7faAJhmuBfQ2m0NUwmSbjAIc+YkD4QoiG5nYU+l+8FVDvlqI/gF7DzT+gKwH43iO91YhGgIxhpMz7+uZq8= ARC-Message-Signature:i=2; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1714054374; c=relaxed/simple; bh=B6WHt+CH5Hy9yO81kX6Dp7XYlv+MG2xS8PvPmAxCPJ8=; h=Message-ID:Date:Cc:Subject:To:References:From:In-Reply-To: Content-Type:MIME-Version; b=VmvFXJIoHPeEukqX1ZQ6mfAU0rpZwQbbFfX721dTuXo0CXHw8E+FkCgjWkNN9DhvrKFbkl8RxHCZzwmigEccwgwX1knkC/L+tis1AMqQpFSv+rXlRfAWdHyi/nCnGPHuSvmm3Z0IjF11buumwCQFHVEUC19mdd4yc8bnJXi5sSY= ARC-Authentication-Results:i=2; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=amd.com; spf=fail smtp.mailfrom=amd.com; dkim=pass (1024-bit key) header.d=amd.com header.i=@amd.com header.b=cbF74ojF; arc=fail smtp.client-ip=40.107.237.68 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=amd.com Authentication-Results: smtp.subspace.kernel.org; spf=fail smtp.mailfrom=amd.com ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=eWCCckN9NSupOpS7pJa4v2mZz2GrereKaua0F8eqCsJU6FhagvCfMkFzf3dNA7xyU5O0RlVbAUZFNTX82MaabTRuBjLCVdkTNmLh0Bu3dso5aHOccNlsaABEM4PJjnPSAH4wA2RDqHGQj8wO0ETsfRqOn1Jyf2zjcw+emCpZV5jIcSEXq/dHgKlVpylDP3D6ZhV0TncW3Jbh5Hfok2MGDVb9r77BUONQQEigD0o1aBPtC9PbLSDhClMtMMslg8avJwsoiUhK+2kQwaCT2k1Sk/NLUEEyO4GBIdzZgUGq9Ur441KA8ok21ttWSj2CUMu7kPz2Hzf5B3c7J0fsYZE4Ww== 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=bJZ49GcJFAaGr0VugH+a5oJzm9AM9XDTgu1Xhcp0dD4=; b=iqNGYdO3Whx0vg14BEOXxox6xTMfQQpyBazq+5IrcgMdxNeOmEAWWRwa+tRazni+MR0gVAoLgdZdxWrBWrB+83X9xGHDMLdltIuYNnu2qEmCmylVl4zMd9GJlfpWLps5VPU/napRmWM3w4UU1+YPQ8sn8P3AIsnRBgi/RMWreC1EdqlspQ4z1acJDHRq2GvNeke8ptPXCdLhNqRj55LZ8L8Lh7u+lYmpwSJO8GgI8TjBNcCjAw9+In3RNWmaRJdCx7OE6hO+593vqK5fPM1bkubbTgXIqsA9JZu0JLHpQscd6sLt71//kFBpuBYE+swsnRwKC3SUWlj3oizhbNeCyw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=amd.com; dmarc=pass action=none header.from=amd.com; dkim=pass header.d=amd.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amd.com; s=selector1; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=bJZ49GcJFAaGr0VugH+a5oJzm9AM9XDTgu1Xhcp0dD4=; b=cbF74ojF8yiNUxWHtCJ4N/gRqvle1TBWY8+zC+OSZm1QBKocexsfKrvc1Rj5DSMhQPcQmj8KXWHbPN9KHrobeRMvUYoKyedTrS6jErcvZktuWwbQvyb9zH0A0k5YWKLrHAghnvh4uQVh08Vl3/kHiHwWDZvJt3jwGPA++2L86CM= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=amd.com; Received: from BN8PR12MB3108.namprd12.prod.outlook.com (2603:10b6:408:40::20) by MW4PR12MB8612.namprd12.prod.outlook.com (2603:10b6:303:1ec::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.7519.24; Thu, 25 Apr 2024 14:12:48 +0000 Received: from BN8PR12MB3108.namprd12.prod.outlook.com ([fe80::43a5:ed10:64c2:aba3]) by BN8PR12MB3108.namprd12.prod.outlook.com ([fe80::43a5:ed10:64c2:aba3%7]) with mapi id 15.20.7472.044; Thu, 25 Apr 2024 14:12:48 +0000 Message-ID: Date: Thu, 25 Apr 2024 10:12:44 -0400 User-Agent: Mozilla Thunderbird Cc: yazen.ghannam@amd.com, linux-edac@vger.kernel.org, linux-kernel@vger.kernel.org, tony.luck@intel.com, x86@kernel.org, Avadhut.Naik@amd.com, John.Allen@amd.com Subject: Re: [PATCH v2 07/16] x86/mce/amd: Simplify DFR handler setup Content-Language: en-US To: Borislav Petkov , robert.richter@amd.com References: <20240404151359.47970-1-yazen.ghannam@amd.com> <20240404151359.47970-8-yazen.ghannam@amd.com> <20240424190658.GHZilYUvw1KfSfVd_e@fat_crate.local> From: Yazen Ghannam In-Reply-To: <20240424190658.GHZilYUvw1KfSfVd_e@fat_crate.local> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-ClientProxiedBy: BN9PR03CA0216.namprd03.prod.outlook.com (2603:10b6:408:f8::11) To BN8PR12MB3108.namprd12.prod.outlook.com (2603:10b6:408:40::20) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: BN8PR12MB3108:EE_|MW4PR12MB8612:EE_ X-MS-Office365-Filtering-Correlation-Id: c4adc1f8-3aa9-4383-abd2-08dc6531c8fa X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0;ARA:13230031|376005|1800799015|366007; X-Microsoft-Antispam-Message-Info: =?utf-8?B?aEhpRzQrNWxYVGZXa1kwb1ZFZ21FSjJmUnZqWVhRVTVuSnlSeFJWbHBYOG40?= =?utf-8?B?WmZGbXVEZkVCK3lSbXlJWGlsMmcxQjNWemZVL2F4MmZLdXpuVXFTTzM1cTJJ?= =?utf-8?B?bGtzY09udkQ5RUxZSFNDMkluK3A5a0lPZzFlWG1DS01ic3o0RzljRC92SnQx?= =?utf-8?B?S200OVcwUHNaL3d5b3Z3aWxidzh6Q2VodTRsYXhXVGExYkNvQm9mbWFOdHBy?= =?utf-8?B?NWQ3STVUYVVobzhZWWRvZkVGSzVna1MvVXhFK21lT3NJZ0Y4eXJZN3dOOS9t?= =?utf-8?B?eHVCQ0wrM29rbGZTR05iVEwrSktVbkpTcGN2S1NITU5WNFdtUWY5ZFZqL2F4?= =?utf-8?B?UGtvbndINEhGdFZpM1A2ZlNnekpNTFNnQzlmWnhnRW1sM3cxalhFZDdTZFN3?= =?utf-8?B?NWp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VeW1NRXBKbzVm?= =?utf-8?B?OFdMYjFnRTV4cjdwc1JNNlZpL3IzNldJVi9XVXBEVjlqQkFJdHpYcHBGY2da?= =?utf-8?B?MWNBUTRkWkVYakY2aTRKa1phcFRpVjZ1MlhTWWVwcFJMWXFrNlJOdDZveUJB?= =?utf-8?B?dDJ5bG9GeUZ6NkVXYVJCbWF5OHJLUm4vYkVjU0k0U2ErMEEzaUwrSWdSb1k3?= =?utf-8?B?dGFjV3BweGNxa2d1Y1BLWkpUVWRoMG45UStwSUhCYUY4dUJLaW4vdWc4L09a?= =?utf-8?B?MUNQTjdtdllqWVNxQVY2TmVRV3hQN0hXdGkyRit4QVYzTFhWYldhc1FnODBL?= =?utf-8?B?NXNqbk55RGNObzB5M21DMm9QdDFkOUVHTWY5NDVmR0NTUUxZYkpzdjVZVzZv?= =?utf-8?B?d0xKbHZ1d2YzanQ1cWFGNUFGQ0tKalhFSy9XUXN5N3h6VU4vYWhvWXJRPT0=?= X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:BN8PR12MB3108.namprd12.prod.outlook.com;PTR:;CAT:NONE;SFS:(13230031)(376005)(1800799015)(366007);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: =?utf-8?B?M3grVVdpeVFRWDk1T3kxVEQ4bGJlU2J5dXNzL3dXajliUE1ndjVzM3JaMm9T?= =?utf-8?B?VE90UG5ONWVYMDFLY2lsaGxUc1dOZzhCYW1TTDM2SFg5UktsZFluUy9odjZ5?= =?utf-8?B?MEJEVE9Fc0p6aHR0MEd2M1pvMkJJeVg1aGMzWGFzVlEzOFhUSmVFVUdQQnZG?= =?utf-8?B?S1FHRll6cnMrNmpDYXEwTEtwNmx3NHR4VEhpaDRJQWNnMlBrc3hIbk8ySm45?= =?utf-8?B?SktGZHZuTC9CTVNRMy8zVGgzdDFFZHUrZHZx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Gp6dkRlc1JiMFR3U3pKRStiZ01TdkYrMFUyR1JY?= =?utf-8?Q?b1NMAmJpjD3d6FfZWT8p2O6on?= X-OriginatorOrg: amd.com X-MS-Exchange-CrossTenant-Network-Message-Id: c4adc1f8-3aa9-4383-abd2-08dc6531c8fa X-MS-Exchange-CrossTenant-AuthSource: BN8PR12MB3108.namprd12.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 25 Apr 2024 14:12:48.0367 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 3dd8961f-e488-4e60-8e11-a82d994e183d X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: Lr5/UofYqw160LAHKVPfQmL03MYc4klaNxqGxmlCINlxgfVNp5xSqQJ34ArZ7HuXdG3XAnWTZoQRtop9lGKd3w== X-MS-Exchange-Transport-CrossTenantHeadersStamped: MW4PR12MB8612 On 4/24/2024 3:06 PM, Borislav Petkov wrote: > On Thu, Apr 04, 2024 at 10:13:50AM -0500, Yazen Ghannam wrote: >> AMD systems with the SUCCOR feature can send an APIC LVT interrupt for >> deferred errors. The LVT offset is 0x2 by convention, i.e. this is the >> default as listed in hardware documentation. >> >> However, the MCA registers may list a different LVT offset for this >> interrupt. The kernel should honor the value from the hardware. > > There's this "may" thing again. > Right, I should say "the microarchitecture allows it". :) > Is this enablement for some future hw too or do you really trust the > value in MSR_CU_DEF_ERR is programmed correctly in all cases? > I trust the value from hardware. The intention here is to simplify the code for general maintenance and to make later patches easier. >> Simplify the enable flow by using the hardware-provided value. Any >> conflicts will be caught by setup_APIC_eilvt(). Conflicts on production >> systems can be handled as quirks, if needed. > > Well, which systems support succor? > > I'd like to test this on them before we face all the quirkery. :) > All Zen/SMCA systems. I don't recall any issues in this area. Some later Family 15h systems (Carrizo?) had it. But I don't know if it was used in production. It was slightly before my time. > That area has been plagued by hw snafus if you look at > setup_APIC_eilvt() and talk to uncle Robert. :-P > Right, I found this: 27afdf2008da ("apic, x86: Use BIOS settings for IBS and MCE threshold interrupt LVT offsets") Which is basically the same idea: use what is in the register. But it looks there was an issue with IBS on Family 10h. Is this the only case of a real issue? If so, then why apply this method to the THR and DFR interrupts? Robert, were there any other issues? >> @@ -595,17 +584,15 @@ static void deferred_error_interrupt_enable(struct cpuinfo_x86 *c) >> if (rdmsr_safe(MSR_CU_DEF_ERR, &low, &high)) >> return; >> >> + /* >> + * Trust the value from hardware. >> + * If there's a conflict, then setup_APIC_eilvt() will throw an error. >> + */ >> def_new = (low & MASK_DEF_LVTOFF) >> 4; >> - if (!(low & MASK_DEF_LVTOFF)) { >> - pr_err(FW_BUG "Your BIOS is not setting up LVT offset 0x2 for deferred error IRQs correctly.\n"); >> - def_new = DEF_LVT_OFF; >> - low = (low & ~MASK_DEF_LVTOFF) | (DEF_LVT_OFF << 4); >> - } >> + if (setup_APIC_eilvt(def_new, DEFERRED_ERROR_VECTOR, APIC_EILVT_MSG_FIX, 0)) >> + return; >> >> - def_offset = setup_APIC_deferred_error(def_offset, def_new); >> - if ((def_offset == def_new) && >> - (deferred_error_int_vector != amd_deferred_error_interrupt)) >> - deferred_error_int_vector = amd_deferred_error_interrupt; > > There was a reason for that - deferred_error_int_vector is a global var > and you're calling enable_deferred_error_interrupt() on each CPU. > Right, and all CPUs should use the same APIC LVT offset. If they differ, then setup_APIC_eilvt() will fail above and return. Why check "if X != Y, then X = Y"? Why not just unconditionally do "X = Y"? >> + deferred_error_int_vector = amd_deferred_error_interrupt; >> >> if (!mce_flags.smca) >> low = (low & ~MASK_DEF_INT_TYPE) | DEF_INT_TYPE_APIC; > > Thx. > Thanks, Yazen