From: Suravee Suthikulanit <suravee.suthikulpanit@amd.com>
To: rjw@rjwysocki.net, bhelgaas@google.com, robin.murphy@arm.com
Cc: arnd@arndb.de, linux-pci@vger.kernel.org,
linux-acpi@vger.kernel.org, linux-kernel@vger.kernel.org,
linux-arm-kernel@lists.infradead.org,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
Subject: Re: [PATCH] PCI: Fix logic OF logic in pci_dma_configure()
Date: Wed, 18 Nov 2015 18:54:16 -0600 [thread overview]
Message-ID: <564D1DB8.7000504@amd.com> (raw)
In-Reply-To: <1447894192-17210-1-git-send-email-Suravee.Suthikulpanit@amd.com>
Arg... sorry for the typo in the subject. It should say:
[PATCH] PCI: Fix OF logic in pci_dma_configure()
Suravee
On 11/18/2015 6:49 PM, Suravee Suthikulpanit wrote:
> This patch fixes a bug introduced by previous commit,
> which incorrectly checkes the of_node of the end-point device.
> Instead, it should check the of_node of the host bridge.
>
> Fixes: 50230713b639 ("PCI: OF: Move of_pci_dma_configure() to pci_dma_configure()")
> Reported-by: Robin Murphy <robin.murphy@arm.com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Cc: Bjorn Helgaas <bhelgaas@google.com>
> Cc: Arnd Bergmann <arnd@arndb.de>
> Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
> ---
> drivers/pci/probe.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
> index e735c72..edb1984 100644
> --- a/drivers/pci/probe.c
> +++ b/drivers/pci/probe.c
> @@ -1685,8 +1685,8 @@ static void pci_dma_configure(struct pci_dev *dev)
> {
> struct device *bridge = pci_get_host_bridge_device(dev);
>
> - if (IS_ENABLED(CONFIG_OF) && dev->dev.of_node) {
> - if (bridge->parent)
> + if (IS_ENABLED(CONFIG_OF) &&
> + bridge->parent && bridge->parent->of_node) {
> of_dma_configure(&dev->dev, bridge->parent->of_node);
> } else if (has_acpi_companion(bridge)) {
> struct acpi_device *adev = to_acpi_device_node(bridge->fwnode);
>
WARNING: multiple messages have this Message-ID (diff)
From: Suravee Suthikulanit <suravee.suthikulpanit@amd.com>
To: <rjw@rjwysocki.net>, <bhelgaas@google.com>, <robin.murphy@arm.com>
Cc: <arnd@arndb.de>, <linux-pci@vger.kernel.org>,
<linux-acpi@vger.kernel.org>, <linux-kernel@vger.kernel.org>,
<linux-arm-kernel@lists.infradead.org>,
"Rafael J. Wysocki" <rafael.j.wysocki@intel.com>
Subject: Re: [PATCH] PCI: Fix logic OF logic in pci_dma_configure()
Date: Wed, 18 Nov 2015 18:54:16 -0600 [thread overview]
Message-ID: <564D1DB8.7000504@amd.com> (raw)
In-Reply-To: <1447894192-17210-1-git-send-email-Suravee.Suthikulpanit@amd.com>
Arg... sorry for the typo in the subject. It should say:
[PATCH] PCI: Fix OF logic in pci_dma_configure()
Suravee
On 11/18/2015 6:49 PM, Suravee Suthikulpanit wrote:
> This patch fixes a bug introduced by previous commit,
> which incorrectly checkes the of_node of the end-point device.
> Instead, it should check the of_node of the host bridge.
>
> Fixes: 50230713b639 ("PCI: OF: Move of_pci_dma_configure() to pci_dma_configure()")
> Reported-by: Robin Murphy <robin.murphy@arm.com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Cc: Bjorn Helgaas <bhelgaas@google.com>
> Cc: Arnd Bergmann <arnd@arndb.de>
> Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
> ---
> drivers/pci/probe.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
> index e735c72..edb1984 100644
> --- a/drivers/pci/probe.c
> +++ b/drivers/pci/probe.c
> @@ -1685,8 +1685,8 @@ static void pci_dma_configure(struct pci_dev *dev)
> {
> struct device *bridge = pci_get_host_bridge_device(dev);
>
> - if (IS_ENABLED(CONFIG_OF) && dev->dev.of_node) {
> - if (bridge->parent)
> + if (IS_ENABLED(CONFIG_OF) &&
> + bridge->parent && bridge->parent->of_node) {
> of_dma_configure(&dev->dev, bridge->parent->of_node);
> } else if (has_acpi_companion(bridge)) {
> struct acpi_device *adev = to_acpi_device_node(bridge->fwnode);
>
WARNING: multiple messages have this Message-ID (diff)
From: suravee.suthikulpanit@amd.com (Suravee Suthikulanit)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] PCI: Fix logic OF logic in pci_dma_configure()
Date: Wed, 18 Nov 2015 18:54:16 -0600 [thread overview]
Message-ID: <564D1DB8.7000504@amd.com> (raw)
In-Reply-To: <1447894192-17210-1-git-send-email-Suravee.Suthikulpanit@amd.com>
Arg... sorry for the typo in the subject. It should say:
[PATCH] PCI: Fix OF logic in pci_dma_configure()
Suravee
On 11/18/2015 6:49 PM, Suravee Suthikulpanit wrote:
> This patch fixes a bug introduced by previous commit,
> which incorrectly checkes the of_node of the end-point device.
> Instead, it should check the of_node of the host bridge.
>
> Fixes: 50230713b639 ("PCI: OF: Move of_pci_dma_configure() to pci_dma_configure()")
> Reported-by: Robin Murphy <robin.murphy@arm.com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
> Cc: Bjorn Helgaas <bhelgaas@google.com>
> Cc: Arnd Bergmann <arnd@arndb.de>
> Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@amd.com>
> ---
> drivers/pci/probe.c | 4 ++--
> 1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/pci/probe.c b/drivers/pci/probe.c
> index e735c72..edb1984 100644
> --- a/drivers/pci/probe.c
> +++ b/drivers/pci/probe.c
> @@ -1685,8 +1685,8 @@ static void pci_dma_configure(struct pci_dev *dev)
> {
> struct device *bridge = pci_get_host_bridge_device(dev);
>
> - if (IS_ENABLED(CONFIG_OF) && dev->dev.of_node) {
> - if (bridge->parent)
> + if (IS_ENABLED(CONFIG_OF) &&
> + bridge->parent && bridge->parent->of_node) {
> of_dma_configure(&dev->dev, bridge->parent->of_node);
> } else if (has_acpi_companion(bridge)) {
> struct acpi_device *adev = to_acpi_device_node(bridge->fwnode);
>
next prev parent reply other threads:[~2015-11-19 0:54 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-11-19 0:49 [PATCH] PCI: Fix logic OF logic in pci_dma_configure() Suravee Suthikulpanit
2015-11-19 0:49 ` Suravee Suthikulpanit
2015-11-19 0:49 ` Suravee Suthikulpanit
2015-11-19 0:54 ` Suravee Suthikulanit [this message]
2015-11-19 0:54 ` Suravee Suthikulanit
2015-11-19 0:54 ` Suravee Suthikulanit
2015-11-19 1:56 ` Rafael J. Wysocki
2015-11-19 1:56 ` Rafael J. Wysocki
2015-11-19 8:23 ` Arnd Bergmann
2015-11-19 8:23 ` Arnd Bergmann
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=564D1DB8.7000504@amd.com \
--to=suravee.suthikulpanit@amd.com \
--cc=arnd@arndb.de \
--cc=bhelgaas@google.com \
--cc=linux-acpi@vger.kernel.org \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pci@vger.kernel.org \
--cc=rafael.j.wysocki@intel.com \
--cc=rjw@rjwysocki.net \
--cc=robin.murphy@arm.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.