Received: by 2002:ac0:a5a7:0:0:0:0:0 with SMTP id m36-v6csp2581314imm; Mon, 16 Jul 2018 10:19:50 -0700 (PDT) X-Google-Smtp-Source: AAOMgpeIw2eJHllL42gDm6zRGWjdCKN8eicP+81mJKAM3zxFsx7J25LZZUn+niuhIeaqhwhgE8DO X-Received: by 2002:a62:3a9d:: with SMTP id v29-v6mr18858460pfj.215.1531761590719; Mon, 16 Jul 2018 10:19:50 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1531761590; cv=none; d=google.com; s=arc-20160816; b=iWJ6RKvVXD0/LPkcDyzDw8OI5BHMY7Lep0ZuOY7Y7YU4LKMjo2nbWXMQmm8KAeQk4c i7bScxixuUZf2rocSiiiw7yNcShmyiEUzJKdcJcdJ3phl8eLybU66U9Sz5fcedQ9lRHJ BYHCiMsvMLT9WQBspm8cAI4A94Yzm+HaNt78BjE1aUaiFVIXkK67yl1FYixduBZbVTwY cXTqVUE8sJLrqFWuXMBh5rc3bLbDI3/BoxYLBVJqFav5fJUTgkfflzqGWSoBwEApOpPT 9FSq9pWTBsHJ2ZMGzRS5ShfwLHs3n9J4C0z3S4xVavSosN0CX3JL56SqWxuwhnZbUj5w xjRw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:subject:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:from:references:cc:to:arc-authentication-results; bh=/e2qwXLeliiHBsonsCY7n0aOkWxASK3A5v9rs0uzSUM=; b=pfy4AUtdWG+D0KHILydmHxwQIoPCRpgows7lI48zmDFp95EZnGJ4vp09vCfuca9zjk wyFN2NFI7CcxG+vMv+s63C4UZSkl/yHhvqwjbbIHNFdIA/Lfb4aGt3hRZhhm9RhMPM4M 1osSuCmHIJ4ceR9Byx28OVqEctPG76r9LfJsz84tlNFrNjn/fisHnxZacKbKUpbZG83r ASt0srHenmZjU3B2SjLoWAWvY6MAGvqHeu8JLZVos9INF4he8L2ATg07LYeAc0j2Ffp2 u3kOj1Ht22StyuXPV7UJKD1KXhiPTebK96czWTZ1TTQ+SMermWIHEyI9r0Op1W34cYn0 Pe6A== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s9-v6si8896338plq.197.2018.07.16.10.19.35; Mon, 16 Jul 2018 10:19:50 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729595AbeGPRqV (ORCPT + 99 others); Mon, 16 Jul 2018 13:46:21 -0400 Received: from ale.deltatee.com ([207.54.116.67]:37002 "EHLO ale.deltatee.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727479AbeGPRqU (ORCPT ); Mon, 16 Jul 2018 13:46:20 -0400 Received: from guinness.priv.deltatee.com ([172.16.1.162]) by ale.deltatee.com with esmtp (Exim 4.89) (envelope-from ) id 1ff77l-0005gj-8L; Mon, 16 Jul 2018 11:17:25 -0600 To: Alex Williamson Cc: linux-kernel@vger.kernel.org, linux-pci@vger.kernel.org, linux-doc@vger.kernel.org, Stephen Bates , Christoph Hellwig , Bjorn Helgaas , Jonathan Corbet , Ingo Molnar , Thomas Gleixner , "Paul E. McKenney" , Marc Zyngier , Kai-Heng Feng , Frederic Weisbecker , Dan Williams , =?UTF-8?B?SsOpcsO0bWUgR2xpc3Nl?= , Benjamin Herrenschmidt , =?UTF-8?Q?Christian_K=c3=b6nig?= , Matthew Wilcox References: <20180713233158.19528-1-logang@deltatee.com> <20180713233158.19528-5-logang@deltatee.com> <20180716111543.6ddf584c@t450s.home> From: Logan Gunthorpe Message-ID: <0a195c47-0a3d-e2f0-588b-214f6720528a@deltatee.com> Date: Mon, 16 Jul 2018 11:17:07 -0600 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.8.0 MIME-Version: 1.0 In-Reply-To: <20180716111543.6ddf584c@t450s.home> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 172.16.1.162 X-SA-Exim-Rcpt-To: willy@infradead.org, christian.koenig@amd.com, benh@kernel.crashing.org, jglisse@redhat.com, dan.j.williams@intel.com, frederic@kernel.org, kai.heng.feng@canonical.com, marc.zyngier@arm.com, paulmck@linux.vnet.ibm.com, tglx@linutronix.de, mingo@kernel.org, corbet@lwn.net, bhelgaas@google.com, hch@lst.de, sbates@raithlin.com, linux-doc@vger.kernel.org, linux-pci@vger.kernel.org, linux-kernel@vger.kernel.org, alex.williamson@redhat.com X-SA-Exim-Mail-From: logang@deltatee.com X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on ale.deltatee.com X-Spam-Level: X-Spam-Status: No, score=-8.9 required=5.0 tests=ALL_TRUSTED,BAYES_00, GREYLIST_ISWHITE autolearn=ham autolearn_force=no version=3.4.1 Subject: Re: [PATCH v6 4/4] PCI: Introduce the disable_acs_redir parameter X-SA-Exim-Version: 4.2.1 (built Tue, 02 Aug 2016 21:08:31 +0000) X-SA-Exim-Scanned: Yes (on ale.deltatee.com) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 16/07/18 11:15 AM, Alex Williamson wrote: >> + pos = pci_find_ext_capability(dev, PCI_EXT_CAP_ID_ACS); >> + if (!pos) { >> + pci_warn(dev, "cannot disable ACS redirect for this hardware as it does not have ACS capabilities\n"); >> + return; >> + } >> + >> + if (!pci_dev_specific_disable_acs_redir(dev)) >> + return; > > Shouldn't this come before the above ACS capability test? The PCH > quirk without a disable_acs_redir callback will fall out with the > pci_warn() above either way, but this ordering precludes that a quirk > could be written for that device since it doesn't have an ACS > capability. Otherwise the series looks ok to me. Thanks, Yup, nice catch. I'll respin a v7 shortly. Thanks, Logan