summaryrefslogtreecommitdiffstats
path: root/drivers/interconnect
diff options
context:
space:
mode:
authorJohan Hovold <johan+linaro@kernel.org>2023-03-06 08:56:51 +0100
committerGeorgi Djakov <djakov@kernel.org>2023-04-05 11:29:59 +0300
commitb2d110cd5d28ded813f060b735cd68bfe2e5010f (patch)
treea692d529fb5bf4e7adb11fdf6d7419c6eba1b48c /drivers/interconnect
parent419405c92299d793b95053aa54d95e2d3f45a1a4 (diff)
downloadlinux-stable-b2d110cd5d28ded813f060b735cd68bfe2e5010f.tar.gz
linux-stable-b2d110cd5d28ded813f060b735cd68bfe2e5010f.tar.bz2
linux-stable-b2d110cd5d28ded813f060b735cd68bfe2e5010f.zip
interconnect: drop unused icc_link_destroy() interface
Now that the link array is deallocated when destroying nodes and the explicit link removal has been dropped from the exynos driver there are no further users of and no need for the icc_link_destroy() interface. Signed-off-by: Johan Hovold <johan+linaro@kernel.org> Link: https://lore.kernel.org/r/20230306075651.2449-24-johan+linaro@kernel.org Signed-off-by: Georgi Djakov <djakov@kernel.org>
Diffstat (limited to 'drivers/interconnect')
-rw-r--r--drivers/interconnect/core.c46
1 files changed, 0 insertions, 46 deletions
diff --git a/drivers/interconnect/core.c b/drivers/interconnect/core.c
index da456329c524..0edf85ba055e 100644
--- a/drivers/interconnect/core.c
+++ b/drivers/interconnect/core.c
@@ -911,52 +911,6 @@ out:
EXPORT_SYMBOL_GPL(icc_link_create);
/**
- * icc_link_destroy() - destroy a link between two nodes
- * @src: pointer to source node
- * @dst: pointer to destination node
- *
- * Return: 0 on success, or an error code otherwise
- */
-int icc_link_destroy(struct icc_node *src, struct icc_node *dst)
-{
- struct icc_node **new;
- size_t slot;
- int ret = 0;
-
- if (IS_ERR_OR_NULL(src))
- return -EINVAL;
-
- if (IS_ERR_OR_NULL(dst))
- return -EINVAL;
-
- mutex_lock(&icc_lock);
-
- for (slot = 0; slot < src->num_links; slot++)
- if (src->links[slot] == dst)
- break;
-
- if (WARN_ON(slot == src->num_links)) {
- ret = -ENXIO;
- goto out;
- }
-
- src->links[slot] = src->links[--src->num_links];
-
- new = krealloc(src->links, src->num_links * sizeof(*src->links),
- GFP_KERNEL);
- if (new)
- src->links = new;
- else
- ret = -ENOMEM;
-
-out:
- mutex_unlock(&icc_lock);
-
- return ret;
-}
-EXPORT_SYMBOL_GPL(icc_link_destroy);
-
-/**
* icc_node_add() - add interconnect node to interconnect provider
* @node: pointer to the interconnect node
* @provider: pointer to the interconnect provider