From: Sachin Kamat Date: Fri, 7 Jun 2013 11:06:00 +0000 (+0100) Subject: staging: iio: spear_adc: Add missing CONFIG_OF macro X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=e89b6747058748f0190a6852f53d65a7e79f4a9f;p=GitHub%2FLineageOS%2Fandroid_kernel_motorola_exynos9610.git staging: iio: spear_adc: Add missing CONFIG_OF macro The data structure is required only when DT is enabled. Hence compile it conditionally. Signed-off-by: Sachin Kamat Acked-by: Stefan Roese Signed-off-by: Jonathan Cameron --- diff --git a/drivers/staging/iio/adc/spear_adc.c b/drivers/staging/iio/adc/spear_adc.c index 25a06cbe16c0..736219c30308 100644 --- a/drivers/staging/iio/adc/spear_adc.c +++ b/drivers/staging/iio/adc/spear_adc.c @@ -415,11 +415,13 @@ static int spear_adc_remove(struct platform_device *pdev) return 0; } +#ifdef CONFIG_OF static const struct of_device_id spear_adc_dt_ids[] = { { .compatible = "st,spear600-adc", }, { /* sentinel */ } }; MODULE_DEVICE_TABLE(of, spear_adc_dt_ids); +#endif static struct platform_driver spear_adc_driver = { .probe = spear_adc_probe,