[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210602080212.4992-1-jrdr.linux@gmail.com>
Date: Wed, 2 Jun 2021 13:32:12 +0530
From: Souptick Joarder <jrdr.linux@...il.com>
To: hjc@...k-chips.com, heiko@...ech.de, airlied@...ux.ie,
daniel@...ll.ch
Cc: dri-devel@...ts.freedesktop.org,
linux-arm-kernel@...ts.infradead.org,
linux-rockchip@...ts.infradead.org, linux-kernel@...r.kernel.org,
Souptick Joarder <jrdr.linux@...il.com>,
kernel test robot <lkp@...el.com>
Subject: [PATCH] drm/rockchip: defined struct rockchip_dp_dt_ids[] under CONFIG_OF
Kernel test robot throws below warning when CONFIG_OF
is not set.
>> drivers/gpu/drm/rockchip/analogix_dp-rockchip.c:457:34:
warning: unused variable 'rockchip_dp_dt_ids' [-Wunused-const-variable]
static const struct of_device_id rockchip_dp_dt_ids[] = {
Fixed it by defining rockchip_dp_dt_ids[] under CONFIG_OF.
Reported-by: kernel test robot <lkp@...el.com>
Signed-off-by: Souptick Joarder <jrdr.linux@...il.com>
---
drivers/gpu/drm/rockchip/analogix_dp-rockchip.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c
index ade2327a10e2..9b79ebaeae97 100644
--- a/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c
+++ b/drivers/gpu/drm/rockchip/analogix_dp-rockchip.c
@@ -454,12 +454,14 @@ static const struct rockchip_dp_chip_data rk3288_dp = {
.chip_type = RK3288_DP,
};
+#ifdef CONFIG_OF
static const struct of_device_id rockchip_dp_dt_ids[] = {
{.compatible = "rockchip,rk3288-dp", .data = &rk3288_dp },
{.compatible = "rockchip,rk3399-edp", .data = &rk3399_edp },
{}
};
MODULE_DEVICE_TABLE(of, rockchip_dp_dt_ids);
+#endif
struct platform_driver rockchip_dp_driver = {
.probe = rockchip_dp_probe,
--
2.25.1
Powered by blists - more mailing lists