Received: by 2002:a05:6a10:16a7:0:0:0:0 with SMTP id gp39csp222048pxb; Wed, 11 Nov 2020 01:51:09 -0800 (PST) X-Google-Smtp-Source: ABdhPJz4JVinp1gNleVN6arVV9rvjseEcsTX0izg1DPUonVkJ3Ke16MhELAiX5Hm56Ie4iGXjRAg X-Received: by 2002:a17:906:7e55:: with SMTP id z21mr24074090ejr.154.1605088268816; Wed, 11 Nov 2020 01:51:08 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1605088268; cv=none; d=google.com; s=arc-20160816; b=GRnbfHELMijlPKikBqX+bktmyjcFhU3TRcqkRruc8cbKFfOJ3c/L6Zj9ILZiVNBeEi 3BAWBZ3rGVLK/ZhOKhEXK4Frz+1A8msHC12YWTSyqELclCyPa8KIBmQJAiOQlMG+f8aj IniEfUtREuaewvOBpTkEnfTZYk1R+vVw2A7qXO97KbEWr/qkdbs46gEUBeOzj7L9KkEQ z5qsnBVM1TDEdMjg8ZrEvjad8PvUxgNvoKKSuLH9uNPdNWOWM1p+OZLFUAB9rQ5BXUeG eV3P+2nu/JwCLKbuRH5lDDMsp5crpVktc6czUCwIRh2ujADXpq6aXOwSVvv2H0tCDSbi LyGw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:mime-version:message-id:date:references :in-reply-to:subject:cc:to:dkim-signature:dkim-signature:from; bh=JBGgYpNE48xLdaSx9SJyuRgs17Z12VxMWi2bsgM8DpA=; b=t4udS8mKcGnG/AyGQu0VYzT9CE8UwbiQC54f3EmqUhRojZ5pBceBK2I5LnjoCXpJ0U XOxk/1VRksOlzJ51bnBKdJLiA+i/bW16gN76Nb6VJd/yOQM6nxcM3AfX7krfyidzdKr8 +0qc4N6xKPMfJAF/WyOVnSnstv7Todux4oHtvkuq0VpCh9GF33WFlVnRScWAow6VH44S Fudgt5OaS+Sp9dQAmyOxmojz4mxeMz8hHv5LSK+K+C1PJZcmvYoYPHQlLTp+qLjXK6xM tVjeaifKnr1mO7jUfzCz7wGW3+XbpIZZcKLFohZthqg7ZXBm6RDjAr6lr2YMiUGHSER1 QhaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=JrYegkaT; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; 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=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id rl2si892496ejb.720.2020.11.11.01.50.45; Wed, 11 Nov 2020 01:51:08 -0800 (PST) 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=@linutronix.de header.s=2020 header.b=JrYegkaT; dkim=neutral (no key) header.i=@linutronix.de header.s=2020e; 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=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727065AbgKKJq0 (ORCPT + 99 others); Wed, 11 Nov 2020 04:46:26 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:45738 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725830AbgKKJqZ (ORCPT ); Wed, 11 Nov 2020 04:46:25 -0500 Received: from galois.linutronix.de (Galois.linutronix.de [IPv6:2a0a:51c0:0:12e:550::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 42568C0613D1 for ; Wed, 11 Nov 2020 01:46:25 -0800 (PST) From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1605087983; 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: in-reply-to:in-reply-to:references:references; bh=JBGgYpNE48xLdaSx9SJyuRgs17Z12VxMWi2bsgM8DpA=; b=JrYegkaT2uptksIpDgutFBjIzBimCAGccgf49XznMd+eIHWWMHBsn6a9BV4AuM1CuzEV0X sJpQE9UMam8/paR3LWytzkUuLasRXgusQNIlzAD/BThHLicM2AYUGMob2buUzHpHA98R0e TqPxWCRqP0A8ce4DZdzE1piJqo9tvBQBm4j1kOqLG9fDX330Tmh9QvxhotlaNkibJWg8+j hBpGZpN5AS4ykTcfpATYSpYdmz0UvL0vWOl2IiNwhI6ufh1FqO0lyF6AjWaOCKEU/VpxvT XMqb6vffoMTXoKay0NauNpsbOCYugZvKQbE7d3l+k+Pw6Dlccp/NF8dCI7pu3Q== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1605087983; 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: in-reply-to:in-reply-to:references:references; bh=JBGgYpNE48xLdaSx9SJyuRgs17Z12VxMWi2bsgM8DpA=; b=mI/NXhm0h/Xc76FRp2LRKgSfTCSZKE3YqHkx2p/gho1GEJaYeThhJa0uNBdVg0lYTD5+LU ugksbj9jSSQ1YXBA== To: David Woodhouse , Tom Lendacky , Borislav Petkov Cc: linux-kernel@vger.kernel.org, x86 , Qian Cai , Joerg Roedel Subject: Re: [EXTERNAL] [tip: x86/apic] x86/io_apic: Cleanup trigger/polarity helpers In-Reply-To: <5c86570ce3bedb90514bc1e73b96011660f520b0.camel@infradead.org> References: <20201024213535.443185-20-dwmw2@infradead.org> <160397373817.397.3191135882528008704.tip-bot2@tip-bot2> <20201110061046.GA7290@nazgul.tnic> <87d00lgu13.fsf@nanos.tec.linutronix.de> <9a003c2f-f59a-43ab-bbd5-861b14436d29@amd.com> <87a6vpgqbt.fsf@nanos.tec.linutronix.de> <82d54a74-af90-39a4-e483-b3cd73e2ef03@amd.com> <78be575e10034e546cc349d65fac2fcfc6f486b2.camel@infradead.org> <877dqtgkzb.fsf@nanos.tec.linutronix.de> <874klxghwu.fsf@nanos.tec.linutronix.de> <45B3C20C-3BBB-40F3-8A7B-EB20EDD0706F@infradead.org> <87y2j9exk2.fsf@nanos.tec.linutronix.de> <8C2E184C-D069-4C60-96B5-0758FBC6E402@infradead.org> <87tutwg76j.fsf@nanos.tec.linutronix.de> <5c86570ce3bedb90514bc1e73b96011660f520b0.camel@infradead.org> Date: Wed, 11 Nov 2020 10:46:23 +0100 Message-ID: <87o8k4fcpc.fsf@nanos.tec.linutronix.de> MIME-Version: 1.0 Content-Type: text/plain Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Nov 11 2020 at 08:16, David Woodhouse wrote: > On Tue, 2020-11-10 at 23:48 +0100, Thomas Gleixner wrote: >> + * IRQCHIP_MSI_EXTID The MSI message created for this chip can >> + * have an otherwise forbidden extended ID > > If we're going to do that then we could ditch the separate > iommu_compose_msi_msg() function too, right? > > But actually I'd be more inclined to fix this differently, in a way > that doesn't still leave AMD's iommu_init_intcapxt() having to set use > irq_set_affinity_notifier() to update its own registers. That's icky. > > Given that this is *its* irqdomain in the first place, it should just > sit at ->set_affinity() for itself, and call its parent as usual > without having to use a notifier. > > We should also leave it using the basic PCI MSI support in the case > where the IOMMU doesn't have XTSUP support. It doesn't need its own > irqdomain for that. Looking at it now with brain awake, the XTSUP stuff is pretty much the same as DMAR, which I didn't realize yesterday. The affinity notifier muck is not needed when we have a write_msg() function which twiddles the bits into those other locations. Thanks, tglx