Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

powerpc/pci: Use dev_is_pci() to check whether it is pci device

Use PCI standard marco dev_is_pci() instead of directly compare
pci_bus_type to check whether it is pci device.

Signed-off-by: Yijing Wang <wangyijing@huawei.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>

authored by

Yijing Wang and committed by
Benjamin Herrenschmidt
d317ac17 5877231f

+1 -1
+1 -1
arch/powerpc/sysdev/fsl_pci.c
··· 122 122 * address width of the SoC such that we can address any internal 123 123 * SoC address from across PCI if needed 124 124 */ 125 - if ((dev->bus == &pci_bus_type) && 125 + if ((dev_is_pci(dev)) && 126 126 dma_mask >= DMA_BIT_MASK(MAX_PHYS_ADDR_BITS)) { 127 127 set_dma_ops(dev, &dma_direct_ops); 128 128 set_dma_offset(dev, pci64_dma_offset);