lkml.org 
[lkml]   [2020]   [Dec]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH] Input: da7280 - protect OF match table with CONFIG_OF
Date
On Friday, December 18, 2020 3:50 PM, Dmitry Torokhov wrote:

> The OF match table is only used when OF is enabled.
>
> Fixes: cd3f609823a5 ("Input: new da7280 haptic driver")
> Reported-by: kernel test robot <lkp@intel.com>
> Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
> ---
> drivers/input/misc/da7280.c | 2 ++
> 1 file changed, 2 insertions(+)
>
> diff --git a/drivers/input/misc/da7280.c b/drivers/input/misc/da7280.c index 2f698a8c1d65..b08610d6e575 100644
> --- a/drivers/input/misc/da7280.c
> +++ b/drivers/input/misc/da7280.c
> @@ -1300,11 +1300,13 @@ static int __maybe_unused da7280_resume(struct device *dev)
> return retval;
> }
>
> +#ifdef CONFIG_OF
> static const struct of_device_id da7280_of_match[] = {
> { .compatible = "dlg,da7280", },
> { }
> };
> MODULE_DEVICE_TABLE(of, da7280_of_match);
> +#endif
>
> static const struct i2c_device_id da7280_i2c_id[] = {
> { "da7280", },
> --
> 2.29.2.729.g45daf8777d-goog
>
>
> --
> Dmitry

Thanks!

Acked-by: Roy Im <roy.im.opensource@diasemi.com>

\
 
 \ /
  Last update: 2020-12-18 17:51    [W:0.057 / U:1.568 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site