Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit df907938 authored by Yijing Wang's avatar Yijing Wang Committed by Bjorn Helgaas
Browse files

sparc/PCI: Use dev_is_pci() to identify PCI devices



Use dev_is_pci() instead of checking bus type directly.

Signed-off-by: default avatarYijing Wang <wangyijing@huawei.com>
Signed-off-by: default avatarBjorn Helgaas <bhelgaas@google.com>
parent c7797d67
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -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

+2 −3
Original line number Diff line number Diff line
@@ -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);