Re: [PATCH] x86/olpc: select GPIOLIB_LEGACY
From: Bartosz Golaszewski
Date: Tue Apr 28 2026 - 04:13:53 EST
On Mon, 27 Apr 2026 16:43:05 +0200, Arnd Bergmann <arnd@xxxxxxxxxx> said:
> From: Arnd Bergmann <arnd@xxxxxxxx>
>
> The OLPC GPIO controller sets up a fixed number space that is used
> by at least two drivers:
>
> arch/x86/platform/olpc/olpc-xo1-sci.c: In function 'setup_ec_sci':
> arch/x86/platform/olpc/olpc-xo1-sci.c:358:13: error: implicit declaration of function 'gpio_request' [-Wimplicit-function-declaration]
> 358 | r = gpio_request(OLPC_GPIO_ECSCI, "OLPC-ECSCI");
> | ^~~~~~~~~~~~
> sound/pci/cs5535audio/cs5535audio_olpc.c: In function 'olpc_analog_input':
> sound/pci/cs5535audio/cs5535audio_olpc.c:41:9: error: implicit declaration of function 'gpio_set_value'; did you mean 'gpiod_set_value'? [-Wimplicit-function-declaration]
> 41 | gpio_set_value(OLPC_GPIO_MIC_AC, on);
>
> Select CONFIG_GPIOLIB_LEGACY for this platform and make sure the
> sound driver portion cannot be compiled without this.
>
> Acked-by: Borislav Petkov (AMD) <bp@xxxxxxxxx>
> Signed-off-by: Arnd Bergmann <arnd@xxxxxxxx>
> ---
Reviewed-by: Bartosz Golaszewski <bartosz.golaszewski@xxxxxxxxxxxxxxxx>