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 X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 039DBC761A6 for ; Mon, 17 Feb 2020 12:40:40 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id CF36720801 for ; Mon, 17 Feb 2020 12:40:39 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="xB+yOUMH" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728302AbgBQMkj (ORCPT ); Mon, 17 Feb 2020 07:40:39 -0500 Received: from mail-wm1-f65.google.com ([209.85.128.65]:36668 "EHLO mail-wm1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728228AbgBQMkj (ORCPT ); Mon, 17 Feb 2020 07:40:39 -0500 Received: by mail-wm1-f65.google.com with SMTP id p17so18298100wma.1 for ; Mon, 17 Feb 2020 04:40:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=VM4sr45eMsFNfm3I8AuewKPZ2mzCi8kc40UVw+7O2LQ=; b=xB+yOUMH1+HqPIVwYA3f+1KohCCBUZKzi2se4L7bK+0Hs0L2ST4OcrzccxNLIKZSZL meF2am7U3/daqiwqZ2iYjulCYMVLvp6cA+U2CEevmBa4//Ar02kR0gI8SOaoXc2FPtNM 4mii9R/d783fyE/dxumDzGZA8y7IOZs1u0FLd3Z4kzBmSygQEGxTGUYOe5fqlT9fjxx2 FBivVrn9YMs6qKmDf7fYx4XhyXb2rq9Zz7yxrlKls/r0+mqTuKY6553nH6pjvXf0vhDz dxEhqGpoCEOSpWjK878ms0OPbBVieYrKP3NYoCNhXJO1KEiCzbAQp4gwPxSiLHMZGPv/ 8yrA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=VM4sr45eMsFNfm3I8AuewKPZ2mzCi8kc40UVw+7O2LQ=; b=hHLYXP2EIwBHAr8M1uacd3WWuWqTg0zuzs4yQ9PAHZAezOhreTeB510c15kk7C7xJG 7OmzKqZqF6JMmPoYF32hOQjjsXTElzM2stDWi1M6spyiag0mcWpuWaJ31G+mRNattbV1 Mdo3iV12CFhygP8MG97DEn85DAp+RbzFafDm8UaiTTFLQQwB0zOxBxY1pd8/3qIWRloZ cLOOdV2bzoANCUprcSMOSeQPWZdLl5tNHGDdWf+0J8BxPGhnLco0JDn3TyEPN0fcrArK u+R55Y8qLmhUac9vhWQMdshv3dNpWK8ECGYH0TRh23JHlAQ/SzgpNr43FSBgpwmZ/qlY tyYQ== X-Gm-Message-State: APjAAAXU6J+VaIPDClWARIJfpm5Agt8bJBAEOs7wfjnc87lBfhmUlcDc r7dVw5SpEsPwYRHleyLKOxdPPg== X-Google-Smtp-Source: APXvYqw7OaMmOiCFpqSYiEkkioeWfbwcKs6q33Y3t8Kyrhd1NgY0z99Vh6YZxCeeeslYOpZSiSCuUQ== X-Received: by 2002:a7b:c0d9:: with SMTP id s25mr21509184wmh.98.1581943237117; Mon, 17 Feb 2020 04:40:37 -0800 (PST) Received: from myrica ([2001:171b:2276:930:116c:c27a:3e7f:5eaf]) by smtp.gmail.com with ESMTPSA id d16sm917782wrg.27.2020.02.17.04.40.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Feb 2020 04:40:36 -0800 (PST) Date: Mon, 17 Feb 2020 13:40:28 +0100 From: Jean-Philippe Brucker To: Rob Herring Cc: Bjorn Helgaas , Will Deacon , Lorenzo Pieralisi , Joerg Roedel , Lu Baolu , Linux Doc Mailing List , PCI , "moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE" , devicetree@vger.kernel.org, linux-acpi@vger.kernel.org, Linux IOMMU , Jonathan Corbet , Mark Rutland , Liviu Dudau , Sudeep Holla , Hanjun Guo , "Rafael J. Wysocki" , Len Brown , Robin Murphy , David Woodhouse , Andrew Murray , Frank Rowand Subject: Re: [PATCH 03/11] PCI: OF: Check whether the host bridge supports ATS Message-ID: <20200217124028.GC1650092@myrica> References: <20200213165049.508908-1-jean-philippe@linaro.org> <20200213165049.508908-4-jean-philippe@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Sender: linux-acpi-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-acpi@vger.kernel.org On Thu, Feb 13, 2020 at 12:26:46PM -0600, Rob Herring wrote: > On Thu, Feb 13, 2020 at 10:52 AM Jean-Philippe Brucker > wrote: > > > > Copy the ats-supported flag into the pci_host_bridge structure. > > > > Signed-off-by: Jean-Philippe Brucker > > --- > > drivers/pci/controller/pci-host-common.c | 1 + > > drivers/pci/of.c | 9 +++++++++ > > include/linux/of_pci.h | 3 +++ > > 3 files changed, 13 insertions(+) > > > > diff --git a/drivers/pci/controller/pci-host-common.c b/drivers/pci/controller/pci-host-common.c > > index 250a3fc80ec6..a6ac927be291 100644 > > --- a/drivers/pci/controller/pci-host-common.c > > +++ b/drivers/pci/controller/pci-host-common.c > > @@ -92,6 +92,7 @@ int pci_host_common_probe(struct platform_device *pdev, > > return ret; > > } > > > > + of_pci_host_check_ats(bridge); > > platform_set_drvdata(pdev, bridge->bus); > > return 0; > > } > > diff --git a/drivers/pci/of.c b/drivers/pci/of.c > > index 81ceeaa6f1d5..4b8a877f1e9f 100644 > > --- a/drivers/pci/of.c > > +++ b/drivers/pci/of.c > > @@ -576,6 +576,15 @@ int pci_parse_request_of_pci_ranges(struct device *dev, > > } > > EXPORT_SYMBOL_GPL(pci_parse_request_of_pci_ranges); > > > > +void of_pci_host_check_ats(struct pci_host_bridge *bridge) > > +{ > > + struct device_node *np = bridge->bus->dev.of_node; > > + > > + if (!np) > > + return; > > + > > + bridge->ats_supported = of_property_read_bool(np, "ats-supported"); > > +} > > Not really any point in a common function if we expect this to be only > for ECAM hosts which it seems to be based on the binding. I'll move this to pci-host-common.c Thanks, Jean 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 X-Spam-Level: X-Spam-Status: No, score=-6.5 required=3.0 tests=DKIM_INVALID,DKIM_SIGNED, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A0D40C34021 for ; Mon, 17 Feb 2020 12:40:43 +0000 (UTC) Received: from silver.osuosl.org (smtp3.osuosl.org [140.211.166.136]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 6837B20725 for ; Mon, 17 Feb 2020 12:40:43 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=fail reason="signature verification failed" (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="xB+yOUMH" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 6837B20725 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=iommu-bounces@lists.linux-foundation.org Received: from localhost (localhost [127.0.0.1]) by silver.osuosl.org (Postfix) with ESMTP id 2548B2043E; Mon, 17 Feb 2020 12:40:43 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from silver.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 34DODP4uOABj; Mon, 17 Feb 2020 12:40:42 +0000 (UTC) Received: from lists.linuxfoundation.org (lf-lists.osuosl.org [140.211.9.56]) by silver.osuosl.org (Postfix) with ESMTP id 0D00C20027; Mon, 17 Feb 2020 12:40:42 +0000 (UTC) Received: from lf-lists.osuosl.org (localhost [127.0.0.1]) by lists.linuxfoundation.org (Postfix) with ESMTP id EC3D1C08A0; Mon, 17 Feb 2020 12:40:41 +0000 (UTC) Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by lists.linuxfoundation.org (Postfix) with ESMTP id BA045C013E for ; Mon, 17 Feb 2020 12:40:39 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id B63B784755 for ; Mon, 17 Feb 2020 12:40:39 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id MP1AASro2lCP for ; Mon, 17 Feb 2020 12:40:39 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-wm1-f65.google.com (mail-wm1-f65.google.com [209.85.128.65]) by fraxinus.osuosl.org (Postfix) with ESMTPS id B1B0F8457E for ; Mon, 17 Feb 2020 12:40:38 +0000 (UTC) Received: by mail-wm1-f65.google.com with SMTP id t14so18294927wmi.5 for ; Mon, 17 Feb 2020 04:40:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=VM4sr45eMsFNfm3I8AuewKPZ2mzCi8kc40UVw+7O2LQ=; b=xB+yOUMH1+HqPIVwYA3f+1KohCCBUZKzi2se4L7bK+0Hs0L2ST4OcrzccxNLIKZSZL meF2am7U3/daqiwqZ2iYjulCYMVLvp6cA+U2CEevmBa4//Ar02kR0gI8SOaoXc2FPtNM 4mii9R/d783fyE/dxumDzGZA8y7IOZs1u0FLd3Z4kzBmSygQEGxTGUYOe5fqlT9fjxx2 FBivVrn9YMs6qKmDf7fYx4XhyXb2rq9Zz7yxrlKls/r0+mqTuKY6553nH6pjvXf0vhDz dxEhqGpoCEOSpWjK878ms0OPbBVieYrKP3NYoCNhXJO1KEiCzbAQp4gwPxSiLHMZGPv/ 8yrA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=VM4sr45eMsFNfm3I8AuewKPZ2mzCi8kc40UVw+7O2LQ=; b=W1BzKJ53O8LiBuTmtCi0JcL4BKdlWOJwCk3+XhEI2/qrMoaH+LdSE2pU+4/s5+/hId 8i0iG2pgtha5MHWnUDG/XADj/vbC01CFvAsCARDC1YvUlFGU2IxGcZoSZQkSxbS2Vs47 K4r+XafmPx10aWtrwv959TnOrjoKrDfYtWi+bFXiwF/nm9pf8OS+3zCvE3Xy0Ibfn2dX DceT8oehGHy6+H+4zf2Q9TAukDit7bjqdZ1YsgpDLXd3pbR97ks+IDmWw9sOLQDYIjlY qE72nZnxgcEGF1M2TQpvKHFQIrP2OT5/2jF2ahQLRZlWZXGzpTNau1EL5kJMFSAMj2QJ /AAQ== X-Gm-Message-State: APjAAAVeeSQwUstWnrMyAEoYJCRwuF5HncQzwSnJ4yOZmj4z6Iy8UU53 Gz3cE/sJ6wbu9CeZc3iOxWR/mg== X-Google-Smtp-Source: APXvYqw7OaMmOiCFpqSYiEkkioeWfbwcKs6q33Y3t8Kyrhd1NgY0z99Vh6YZxCeeeslYOpZSiSCuUQ== X-Received: by 2002:a7b:c0d9:: with SMTP id s25mr21509184wmh.98.1581943237117; Mon, 17 Feb 2020 04:40:37 -0800 (PST) Received: from myrica ([2001:171b:2276:930:116c:c27a:3e7f:5eaf]) by smtp.gmail.com with ESMTPSA id d16sm917782wrg.27.2020.02.17.04.40.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Feb 2020 04:40:36 -0800 (PST) Date: Mon, 17 Feb 2020 13:40:28 +0100 From: Jean-Philippe Brucker To: Rob Herring Subject: Re: [PATCH 03/11] PCI: OF: Check whether the host bridge supports ATS Message-ID: <20200217124028.GC1650092@myrica> References: <20200213165049.508908-1-jean-philippe@linaro.org> <20200213165049.508908-4-jean-philippe@linaro.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: Cc: Mark Rutland , Linux Doc Mailing List , PCI , Liviu Dudau , Hanjun Guo , Frank Rowand , Jonathan Corbet , Will Deacon , linux-acpi@vger.kernel.org, Len Brown , devicetree@vger.kernel.org, Bjorn Helgaas , "moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE" , David Woodhouse , "Rafael J. Wysocki" , Linux IOMMU , Sudeep Holla , Robin Murphy , Andrew Murray X-BeenThere: iommu@lists.linux-foundation.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: Development issues for Linux IOMMU support List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: iommu-bounces@lists.linux-foundation.org Sender: "iommu" On Thu, Feb 13, 2020 at 12:26:46PM -0600, Rob Herring wrote: > On Thu, Feb 13, 2020 at 10:52 AM Jean-Philippe Brucker > wrote: > > > > Copy the ats-supported flag into the pci_host_bridge structure. > > > > Signed-off-by: Jean-Philippe Brucker > > --- > > drivers/pci/controller/pci-host-common.c | 1 + > > drivers/pci/of.c | 9 +++++++++ > > include/linux/of_pci.h | 3 +++ > > 3 files changed, 13 insertions(+) > > > > diff --git a/drivers/pci/controller/pci-host-common.c b/drivers/pci/controller/pci-host-common.c > > index 250a3fc80ec6..a6ac927be291 100644 > > --- a/drivers/pci/controller/pci-host-common.c > > +++ b/drivers/pci/controller/pci-host-common.c > > @@ -92,6 +92,7 @@ int pci_host_common_probe(struct platform_device *pdev, > > return ret; > > } > > > > + of_pci_host_check_ats(bridge); > > platform_set_drvdata(pdev, bridge->bus); > > return 0; > > } > > diff --git a/drivers/pci/of.c b/drivers/pci/of.c > > index 81ceeaa6f1d5..4b8a877f1e9f 100644 > > --- a/drivers/pci/of.c > > +++ b/drivers/pci/of.c > > @@ -576,6 +576,15 @@ int pci_parse_request_of_pci_ranges(struct device *dev, > > } > > EXPORT_SYMBOL_GPL(pci_parse_request_of_pci_ranges); > > > > +void of_pci_host_check_ats(struct pci_host_bridge *bridge) > > +{ > > + struct device_node *np = bridge->bus->dev.of_node; > > + > > + if (!np) > > + return; > > + > > + bridge->ats_supported = of_property_read_bool(np, "ats-supported"); > > +} > > Not really any point in a common function if we expect this to be only > for ECAM hosts which it seems to be based on the binding. I'll move this to pci-host-common.c Thanks, Jean _______________________________________________ iommu mailing list iommu@lists.linux-foundation.org https://lists.linuxfoundation.org/mailman/listinfo/iommu 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 X-Spam-Level: X-Spam-Status: No, score=-6.8 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI, SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F3AABC34020 for ; Mon, 17 Feb 2020 12:40:48 +0000 (UTC) Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id C6A5B20725 for ; Mon, 17 Feb 2020 12:40:48 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="q3kj61T0"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=linaro.org header.i=@linaro.org header.b="xB+yOUMH" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org C6A5B20725 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=linaro.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=+0724r/RpfJ6mCNPyCCIOQDA96TR5/9ORBwObKBBFOE=; b=q3kj61T0PkvLOI rvdxuvnkdBFOpXa2zi/gR/qe+bSM7MQPhgJsmwHGicU+rYzXbLEd+j8BnTdqUsTlQXG5IJcN6Efvg 4TVkje9ctGvijUnJreQcbhbCqAL8KY/83f8zsAc4w5ixpbhriyOMp4tHHUP70X7iE/YPTBGFfRaJO ku1cclmx/3Kv9oCWOVLVfKdoZ+94s7I/66filFizJh4oOWjnBlTI54znfyINS7O/+is5VlHNFmmUT S2w3EC3d//6s31qRyNzkwcMoB7bKbftOIjYVCgBIruMQsZPmA1abRMMPrV5zj0vihcslPu9qutsHU I+Lv6zeDhwrLicxN019w==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1j3fhb-0005ZU-1K; Mon, 17 Feb 2020 12:40:43 +0000 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1j3fhX-0005Yi-U5 for linux-arm-kernel@lists.infradead.org; Mon, 17 Feb 2020 12:40:41 +0000 Received: by mail-wm1-x343.google.com with SMTP id s10so17004766wmh.3 for ; Mon, 17 Feb 2020 04:40:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=VM4sr45eMsFNfm3I8AuewKPZ2mzCi8kc40UVw+7O2LQ=; b=xB+yOUMH1+HqPIVwYA3f+1KohCCBUZKzi2se4L7bK+0Hs0L2ST4OcrzccxNLIKZSZL meF2am7U3/daqiwqZ2iYjulCYMVLvp6cA+U2CEevmBa4//Ar02kR0gI8SOaoXc2FPtNM 4mii9R/d783fyE/dxumDzGZA8y7IOZs1u0FLd3Z4kzBmSygQEGxTGUYOe5fqlT9fjxx2 FBivVrn9YMs6qKmDf7fYx4XhyXb2rq9Zz7yxrlKls/r0+mqTuKY6553nH6pjvXf0vhDz dxEhqGpoCEOSpWjK878ms0OPbBVieYrKP3NYoCNhXJO1KEiCzbAQp4gwPxSiLHMZGPv/ 8yrA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=VM4sr45eMsFNfm3I8AuewKPZ2mzCi8kc40UVw+7O2LQ=; b=Edxgv5g1y6guz78Ix+qsuuHC3GjSb7Vkt5049dbDsjXzwUon4mxAHypRvmbrzwy5FK fEWt+1uoIcwCWkNSwUqezYNJtXqZ4MGRkTYnICOqXdvjLsQVjGUwjoBOSc3gwSiEbjRb liyInWRJj29dKqT2B7EsCPYpCxCqpLu+2JwPgwjhdU8fZ/1PwQfjrcsI4iDXGAmXAb/b KmZRua1mckF4IwkGrfSdGtq+71uIIY9gygqyG4269dJi+BXZ+d2trx9kCDeo0/MBcG/N n+4WdoxrYGfmm6cslU6Un/ECtzpapRf2CUXpjyxi5AiuP5ker6cZ7PRSyPLXGWWRJ9EK Wbhg== X-Gm-Message-State: APjAAAWHRrHO9a+pD+aR58UiNHZKHLHic0YXvKcYbksAEAVudXnVUB9w urF5mN6bYDV5HF13ZC2QEpvpTg== X-Google-Smtp-Source: APXvYqw7OaMmOiCFpqSYiEkkioeWfbwcKs6q33Y3t8Kyrhd1NgY0z99Vh6YZxCeeeslYOpZSiSCuUQ== X-Received: by 2002:a7b:c0d9:: with SMTP id s25mr21509184wmh.98.1581943237117; Mon, 17 Feb 2020 04:40:37 -0800 (PST) Received: from myrica ([2001:171b:2276:930:116c:c27a:3e7f:5eaf]) by smtp.gmail.com with ESMTPSA id d16sm917782wrg.27.2020.02.17.04.40.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Feb 2020 04:40:36 -0800 (PST) Date: Mon, 17 Feb 2020 13:40:28 +0100 From: Jean-Philippe Brucker To: Rob Herring Subject: Re: [PATCH 03/11] PCI: OF: Check whether the host bridge supports ATS Message-ID: <20200217124028.GC1650092@myrica> References: <20200213165049.508908-1-jean-philippe@linaro.org> <20200213165049.508908-4-jean-philippe@linaro.org> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200217_044040_147856_3843F3BE X-CRM114-Status: GOOD ( 18.30 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , Linux Doc Mailing List , PCI , Liviu Dudau , Hanjun Guo , Frank Rowand , Lorenzo Pieralisi , Jonathan Corbet , Will Deacon , Joerg Roedel , linux-acpi@vger.kernel.org, Len Brown , devicetree@vger.kernel.org, Bjorn Helgaas , "moderated list:ARM/FREESCALE IMX / MXC ARM ARCHITECTURE" , David Woodhouse , "Rafael J. Wysocki" , Linux IOMMU , Sudeep Holla , Lu Baolu , Robin Murphy , Andrew Murray Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org On Thu, Feb 13, 2020 at 12:26:46PM -0600, Rob Herring wrote: > On Thu, Feb 13, 2020 at 10:52 AM Jean-Philippe Brucker > wrote: > > > > Copy the ats-supported flag into the pci_host_bridge structure. > > > > Signed-off-by: Jean-Philippe Brucker > > --- > > drivers/pci/controller/pci-host-common.c | 1 + > > drivers/pci/of.c | 9 +++++++++ > > include/linux/of_pci.h | 3 +++ > > 3 files changed, 13 insertions(+) > > > > diff --git a/drivers/pci/controller/pci-host-common.c b/drivers/pci/controller/pci-host-common.c > > index 250a3fc80ec6..a6ac927be291 100644 > > --- a/drivers/pci/controller/pci-host-common.c > > +++ b/drivers/pci/controller/pci-host-common.c > > @@ -92,6 +92,7 @@ int pci_host_common_probe(struct platform_device *pdev, > > return ret; > > } > > > > + of_pci_host_check_ats(bridge); > > platform_set_drvdata(pdev, bridge->bus); > > return 0; > > } > > diff --git a/drivers/pci/of.c b/drivers/pci/of.c > > index 81ceeaa6f1d5..4b8a877f1e9f 100644 > > --- a/drivers/pci/of.c > > +++ b/drivers/pci/of.c > > @@ -576,6 +576,15 @@ int pci_parse_request_of_pci_ranges(struct device *dev, > > } > > EXPORT_SYMBOL_GPL(pci_parse_request_of_pci_ranges); > > > > +void of_pci_host_check_ats(struct pci_host_bridge *bridge) > > +{ > > + struct device_node *np = bridge->bus->dev.of_node; > > + > > + if (!np) > > + return; > > + > > + bridge->ats_supported = of_property_read_bool(np, "ats-supported"); > > +} > > Not really any point in a common function if we expect this to be only > for ECAM hosts which it seems to be based on the binding. I'll move this to pci-host-common.c Thanks, Jean _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel