From nobody Tue Dec 16 00:59:19 2025 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 1841D25A33F; Tue, 20 May 2025 06:34:53 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747722894; cv=none; b=HzSyLBktBZ0f0qO6yOMW4d9hGbFxKBjtwSwr9IPLisfKfHdO9ZivsQJtKyPYKohddSRGFYG0CmJnleCYRQeMOOZ5pwvnHRixFkMBKXC8u9Hq28VetUl4LvnULeW2ZWxQrP0dDJQu1/b55hEC4RF3H8HzkB6RoPBuy3UrA8PqXnE= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1747722894; c=relaxed/simple; bh=OL7PYd2KFiQcNdgb/Lbozay8dDafpJiTxMPrWeltM+w=; h=From:Date:Subject:MIME-Version:Content-Type:Message-Id:References: In-Reply-To:To:Cc; b=A60toUhG5b8X8vV+5/Ph/JYJHJEPZ4rOKPDyLU2JO8vmBTyXInAYeBOJ/kIGg5BGjtyVyckCa4s4VvAljoPxndNJcF8C5ba82guhHeo2j4GxtVVN+0fRQzMIJrcAzgzApY7Xr0zYY9lreUfCLl52HqdEAa+2aamCi65k+UeBxRQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=r+x2S6dB; arc=none smtp.client-ip=10.30.226.201 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="r+x2S6dB" Received: by smtp.kernel.org (Postfix) with ESMTPS id A2969C4CEF3; Tue, 20 May 2025 06:34:53 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1747722893; bh=OL7PYd2KFiQcNdgb/Lbozay8dDafpJiTxMPrWeltM+w=; h=From:Date:Subject:References:In-Reply-To:To:Cc:Reply-To:From; b=r+x2S6dBp1h2Gh0VLJmwt0cMvj7FfCPTFpaeOxaM7o0Ki5cAWcvV54kKx4fA+VKa+ XeWG8TcwZwK+Z++fhOTPdd6yaOvqTTyRKspLk+8JsFsflTHwrT4BGAQHBKIisJQr81 12Eu8wNWNkI5D7mJoVwaAFBaj7xvwipgv5P0HuKwmuCoIUvzI68eWi5R0gr4+8KhiZ crCRy7I7Z5NiakMYgazX4cT7ZL0ZvK4cGGpRP+L8TODI5bEtnCRCbnbT6L1AA0dOyi e0vf4ybGY8rIv7snkEhDBRN70l3H1XjutMvGHzzIalttA0CYqjE4IXrwrnt2SVLk8X uWR/+viPQB1DQ== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 8F9BFC3DA6D; Tue, 20 May 2025 06:34:53 +0000 (UTC) From: Maud Spierings via B4 Relay Date: Tue, 20 May 2025 08:34:51 +0200 Subject: [PATCH v7 2/8] arm64: dts: imx8mp: Add pinctrl config definitions Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Message-Id: <20250520-initial_display-v7-2-a8f0195420aa@gocontroll.com> References: <20250520-initial_display-v7-0-a8f0195420aa@gocontroll.com> In-Reply-To: <20250520-initial_display-v7-0-a8f0195420aa@gocontroll.com> To: Rob Herring , Krzysztof Kozlowski , Conor Dooley , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org, Maud Spierings , Frank Li X-Mailer: b4 0.14.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1747722892; l=2173; i=maudspierings@gocontroll.com; s=20250214; h=from:subject:message-id; bh=Tp5BCMz7EOT7+F0/OBD2pVg95lMHmhItqzrfsEeT2Qg=; b=Fvv9QmJtkNdpF50/rV09T9k9rGfKN06swbAAe/QozLyrakSgDxDMP7MXbVzh4cuj1OxMnibGX 5E6Q3b6Lu+RBgzOyPzvfg7xbQTgmN6i5DhaYi7UUiQfzaCNVl1b4sEW X-Developer-Key: i=maudspierings@gocontroll.com; a=ed25519; pk=7chUb8XpaTQDvWhzTdHC0YPMkTDloELEC7q94tOUyPg= X-Endpoint-Received: by B4 Relay for maudspierings@gocontroll.com/20250214 with auth_id=341 X-Original-From: Maud Spierings Reply-To: maudspierings@gocontroll.com From: Maud Spierings Currently to configure each IOMUXC_SW_PAD_CTL_PAD the raw value of this register is written in the dts, these values are not obvious. Add defines which describe the fields of this register which can be or-ed together to produce readable settings. Reviewed-by: Frank Li Acked-by: Rob Herring (Arm) Signed-off-by: Maud Spierings --- This patch has already been sent in a different group of patches: [1] It was requested there to submit it along with a user, this series also includes some users for it. [1]: https://lore.kernel.org/all/20250218-pinctrl_defines-v2-2-c554cad0e1d2= @gocontroll.com/ --- arch/arm64/boot/dts/freescale/imx8mp-pinfunc.h | 33 ++++++++++++++++++++++= ++++ 1 file changed, 33 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mp-pinfunc.h b/arch/arm64/bo= ot/dts/freescale/imx8mp-pinfunc.h index 0fef066471ba607be02d0ab15da5a048a8a213a7..16f5899de415263da40928078c4= c381099728fd5 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp-pinfunc.h +++ b/arch/arm64/boot/dts/freescale/imx8mp-pinfunc.h @@ -6,6 +6,39 @@ #ifndef __DTS_IMX8MP_PINFUNC_H #define __DTS_IMX8MP_PINFUNC_H =20 +/* Drive Strength */ +#define MX8MP_DSE_X1 0x0 +#define MX8MP_DSE_X2 0x4 +#define MX8MP_DSE_X4 0x2 +#define MX8MP_DSE_X6 0x6 + +/* Slew Rate */ +#define MX8MP_FSEL_FAST 0x10 +#define MX8MP_FSEL_SLOW 0x0 + +/* Open Drain */ +#define MX8MP_ODE_ENABLE 0x20 +#define MX8MP_ODE_DISABLE 0x0 + +#define MX8MP_PULL_DOWN 0x0 +#define MX8MP_PULL_UP 0x40 + +/* Hysteresis */ +#define MX8MP_HYS_CMOS 0x0 +#define MX8MP_HYS_SCHMITT 0x80 + +#define MX8MP_PULL_ENABLE 0x100 +#define MX8MP_PULL_DISABLE 0x0 + +/* SION force input mode */ +#define MX8MP_SION 0x40000000 + +/* long defaults */ +#define MX8MP_USDHC_DATA_DEFAULT (MX8MP_FSEL_FAST | MX8MP_PULL_UP | \ + MX8MP_HYS_SCHMITT | MX8MP_PULL_ENABLE) +#define MX8MP_I2C_DEFAULT (MX8MP_DSE_X6 | MX8MP_PULL_UP | MX8MP_HYS_SCHMIT= T | \ + MX8MP_PULL_ENABLE | MX8MP_SION) + /* * The pin function ID is a tuple of * --=20 2.49.0