summaryrefslogtreecommitdiff
path: root/arch/sh
diff options
context:
space:
mode:
authorGeert Uytterhoeven <geert+renesas@glider.be>2024-03-02 00:02:26 +0300
committerJohn Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>2024-05-02 13:01:24 +0300
commit41899dcd1d284cd4211beffb335bb3ccd1eee80e (patch)
tree3dccc8133b5065806ece3665b84f297273da4998 /arch/sh
parent74feee2c562149df7e043ead148e0b6559c12917 (diff)
downloadlinux-41899dcd1d284cd4211beffb335bb3ccd1eee80e.tar.xz
sh: dma: Remove unused dmac_search_free_channel()
arch/sh/drivers/dma/dma-api.c:164:5: warning: no previous prototype for 'dmac_search_free_channel' [-Wmissing-prototypes] dmac_search_free_channel() never had a user in upstream, remove it. Signed-off-by: Geert Uytterhoeven <geert+renesas@glider.be> Reviewed-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de> Link: https://lore.kernel.org/r/82d5efdde44f9489c5a7d11d0a19750445116c95.1709326528.git.geert+renesas@glider.be Signed-off-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Diffstat (limited to 'arch/sh')
-rw-r--r--arch/sh/drivers/dma/dma-api.c27
1 files changed, 0 insertions, 27 deletions
diff --git a/arch/sh/drivers/dma/dma-api.c b/arch/sh/drivers/dma/dma-api.c
index 89cd4a3b4cca..f49097fa634c 100644
--- a/arch/sh/drivers/dma/dma-api.c
+++ b/arch/sh/drivers/dma/dma-api.c
@@ -161,33 +161,6 @@ int request_dma_bycap(const char **dmac, const char **caps, const char *dev_id)
}
EXPORT_SYMBOL(request_dma_bycap);
-int dmac_search_free_channel(const char *dev_id)
-{
- struct dma_channel *channel = { 0 };
- struct dma_info *info = get_dma_info(0);
- int i;
-
- for (i = 0; i < info->nr_channels; i++) {
- channel = &info->channels[i];
- if (unlikely(!channel))
- return -ENODEV;
-
- if (atomic_read(&channel->busy) == 0)
- break;
- }
-
- if (info->ops->request) {
- int result = info->ops->request(channel);
- if (result)
- return result;
-
- atomic_set(&channel->busy, 1);
- return channel->chan;
- }
-
- return -ENOSYS;
-}
-
int request_dma(unsigned int chan, const char *dev_id)
{
struct dma_channel *channel = { 0 };