Skip to contentSkip to conversation

spi: davinci: Full dm conversion

PATCH New Jagan Teki 1 participant 1 message Mar 6, 2018 SPI

lore
Share & tools
lore

Jagan Teki

author
#0 lore raw

PATCH 1/1 spi: davinci: Full dm conversion

davinci_spi now support dt along with platform data, respective boards need to switch into dm for the same.

---
 drivers/spi/Kconfig                    |  12 +-
 drivers/spi/davinci_spi.c              | 275 +++++++++------------------------
 include/dm/platform_data/spi_davinci.h |  15 ++
 3 files changed, 90 insertions(+), 212 deletions(-)
 create mode 100644 include/dm/platform_data/spi_davinci.h
drivers/spi/Kconfig +6 -6
index 2f231fc12b..589484fba0 100644
@@ -70,6 +70,12 @@ config CADENCE_QSPI
 	  used to access the SPI NOR flash on platforms embedding this
 	  Cadence IP core.
 
+config DAVINCI_SPI
+	bool "Davinci & Keystone SPI driver"
+	depends on ARCH_DAVINCI || ARCH_KEYSTONE
+	help
+	  Enable the Davinci SPI driver
+
 config DESIGNWARE_SPI
 	bool "Designware SPI driver"
 	help
@@ -246,12 +252,6 @@ config FSL_QSPI
 	  used to access the SPI NOR flash on platforms embedding this
 	  Freescale IP core.
 
-config DAVINCI_SPI
-	bool "Davinci & Keystone SPI driver"
-	depends on ARCH_DAVINCI || ARCH_KEYSTONE
-	help
-	  Enable the Davinci SPI driver
-
 config SH_SPI
 	bool "SuperH SPI driver"
 	help
drivers/spi/davinci_spi.c +69 -206

350 lines not on this page · raw message

include/dm/platform_data/spi_davinci.h new file +15 -0
new file mode 100644
index 0000000000..fbc62c262a
@@ -0,0 +1,15 @@
+/*
+ * Copyright (C) 2018 Jagan Teki <[email protected]>
+ *
+ * SPDX-License-Identifier:	GPL-2.0+
+ */
+
+#ifndef __spi_davinci_h
+#define __spi_davinci_h
+
+struct davinci_spi_platdata {
+	struct davinci_spi_regs *regs;
+	u8 num_cs;	   /* total no. of CS available */
+};
+
+#endif /* __spi_davinci_h */
Signature · 1 line
2.14.3