2
0
mirror of git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git synced 2025-09-04 20:19:47 +08:00
linux/drivers/gpu/drm/bridge/analogix
Zhu Wang 132b6512e6
drm/bridge: fix -Wunused-const-variable= warning
When building with W=1, the following warning occurs.

drivers/gpu/drm/bridge/analogix/analogix-anx78xx.c:48:17: warning: ‘anx781x_i2c_addresses’ defined but not used [-Wunused-const-variable=]  static const u8 anx781x_i2c_addresses[] = {
                 ^~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/bridge/analogix/analogix-anx78xx.c:40:17: warning: ‘anx7808_i2c_addresses’ defined but not used [-Wunused-const-variable=]  static const u8 anx7808_i2c_addresses[] = {

When CONFIG_IO is disabled, above two variables are not used,
since the place where it is used is inclueded in the macro
CONFIG_OF.

Even for drivers that do not depend on CONFIG_OF, it's almost
always better to leave out the of_match_ptr(), since the only
thing it can possibly do is to save a few bytes of .text if a
driver can be used both with and without it. Hence we remove
all of_match_ptr() used in other places.

Fixes: 0647e7dd3f ("drm/bridge: Add Analogix anx78xx support")
Signed-off-by: Zhu Wang <wangzhu9@huawei.com>
Reviewed-by: Arnd Bergmann <arnd@arndb.de>
Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Robert Foss <rfoss@kernel.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20230731021345.219588-1-wangzhu9@huawei.com
2023-07-31 11:14:24 +02:00
..
analogix_dp_core.c Revert "drm: bridge: analogix/dp: add panel prepare/unprepare in suspend/resume time" 2022-09-23 07:15:18 -07:00
analogix_dp_core.h drm: Rename dp/ to display/ 2022-04-25 11:17:45 +02:00
analogix_dp_reg.c drm/bridge: analogix_dp: Make PSR-exit block less 2021-11-04 11:54:09 +01:00
analogix_dp_reg.h treewide: Replace GPLv2 boilerplate/reference with SPDX - rule 500 2019-06-19 17:09:55 +02:00
analogix-anx78xx.c drm/bridge: fix -Wunused-const-variable= warning 2023-07-31 11:14:24 +02:00
analogix-anx78xx.h drm/bridge: split some definitions of ANX78xx to dedicated headers 2019-11-08 10:27:32 +01:00
analogix-anx6345.c drm/bridge: fix -Wunused-const-variable= warning 2023-07-31 11:14:24 +02:00
analogix-i2c-dptx.c drm: Rename dp/ to display/ 2022-04-25 11:17:45 +02:00
analogix-i2c-dptx.h drm/bridge: Prepare Analogix anx6345 support 2019-11-08 10:27:53 +01:00
analogix-i2c-txcommon.h drm/bridge: Prepare Analogix anx6345 support 2019-11-08 10:27:53 +01:00
anx7625.c drm/bridge: Remove redundant i2c_client in anx7625/it6505 2023-07-24 10:38:02 +02:00
anx7625.h drm/bridge: Remove redundant i2c_client in anx7625/it6505 2023-07-24 10:38:02 +02:00
Kconfig drm/display: Move HDCP helpers into display-helper module 2022-04-25 11:19:36 +02:00
Makefile drm/bridge: anx7625: Add anx7625 MIPI DSI/DPI to DP 2020-10-16 23:35:16 +02:00