| .. | .. |
|---|
| 5 | 5 | #ifndef __PCIE_DW_DMATEST_H |
|---|
| 6 | 6 | #define __PCIE_DW_DMATEST_H |
|---|
| 7 | 7 | |
|---|
| 8 | +struct dma_trx_obj; |
|---|
| 9 | +struct device; |
|---|
| 10 | + |
|---|
| 8 | 11 | #if IS_ENABLED(CONFIG_PCIE_DW_DMATEST) |
|---|
| 9 | | -struct dma_trx_obj *pcie_dw_dmatest_register(struct dw_pcie *pci, bool irq_en); |
|---|
| 12 | +struct dma_trx_obj *pcie_dw_dmatest_register(struct device *dev, bool irq_en); |
|---|
| 13 | +void pcie_dw_dmatest_unregister(struct dma_trx_obj *obj); |
|---|
| 14 | +int pcie_dw_wired_dma_frombus_block(struct dma_trx_obj *obj, u32 chn, u64 local_paddr, u64 bus_paddr, u32 size); |
|---|
| 15 | +int pcie_dw_wired_dma_tobus_block(struct dma_trx_obj *obj, u32 chn, u64 bus_paddr, u64 local_paddr, u32 size); |
|---|
| 10 | 16 | #else |
|---|
| 11 | | -static inline struct dma_trx_obj *pcie_dw_dmatest_register(struct dw_pcie *pci, bool irq_en) |
|---|
| 17 | +static inline struct dma_trx_obj *pcie_dw_dmatest_register(struct device *dev, bool irq_en) |
|---|
| 12 | 18 | { |
|---|
| 13 | 19 | return NULL; |
|---|
| 14 | 20 | } |
|---|
| 21 | + |
|---|
| 22 | +static inline void pcie_dw_dmatest_unregister(struct dma_trx_obj *obj) { } |
|---|
| 23 | + |
|---|
| 24 | +static inline int pcie_dw_wired_dma_frombus_block(struct dma_trx_obj *obj, u32 chn, u64 local_paddr, u64 bus_paddr, u32 size) |
|---|
| 25 | +{ |
|---|
| 26 | + return -1; |
|---|
| 27 | +} |
|---|
| 28 | + |
|---|
| 29 | +static inline int pcie_dw_wired_dma_tobus_block(struct dma_trx_obj *obj, u32 chn, u64 bus_paddr, u64 local_paddr, u32 size) |
|---|
| 30 | +{ |
|---|
| 31 | + return -1; |
|---|
| 32 | +} |
|---|
| 15 | 33 | #endif |
|---|
| 16 | 34 | |
|---|
| 17 | 35 | #endif |
|---|