[PATCH] wilc1000: Add id_table to spi_driver

Subsystems: microchip wilc1000 wifi driver, the rest

STALE1763d LANDED

Landed in mainline as f2f16ae9cc9c on 2021-12-08.

2 messages, 2 authors, 2021-12-08 · open the first message on its own page

[PATCH] wilc1000: Add id_table to spi_driver

From: David Mosberger-Tang <hidden>
Date: 2021-12-02 04:50:43

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 <redacted>
---
 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

Re: [PATCH] wilc1000: Add id_table to spi_driver

From: Kalle Valo <kvalo@kernel.org>
Date: 2021-12-08 18:33:33

David Mosberger-Tang [off-list ref] wrote:
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 <redacted>
Patch applied to wireless-drivers-next.git, thanks.

f2f16ae9cc9c wilc1000: Add id_table to spi_driver

-- 
https://patchwork.kernel.org/project/linux-wireless/patch/20211202045001.2901903-1-davidm@egauge.net/

https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help