Skip to content

Commit ade1229

Browse files
committed
dma-mapping: no need to pass a bus_type into get_arch_dma_ops()
The get_arch_dma_ops() arch-specific function never does anything with the struct bus_type that is passed into it, so remove it entirely as it is not needed. Cc: Richard Henderson <richard.henderson@linaro.org> Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru> Cc: Matt Turner <mattst88@gmail.com> Cc: Thomas Bogendoerfer <tsbogend@alpha.franken.de> Cc: "James E.J. Bottomley" <James.Bottomley@HansenPartnership.com> Cc: Helge Deller <deller@gmx.de> Cc: "David S. Miller" <davem@davemloft.net> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Ingo Molnar <mingo@redhat.com> Cc: Borislav Petkov <bp@alien8.de> Cc: Dave Hansen <dave.hansen@linux.intel.com> Cc: x86@kernel.org Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Marek Szyprowski <m.szyprowski@samsung.com> Cc: Robin Murphy <robin.murphy@arm.com> Cc: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com> Cc: linux-alpha@vger.kernel.org Cc: linux-kernel@vger.kernel.org Cc: linux-ia64@vger.kernel.org Cc: linux-mips@vger.kernel.org Cc: linux-parisc@vger.kernel.org Cc: sparclinux@vger.kernel.org Cc: iommu@lists.linux.dev Cc: linux-arch@vger.kernel.org Acked-by: Christoph Hellwig <hch@lst.de> Reviewed-by: Arnd Bergmann <arnd@arndb.de> Link: https://lore.kernel.org/r/20230214140121.131859-1-gregkh@linuxfoundation.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
1 parent 779aeb7 commit ade1229

8 files changed

Lines changed: 8 additions & 8 deletions

File tree

arch/alpha/include/asm/dma-mapping.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
extern const struct dma_map_ops alpha_pci_ops;
66

7-
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
7+
static inline const struct dma_map_ops *get_arch_dma_ops(void)
88
{
99
#ifdef CONFIG_ALPHA_JENSEN
1010
return NULL;

arch/ia64/include/asm/dma-mapping.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
*/
99
extern const struct dma_map_ops *dma_ops;
1010

11-
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
11+
static inline const struct dma_map_ops *get_arch_dma_ops(void)
1212
{
1313
return dma_ops;
1414
}

arch/mips/include/asm/dma-mapping.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66

77
extern const struct dma_map_ops jazz_dma_ops;
88

9-
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
9+
static inline const struct dma_map_ops *get_arch_dma_ops(void)
1010
{
1111
#if defined(CONFIG_MACH_JAZZ)
1212
return &jazz_dma_ops;

arch/parisc/include/asm/dma-mapping.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
extern const struct dma_map_ops *hppa_dma_ops;
2323

24-
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
24+
static inline const struct dma_map_ops *get_arch_dma_ops(void)
2525
{
2626
return hppa_dma_ops;
2727
}

arch/sparc/include/asm/dma-mapping.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
extern const struct dma_map_ops *dma_ops;
66

7-
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
7+
static inline const struct dma_map_ops *get_arch_dma_ops(void)
88
{
99
/* sparc32 uses per-device dma_ops */
1010
return IS_ENABLED(CONFIG_SPARC64) ? dma_ops : NULL;

arch/x86/include/asm/dma-mapping.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44

55
extern const struct dma_map_ops *dma_ops;
66

7-
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
7+
static inline const struct dma_map_ops *get_arch_dma_ops(void)
88
{
99
return dma_ops;
1010
}

include/asm-generic/dma-mapping.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
#ifndef _ASM_GENERIC_DMA_MAPPING_H
33
#define _ASM_GENERIC_DMA_MAPPING_H
44

5-
static inline const struct dma_map_ops *get_arch_dma_ops(struct bus_type *bus)
5+
static inline const struct dma_map_ops *get_arch_dma_ops(void)
66
{
77
return NULL;
88
}

include/linux/dma-map-ops.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ static inline const struct dma_map_ops *get_dma_ops(struct device *dev)
9090
{
9191
if (dev->dma_ops)
9292
return dev->dma_ops;
93-
return get_arch_dma_ops(dev->bus);
93+
return get_arch_dma_ops();
9494
}
9595

9696
static inline void set_dma_ops(struct device *dev,

0 commit comments

Comments
 (0)