[PATCH] cpufreq: integrator: fix integrator_cpufreq_remove return type

Linus Walleij linus.walleij at linaro.org
Thu Oct 2 01:28:44 PDT 2014


On Fri, Sep 26, 2014 at 10:19 PM, Arnd Bergmann <arnd at arndb.de> wrote:

> When building this driver as a module, we get a helpful warning
> about the return type:
>
> drivers/cpufreq/integrator-cpufreq.c:232:2: warning: initialization from incompatible pointer type
>   .remove = __exit_p(integrator_cpufreq_remove),
>
> If the remove callback returns void, the caller gets an undefined
> value as it expects an integer to be returned. This fixes the
> problem by passing down the value from cpufreq_unregister_driver.
>
> Signed-off-by: Arnd Bergmann <arnd at arndb.de>

Acked-by: Linus Walleij <linus.walleij at linaro.org>

Yours,
Linus Walleij



More information about the linux-arm-kernel mailing list