From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (prime256v1) server-digest SHA256) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8EFCF606A327 for ; Tue, 1 Dec 2026 12:04:14 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.a=rsa-sha256 header.s=bombadil.20210309 header.b=bU1kHFgh; dkim=pass (1024-bit key) header.d=arm.com header.i=@arm.com header.a=rsa-sha256 header.s=foss header.b=dhEfweLP DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Content-Transfer-Encoding: Content-Type:In-Reply-To:From:References:Cc:To:Subject:MIME-Version:Date: Message-ID:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Unsubscribe-Post: List-Owner; bh=cc4T5n/8LX33z4hKplc8+24xsZKXnIhD0tejrMLfYU4=; b=bU1kHFghQtXU0P CSSV4CePahxmrJqUGHmI3BGvMxFXv8wv+w+D1QjYzIVqL2Sku4SmBhrsUMelL4cEK3jdLS59ZrNTK AVhTvHTTsXhcboR8G1yuI9WoWNdJVR9MdGPvTOqQJiMJmW0BeEe3FE3zl3czbqR9Tn2l4ffmJAb7m ypV5lCVC0y/0hwrX1wOtK4mQ7RPwX2LaRGuoxoFxrWRv5fUj0/mVWWojTbG0K8zvzSY1zh+gJX6Bp +07cGvhtJfsecFDdVVD/lzkRuxMZyHrXVaelEV4I6S0nvXJlvwwF8hXbPMIrzE8hF9os2PIrc1ATa xy2fuDzC1ZBVvTRq5zTQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xYMaR-00000007hdR-3GZL; Tue, 01 Dec 2026 12:03:55 +0000 Received: from foss.arm.com ([217.140.110.172]) by bombadil.infradead.org with esmtp (Exim 4.100.1 #2 (Red Hat Linux)) id 1xYMaP-00000007hcW-29X7 for linux-arm-kernel@lists.infradead.org; Tue, 01 Dec 2026 12:03:55 +0000 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 682AF497; Tue, 1 Dec 2026 04:03:47 -0800 (PST) Received: from [192.168.178.24] (usa-sjc-mx-foss1.foss.arm.com [172.31.20.19]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id 4F1833F871; Tue, 1 Dec 2026 04:03:48 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=arm.com; s=foss; t=1796126630; bh=xgfuvZjvhmRoYG6o8Ln2PoWebmzKrhuzdrQtQlWXN7U=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=dhEfweLPAHUqVXQ+eELQUjQbFonAza6/aJcqrIlzNubvmQ7GuJlg0yblHIOJGTl/q Dn5QTj8u13qoj/5zXvn5jf6fVaCehcMwoL6yTWc8xXjxl2KYoAyiT4oR041A8rDlZk o2SK1k4Iq9d5Nishy3/c/GRRvCCA5g3z2pwixZEw= Message-ID: <363b6dd1-a990-41e5-a207-e6492256656b@arm.com> Date: Tue, 1 Dec 2026 13:03:42 +0100 X-Archived-By: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: [PATCH v2 4/4] arm64: dts: allwinner: a133: Add KickPi K5C To: rajanyadav0307@gmail.com, Rob Herring , Krzysztof Kozlowski , Conor Dooley , Chen-Yu Tsai , Jernej Skrabec , Samuel Holland , Maxime Ripard Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, Paul Kocialkowski References: <20261128-k5c-dt-v1-v2-0-eac2647049cd@gmail.com> <20261128-k5c-dt-v1-v2-4-eac2647049cd@gmail.com> Content-Language: en-GB From: Andre Przywara In-Reply-To: <20261128-k5c-dt-v1-v2-4-eac2647049cd@gmail.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.9.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20261201_040353_645380_11136333 X-CRM114-Status: GOOD ( 34.42 ) X-Spam-Score: -4.4 (----) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" X-Spam-Status: No, score=-17.4 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER,INCLUDES_PATCH, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,USER_AGENT_SANE_1 autolearn=ham autolearn_force=no version=4.0.1 X-Spam-Checker-Version: SpamAssassin 4.0.1 (2024-03-26) on aws-us-west-2-korg-listserv-alma10-1 Hi, On 11/29/26 00:32, Rajan Yadav via B4 Relay wrote: > From: Rajan Yadav > > The KickPi K5C is a Single Board Computer (SBC). > It uses an Allwinner A133. > Add a device tree for PCB V1.3. > > Features: > - 2 GB DDR3, 8-bit eMMC (HS200), microSD (card detect on PF6) > - the AXP707 PMIC, DCDC2 + DCDC3 in dual phase for CPU > - HYM8563 RTC on I2C3 (PH12/PH13) > - power input: 12V jack or USB-C (5V) > - 2 USB-A ports are behind a USB hub, power switch on PL8 > - blue status LED on PL10 > - debug UART on PB9/PB10 > > The values come from board schematic V1.3. > Checked them on the running board; register reads and the tests > (eMMC, SD, USB, RTC, LED). Thanks for the changes, compared against the schematic those look correct to me. I checked the power supply rails, voltages and pins used. So with the empty lines before the status property removed (marked inline), this is: Reviewed-by: Andre Przywara > > Not described yet: > - Ethernet: V1.3 schematic shows a Realtek RTL8211F PHY; > this board has a Maxio MAE0621A-Q2C (PHY ID 0x7b744411); > so left out for now. > - Wi-Fi/BT module on MMC1 > - USB data on the USB-C port (not yet tested) > - RTC alarm interrupt For those peripherals we have bindings. The RTC int should be very straight-forward to add (PB8 using &pio as the interrupt-parent). The USB-OTG looks interesting, we have all OTG-ID, VBUS detect and VBUS driver signals connected, so could describe the proper OTG port. The WiFi chip (AW859A) doesn't have a mainline binding, but we could at least describe the MMC port, plus the GPIO used for wake and reset, also the power supply. But I guess this should be done in a follow-up patch. Cheers, Andre > - display, camera, audio, IR, fan, battery > > Suggested-by: Andre Przywara > Link: https://lore.kernel.org/all/d4d89cf9-884d-424b-927d-5b6692f50327@arm.com/ > Signed-off-by: Rajan Yadav > --- > Changes in v2: > - rebased on next-20261127; DTS unchanged > - dropped the AXP707/AXP803 explanation (Andre) > - corrected Ethernet note: v1 only discussed Maxio PHY, > now it also says schematic's RTL8211F (Andre). > - moved AI note below "---" line > > Anthropic's Claude Code (Opus 5.5) drafted board file and Makefile in v1 > from board schematic (V1.3), KickPi's documentation, > vendor's device tree (only for reference values), board measurements. > For v2 it rebased the patch onto next-20261127; > ran dtbs_check, a W=1 build and checkpatch. > I reviewed the code line by line, ensuring correctness and purpose > of change. I tested it on my K5C board. > --- > arch/arm64/boot/dts/allwinner/Makefile | 1 + > .../boot/dts/allwinner/sun50i-a133-kickpi-k5c.dts | 228 +++++++++++++++++++++ > 2 files changed, 229 insertions(+) > > diff --git a/arch/arm64/boot/dts/allwinner/Makefile b/arch/arm64/boot/dts/allwinner/Makefile > index da39f02252d4..0176de509fb7 100644 > --- a/arch/arm64/boot/dts/allwinner/Makefile > +++ b/arch/arm64/boot/dts/allwinner/Makefile > @@ -25,6 +25,7 @@ dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a64-teres-i.dtb > dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h64-remix-mini-pc.dtb > dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a100-allwinner-perf1.dtb > dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a133-helperboard.dtb > +dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a133-kickpi-k5c.dtb > dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a133-liontron-h-a133l.dtb > dtb-$(CONFIG_ARCH_SUNXI) += sun50i-a133-teclast-p80.dtb > dtb-$(CONFIG_ARCH_SUNXI) += sun50i-h5-bananapi-m2-plus.dtb > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-a133-kickpi-k5c.dts b/arch/arm64/boot/dts/allwinner/sun50i-a133-kickpi-k5c.dts > new file mode 100644 > index 000000000000..ce977e9edbd2 > --- /dev/null > +++ b/arch/arm64/boot/dts/allwinner/sun50i-a133-kickpi-k5c.dts > @@ -0,0 +1,228 @@ > +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) > +/* > + * Copyright (c) 2026 Rajan Yadav > + */ > + > +/dts-v1/; > + > +#include "sun50i-a100.dtsi" > +#include "sun50i-a100-cpu-opp.dtsi" > + > +#include > +#include > +#include > + > +/{ > + model = "KickPi K5C"; > + compatible = "kickpi,k5c", "allwinner,sun50i-a133"; > + > + aliases { > + serial0 = &uart0; > + }; > + > + chosen { > + stdout-path = "serial0:115200n8"; > + }; > + > + leds { > + compatible = "gpio-leds"; > + > + led { > + function = LED_FUNCTION_STATUS; > + color = ; > + gpios = <&r_pio 0 10 GPIO_ACTIVE_HIGH>; /* PL10 */ > + }; > + }; > + > + reg_usb1_vbus: regulator-usb1-vbus { > + /* USB-A port power switch, also powers the on-board USB hub */ > + compatible = "regulator-fixed"; > + enable-active-high; > + gpio = <&r_pio 0 8 GPIO_ACTIVE_HIGH>; /* PL8 */ > + regulator-min-microvolt = <5000000>; > + regulator-max-microvolt = <5000000>; > + regulator-name = "usb1-vbus"; > + vin-supply = <®_vcc5v>; > + }; > + > + reg_vcc5v: regulator-vcc5v { > + /* 5V rail, powered from the USB-C port or the 12V DC jack */ > + compatible = "regulator-fixed"; > + regulator-always-on; > + regulator-min-microvolt = <5000000>; > + regulator-max-microvolt = <5000000>; > + regulator-name = "vcc-5v"; > + }; > +}; > + > +&cpu0 { > + cpu-supply = <®_dcdc2>; > +}; > + > +&ehci1 { > + status = "okay"; > +}; > + > +&i2c3 { > + pinctrl-0 = <&i2c3_ph_pins>; > + pinctrl-names = "default"; > + Please no empty lines in the list of properties. > + status = "okay"; > + > + rtc@51 { > + compatible = "haoyu,hym8563"; > + reg = <0x51>; > + #clock-cells = <0>; > + }; > +}; > + > +&mmc0 { > + bus-width = <4>; > + cd-gpios = <&pio 5 6 GPIO_ACTIVE_LOW>; /* PF6 */ > + disable-wp; > + vmmc-supply = <®_dcdc1>; > + Same here, drop the empty line. > + status = "okay"; > +}; > + > +&mmc2 { > + bus-width = <8>; > + cap-mmc-hw-reset; > + mmc-ddr-1_8v; > + mmc-hs200-1_8v; > + non-removable; > + vmmc-supply = <®_dcdc1>; > + vqmmc-supply = <®_eldo1>; > + drop empty line > + status = "okay"; > +}; > + > +&ohci1 { > + status = "okay"; > +}; > + > +&pio { > + vcc-pb-supply = <®_dcdc1>; > + vcc-pc-supply = <®_eldo1>; > + vcc-pd-supply = <®_dcdc1>; > + vcc-pe-supply = <®_dldo2>; > + vcc-pf-supply = <®_dcdc1>; > + vcc-pg-supply = <®_dldo1>; > + vcc-ph-supply = <®_dcdc1>; > +}; > + > +&r_i2c0 { > + status = "okay"; > + > + axp803: pmic@34 { > + compatible = "x-powers,axp803"; > + reg = <0x34>; > + interrupt-parent = <&r_intc>; > + interrupts = <0 IRQ_TYPE_LEVEL_LOW>; > + }; > +}; > + > +#include "axp803.dtsi" > + > +®_aldo1 { > + /* AVCC, PLL and DRAM 1.8V */ > + regulator-always-on; > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + regulator-name = "vcc-pll-avcc"; > +}; > + > +/* ALDO2 is for LPDDR and not used with the DDR3 on this board */ > + > +®_aldo3 { > + /* > + * Supply of the PL pin bank. It is not given to r_pio as > + * vcc-pl-supply: the PMIC is reached through PL0/PL1, so r_pio and > + * the PMIC would each wait for the other and the boot stops. > + */ > + regulator-always-on; > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + regulator-name = "vcc-pl"; > +}; > + > +®_dcdc1 { > + /* SoC I/O, USB analog, eMMC and SD card */ > + regulator-always-on; > + regulator-min-microvolt = <3300000>; > + regulator-max-microvolt = <3300000>; > + regulator-name = "vcc-3v3"; > +}; > + > +®_dcdc2 { > + regulator-always-on; > + regulator-min-microvolt = <810000>; > + regulator-max-microvolt = <1200000>; > + regulator-name = "vdd-cpux"; > +}; > + > +/* DCDC3 runs in dual phase with DCDC2 for VDD-CPUX and has no node */ > + > +®_dcdc4 { > + /* VDD-SYS, also used as VDD-USB */ > + regulator-always-on; > + regulator-min-microvolt = <950000>; > + regulator-max-microvolt = <950000>; > + regulator-name = "vdd-sys"; > +}; > + > +®_dcdc5 { > + /* DDR3 */ > + regulator-always-on; > + regulator-min-microvolt = <1500000>; > + regulator-max-microvolt = <1500000>; > + regulator-name = "vcc-dram"; > +}; > + > +/* DCDC6 is not connected */ > +®_dcdc6 { > + status = "disabled"; > +}; > + > +®_dldo1 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + regulator-name = "vcc-pg"; > +}; > + > +®_dldo2 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + regulator-name = "vcc-pe"; > +}; > + > +®_eldo1 { > + regulator-min-microvolt = <1800000>; > + regulator-max-microvolt = <1800000>; > + regulator-name = "vcc-pc"; > +}; > + > +®_fldo1 { > + /* VDD-CPUS */ > + regulator-always-on; > + regulator-min-microvolt = <900000>; > + regulator-max-microvolt = <900000>; > + regulator-name = "vdd-cpus"; > +}; > + > +&uart0 { > + pinctrl-0 = <&uart0_pb_pins>; > + pinctrl-names = "default"; > + no empty line > + status = "okay"; > +}; > + > +&usb_power_supply { > + status = "okay"; > +}; > + > +&usbphy { > + usb1_vbus-supply = <®_usb1_vbus>; > + > + status = "okay"; > +}; >