iio: at91_adc: Add missing CONFIG_OF macro
authorSachin Kamat <sachin.kamat@linaro.org>
Thu, 23 May 2013 05:26:00 +0000 (06:26 +0100)
committerJonathan Cameron <jic23@kernel.org>
Tue, 4 Jun 2013 17:29:49 +0000 (18:29 +0100)
The data structure is required only when DT is enabled.
Hence compile it conditionally.

Signed-off-by: Sachin Kamat <sachin.kamat@linaro.org>
Acked-by: Maxime Ripard <maxime.ripard@free-electrons.com>
Signed-off-by: Jonathan Cameron <jic23@kernel.org>
drivers/iio/adc/at91_adc.c

index e5b88d5d3b59425cf07e79ba20937322fa8c50fc..b6db6a0e09cd8107a58ccc1834d02feb15de6836 100644 (file)
@@ -774,11 +774,13 @@ static int at91_adc_remove(struct platform_device *pdev)
        return 0;
 }
 
+#ifdef CONFIG_OF
 static const struct of_device_id at91_adc_dt_ids[] = {
        { .compatible = "atmel,at91sam9260-adc" },
        {},
 };
 MODULE_DEVICE_TABLE(of, at91_adc_dt_ids);
+#endif
 
 static struct platform_driver at91_adc_driver = {
        .probe = at91_adc_probe,