From nobody Mon Oct 6 15:13:21 2025 Received: from mx.denx.de (mx.denx.de [89.58.32.78]) (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 42EE71EB3D; Sat, 19 Jul 2025 06:42:21 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=89.58.32.78 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752907342; cv=none; b=L9Qs6UvHyJ0GVPnleL5sUTta+52LE4Jrme2PD0fRSC2jG7706RS8+5r3bHJvcWNrSoJXQsKaebVYC04USZ6YsLLkKj4Xe6Hoh0NljGaP2c2AiImTM5wFgK2kKAkvdFiArV5G3/+CRJ57XyV6tSVS5SXxAJF+r2d9T9q2ZTkG+Ic= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752907342; c=relaxed/simple; bh=ZaaaMC9y/tvIrNbJiz0ihB/v219ZkoS3fwKyb4kFE0s=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=h5r2l/6VVAJiJcCwlZjhk7QUaNCXrM0zWwBKZAmaIU0t+u8DKV5rHCZpBKU6lYaemxlSM6OKzACs4Zu3KJ45zjcNu5Tr0ljfqBMXwGU2IThk2NxkIKSaF+ZsYbRDvibV7tTBMZITy8+rGzy1dYWjmD6d23liPYmLybPULZXDS/Y= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de; spf=pass smtp.mailfrom=denx.de; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b=I+2cPwbW; arc=none smtp.client-ip=89.58.32.78 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=denx.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b="I+2cPwbW" Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 09B681026E997; Sat, 19 Jul 2025 08:34:19 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=mx-20241105; t=1752906861; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding:in-reply-to:references; bh=TZcw6V3GROU8ELqtLuN73sY9LOkBh3a89bo1yjYcRlI=; b=I+2cPwbWUHhxZrjezH6Kj1GCdcMTRJWPQtGV3TZ6r9GjGp05x0mHCwYzUurNJGgofGKhpw 8M2bp0yJk8znvbZ/SMC3Mm6r37CooKgjIiIS1ZUWauppklLLDkuWWxoXne7nzL2SPURfuu oCECfegPLEB7uWOmNY1KTBTnxNXCZUoKhipFS8Bzs8GcEt3HU3qtPhBHdH1s4fkFeoqCOu HmjAWFTvmuCNAFt1IJS9aZ1+PYAqCKURLwddmbfpVVRlJpq9WrDKiKeqDb7V3aH0/zs95Q h4cr7lYbk7N3ybczHTnhKDEosrgTnhjJ0JAIzVNOlBD1Waf7I55sLWWlqI716w== From: Heiko Schocher To: linux-spi@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Heiko Schocher , Andrei Lalaev , Chanh Nguyen , Conor Dooley , Fabio Estevam , Grant Peltier , Guenter Roeck , Jonathan Cameron , Krzysztof Kozlowski , Laurent Pinchart , Michal Simek , Naresh Solanki , Rob Herring , Rodrigo Gobbi , devicetree@vger.kernel.org Subject: [PATCH v1 1/3] dt-bindings: trivial-devices: Document ABB sensors Date: Sat, 19 Jul 2025 08:33:52 +0200 Message-Id: <20250719063355.73111-2-hs@denx.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20250719063355.73111-1-hs@denx.de> References: <20250719063355.73111-1-hs@denx.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Last-TLS-Session-Version: TLSv1.3 Content-Type: text/plain; charset="utf-8" Add documentation for spi based ABB sensors, which are currently operated from userspace. Signed-off-by: Heiko Schocher --- Documentation/devicetree/bindings/trivial-devices.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/trivial-devices.yaml b/Docum= entation/devicetree/bindings/trivial-devices.yaml index 27930708ccd5..25260c2b81df 100644 --- a/Documentation/devicetree/bindings/trivial-devices.yaml +++ b/Documentation/devicetree/bindings/trivial-devices.yaml @@ -30,6 +30,8 @@ properties: items: # Entries are sorted alphanumerically by the compatible - enum: + # ABB register based spi sensors + - abb,spi-sensor # Acbel fsg032 power supply - acbel,fsg032 # SMBus/I2C Digital Temperature Sensor in 6-Pin SOT with SMBus= Alert and Over Temperature Pin --=20 2.20.1 From nobody Mon Oct 6 15:13:21 2025 Received: from mx.denx.de (mx.denx.de [89.58.32.78]) (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 4E4471EB39; Sat, 19 Jul 2025 06:34:29 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=89.58.32.78 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752906870; cv=none; b=HiwePTiRbHR/pfZpL0JaZaLcoPKq243TZvdNHCiRAuM6/5eC/MBVullEq/gtY89LnHZUG4Wqt4q5Xo8IRCq7jGqOPZcShb35c3abIat8kJKQo9AYxgJ0qwnjQsyADpgL1OIVbDPg2t1l4Zaw0aLRDBwCvvinRAN0ScjON13WJOA= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752906870; c=relaxed/simple; bh=n3KWkOCcHTVU6vNLmust/XfHc/BODC8tv2IfQRlQGps=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=M0bDUxuMagp+liBRvIJ3P0E7z3kfY8ftQdFqqNgvcjLw0tAV0+OhhTJX2CIzAlZN/8iaBBrarF4SbbbY9Qi49dPF4crbtlhBStoI3W8YSj/sHglqFsaMWMlQGoUMVQKckdNrxi2S120rjT2mVuttWC+016SC8wO9fZWkYAlDz1U= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de; spf=pass smtp.mailfrom=denx.de; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b=XEks53br; arc=none smtp.client-ip=89.58.32.78 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=denx.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b="XEks53br" Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id CD2D41026E99C; Sat, 19 Jul 2025 08:34:26 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=mx-20241105; t=1752906867; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding:in-reply-to:references; bh=ZsJipXJnLim3ZnxtZh7I9eTppXnxH1fDA/ujGPQeeOQ=; b=XEks53brWlX7ocrj+LN1OD0CjB3tARg49Tu9nv0Py72fIXNIX1VV+nYUuS7+yl4XSijLii AToloETvfmULnZkORcGFxN5Uwjcn4X7lFO0PZihHB2WJvWbk8vHY8lqVizuwfBF41ePBiU cjqcqTD7nzMS7vC0Gr7YLzj4wC0SSGogh1IGmQGANZWYSsEWWfm6Id8RROvmvCDg5uHrF+ jACXMWP9IY9JJNyeAL8/Rh464fJYfEMOh7NSapmWCsiN0I7VtsxfJKdsUxd6SFkD/hIpa9 wRrC6nuSykFBO5lBP48oW1LAZtBTgYr/zNdOygRzM7gQO49NROppSfTJcLU9cw== From: Heiko Schocher To: linux-spi@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Heiko Schocher , Mark Brown Subject: [PATCH v1 2/3] spi: spidev: Add an entry for the ABB spi sensors Date: Sat, 19 Jul 2025 08:33:53 +0200 Message-Id: <20250719063355.73111-3-hs@denx.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20250719063355.73111-1-hs@denx.de> References: <20250719063355.73111-1-hs@denx.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Last-TLS-Session-Version: TLSv1.3 Content-Type: text/plain; charset="utf-8" This sensors are currently controlled from userspace, ideally we will add full drivers in the future. Signed-off-by: Heiko Schocher --- drivers/spi/spidev.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/spi/spidev.c b/drivers/spi/spidev.c index 6108959c28d9..5300c942a2a4 100644 --- a/drivers/spi/spidev.c +++ b/drivers/spi/spidev.c @@ -703,6 +703,7 @@ static const struct class spidev_class =3D { * spidev_dt_ids array below. Both arrays are kept in the same ordering. */ static const struct spi_device_id spidev_spi_ids[] =3D { + { .name =3D /* abb */ "spi-sensor" }, { .name =3D /* cisco */ "spi-petra" }, { .name =3D /* dh */ "dhcom-board" }, { .name =3D /* elgin */ "jg10309-01" }, @@ -735,6 +736,7 @@ static int spidev_of_check(struct device *dev) } =20 static const struct of_device_id spidev_dt_ids[] =3D { + { .compatible =3D "abb,spi-sensor", .data =3D &spidev_of_check }, { .compatible =3D "cisco,spi-petra", .data =3D &spidev_of_check }, { .compatible =3D "dh,dhcom-board", .data =3D &spidev_of_check }, { .compatible =3D "elgin,jg10309-01", .data =3D &spidev_of_check }, --=20 2.20.1 From nobody Mon Oct 6 15:13:21 2025 Received: from mx.denx.de (mx.denx.de [89.58.32.78]) (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 44BF12288F9; Sat, 19 Jul 2025 06:34:32 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=89.58.32.78 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752906873; cv=none; b=ZukzXx5RfjiRizclJwsUFoOHii5W+1p3QYbZYjI0NriYwh6jQ8cCtlLMt8P8HrrULuIPYcRFrN93VeEStxQdDC+1mM4PMUvQVBgUPG6rpBqiIx259D2toB5Gk3Y6jCMtvGdbmh4X9qMp54zpm3RA9w4uD1TxHEqkRCAijiGvoII= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1752906873; c=relaxed/simple; bh=Cts4p0Q/oHC3LzZpBAvfSy4d3fhXG/mDthrN8Ts63fg=; h=From:To:Cc:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=clRQW9LYMl5SNjMJ2Vy3NlJPOaTJ7MPxhNdlfnYtMsoYw8TumTU+K2qcikv552DKQ4fZJFygGCC+KLLMLYMIUh3QgVbg1IEsVERWFdjPqrZu9lI5rqHzOrcF050Wy6puJg46PywnWS2wrO6dINVYJ8jTRRc8NmBbqk+O7GiWYBM= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de; spf=pass smtp.mailfrom=denx.de; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b=hp6+YCbj; arc=none smtp.client-ip=89.58.32.78 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=denx.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=denx.de Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=denx.de header.i=@denx.de header.b="hp6+YCbj" Received: from [127.0.0.1] (localhost [127.0.0.1]) by localhost (Mailerdaemon) with ESMTPSA id 526971026E9A1; Sat, 19 Jul 2025 08:34:29 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=mx-20241105; t=1752906870; h=from:subject:date:message-id:to:cc:mime-version: content-transfer-encoding:in-reply-to:references; bh=YPr66/zoW/Ul/rXlgG2lDYhfvi+t7ldJNuTap5nuaxU=; b=hp6+YCbjFFY2U5Gwhax9VTCclYxIMm0AKxAahjJorZwCA7MTaTgi0KmfOFLpukgPfr4iM4 ABAEcvMXuiiYX44WKPFY3Gq267xJKc1n+8Zqg0+BlYS7pBDsDBqMPDvEwbfY6dIJhiacS5 8e590CPgoRwpnyzkTDCXMt79ux5JV0F2GxzI1uGuLeI0cktXiFekcc82PIrzynzrwWoM0u CLR29A8d8+inoIGGu5HyLhPCCA2rzFWvd68lZo4FbNY2UxHjEdTMvzytZe6O7MvAfby1J4 9emCzF6cnbdWFqHiLK4UNcspLQkKFqWBiqvzmmNK/v656z7rfwNaU8I6swLWjA== From: Heiko Schocher To: linux-spi@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Heiko Schocher , Conor Dooley , Fabio Estevam , Krzysztof Kozlowski , Pengutronix Kernel Team , Rob Herring , Sascha Hauer , Shawn Guo , devicetree@vger.kernel.org, imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org Subject: [PATCH v1 3/3] arm64: dts: imx8mp: add ABB spi sensors Date: Sat, 19 Jul 2025 08:33:54 +0200 Message-Id: <20250719063355.73111-4-hs@denx.de> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20250719063355.73111-1-hs@denx.de> References: <20250719063355.73111-1-hs@denx.de> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable X-Last-TLS-Session-Version: TLSv1.3 Content-Type: text/plain; charset="utf-8" add for the spi busses the ABB sensor trivial compatible entry, so they can be accessed from userspace. Signed-off-by: Heiko Schocher --- .../freescale/imx8mp-aristainetos3-helios.dts | 28 +++++++++++++++++++ .../imx8mp-aristainetos3-proton2s.dts | 22 +++++++++++++++ 2 files changed, 50 insertions(+) diff --git a/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-helios.dts = b/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-helios.dts index a4e649a8239b..b6ba6229acd7 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-helios.dts +++ b/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-helios.dts @@ -52,6 +52,34 @@ }; }; =20 +&ecspi1 { + spidev0_0: spi@0 { + reg =3D <0>; + compatible =3D "abb,spi-sensor"; + spi-max-frequency =3D <54000000>; + }; + + spidev0_1: spi@1 { + compatible =3D "abb,spi-sensor"; + reg =3D <1>; + spi-max-frequency =3D <54000000>; + }; +}; + +&ecspi2 { + spidev1_0: spi@0 { + reg =3D <0>; + compatible =3D "abb,spi-sensor"; + spi-max-frequency =3D <54000000>; + }; + + spidev1_1: spi@1 { + reg =3D <1>; + compatible =3D "abb,spi-sensor"; + spi-max-frequency =3D <54000000>; + }; +}; + ðphy1 { status =3D "disabled"; }; diff --git a/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-proton2s.dt= s b/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-proton2s.dts index 2a736dbe96b4..e804688b2e74 100644 --- a/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-proton2s.dts +++ b/arch/arm64/boot/dts/freescale/imx8mp-aristainetos3-proton2s.dts @@ -28,6 +28,28 @@ }; }; =20 +&ecspi1 { + spidev0_0: spi@0 { + compatible =3D "abb,spi-sensor"; + reg =3D <0>; + spi-max-frequency =3D <54000000>; + }; + + spidev0_1: spi@1 { + compatible =3D "abb,spi-sensor"; + reg =3D <1>; + spi-max-frequency =3D <54000000>; + }; +}; + +&ecspi2 { + spidev1_0: spi@0 { + compatible =3D "abb,spi-sensor"; + reg =3D <0>; + spi-max-frequency =3D <54000000>; + }; +}; + ðphy1 { status =3D "disabled"; }; --=20 2.20.1