mirror-linux/drivers/staging
Suraj Upadhyay ff98ca159b staging: qlge: Remove pci-dma-compat wrapper APIs.
The legacy API wrappers in include/linux/pci-dma-compat.h
should go away as it creates unnecessary midlayering
for include/linux/dma-mapping.h APIs, instead use dma-mapping.h
APIs directly.

The patch has been generated with the coccinelle script below
and compile-tested.

@@@@
- PCI_DMA_BIDIRECTIONAL
+ DMA_BIDIRECTIONAL

@@@@
- PCI_DMA_TODEVICE
+ DMA_TO_DEVICE

@@@@
- PCI_DMA_FROMDEVICE
+ DMA_FROM_DEVICE

@@@@
- PCI_DMA_NONE
+ DMA_NONE

@@ expression E1, E2, E3; @@
- pci_alloc_consistent(E1, E2, E3)
+ dma_alloc_coherent(&E1->dev, E2, E3, GFP_ATOMIC)

@@ expression E1, E2, E3; @@
- pci_zalloc_consistent(E1, E2, E3)
+ dma_alloc_coherent(&E1->dev, E2, E3, GFP_ATOMIC)

@@ expression E1, E2, E3, E4; @@
- pci_free_consistent(E1, E2, E3, E4)
+ dma_free_coherent(&E1->dev, E2, E3, E4)

@@ expression E1, E2, E3, E4; @@
- pci_map_single(E1, E2, E3, E4)
+ dma_map_single(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4; @@
- pci_unmap_single(E1, E2, E3, E4)
+ dma_unmap_single(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4, E5; @@
- pci_map_page(E1, E2, E3, E4, E5)
+ dma_map_page(&E1->dev, E2, E3, E4, (enum dma_data_direction)E5)

@@ expression E1, E2, E3, E4; @@
- pci_unmap_page(E1, E2, E3, E4)
+ dma_unmap_page(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4; @@
- pci_map_sg(E1, E2, E3, E4)
+ dma_map_sg(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4; @@
- pci_unmap_sg(E1, E2, E3, E4)
+ dma_unmap_sg(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4; @@
- pci_dma_sync_single_for_cpu(E1, E2, E3, E4)
+ dma_sync_single_for_cpu(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4; @@
- pci_dma_sync_single_for_device(E1, E2, E3, E4)
+ dma_sync_single_for_device(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4; @@
- pci_dma_sync_sg_for_cpu(E1, E2, E3, E4)
+ dma_sync_sg_for_cpu(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2, E3, E4; @@
- pci_dma_sync_sg_for_device(E1, E2, E3, E4)
+ dma_sync_sg_for_device(&E1->dev, E2, E3, (enum dma_data_direction)E4)

@@ expression E1, E2; @@
- pci_dma_mapping_error(E1, E2)
+ dma_mapping_error(&E1->dev, E2)

@@ expression E1, E2; @@
- pci_set_consistent_dma_mask(E1, E2)
+ dma_set_coherent_mask(&E1->dev, E2)

@@ expression E1, E2; @@
- pci_set_dma_mask(E1, E2)
+ dma_set_mask(&E1->dev, E2)

Signed-off-by: Suraj Upadhyay <usuraj35@gmail.com>
Link: https://lore.kernel.org/r/20200711124633.GA16459@blackclown
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2020-07-13 15:36:31 +02:00
..
android staging: ion: fix common struct sg_table related issues 2020-06-25 16:34:54 +02:00
axis-fifo
board
clocking-wizard clk: staging: Specify IOMEM dependency for Xilinx Clocking Wizard driver 2020-07-01 15:43:05 +02:00
comedi staging: comedi: fix up missing whitespace in comment 2020-06-18 09:48:53 +02:00
emxx_udc
fbtft staging: fbtft: fb_st7789v: make HSD20_IPS numeric and not a string 2020-05-22 10:48:32 +02:00
fieldbus
fsl-dpaa2 Staging/IIO driver patches for 5.8-rc1 2020-06-07 10:45:08 -07:00
fwserial
gasket staging: gasket: replace symbolic permissions 2020-06-25 15:36:20 +02:00
gdm724x
goldfish
greybus treewide: replace '---help---' in Kconfig files with 'help' 2020-06-14 01:57:21 +09:00
gs_fpgaboot
iio Merge 5.7-rc7 into staging-next 2020-05-25 09:11:19 +02:00
kpc2000 staging: kpc2000: kpc_dma: Remove additional goto statements 2020-07-01 15:44:26 +02:00
ks7010 staging: ks7010: fix ks_wlan_start_xmit()'s return type 2020-06-29 09:28:27 +02:00
media Kbuild updates for v5.8 (2nd) 2020-06-13 13:29:16 -07:00
most staging: most: sound: remove overcautious argument checking 2020-06-25 15:41:17 +02:00
mt7621-dma
mt7621-dts
mt7621-pci
mt7621-pci-phy
mt7621-pinctrl
netlogic
nvec Staging: nvec: Replace HTTP links with HTTPS ones 2020-07-10 13:52:46 +02:00
octeon
octeon-usb
olpc_dcon
pi433
qlge staging: qlge: Remove pci-dma-compat wrapper APIs. 2020-07-13 15:36:31 +02:00
ralink-gdma
rtl8188eu staging: rtl8188eu: Use fallthrough pseudo-keyword 2020-07-10 13:52:46 +02:00
rtl8192e staging: rtl8192e: rtl_core: Remove pci-dma-compat wrapper APIs. 2020-07-13 15:36:31 +02:00
rtl8192u staging: rtl8192u: Using comparison to true is error prone 2020-07-10 13:52:46 +02:00
rtl8712 staging: rtl8712/: Using comparison to true is error prone 2020-07-10 13:55:11 +02:00
rtl8723bs staging: rtl8723bs: Using comparison to true is error prone 2020-07-10 13:52:46 +02:00
rts5208 staging: rts5208: Assign array_size() to a variable 2020-07-13 15:36:31 +02:00
sm750fb staging: sm750fb: Add names to proc_setBLANK args 2020-05-29 12:35:59 +02:00
speakup Staging: speakup: Replace HTTP links with HTTPS ones 2020-07-13 15:36:31 +02:00
unisys
vc04_services staging: vchiq: Move vchiq.h into include directory 2020-07-01 15:47:08 +02:00
vme
vt6655 staging: vt6655: Use fallthrough pseudo-keyword 2020-07-10 13:52:46 +02:00
vt6656 staging: vt6655: Use fallthrough pseudo-keyword 2020-07-10 13:52:46 +02:00
wfx staging: wfx: Get descriptors for GPIOs 2020-07-10 13:51:22 +02:00
wlan-ng
Kconfig wilc1000: move wilc driver out of staging 2020-06-26 08:46:46 +03:00
Makefile wilc1000: move wilc driver out of staging 2020-06-26 08:46:46 +03:00