lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <564D1DB8.7000504@amd.com>
Date:	Wed, 18 Nov 2015 18:54:16 -0600
From:	Suravee Suthikulanit <suravee.suthikulpanit@....com>
To:	<rjw@...ysocki.net>, <bhelgaas@...gle.com>, <robin.murphy@....com>
CC:	<arnd@...db.de>, <linux-pci@...r.kernel.org>,
	<linux-acpi@...r.kernel.org>, <linux-kernel@...r.kernel.org>,
	<linux-arm-kernel@...ts.infradead.org>,
	"Rafael J. Wysocki" <rafael.j.wysocki@...el.com>
Subject: Re: [PATCH] PCI: Fix logic OF logic in pci_dma_configure()

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@....com>
> Cc: Rafael J. Wysocki <rafael.j.wysocki@...el.com>
> Cc: Bjorn Helgaas <bhelgaas@...gle.com>
> Cc: Arnd Bergmann <arnd@...db.de>
> Signed-off-by: Suravee Suthikulpanit <suravee.suthikulpanit@....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);
>

--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ