[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20240222172853.25082-4-fancer.lancer@gmail.com>
Date: Thu, 22 Feb 2024 20:28:46 +0300
From: Serge Semin <fancer.lancer@...il.com>
To: Serge Semin <fancer.lancer@...il.com>,
Mark Brown <broonie@...nel.org>,
Andy Shevchenko <andy.shevchenko@...il.com>
Cc: Alexey Malahov <Alexey.Malahov@...kalelectronics.ru>,
Andy Shevchenko <andriy.shevchenko@...ux.intel.com>,
Andy Shevchenko <andy@...nel.org>,
linux-spi@...r.kernel.org,
linux-kernel@...r.kernel.org
Subject: [PATCH v2 3/4] spi: dw: Convert dw_spi::num_cs to u32
Number of native chip-select lines is either retrieved from the "num-cs"
DT-property or auto-detected in the generic DW APB/AHB SSI probe method.
In the former case the property is supposed to be of the "u32" size.
Convert the field type to being u32 then to be able to drop the temporary
variable afterwards.
Signed-off-by: Serge Semin <fancer.lancer@...il.com>
---
Changelog v2:
- Just added.
---
drivers/spi/spi-dw.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index 6cafeee8ee2a..fc267c6437ae 100644
--- a/drivers/spi/spi-dw.h
+++ b/drivers/spi/spi-dw.h
@@ -164,8 +164,8 @@ struct dw_spi {
u32 max_freq; /* max bus freq supported */
u32 reg_io_width; /* DR I/O width in bytes */
+ u32 num_cs; /* chip select lines */
u16 bus_num;
- u16 num_cs; /* supported slave numbers */
void (*set_cs)(struct spi_device *spi, bool enable);
/* Current message transfer state info */
--
2.43.0
Powered by blists - more mailing lists