mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] wilc1000: Add id_table to spi_driver
@ 2021-12-02  4:50 David Mosberger-Tang
  2021-12-08 18:33 ` Kalle Valo
  0 siblings, 1 reply; 2+ messages in thread
From: David Mosberger-Tang @ 2021-12-02  4:50 UTC (permalink / raw)
  To: Ajay Singh
  Cc: Claudiu Beznea, Kalle Valo, David S. Miller, Jakub Kicinski,
	linux-wireless, netdev, linux-kernel, David Mosberger-Tang

This eliminates warning message:

	SPI driver WILC_SPI has no spi_device_id for microchip,wilc1000

and makes device-tree autoloading work.

Signed-off-by: David Mosberger-Tang <davidm@egauge.net>
---
 drivers/net/wireless/microchip/wilc1000/spi.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/drivers/net/wireless/microchip/wilc1000/spi.c b/drivers/net/wireless/microchip/wilc1000/spi.c
index 640850f989dd..6e7fd18c14e7 100644
--- a/drivers/net/wireless/microchip/wilc1000/spi.c
+++ b/drivers/net/wireless/microchip/wilc1000/spi.c
@@ -203,11 +203,18 @@ static const struct of_device_id wilc_of_match[] = {
 };
 MODULE_DEVICE_TABLE(of, wilc_of_match);
 
+static const struct spi_device_id wilc_spi_id[] = {
+	{ "wilc1000", 0 },
+	{ /* sentinel */ }
+};
+MODULE_DEVICE_TABLE(spi, wilc_spi_id);
+
 static struct spi_driver wilc_spi_driver = {
 	.driver = {
 		.name = MODALIAS,
 		.of_match_table = wilc_of_match,
 	},
+	.id_table = wilc_spi_id,
 	.probe =  wilc_bus_probe,
 	.remove = wilc_bus_remove,
 };
-- 
2.25.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2021-12-08 18:33 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-12-02  4:50 [PATCH] wilc1000: Add id_table to spi_driver David Mosberger-Tang
2021-12-08 18:33 ` Kalle Valo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®