From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 574A3C433FE for ; Fri, 11 Nov 2022 22:08:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234532AbiKKWIn (ORCPT ); Fri, 11 Nov 2022 17:08:43 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40224 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234527AbiKKWIH (ORCPT ); Fri, 11 Nov 2022 17:08:07 -0500 Received: from mail.zytor.com (unknown [IPv6:2607:7c80:54:3::138]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C632788559; Fri, 11 Nov 2022 14:07:36 -0800 (PST) Received: from [127.0.0.1] ([73.223.250.219]) (authenticated bits=0) by mail.zytor.com (8.17.1/8.17.1) with ESMTPSA id 2ABM79Ie1232560 (version=TLSv1.3 cipher=TLS_AES_128_GCM_SHA256 bits=128 verify=NO); Fri, 11 Nov 2022 14:07:09 -0800 DKIM-Filter: OpenDKIM Filter v2.11.0 mail.zytor.com 2ABM79Ie1232560 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=zytor.com; s=2022110601; t=1668204430; bh=qiOQuHaGOzvrf8e0omxIQW2OX158BWNc3RVEXRzilII=; h=Date:From:To:CC:Subject:In-Reply-To:References:From; b=FpzBJKmRL7vLt1n0fTRXI/3MnL6r/SLyWOXChBzaiYC02z4cW1rUisXtZbIUc1F2Y lcE8KLkxje0L9FOhPALFGd4sc8s9mobABzWcwXvUWCJQiw4wk31c8TzdsRhDAZHPcA wWd/F9/UUdxF/TPOFhB/fbxEwqXuGpJdZKtRf3lzKDQY6bfxNgSD1LzuMEkIl3MCaJ YVSLC9jrYc4WRvwWWjlb/biHXzG3cL519UDQIVgBR8mxijnJtUd1ckroyhThW1rDr+ lT1Tk/iikZdR9/I/ARUFTEQm2To7+HbVqHQqKOYz1CaAuYVWxMrsvPAAkLZPczDE3V sR9Yc0jANWYUA== Date: Fri, 11 Nov 2022 14:07:05 -0800 From: "H. Peter Anvin" To: "Li, Xin3" , Peter Zijlstra CC: "linux-kernel@vger.kernel.org" , "x86@kernel.org" , "kvm@vger.kernel.org" , "tglx@linutronix.de" , "mingo@redhat.com" , "bp@alien8.de" , "dave.hansen@linux.intel.com" , "Christopherson,, Sean" , "pbonzini@redhat.com" , "Tian, Kevin" Subject: =?US-ASCII?Q?RE=3A_=5BRESEND_PATCH_2/6=5D_x86/traps=3A_add_a_system?= =?US-ASCII?Q?_interrupt_table_for_system_interrupt_dispatch?= User-Agent: K-9 Mail for Android In-Reply-To: References: <20221110061545.1531-1-xin3.li@intel.com> <20221110061545.1531-3-xin3.li@intel.com> Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On November 10, 2022 11:55:22 AM PST, "Li, Xin3" wr= ote: >> > Signed-off-by: H=2E Peter Anvin (Intel) >> > Signed-off-by: Xin Li >>=20 >> This is not a valid SOB, it would suggest hpa is the author, but he's n= ot in in >> From=2E > >HPA wrote the initial dispatch code for FRED, and I worked with him to >refactor it for KVM/VMX NMI/IRQ dispatch=2E So use SOB from both=2E No? > >> > diff --git a/arch/x86/kernel/traps=2Ec b/arch/x86/kernel/traps=2Ec in= dex >> > 178015a820f0=2E=2E95dd917ef9ad 100644 >> > --- a/arch/x86/kernel/traps=2Ec >> > +++ b/arch/x86/kernel/traps=2Ec >> > @@ -1444,6 +1444,61 @@ DEFINE_IDTENTRY_SW(iret_error) } #endif >> > >> > +#define SYSV(x,y) [(x) - FIRST_SYSTEM_VECTOR] =3D >> > +(system_interrupt_handler)y >> > + >> > +#pragma GCC diagnostic push >> > +#pragma GCC diagnostic ignored "-Wcast-function-type" >>=20 >> How does this not break CFI ? > >I wasn't aware of it, will check=2E > It doesn't break CFI because the arguments passed is always a strict super= set of the ones expected and they are free enough that they are always pass= ed in registers=2E