Received: by 2002:a25:868d:0:0:0:0:0 with SMTP id z13csp1368273ybk; Thu, 14 May 2020 07:20:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJz+R/28k340s+i7gOfP2FGfGQZ8eJRw9jligQjPaiOcDaAD6VgJocKPkVUgWDjH1Iy7xIbJ X-Received: by 2002:a50:dac4:: with SMTP id s4mr3989803edj.277.1589466021264; Thu, 14 May 2020 07:20:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1589466021; cv=none; d=google.com; s=arc-20160816; b=zv4/sENWD6Y9RM8m8IovyYSujk5ML8dB7iFRKGGmDUffNXW8RIsP/be7MhqpE0vmik k6ixJTAOvtbzKRCUPCnqJoUZ1wn9NyOYSnlLi8PEWCAIMIb7/g1SnY32pR/5/5pqXWmz qcJIVCZd0iU4qTJlvjxEUhhGfcvvnAk0wMHqx05gFQBTPVHtxc6ElLr20cV3IkPToO7C +LDoI/xT1uFxY+FVJn0VIYZwavrChP6NIIO7PrtR7Vg0ulJ+hxJyzRFGe8cKPHPLeJ1T E3ja6xcK4yTfhqR0nklJVLdFrSiW59229ofXREW4k6NNjZCb9FxSepDmrDXRb4ClBhVV DUeg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=j3imiznRcTcesSved9eAcuXC+pa5ngT+M54jGjyJhLM=; b=eKoeG1pgwaeDNr5DzJiy4gfbA8ru+/8n0RXsNmseO1+p5jVc91oTYBADAOo7EhGvGU /yjY9CiTk8gQC1HLVyLXJWbD/wMTvp11MjbHJK2uY9F93ZC+3hnFsgOt/rseiEXWCr22 xAKl1Ac3J5uepQ+VIQzb/JHbgAl9/vEtH2TO8dnIqM5ZD3n9GocDqxX1zGxevl/yrA/W YaAnbJpkmxOQM6qD8FTYqJqGUZ2XSXgoaf4oiJLfwntjmlfFPp4TBeL8bD8kCk4glcpx Iqi7/7dduOWR0P1d7gohFZ8jxferyB8eCQtvVocNm5ffhID67MfZJpVInty8ADLzns2B 5d6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b="B/sOjEXB"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id dk23si1613462edb.282.2020.05.14.07.19.56; Thu, 14 May 2020 07:20:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@alien8.de header.s=dkim header.b="B/sOjEXB"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=alien8.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726232AbgENOQY (ORCPT + 99 others); Thu, 14 May 2020 10:16:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33338 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726050AbgENOQY (ORCPT ); Thu, 14 May 2020 10:16:24 -0400 Received: from mail.skyhub.de (mail.skyhub.de [IPv6:2a01:4f8:190:11c2::b:1457]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 5D826C061A0C for ; Thu, 14 May 2020 07:16:24 -0700 (PDT) Received: from zn.tnic (p200300EC2F0BBD00DC45039F589BC722.dip0.t-ipconnect.de [IPv6:2003:ec:2f0b:bd00:dc45:39f:589b:c722]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.skyhub.de (SuperMail on ZX Spectrum 128k) with ESMTPSA id C712A1EC015C; Thu, 14 May 2020 16:16:20 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=alien8.de; s=dkim; t=1589465780; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:in-reply-to:in-reply-to: references:references; bh=j3imiznRcTcesSved9eAcuXC+pa5ngT+M54jGjyJhLM=; b=B/sOjEXBhpV8YUWlTypNzQpxGaJEb+QBrJu20oiBM46w2rubcez3+gujWhltnAg1yO1hJH 6ejjyRDTpkAijOAKrYplYMaETfO8SM7zo2tHNEsK4YAdaZE1PvsxDjeK7J7c/NKpDmn/X+ no9h/n9PzV0+H3MuI9UoTo6uqEcD+PA= Date: Thu, 14 May 2020 16:16:16 +0200 From: Borislav Petkov To: Andy Lutomirski Cc: Thomas Gleixner , LKML , X86 ML , "Paul E. McKenney" , Alexandre Chartre , Frederic Weisbecker , Paolo Bonzini , Sean Christopherson , Masami Hiramatsu , Petr Mladek , Steven Rostedt , Joel Fernandes , Boris Ostrovsky , Juergen Gross , Brian Gerst , Mathieu Desnoyers , Josh Poimboeuf , Will Deacon , "Peter Zijlstra (Intel)" Subject: Re: [patch V4 part 1 29/36] x86/mce: Send #MC singal from task work Message-ID: <20200514141616.GC9266@zn.tnic> References: <20200505131602.633487962@linutronix.de> <20200505134100.957390899@linutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, May 07, 2020 at 11:02:09AM -0700, Andy Lutomirski wrote: > IOW, if we want to recover from CPL0 #MC, we will need a different mechanism. Recovering from CPL0 #MC is mostly doomed to failure. Except this mcsafe crap with the exception handling: /* * Handle an MCE which has happened in kernel space but from * which the kernel can recover: ex_has_fault_handler() has * already verified that the rIP at which the error happened is * a rIP from which the kernel can recover (by jumping to * recovery code specified in _ASM_EXTABLE_FAULT()) and the * corresponding exception handler which would do that is the * proper one. */ if (m.kflags & MCE_IN_KERNEL_RECOV) { if (!fixup_exception(regs, X86_TRAP_MC, error_code, 0)) mce_panic("Failed kernel mode recovery", &m, msg); Other than that, we iz done. -- Regards/Gruss, Boris. https://people.kernel.org/tglx/notes-about-netiquette