summaryrefslogtreecommitdiff
path: root/drivers/ata/sata_gemini.c
diff options
context:
space:
mode:
authorDamien Le Moal <damien.lemoal@opensource.wdc.com>2022-10-13 17:30:34 +0900
committerDamien Le Moal <damien.lemoal@opensource.wdc.com>2022-10-18 08:04:46 +0900
commit6c4c900b7397365c1c1559fce90a50f1937921ee (patch)
treee7dae50dc9c1fac12bb9ccbf68627198c2f6ed16 /drivers/ata/sata_gemini.c
parent1dea5edc90855cab8359b599128e3f322803cd09 (diff)
ata: sata_gemini: Remove dependency on OF for compile tests
If CONFIG_OF is disabled, then using the macro of_match_ptr() results in the gemini_sata_of_match variable being unused, which generates a compilation warning and a compilation error if CONFIG_WERROR is enabled. Removing the use of this macro by directly assigning the gemini_sata_of_match match table to the .of_match_table field in the platform driver definition allows removing the dependency on OF for compile tests, thus improving compile test coverage. Fixes: f7220eac752f ("ata: Kconfig: fix sata gemini compile test condition") Signed-off-by: Damien Le Moal <damien.lemoal@opensource.wdc.com> Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/ata/sata_gemini.c')
-rw-r--r--drivers/ata/sata_gemini.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/ata/sata_gemini.c b/drivers/ata/sata_gemini.c
index b729e9919bb0..c42cc9bbbc4e 100644
--- a/drivers/ata/sata_gemini.c
+++ b/drivers/ata/sata_gemini.c
@@ -421,7 +421,7 @@ static const struct of_device_id gemini_sata_of_match[] = {
static struct platform_driver gemini_sata_driver = {
.driver = {
.name = DRV_NAME,
- .of_match_table = of_match_ptr(gemini_sata_of_match),
+ .of_match_table = gemini_sata_of_match,
},
.probe = gemini_sata_probe,
.remove = gemini_sata_remove,