[PATCH 07/13] ASoC: replace linux/gpio.h inclusions

sashiko-bot at kernel.org sashiko-bot at kernel.org
Tue Jun 30 06:28:31 PDT 2026


Thank you for your contribution! Sashiko AI review found 1 potential issue(s) to consider:
- [Low] The patch introduces duplicate `#include <linux/gpio/consumer.h>` directives in `cs42l84.c` and `dmic.c`.
--

commit 5e88ad9a5863dbafbe414c688b31a85827de20da
Author: Arnd Bergmann <arnd at arndb.de>

ASoC: replace linux/gpio.h inclusions

This commit updates multiple ASoC codecs to use linux/gpio/consumer.h instead
of the deprecated linux/gpio.h header.

> diff --git a/sound/soc/codecs/cs42l84.c b/sound/soc/codecs/cs42l84.c
> index f2a58163de0ed..36c3abc21fedc 100644
> --- a/sound/soc/codecs/cs42l84.c
> +++ b/sound/soc/codecs/cs42l84.c
> @@ -16,7 +16,7 @@
>  #include <linux/init.h>
>  #include <linux/delay.h>
>  #include <linux/i2c.h>
> -#include <linux/gpio.h>
> +#include <linux/gpio/consumer.h>

[Severity: Low]
This isn't a bug, but does this create a duplicate include? It appears
linux/gpio/consumer.h is already included further down in this file. Could we
simply drop the linux/gpio.h include entirely?

>  #include <linux/regmap.h>
>  #include <linux/slab.h>
>  #include <linux/acpi.h>

[ ... ]

> diff --git a/sound/soc/codecs/dmic.c b/sound/soc/codecs/dmic.c
> index 61e1bf1b3c9e6..8b05d6f9b429b 100644
> --- a/sound/soc/codecs/dmic.c
> +++ b/sound/soc/codecs/dmic.c
> @@ -6,7 +6,7 @@
>   */
>  
>  #include <linux/delay.h>
> -#include <linux/gpio.h>
> +#include <linux/gpio/consumer.h>
>  #include <linux/gpio/consumer.h>

[Severity: Low]
This isn't a bug, but should we just delete the old include line? Replacing
it leaves two identical includes back-to-back.

>  #include <linux/platform_device.h>
>  #include <linux/regulator/consumer.h>

-- 
Sashiko AI review · https://sashiko.dev/#/patchset/20260629132633.1300009-1-arnd@kernel.org?part=7



More information about the linux-phy mailing list