sparc/PCI: Use dev_is_pci() to identify PCI devices
Subsystems (2)
PATCH v3 1/1 sparc/PCI: Use dev_is_pci() to identify PCI devices
Use dev_is_pci() instead of checking bus type directly.
---
v2->v3: Keep use dev->bus = &pci_bus_type in
arch/sparc/include/asm/dma-mapping.h, because we
can't include <linux/pci.h> in this file, or it will cause lots of building errors, it's so strange. This patch was built ok in my Cross Complier.
--- arch/sparc/kernel/iommu.c | 2 +- arch/sparc/kernel/ioport.c | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-)
arch/sparc/kernel/iommu.c +1 -1
@@ -854,7 +854,7 @@ int dma_supported(struct device *dev, u64 device_mask)return 1 ;#ifdef CONFIG_PCI -if (dev->bus = &pci_bus_type) +if (dev_is_pci (dev))return pci64_dma_supported (to_pci_dev (dev), device_mask);#endif
arch/sparc/kernel/ioport.c +2 -3
@@ -666,10 +666,9 @@ EXPORT_SYMBOL(dma_ops);*/ int dma_supported (struct device *dev,u64 mask) { -#ifdef CONFIG_PCI -if (dev->bus = &pci_bus_type) +if (dev_is_pci (dev))return 1 ; -#endif +return 0 ; }EXPORT_SYMBOL (dma_supported);
Signature · 1 line
1.7.1
From: Yijing Wang <[email protected]>
Date: Wed, 11 Dec 2013 14:00:26 +0800
Quoted 4 lines
Use
dev_is_pci()instead of checking bus type directly.Signed-off-by Yijing Wang <[email protected]>Signed-off-by Bjorn Helgaas <[email protected]>
Applied.
Quoted 11 lines · David Miller
From: Yijing Wang <[email protected]>
Date: Wed, 11 Dec 2013 14:00:26 +0800Quoted 4 lines
Use
dev_is_pci()instead of checking bus type directly.Signed-off-by Yijing Wang <[email protected]>Signed-off-by Bjorn Helgaas <[email protected]>Applied.
Hi David,
This patch has been merged in Bjorn's pci tree, so will have some conflict between yours and Bjorn's tree?
Signature · 2 lines
Thanks! Yijing
David Miller
maintainerFrom: Yijing Wang <[email protected]>
Date: Mon, 6 Jan 2014 09:08:28 +0800
Quoted 1 line
This patch has been merged in Bjorn's pci tree, so will have some conflict between yours and Bjorn's tree?
GIT will figure it out just fine.
Quoted 6 lines · David Miller
From: Yijing Wang <[email protected]>
Date: Mon, 6 Jan 2014 09:08:28 +0800Quoted 1 line
This patch has been merged in Bjorn's pci tree, so will have some conflict between yours and Bjorn's tree?
GIT will figure it out just fine.
OK, thanks very much!
Quoted 2 lines
Signature · 2 lines
Thanks! Yijing