Skip to contentSkip to conversation

spi: nds_ae3xx: Rename nds_ae3xx_spi as atcspi200_spi

PATCH Superseded Andes 1 participant 4 messages Nov 15, 2017 SPI

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore

Andes

author
#0 lore raw

cover spi: nds_ae3xx: Rename nds_ae3xx_spi as atcspi200_spi

From: Rick Chen <[email protected]>

ATCSPI200 is Andestech SPI IP which is embedded in AE3XX and AE250 platforms.So rename it as atcspi200 will be more reasonable to be used in different platforms in the future.

Rick Chen (3):
spi: nds_ae3xx: Rename nds_ae3xx_spi as atcspi200_spi
nds32: defconfig: Rename NDS_AE3XX as ATCSPI200
dt-bindings: spi: Add andestech atcspi200 spi binding doc

 configs/adp-ae3xx_defconfig                    |    2 +-
 doc/device-tree-bindings/spi/spi-atcspi200.txt |   37 ++
 drivers/spi/Kconfig                            |   10 +-
 drivers/spi/Makefile                           |    2 +-
 drivers/spi/atcspi200_spi.c                    |  499 ++++++++++++++++++++++++
 drivers/spi/nds_ae3xx_spi.c                    |  499 ------------------------
 6 files changed, 543 insertions(+), 506 deletions(-)
 create mode 100644 doc/device-tree-bindings/spi/spi-atcspi200.txt
 create mode 100644 drivers/spi/atcspi200_spi.c
 delete mode 100644 drivers/spi/nds_ae3xx_spi.c
Signature · 1 line
1.7.9.5
author
#1 lore raw

PATCH 1/3 spi: nds_ae3xx: Rename nds_ae3xx_spi as atcspi200_spi

From: Rick Chen <[email protected]>

atcspi200 is Andestech spi ip which is embedded in AE3XX and AE250 platforms. So rename as atcspi200 will be more reasonable to be used in different platforms.

---
 drivers/spi/Kconfig         |   10 +-
 drivers/spi/Makefile        |    2 +-
 drivers/spi/atcspi200_spi.c |  499 +++++++++++++++++++++++++++++++++++++++++++
 drivers/spi/nds_ae3xx_spi.c |  499 -------------------------------------------
 4 files changed, 505 insertions(+), 505 deletions(-)
 create mode 100644 drivers/spi/atcspi200_spi.c
 delete mode 100644 drivers/spi/nds_ae3xx_spi.c
drivers/spi/Kconfig +5 -5
index 88da9a4..494639f 100644
@@ -210,12 +210,12 @@ config FSL_QSPI
 	  used to access the SPI NOR flash on platforms embedding this
 	  Freescale IP core.
 
-config NDS_AE3XX_SPI
-	bool "Andestech AE3XX SPI driver"
+config ATCSPI200_SPI
+	bool "Andestech ATCSPI200 SPI driver"
 	help
-	  Enable the Andestech AE3XX SPI driver. This driver can be
-	  used to access the SPI flash on platforms embedding this
-	  Andestech IP core.
+	  Enable the Andestech ATCSPI200 SPI driver. This driver can be
+	  used to access the SPI flash on AE3XX and AE250 platforms embedding
+	  this Andestech IP core.
 
 config TI_QSPI
 	bool "TI QSPI driver"
drivers/spi/Makefile +1 -1
index ad56203..e3184db 100644
@@ -34,7 +34,7 @@ obj-$(CONFIG_MPC8XXX_SPI) += mpc8xxx_spi.o
 obj-$(CONFIG_MVEBU_A3700_SPI) += mvebu_a3700_spi.o
 obj-$(CONFIG_MXC_SPI) += mxc_spi.o
 obj-$(CONFIG_MXS_SPI) += mxs_spi.o
-obj-$(CONFIG_NDS_AE3XX_SPI) += nds_ae3xx_spi.o
+obj-$(CONFIG_ATCSPI200_SPI) += atcspi200_spi.o
 obj-$(CONFIG_OMAP3_SPI) += omap3_spi.o
 obj-$(CONFIG_PIC32_SPI) += pic32_spi.o
 obj-$(CONFIG_ROCKCHIP_SPI) += rk_spi.o
drivers/spi/atcspi200_spi.c new file +499 -0

499 lines not on this page · raw message

drivers/spi/nds_ae3xx_spi.c deleted +0 -499

499 lines not on this page · raw message

Signature · 1 line
1.7.9.5
author
#2 lore raw

PATCH 2/3 nds32: defconfig: Rename NDS_AE3XX as ATCSPI200

In reply to Andes

From: Rick Chen <[email protected]>

Modify Andestech ae3xx board defconfig NDS_AE3XX
as ATCSPI200 for spi driver renaming.

---
 configs/adp-ae3xx_defconfig |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
configs/adp-ae3xx_defconfig +1 -1
index a3d8b29..6005669 100644
@@ -36,6 +36,6 @@ CONFIG_BAUDRATE=38400
 CONFIG_DM_SERIAL=y
 CONFIG_SYS_NS16550=y
 CONFIG_DM_SPI=y
-CONFIG_NDS_AE3XX_SPI=y
+CONFIG_ATCSPI200_SPI=y
 CONFIG_TIMER=y
 CONFIG_ATCPIT100_TIMER=y
Signature · 1 line
1.7.9.5
author
#3 lore raw

PATCH 3/3 dt-bindings: spi: Add andestech atcspi200 spi binding doc

In reply to Andes

From: Rick Chen <[email protected]>

Add a document to describe Andestech atcspi200 spi and binding information.

---
 doc/device-tree-bindings/spi/spi-atcspi200.txt |   37 ++++++++++++++++++++++++
 1 file changed, 37 insertions(+)
 create mode 100644 doc/device-tree-bindings/spi/spi-atcspi200.txt
doc/device-tree-bindings/spi/spi-atcspi200.txt new file +37 -0
new file mode 100644
index 0000000..9c0630b
@@ -0,0 +1,37 @@
+Andestech ATCSPI200 SPI controller Device Tree Bindings
+-------------------------------------------------------
+ATCSPI200 is a Serial Peripheral Interface (SPI) controller
+which serves as a SPI master or a SPI slave.
+
+It is often be embedded in AE3XX and AE250 platforms.
+
+Required properties:
+- compatible: has to be "andestech,atcspi200".
+- reg: Base address and size of the controllers memory area.
+- #address-cells: <1>, as required by generic SPI binding.
+- #size-cells: <0>, also as required by generic SPI binding.
+- interrupts: Property with a value describing the interrupt number.
+- clocks: Clock phandles (see clock bindings for details).
+- spi-max-frequency: Maximum SPI clocking speed of device in Hz.
+
+Optional properties:
+- num-cs: Number of chip selects used.
+
+Example:
+
+	spi: spi at f0b00000 {
+		compatible = "andestech,atcspi200";
+		reg = <0xf0b00000 0x1000>;
+		#address-cells = <1>;
+		#size-cells = <0>;
+		num-cs = <1>;
+		clocks = <&spiclk>;
+		interrupts = <3 4>;
+		flash at 0 {
+			compatible = "spi-flash";
+			spi-max-frequency = <50000000>;
+			reg = <0>;
+			spi-cpol;
+			spi-cpha;
+		};
+	};
Signature · 1 line
1.7.9.5