Re: [PATCH -block] fault-inject: fix build error when FAULT_INJECTION_CONFIGFS=y and CONFIGFS_FS=m
From: Geert Uytterhoeven
Date: Sun Apr 16 2023 - 05:53:40 EST
Hi Mita-san,
On Sat, Apr 15, 2023 at 3:09 PM Akinobu Mita <akinobu.mita@xxxxxxxxx> wrote:
> This fixes a build error when CONFIG_FAULT_INJECTION_CONFIGFS=y and
> CONFIG_CONFIGFS_FS=m.
>
> Since the fault-injection library cannot built as a module, avoid building
> configfs as a module.
>
> Reported-by: kernel test robot <lkp@xxxxxxxxx>
> Link: https://lore.kernel.org/oe-kbuild-all/202304150025.K0hczLR4-lkp@xxxxxxxxx/
> Signed-off-by: Akinobu Mita <akinobu.mita@xxxxxxxxx>
Thanks for your patch!
> --- a/lib/Kconfig.debug
> +++ b/lib/Kconfig.debug
> @@ -1979,7 +1979,8 @@ config FAIL_SUNRPC
>
> config FAULT_INJECTION_CONFIGFS
> bool "Configfs interface for fault-injection capabilities"
> - depends on FAULT_INJECTION && CONFIGFS_FS
> + depends on FAULT_INJECTION
> + select CONFIGFS_FS
My first thought was "please do not select CONFIGFS_FS", but
apparently this is what most users do, so I guess it's OK.
Reviewed-by: Geert Uytterhoeven <geert@xxxxxxxxxxxxxx>
The alternative would be to do:
- depends on FAULT_INJECTION && CONFIGFS_FS
+ depends on FAULT_INJECTION && (CONFIGFS_FS=y ||
CONFIGFS_FS=FAULT_INJECTION)
> help
> This option allows configfs-based drivers to dynamically configure
> fault-injection via configfs. Each parameter for driver-specific
Gr{oetje,eeting}s,
Geert
--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@xxxxxxxxxxxxxx
In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
-- Linus Torvalds