Re: [PATCH] ASoC: codecs: tlv320adc3xxx: Wrap adc3xxx_i2c_remove() in __exit_p()

From: Geert Uytterhoeven
Date: Mon Oct 17 2022 - 08:59:22 EST


Hi Mark,

On Mon, Oct 17, 2022 at 1:36 PM Mark Brown <broonie@xxxxxxxxxx> wrote:
> On Sun, Oct 16, 2022 at 10:33:50AM +0200, Geert Uytterhoeven wrote:
> > If CONFIG_SND_SOC_TLV320ADC3XXX=y:
> >
> > `.exit.text' referenced in section `.data' of sound/soc/codecs/tlv320adc3xxx.o: defined in discarded section `.exit.text' of sound/soc/codecs/tlv320adc3xxx.o
> >
> > Fix this by wrapping the adc3xxx_i2c_remove() pointer in __exit_p().
>
> Why does this driver need this but most others don't?

Because most drivers don't annotate .remove() functions with __exit?
An alternative would be to drop the __exit annotation, at the expense
of a slightly larger kernel in the built-in case.

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