Skip to contentSkip to conversation

pinctrl: add support for exynos7420 pinctrl driver

PATCH New Thomas Abraham 3 participants 6 messages Apr 6, 2016 – Apr 12, 2016

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

cover pinctrl: add support for exynos7420 pinctrl driver

This patch series adds initial support for Exynos7420 pinctrl driver. The portions of the code that are reusable on other Exynos SoCs has been factored out into a different file. The pin state configurations are looked up from the device tree and the bindings are similar to the bindings used in the linux kernel.

This patch series adds just the Exynos7420 pinctrl driver support. The rest of the Exynos7420 SoC support will be posted later.

Thomas Abraham (2):
pinctrl: add the DM_UC_FLAG_SEQ_ALIAS flag for numbering the devices
pinctrl: Add pinctrl driver support for Exynos7420 SoC

 drivers/pinctrl/Kconfig                     |    1 +
 drivers/pinctrl/Makefile                    |    1 +
 drivers/pinctrl/exynos/Kconfig              |   10 ++
 drivers/pinctrl/exynos/Makefile             |    9 ++
 drivers/pinctrl/exynos/pinctrl-exynos.c     |  141 +++++++++++++++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos.h     |   77 +++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos7420.c |  121 +++++++++++++++++++++++
 drivers/pinctrl/pinctrl-uclass.c            |    1 +
 8 files changed, 361 insertions(+), 0 deletions(-)
 create mode 100644 drivers/pinctrl/exynos/Kconfig
 create mode 100644 drivers/pinctrl/exynos/Makefile
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.c
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.h
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos7420.c
#1 lore raw

PATCH 1/2 pinctrl: add the DM_UC_FLAG_SEQ_ALIAS flag for numbering the devices

It is possible to have multiple pin controllers in the system. Use the DM_UC_FLAG_SEQ_ALIAS flag so that the pinctrl instances are assigned a sequence number.

Cc Masahiro Yamada <[email protected]>
Cc Simon Glass <[email protected]>
---
 drivers/pinctrl/pinctrl-uclass.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/pinctrl/pinctrl-uclass.c +1 -0
index ccc5d30..fd04b26 100644
@@ -287,5 +287,6 @@ static int pinctrl_post_bind(struct udevice *dev)
 UCLASS_DRIVER(pinctrl) = {
 	.id = UCLASS_PINCTRL,
 	.post_bind = pinctrl_post_bind,
+	.flags = DM_UC_FLAG_SEQ_ALIAS,
 	.name = "pinctrl",
 };
Signature · 1 line
1.6.6.rc2
#2 lore raw

PATCH 1/2 pinctrl: add the DM_UC_FLAG_SEQ_ALIAS flag for numbering the devices

Quoted 10 lines · Thomas Abraham

It is possible to have multiple pin controllers in the system. Use the DM_UC_FLAG_SEQ_ALIAS flag so that the pinctrl instances are assigned a sequence number.

Cc Masahiro Yamada <[email protected]>
Cc Simon Glass <[email protected]>
---
 drivers/pinctrl/pinctrl-uclass.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)
#3 lore raw

PATCH 2/2 pinctrl: Add pinctrl driver support for Exynos7420 SoC

In reply to Thomas Abraham

Add pinctrl driver support for Samsung's Exynos7420 SoC. The changes have been split into Exynos7420 specific and common Exynos specific portions so that this implementation is reusable on other Exynos SoCs as well.

The Exynos pinctrl driver supports only device tree based pin configuration. The bindings used are similar to the ones used in the linux kernel.

Cc Masahiro Yamada <[email protected]>
Cc Simon Glass <[email protected]>
Cc Minkyu Kang <[email protected]>
---
 drivers/pinctrl/Kconfig                     |    1 +
 drivers/pinctrl/Makefile                    |    1 +
 drivers/pinctrl/exynos/Kconfig              |   10 ++
 drivers/pinctrl/exynos/Makefile             |    9 ++
 drivers/pinctrl/exynos/pinctrl-exynos.c     |  141 +++++++++++++++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos.h     |   77 +++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos7420.c |  121 +++++++++++++++++++++++
 7 files changed, 360 insertions(+), 0 deletions(-)
 create mode 100644 drivers/pinctrl/exynos/Kconfig
 create mode 100644 drivers/pinctrl/exynos/Makefile
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.c
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.h
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos7420.c
drivers/pinctrl/Kconfig +1 -0
index 2a69bab..bdf8931 100644
@@ -145,5 +145,6 @@ endif
 
 source "drivers/pinctrl/nxp/Kconfig"
 source "drivers/pinctrl/uniphier/Kconfig"
+source "drivers/pinctrl/exynos/Kconfig"
 
 endmenu
drivers/pinctrl/Makefile +1 -0
index 37dc904..19beb04 100644
@@ -11,3 +11,4 @@ obj-$(CONFIG_PINCTRL_SANDBOX)	+= pinctrl-sandbox.o
 
 obj-$(CONFIG_PINCTRL_UNIPHIER)	+= uniphier/
 obj-$(CONFIG_PIC32_PINCTRL)	+= pinctrl_pic32.o
+obj-$(CONFIG_PINCTRL_EXYNOS)	+= exynos/
drivers/pinctrl/exynos/Kconfig new file +10 -0
new file mode 100644
index 0000000..84b6aaa
@@ -0,0 +1,10 @@
+config PINCTRL_EXYNOS
+	bool
+
+config PINCTRL_EXYNOS7420
+	bool "Samsung Exynos7420 pinctrl driver"
+	depends on ARCH_EXYNOS && PINCTRL_FULL
+	select PINCTRL_EXYNOS
+	help
+	  Support pin multiplexing and pin configuration control on
+	  Samsung's Exynos7420 SoC.
drivers/pinctrl/exynos/Makefile new file +9 -0
new file mode 100644
index 0000000..d9b941a
@@ -0,0 +1,9 @@
+#
+# Copyright (C) 2016 Samsung Electronics
+# Thomas Abraham <[email protected]>
+#
+# SPDX-License-Identifier:	GPL-2.0+
+#
+
+obj-$(CONFIG_PINCTRL_EXYNOS)		+= pinctrl-exynos.o
+obj-$(CONFIG_PINCTRL_EXYNOS7420)	+= pinctrl-exynos7420.o
drivers/pinctrl/exynos/pinctrl-exynos.c new file +141 -0

141 lines not on this page · raw message

drivers/pinctrl/exynos/pinctrl-exynos.h new file +77 -0

77 lines not on this page · raw message

drivers/pinctrl/exynos/pinctrl-exynos7420.c new file +121 -0

121 lines not on this page · raw message

Signature · 1 line
1.6.6.rc2
#4 lore raw

PATCH 2/2 pinctrl: Add pinctrl driver support for Exynos7420 SoC

Quoted 13 lines · Thomas Abraham

Add pinctrl driver support for Samsung's Exynos7420 SoC. The changes have been split into Exynos7420 specific and common Exynos specific portions so that this implementation is reusable on other Exynos SoCs as well.

The Exynos pinctrl driver supports only device tree based pin configuration. The bindings used are similar to the ones used in the linux kernel.

Cc Masahiro Yamada <[email protected]>
Cc Simon Glass <[email protected]>
Cc Minkyu Kang <[email protected]>
Quoted 14 lines
---
 drivers/pinctrl/Kconfig                     |    1 +
 drivers/pinctrl/Makefile                    |    1 +
 drivers/pinctrl/exynos/Kconfig              |   10 ++
 drivers/pinctrl/exynos/Makefile             |    9 ++
 drivers/pinctrl/exynos/pinctrl-exynos.c     |  141 +++++++++++++++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos.h     |   77 +++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos7420.c |  121 +++++++++++++++++++++++
 7 files changed, 360 insertions(+), 0 deletions(-)
 create mode 100644 drivers/pinctrl/exynos/Kconfig
 create mode 100644 drivers/pinctrl/exynos/Makefile
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.c
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.h
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos7420.c
#5 lore raw

PATCH 2/2 pinctrl: Add pinctrl driver support for Exynos7420 SoC

Quoted 29 lines · Simon Glass
Quoted 13 lines · Thomas Abraham

Add pinctrl driver support for Samsung's Exynos7420 SoC. The changes have been split into Exynos7420 specific and common Exynos specific portions so that this implementation is reusable on other Exynos SoCs as well.

The Exynos pinctrl driver supports only device tree based pin configuration. The bindings used are similar to the ones used in the linux kernel.

Cc Masahiro Yamada <[email protected]>
Cc Simon Glass <[email protected]>
Cc Minkyu Kang <[email protected]>
Quoted 14 lines
---
 drivers/pinctrl/Kconfig                     |    1 +
 drivers/pinctrl/Makefile                    |    1 +
 drivers/pinctrl/exynos/Kconfig              |   10 ++
 drivers/pinctrl/exynos/Makefile             |    9 ++
 drivers/pinctrl/exynos/pinctrl-exynos.c     |  141 +++++++++++++++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos.h     |   77 +++++++++++++++
 drivers/pinctrl/exynos/pinctrl-exynos7420.c |  121 +++++++++++++++++++++++
 7 files changed, 360 insertions(+), 0 deletions(-)
 create mode 100644 drivers/pinctrl/exynos/Kconfig
 create mode 100644 drivers/pinctrl/exynos/Makefile
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.c
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos.h
 create mode 100644 drivers/pinctrl/exynos/pinctrl-exynos7420.c
Quoted 3 lines

Thanks,
Minkyu Kang.