diff options
author | Peter Ujfalusi <peter.ujfalusi@ti.com> | 2020-12-08 12:04:24 +0300 |
---|---|---|
committer | Vinod Koul <vkoul@kernel.org> | 2020-12-11 18:50:08 +0300 |
commit | 426506a7e0f1902268c3edbdc7e5475624a9d18b (patch) | |
tree | baa00623a22ee6e14644c89e8b9a342523c66292 /drivers/dma/ti/k3-udma-private.c | |
parent | 1609c15a20b8e0c1adc2a26ad81fd7e2b968f81a (diff) | |
download | linux-426506a7e0f1902268c3edbdc7e5475624a9d18b.tar.xz |
dmaengine: ti: k3-udma-glue: Add function to get device pointer for DMA API
Glue layer users should use the device of the DMA for DMA mapping and
allocations as it is the DMA which accesses to descriptors and buffers,
not the clients
Signed-off-by: Peter Ujfalusi <peter.ujfalusi@ti.com>
Reviewed-by: Grygorii Strashko <grygorii.strashko@ti.com>
Link: https://lore.kernel.org/r/20201208090440.31792-5-peter.ujfalusi@ti.com
Signed-off-by: Vinod Koul <vkoul@kernel.org>
Diffstat (limited to 'drivers/dma/ti/k3-udma-private.c')
-rw-r--r-- | drivers/dma/ti/k3-udma-private.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/dma/ti/k3-udma-private.c b/drivers/dma/ti/k3-udma-private.c index aa24e554f7b4..8ff7a264be03 100644 --- a/drivers/dma/ti/k3-udma-private.c +++ b/drivers/dma/ti/k3-udma-private.c @@ -50,6 +50,12 @@ struct udma_dev *of_xudma_dev_get(struct device_node *np, const char *property) } EXPORT_SYMBOL(of_xudma_dev_get); +struct device *xudma_get_device(struct udma_dev *ud) +{ + return ud->dev; +} +EXPORT_SYMBOL(xudma_get_device); + u32 xudma_dev_get_psil_base(struct udma_dev *ud) { return ud->psil_base; |