[<prev] [next>] [day] [month] [year] [list]
Message-ID: <20241127063114epcms1p5aac02aa2dee6506cd7c70511c42568f0@epcms1p5>
Date: Wed, 27 Nov 2024 15:31:14 +0900
From: MyungJoo Ham <myungjoo.ham@...sung.com>
To: Chanwoo Choi <cw00.choi@...sung.com>
CC: "linux@...blig.org" <linux@...blig.org>, Kyungmin Park
<kyungmin.park@...sung.com>, "linux-pm@...r.kernel.org"
<linux-pm@...r.kernel.org>, "linux-kernel@...r.kernel.org"
<linux-kernel@...r.kernel.org>
Subject: RE: [PATCH] PM / devfreq: Remove unused devfreq_event_reset_event
>From: "Dr. David Alan Gilbert"
>
>devfreq_event_reset_event() was added in 2015 by
>commit f262f28c1470 ("PM / devfreq: event: Add devfreq_event class")
>
>but has remained unused.
>
>Remove it.
>
>Signed-off-by: Dr. David Alan Gilbert
Chanwoo:
do we really don't have any drivers using these?
- devfreq_event_reset_event
- devm_devfreq_(un)register_notifier
including both the upstream and forks?
Anyway, I couldn't find one.
Cheers,
MyungJoo
>---
> drivers/devfreq/devfreq-event.c | 26 --------------------------
> include/linux/devfreq-event.h | 6 ------
> 2 files changed, 32 deletions(-)
>
>diff --git a/drivers/devfreq/devfreq-event.c b/drivers/devfreq/devfreq-event.c
>index 3ebac2496679..a60703374006 100644
>--- a/drivers/devfreq/devfreq-event.c
>+++ b/drivers/devfreq/devfreq-event.c
>@@ -183,32 +183,6 @@ int devfreq_event_get_event(struct devfreq_event_dev *edev,
> }
> EXPORT_SYMBOL_GPL(devfreq_event_get_event);
>
>-/**
>- * devfreq_event_reset_event() - Reset all opeations of devfreq-event dev.
>- * @edev : the devfreq-event device
>- *
>- * Note that this function stop all operations of devfreq-event dev and reset
>- * the current event data to make the devfreq-event device into initial state.
>- */
>-int devfreq_event_reset_event(struct devfreq_event_dev *edev)
>-{
>- int ret = 0;
>-
>- if (!edev || !edev->desc)
>- return -EINVAL;
>-
>- if (!devfreq_event_is_enabled(edev))
>- return -EPERM;
>-
>- mutex_lock(&edev->lock);
>- if (edev->desc->ops && edev->desc->ops->reset)
>- ret = edev->desc->ops->reset(edev);
>- mutex_unlock(&edev->lock);
>-
>- return ret;
>-}
>-EXPORT_SYMBOL_GPL(devfreq_event_reset_event);
>-
> /**
> * devfreq_event_get_edev_by_phandle() - Get the devfreq-event dev from
> * devicetree.
>diff --git a/include/linux/devfreq-event.h b/include/linux/devfreq-event.h
>index 4a50a5c71a5f..461080280de9 100644
>--- a/include/linux/devfreq-event.h
>+++ b/include/linux/devfreq-event.h
>@@ -104,7 +104,6 @@ extern bool devfreq_event_is_enabled(struct devfreq_event_dev *edev);
> extern int devfreq_event_set_event(struct devfreq_event_dev *edev);
> extern int devfreq_event_get_event(struct devfreq_event_dev *edev,
> struct devfreq_event_data *edata);
>-extern int devfreq_event_reset_event(struct devfreq_event_dev *edev);
> extern struct devfreq_event_dev *devfreq_event_get_edev_by_phandle(
> struct device *dev,
> const char *phandle_name,
>@@ -149,11 +148,6 @@ static inline int devfreq_event_get_event(struct devfreq_event_dev *edev,
> return -EINVAL;
> }
>
>-static inline int devfreq_event_reset_event(struct devfreq_event_dev *edev)
>-{
>- return -EINVAL;
>-}
>-
> static inline struct devfreq_event_dev *devfreq_event_get_edev_by_phandle(
> struct device *dev,
> const char *phandle_name,
>--
>2.47.0
>
>
>
Powered by blists - more mailing lists