summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet/asix
diff options
context:
space:
mode:
authorJakub Kicinski <kuba@kernel.org>2021-11-04 20:55:27 +0300
committerDavid S. Miller <davem@davemloft.net>2021-11-05 13:44:04 +0300
commit6789a4c05127d3f9257db6767fd7ede614e0241f (patch)
tree39ff3b08d2b78ea3c2e9e15877ad10a02fa16436 /drivers/net/ethernet/asix
parent69dfccbc1186f7091f97b70a9437d6a51313834d (diff)
downloadlinux-6789a4c05127d3f9257db6767fd7ede614e0241f.tar.xz
net: ax88796c: hide ax88796c_dt_ids if !CONFIG_OF
Build bot says: >> drivers/net/ethernet/asix/ax88796c_main.c:1116:34: warning: unused variable 'ax88796c_dt_ids' [-Wunused-const-variable] static const struct of_device_id ax88796c_dt_ids[] = { ^ The only reference to this array is wrapped in of_match_ptr(). Reported-by: kernel test robot <lkp@intel.com> Fixes: a97c69ba4f30 ("net: ax88796c: ASIX AX88796C SPI Ethernet Adapter Driver") Signed-off-by: Jakub Kicinski <kuba@kernel.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/asix')
-rw-r--r--drivers/net/ethernet/asix/ax88796c_main.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/asix/ax88796c_main.c b/drivers/net/ethernet/asix/ax88796c_main.c
index 4b0c5a09fd57..2086de05385c 100644
--- a/drivers/net/ethernet/asix/ax88796c_main.c
+++ b/drivers/net/ethernet/asix/ax88796c_main.c
@@ -1114,11 +1114,13 @@ static int ax88796c_remove(struct spi_device *spi)
return 0;
}
+#ifdef CONFIG_OF
static const struct of_device_id ax88796c_dt_ids[] = {
{ .compatible = "asix,ax88796c" },
{},
};
MODULE_DEVICE_TABLE(of, ax88796c_dt_ids);
+#endif
static const struct spi_device_id asix_id[] = {
{ "ax88796c", 0 },