提交 d4efafcc 编写于 作者: B Brian Norris

mtd: docg3: fix 'defined but not used' warning

With CONFIG_OF=n, we can see the following warning:

   drivers/mtd/devices/docg3.c:2122:28: warning: 'docg3_dt_ids' defined but not used [-Wunused-variable]
    static struct of_device_id docg3_dt_ids[] = {
Signed-off-by: NBrian Norris <computersforpeace@gmail.com>
Cc: Robert Jarzmik <robert.jarzmik@free.fr>
上级 a1ff7d64
...@@ -2119,11 +2119,13 @@ static int __exit docg3_release(struct platform_device *pdev) ...@@ -2119,11 +2119,13 @@ static int __exit docg3_release(struct platform_device *pdev)
return 0; return 0;
} }
#ifdef CONFIG_OF
static struct of_device_id docg3_dt_ids[] = { static struct of_device_id docg3_dt_ids[] = {
{ .compatible = "m-systems,diskonchip-g3" }, { .compatible = "m-systems,diskonchip-g3" },
{} {}
}; };
MODULE_DEVICE_TABLE(of, docg3_dt_ids); MODULE_DEVICE_TABLE(of, docg3_dt_ids);
#endif
static struct platform_driver g3_driver = { static struct platform_driver g3_driver = {
.driver = { .driver = {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册