summaryrefslogtreecommitdiffstats
path: root/drivers/net/dsa/b53/b53_spi.c
diff options
context:
space:
mode:
authorÁlvaro Fernández Rojas <noltari@gmail.com>2021-03-15 15:14:23 +0100
committerDavid S. Miller <davem@davemloft.net>2021-03-16 11:11:24 -0700
commit6d16eadab6db0c1d61e59fee7ed1ecc2d10269be (patch)
treed40c5df37f08a472de963a090885a207784a8a1c /drivers/net/dsa/b53/b53_spi.c
parent1bf343665057312167750509b0c48e8299293ac5 (diff)
downloadlinux-6d16eadab6db0c1d61e59fee7ed1ecc2d10269be.tar.bz2
net: dsa: b53: spi: allow device tree probing
Add missing of_match_table to allow device tree probing. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/dsa/b53/b53_spi.c')
-rw-r--r--drivers/net/dsa/b53/b53_spi.c13
1 files changed, 13 insertions, 0 deletions
diff --git a/drivers/net/dsa/b53/b53_spi.c b/drivers/net/dsa/b53/b53_spi.c
index 7abec8dab8ba..413158275db8 100644
--- a/drivers/net/dsa/b53/b53_spi.c
+++ b/drivers/net/dsa/b53/b53_spi.c
@@ -324,9 +324,22 @@ static int b53_spi_remove(struct spi_device *spi)
return 0;
}
+static const struct of_device_id b53_spi_of_match[] = {
+ { .compatible = "brcm,bcm5325" },
+ { .compatible = "brcm,bcm5365" },
+ { .compatible = "brcm,bcm5395" },
+ { .compatible = "brcm,bcm5397" },
+ { .compatible = "brcm,bcm5398" },
+ { .compatible = "brcm,bcm53115" },
+ { .compatible = "brcm,bcm53125" },
+ { .compatible = "brcm,bcm53128" },
+ { /* sentinel */ }
+};
+
static struct spi_driver b53_spi_driver = {
.driver = {
.name = "b53-switch",
+ .of_match_table = b53_spi_of_match,
},
.probe = b53_spi_probe,
.remove = b53_spi_remove,