All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] spi: dw: Make dw_spi_update_config()
@ 2026-10-10 15:14 Jisheng Zhang
  2026-10-12 22:27 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Jisheng Zhang @ 2026-10-10 15:14 UTC (permalink / raw)
  To: Mark Brown; +Cc: linux-spi, linux-kernel

After commit da0a672268b3 ("spi: dw: Remove not-going-to-be-supported
code for Baikal SoC"), no users of dw_spi_update_config() any more.
Unexport it and make it static. We can also move two structure
definitions to spi-dw-core.c at the same time.

Signed-off-by: Jisheng Zhang <jszhang@kernel.org>
---
 drivers/spi/spi-dw-core.c | 21 ++++++++++++++++++---
 drivers/spi/spi-dw.h      | 18 ------------------
 2 files changed, 18 insertions(+), 21 deletions(-)

diff --git a/drivers/spi/spi-dw-core.c b/drivers/spi/spi-dw-core.c
index 1f0e93800908..2d671e31413e 100644
--- a/drivers/spi/spi-dw-core.c
+++ b/drivers/spi/spi-dw-core.c
@@ -32,6 +32,22 @@ struct dw_spi_chip_data {
 	u32 rx_sample_dly;	/* RX sample delay */
 };
 
+/* Slave spi_transfer/spi_mem_op related */
+struct dw_spi_cfg {
+	u8 tmode;
+	u8 dfs;
+	u32 ndf;
+	u32 freq;
+	u8 spi_frf;
+};
+
+struct dw_spi_enh_cfg {
+	u8 wait_c;
+	u8 inst_l;
+	u8 addr_l;
+	u8 trans_t;
+};
+
 #ifdef CONFIG_DEBUG_FS
 
 #define DW_SPI_DBGFS_REG(_name, _off)	\
@@ -342,8 +358,8 @@ static u32 dw_spi_prepare_cr0(struct dw_spi *dws, struct spi_device *spi)
 	return cr0;
 }
 
-void dw_spi_update_config(struct dw_spi *dws, struct spi_device *spi,
-			  struct dw_spi_cfg *cfg, struct dw_spi_enh_cfg *enh_cfg)
+static void dw_spi_update_config(struct dw_spi *dws, struct spi_device *spi,
+				 struct dw_spi_cfg *cfg, struct dw_spi_enh_cfg *enh_cfg)
 {
 	struct dw_spi_chip_data *chip = spi_get_ctldata(spi);
 	u32 cr0 = chip->cr0;
@@ -406,7 +422,6 @@ void dw_spi_update_config(struct dw_spi *dws, struct spi_device *spi,
 		dw_writel(dws, DW_SPI_SPI_CTRLR0, cr0);
 	}
 }
-EXPORT_SYMBOL_NS_GPL(dw_spi_update_config, "SPI_DW_CORE");
 
 static void dw_spi_irq_setup(struct dw_spi *dws)
 {
diff --git a/drivers/spi/spi-dw.h b/drivers/spi/spi-dw.h
index bfdf371bcacb..c16225c5c887 100644
--- a/drivers/spi/spi-dw.h
+++ b/drivers/spi/spi-dw.h
@@ -158,22 +158,6 @@
 #define DW_SPI_GET_BYTE(_val, _idx) \
 	((_val) >> (BITS_PER_BYTE * (_idx)) & 0xff)
 
-/* Slave spi_transfer/spi_mem_op related */
-struct dw_spi_cfg {
-	u8 tmode;
-	u8 dfs;
-	u32 ndf;
-	u32 freq;
-	u8 spi_frf;
-};
-
-struct dw_spi_enh_cfg {
-	u8 wait_c;
-	u8 inst_l;
-	u8 addr_l;
-	u8 trans_t;
-};
-
 struct dw_spi;
 struct dw_spi_dma_ops {
 	int (*dma_init)(struct device *dev, struct dw_spi *dws);
@@ -345,8 +329,6 @@ static inline void dw_spi_shutdown_chip(struct dw_spi *dws)
 }
 
 extern void dw_spi_set_cs(struct spi_device *spi, bool enable);
-extern void dw_spi_update_config(struct dw_spi *dws, struct spi_device *spi,
-				 struct dw_spi_cfg *cfg, struct dw_spi_enh_cfg *enh_cfg);
 extern int dw_spi_check_status(struct dw_spi *dws, bool raw);
 extern int dw_spi_add_controller(struct device *dev, struct dw_spi *dws);
 extern void dw_spi_remove_controller(struct dw_spi *dws);
-- 
2.53.0


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

* Re: [PATCH] spi: dw: Make dw_spi_update_config()
  2026-10-10 15:14 [PATCH] spi: dw: Make dw_spi_update_config() Jisheng Zhang
@ 2026-10-12 22:27 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2026-10-12 22:27 UTC (permalink / raw)
  To: Jisheng Zhang; +Cc: linux-spi, linux-kernel

On Sat, 10 Oct 2026 23:14:59 +0800, Jisheng Zhang wrote:
> spi: dw: Make dw_spi_update_config()

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/spi.git for-7.4

Thanks!

[1/1] spi: dw: Make dw_spi_update_config()
      https://git.kernel.org/broonie/misc/c/306439eed9ea

All being well this means that it will be integrated into the linux-next
tree (usually sometime in the next 24 hours) and sent to Linus during
the next merge window (or sooner if it is a bug fix), however if
problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing
and review of the tree, please engage with people reporting problems and
send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they
should be sent as incremental updates against current git, existing
patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying
to this mail.

Thanks,
Mark


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

end of thread, other threads:[~2026-10-13 13:01 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-10 15:14 [PATCH] spi: dw: Make dw_spi_update_config() Jisheng Zhang
2026-10-12 22:27 ` Mark Brown

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.