Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1689231

[RESEND RFC PATCH] ARM: dts: stm32: change pinctrl bindings definition

Path csiph.com!eternal-september.org!feeder.eternal-september.org!aioe.org!bofh.it!news.nic.it!robomod
From Alexandre Torgue <alexandre.torgue@st.com>
Newsgroups linux.kernel
Subject [RESEND RFC PATCH] ARM: dts: stm32: change pinctrl bindings definition
Date Mon, 17 Jul 2017 18:30:02 +0200
Message-ID <u4h4e-7oe-15@gated-at.bofh.it> (permalink)
X-Original-To Maxime Coquelin <mcoquelin.stm32@gmail.com>, Linus Walleij <linus.walleij@linaro.org>, Rob Herring <robh+dt@kernel.org>, Mark Rutland <mark.rutland@arm.com>, Arnd Bergmann <arnd@arndb.de>, Russell King <linux@armlinux.org.uk>
X-Mailer git-send-email 1.9.1
MIME-Version 1.0
Content-Type text/plain
X-Originating-IP [10.75.127.45]
X-Clientproxiedby SFHDAG5NODE1.st.com (10.75.127.13) To SFHDAG3NODE2.st.com (10.75.127.8)
X-Proofpoint-Virus-Version vendor=fsecure engine=2.50.10432:,, definitions=2017-07-17_12:,, signatures=0
Sender robomod@news.nic.it
List-ID <linux-kernel.vger.kernel.org>
X-Mailing-List linux-kernel@vger.kernel.org
Approved robomod@news.nic.it
Lines 36
Organization linux.* mail to news gateway
X-Original-Cc <linux-arm-kernel@lists.infradead.org>, <devicetree@vger.kernel.org>, <linux-kernel@vger.kernel.org>
X-Original-Date Mon, 17 Jul 2017 18:23:49 +0200
X-Original-Message-ID <1500308630-14364-1-git-send-email-alexandre.torgue@st.com>
X-Original-Sender linux-kernel-owner@vger.kernel.org
Xref csiph.com linux.kernel:1689231

Show key headers only | View raw


Initially each pin was declared in "include/dt-bindings/stm32f429-pinfunc.h"
and each definition contained SOC names (ex: STM32F429_PA9_FUNC_USART1_TX).
Since this approach was approved, the number of supported MCU has
increased (STM32F429/STM32F469/STM32f746/STM32H743). To avoid to add a new
file in "include/dt-bindings" each time a new STM32 SOC arrives I propose
a new approach which consist to use a macro to define pin muxing in device
tree. All STM32 DT will use the common macro to define pinmux. Furthermore, it
will make easy maintenance and integration of new SOC.

To check that patch generate same dtb than befrore I used dtc binary to (re)generate dts files
(before and after apply the series).
Example on stm32f469-disco:

./scripts/dtc/dtc -I dtb -O dts -o stm32f469-disco-after.dts
stm32f469-disco-after.dtb

./scripts/dtc/dtc -I dtb -O dts -o stm32f469-disco-before.dts
stm32f469-disco-before.dtb

Then diff -u stm32f469-disco-before.dts stm32f469-disco-after.dts

Regards
Alex

Alexandre TORGUE (1):
  ARM: dts: stm32: change pinctrl bindings definition

 arch/arm/boot/dts/stm32f429.dtsi                |  176 ++--
 include/dt-bindings/pinctrl/stm32-pinfunc.h     |   61 ++
 include/dt-bindings/pinctrl/stm32f429-pinfunc.h | 1239 -----------------------
 3 files changed, 149 insertions(+), 1327 deletions(-)
 create mode 100644 include/dt-bindings/pinctrl/stm32-pinfunc.h
 delete mode 100644 include/dt-bindings/pinctrl/stm32f429-pinfunc.h

-- 
1.9.1

Back to linux.kernel | Previous | Next | Find similar | Unroll thread


Thread

[RESEND RFC PATCH] ARM: dts: stm32: change pinctrl bindings definition Alexandre Torgue <alexandre.torgue@st.com> - 2017-07-17 18:30 +0200

csiph-web