Hi Arnd, On Thu, Feb 25, 2021 at 10:40 PM Arnd Bergmann <a...@kernel.org> wrote: > > From: Arnd Bergmann <a...@arndb.de> > > The new gpio support may be optional at runtime, but it requires > building against gpiolib: > > ERROR: modpost: "gpiochip_get_data" [drivers/net/dsa/mt7530.ko] undefined! > ERROR: modpost: "devm_gpiochip_add_data_with_key" [drivers/net/dsa/mt7530.ko] > undefined! > > Add a Kconfig dependency to enforce this.
I think wrapping the GPIO code block with #ifdef CONFIG_GPIOLIB ... #endif may be a better idea. > > Fixes: 429a0edeefd8 ("net: dsa: mt7530: MT7530 optional GPIO support") > Signed-off-by: Arnd Bergmann <a...@arndb.de>