diff mbox series

[1/5] gpiolib: of: remove of_gpio_count()

Message ID 20221219192016.1396950-1-dmitry.torokhov@gmail.com
State New
Headers show
Series [1/5] gpiolib: of: remove of_gpio_count() | expand

Commit Message

Dmitry Torokhov Dec. 19, 2022, 7:20 p.m. UTC
There are no more users of of_gpio_count() in the mainline kernel,
remove it.

Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
---

After 6.2-rc1 there should be no more users of the APIs mentioned in
this series.

 include/linux/of_gpio.h | 11 -----------
 1 file changed, 11 deletions(-)

Comments

Andy Shevchenko Dec. 20, 2022, 1:51 p.m. UTC | #1
On Mon, Dec 19, 2022 at 11:20:12AM -0800, Dmitry Torokhov wrote:
> There are no more users of of_gpio_count() in the mainline kernel,
> remove it.

Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>

> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> ---
> 
> After 6.2-rc1 there should be no more users of the APIs mentioned in
> this series.

I believe you probably want to have this patch applied immediately to the GPIO
subsystem after v6.2-rc1 to avoid new users.

>  include/linux/of_gpio.h | 11 -----------
>  1 file changed, 11 deletions(-)
> 
> diff --git a/include/linux/of_gpio.h b/include/linux/of_gpio.h
> index 6db627257a7b..39f16a960565 100644
> --- a/include/linux/of_gpio.h
> +++ b/include/linux/of_gpio.h
> @@ -105,17 +105,6 @@ static inline int of_gpio_named_count(const struct device_node *np,
>  	return of_count_phandle_with_args(np, propname, "#gpio-cells");
>  }
>  
> -/**
> - * of_gpio_count() - Count GPIOs for a device
> - * @np:		device node to count GPIOs for
> - *
> - * Same as of_gpio_named_count, but hard coded to use the 'gpios' property
> - */
> -static inline int of_gpio_count(const struct device_node *np)
> -{
> -	return of_gpio_named_count(np, "gpios");
> -}
> -
>  static inline int of_get_gpio_flags(const struct device_node *np, int index,
>  		      enum of_gpio_flags *flags)
>  {
> -- 
> 2.39.0.314.g84b9a713c41-goog
>
Dmitry Torokhov Dec. 20, 2022, 6:33 p.m. UTC | #2
On Tue, Dec 20, 2022 at 03:51:43PM +0200, Andy Shevchenko wrote:
> On Mon, Dec 19, 2022 at 11:20:12AM -0800, Dmitry Torokhov wrote:
> > There are no more users of of_gpio_count() in the mainline kernel,
> > remove it.
> 
> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
> 
> > Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> > ---
> > 
> > After 6.2-rc1 there should be no more users of the APIs mentioned in
> > this series.
> 
> I believe you probably want to have this patch applied immediately to the GPIO
> subsystem after v6.2-rc1 to avoid new users.

Thanks for the reviews Andy.

I think Linus pulled all the changes removing these all APIs into
mainline, so it is possible to get it into 6.2 right away. Since
everything is supposed to go through 'next' we will probably catch new
users regardless, but I indeed would not mind having this in 6.2 and not
wait for 6.3.

Thanks.
Bartosz Golaszewski Dec. 30, 2022, 3:55 p.m. UTC | #3
On Mon, Dec 19, 2022 at 8:20 PM Dmitry Torokhov
<dmitry.torokhov@gmail.com> wrote:
>
> There are no more users of of_gpio_count() in the mainline kernel,
> remove it.
>
> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> ---
>
> After 6.2-rc1 there should be no more users of the APIs mentioned in
> this series.
>
>  include/linux/of_gpio.h | 11 -----------
>  1 file changed, 11 deletions(-)
>
> diff --git a/include/linux/of_gpio.h b/include/linux/of_gpio.h
> index 6db627257a7b..39f16a960565 100644
> --- a/include/linux/of_gpio.h
> +++ b/include/linux/of_gpio.h
> @@ -105,17 +105,6 @@ static inline int of_gpio_named_count(const struct device_node *np,
>         return of_count_phandle_with_args(np, propname, "#gpio-cells");
>  }
>
> -/**
> - * of_gpio_count() - Count GPIOs for a device
> - * @np:                device node to count GPIOs for
> - *
> - * Same as of_gpio_named_count, but hard coded to use the 'gpios' property
> - */
> -static inline int of_gpio_count(const struct device_node *np)
> -{
> -       return of_gpio_named_count(np, "gpios");
> -}
> -
>  static inline int of_get_gpio_flags(const struct device_node *np, int index,
>                       enum of_gpio_flags *flags)
>  {
> --
> 2.39.0.314.g84b9a713c41-goog
>

I applied the entire series, thanks a lot for doing that!

Bart
diff mbox series

Patch

diff --git a/include/linux/of_gpio.h b/include/linux/of_gpio.h
index 6db627257a7b..39f16a960565 100644
--- a/include/linux/of_gpio.h
+++ b/include/linux/of_gpio.h
@@ -105,17 +105,6 @@  static inline int of_gpio_named_count(const struct device_node *np,
 	return of_count_phandle_with_args(np, propname, "#gpio-cells");
 }
 
-/**
- * of_gpio_count() - Count GPIOs for a device
- * @np:		device node to count GPIOs for
- *
- * Same as of_gpio_named_count, but hard coded to use the 'gpios' property
- */
-static inline int of_gpio_count(const struct device_node *np)
-{
-	return of_gpio_named_count(np, "gpios");
-}
-
 static inline int of_get_gpio_flags(const struct device_node *np, int index,
 		      enum of_gpio_flags *flags)
 {