lkml.org 
[lkml]   [2022]   [Sep]   [5]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
Subject[PATCH 1/3] leds: cr0014114: silent no spi_device_id warning
Date
From: Wei Yongjun <weiyongjun1@huawei.com>

Add spi_device_id entries to silent following SPI warning:

SPI driver leds_cr0014114 has no spi_device_id for crane,cr0014114

Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
---
drivers/leds/leds-cr0014114.c | 7 +++++++
1 file changed, 7 insertions(+)

diff --git a/drivers/leds/leds-cr0014114.c b/drivers/leds/leds-cr0014114.c
index c87686bd7c18..095455163246 100644
--- a/drivers/leds/leds-cr0014114.c
+++ b/drivers/leds/leds-cr0014114.c
@@ -281,9 +281,16 @@ static const struct of_device_id cr0014114_dt_ids[] = {

MODULE_DEVICE_TABLE(of, cr0014114_dt_ids);

+static const struct spi_device_id cr0014114_spi_ids[] = {
+ { "cr0014114" },
+ { },
+};
+MODULE_DEVICE_TABLE(spi, cr0014114_spi_ids);
+
static struct spi_driver cr0014114_driver = {
.probe = cr0014114_probe,
.remove = cr0014114_remove,
+ .id_table = cr0014114_spi_ids,
.driver = {
.name = KBUILD_MODNAME,
.of_match_table = cr0014114_dt_ids,
--
2.34.1
\
 
 \ /
  Last update: 2022-09-05 17:12    [W:0.047 / U:0.920 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site