From fa6bd065ddad1a3e5d507a4eb9b5fd1fd4b4055a Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Wed, 9 Oct 2024 10:44:10 +0200 Subject: [PATCH 01/15] kernel: backport upstream commit that allows leaving out .ndo_get_stats64 Fixes mac80211 backport device statistics. Fixes: #16642 Signed-off-by: Felix Fietkau --- ...64-if-device-if-driver-is-configured.patch | 29 +++++++++++++++++++ ...et-free_netdev-exit-earlier-if-dummy.patch | 2 +- 2 files changed, 30 insertions(+), 1 deletion(-) create mode 100644 target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch diff --git a/target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch b/target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch new file mode 100644 index 0000000000..871154ecf8 --- /dev/null +++ b/target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch @@ -0,0 +1,29 @@ +From: Breno Leitao +Date: Wed, 28 Feb 2024 03:31:21 -0800 +Subject: [PATCH] net: get stats64 if device if driver is configured + +If the network driver is relying in the net core to do stats allocation, +then we want to dev_get_tstats64() instead of netdev_stats_to_stats64(), +since there are per-cpu stats that needs to be taken in consideration. + +This will also simplify the drivers in regard to statistics. Once the +driver sets NETDEV_PCPU_STAT_TSTATS, it doesn't not need to allocate the +stacks, neither it needs to set `.ndo_get_stats64 = dev_get_tstats64` +for the generic stats collection function anymore. + +Signed-off-by: Breno Leitao +Reviewed-by: Simon Horman +Signed-off-by: Paolo Abeni +--- + +--- a/net/core/dev.c ++++ b/net/core/dev.c +@@ -10658,6 +10658,8 @@ struct rtnl_link_stats64 *dev_get_stats( + ops->ndo_get_stats64(dev, storage); + } else if (ops->ndo_get_stats) { + netdev_stats_to_stats64(storage, ops->ndo_get_stats(dev)); ++ } else if (dev->pcpu_stat_type == NETDEV_PCPU_STAT_TSTATS) { ++ dev_get_tstats64(dev, storage); + } else { + netdev_stats_to_stats64(storage, &dev->stats); + } diff --git a/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch b/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch index 31beb11d54..53f313044a 100644 --- a/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch +++ b/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch @@ -23,7 +23,7 @@ Signed-off-by: David S. Miller --- a/net/core/dev.c +++ b/net/core/dev.c -@@ -10966,7 +10966,8 @@ void free_netdev(struct net_device *dev) +@@ -10968,7 +10968,8 @@ void free_netdev(struct net_device *dev) dev->xdp_bulkq = NULL; /* Compatibility with error handling in drivers */ From c3251f5d52aef636f0cec432a27bf90f7537e1e7 Mon Sep 17 00:00:00 2001 From: Robert Marko Date: Mon, 7 Oct 2024 15:07:39 +0200 Subject: [PATCH 02/15] kernel: netdevices: add RmNet MAP support RmNet driver provides a transport agnostic MAP (multiplexing and aggregation protocol) support in embedded module. Module provides virtual network devices which can be attached to any IP-mode physical device. This is commonly used on Qualcomm based modems for data aggregation. Signed-off-by: Robert Marko --- package/kernel/linux/modules/netdevices.mk | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/package/kernel/linux/modules/netdevices.mk b/package/kernel/linux/modules/netdevices.mk index d77dabfa79..1470c5c176 100644 --- a/package/kernel/linux/modules/netdevices.mk +++ b/package/kernel/linux/modules/netdevices.mk @@ -801,6 +801,23 @@ endef $(eval $(call KernelPackage,r6040)) +define KernelPackage/rmnet + SUBMENU:=$(NETWORK_DEVICES_MENU) + TITLE:=RmNet MAP support + KCONFIG:=CONFIG_RMNET + FILES:=$(LINUX_DIR)/drivers/net/ethernet/qualcomm/rmnet/rmnet.ko + AUTOLOAD:=$(call AutoLoad,30,rmnet) +endef + +define KernelPackage/rmnet/description + Kernel support for RMNET module which is used for handling data in the + multiplexing and aggregation protocol (MAP) format in the embedded data + path. RMNET devices can be attached to any IP mode physical device. +endef + +$(eval $(call KernelPackage,rmnet)) + + define KernelPackage/niu SUBMENU:=$(NETWORK_DEVICES_MENU) TITLE:=Sun Neptune 10Gbit Ethernet support From f8ca3519369998a24406bbfbcf5e30349b0530e7 Mon Sep 17 00:00:00 2001 From: Rosen Penev Date: Fri, 23 Aug 2024 17:39:17 -0700 Subject: [PATCH 03/15] mpc85xx: handle MSM460 wifi mac in dts Userspace handling is deprecated. Signed-off-by: Rosen Penev --- .../etc/hotplug.d/ieee80211/10-fix-wifi-mac | 5 ----- .../mpc85xx/files/arch/powerpc/boot/dts/msm460.dts | 12 ++++++++++++ 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac b/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac index 0e27dfb8cc..20ad8eb44f 100644 --- a/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac +++ b/target/linux/mpc85xx/base-files/etc/hotplug.d/ieee80211/10-fix-wifi-mac @@ -20,11 +20,6 @@ enterasys,ws-ap3710i|\ extreme-networks,ws-ap3825i) mtd_get_mac_ascii cfg2 RADIOADDR${PHYNBR} > /sys${DEVPATH}/macaddress ;; -hpe,msm460) - wifi_mac=$(mtd_get_mac_binary colubris-bid 0x1f9bd) - [ "$PHYNBR" -eq 0 ] && echo "$wifi_mac" > /sys${DEVPATH}/macaddress - [ "$PHYNBR" -eq 1 ] && echo "$(macaddr_add $wifi_mac 16)" > /sys${DEVPATH}/macaddress - ;; ocedo,panda) mtd_get_mac_ascii uboot-env0 wmac$(($PHYNBR + 1)) > /sys${DEVPATH}/macaddress ;; diff --git a/target/linux/mpc85xx/files/arch/powerpc/boot/dts/msm460.dts b/target/linux/mpc85xx/files/arch/powerpc/boot/dts/msm460.dts index 46f8e514c9..3666350271 100644 --- a/target/linux/mpc85xx/files/arch/powerpc/boot/dts/msm460.dts +++ b/target/linux/mpc85xx/files/arch/powerpc/boot/dts/msm460.dts @@ -175,6 +175,12 @@ 0x1000000 0x0 0x0 0x1000000 0x0 0x0 0x0 0x100000>; + + wifi@0,0 { + reg = <0x0000 0 0 0 0>; + nvmem-cells = <&macaddr_hwinfo_1f9bd 0>; + nvmem-cell-names = "mac-address"; + }; }; }; @@ -190,6 +196,12 @@ 0x1000000 0x0 0x0 0x1000000 0x0 0x0 0x0 0x100000>; + + wifi@0,0 { + reg = <0x0000 0 0 0 0>; + nvmem-cells = <&macaddr_hwinfo_1f9bd 16>; + nvmem-cell-names = "mac-address"; + }; }; }; From 3f6e087b6ff4e5391cd2396b26f2bd0509622085 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Thu, 10 Oct 2024 10:49:53 +0200 Subject: [PATCH 04/15] mt76: update to Git HEAD (2024-10-10) 86b41a32a5ac wifi: mac80211: don't use rate mask for offchannel TX either 82a452919f52 wifi: mac80211: handle ieee80211_radar_detected() for MLO 02c07fe539b4 wifi: mt76: mt7996: fix rx filter setting for bfee functionality a902bfa6db2f wifi: mt76: mt7915: disable the second PCIe link for MT7915 a7d48cd3ed34 wifi: mt76: mt7915: reduce the number of command retries 0d8474602a9b wifi: mt76: mt7915: decrease timeout for commonly issued MCU commands 5f6051569639 wifi: mt76: mt7915: add module param to select 5 GHz or 6 GHz on MT7916 f5bccb122305 wifi: mt76: mt7996: fix invalid interface combinations 6a1199463fc8 wifi: mt76: mt7915: Fix an error handling path in mt7915_add_interface() Signed-off-by: Felix Fietkau --- package/kernel/mt76/Makefile | 6 +- .../kernel/mt76/patches/100-api_update.patch | 64 ------------------- 2 files changed, 3 insertions(+), 67 deletions(-) delete mode 100644 package/kernel/mt76/patches/100-api_update.patch diff --git a/package/kernel/mt76/Makefile b/package/kernel/mt76/Makefile index 070d0f3c2b..957159201c 100644 --- a/package/kernel/mt76/Makefile +++ b/package/kernel/mt76/Makefile @@ -8,9 +8,9 @@ PKG_LICENSE_FILES:= PKG_SOURCE_URL:=https://github.com/openwrt/mt76 PKG_SOURCE_PROTO:=git -PKG_SOURCE_DATE:=2024-09-29 -PKG_SOURCE_VERSION:=680bc70f161fde0f167e2ae50c771be4775eb50a -PKG_MIRROR_HASH:=bcdb95e40cfceba56a565ad6b6d9f92a122e7230d0f7f950b3d39e4280723cca +PKG_SOURCE_DATE:=2024-10-10 +PKG_SOURCE_VERSION:=6a1199463fc8f7758c32122613288ed95c09e3bd +PKG_MIRROR_HASH:=4b42a586e098c1dc5970fbd3190ac2faf67992c7357161a3ef3040817a8ed8d6 PKG_MAINTAINER:=Felix Fietkau PKG_USE_NINJA:=0 diff --git a/package/kernel/mt76/patches/100-api_update.patch b/package/kernel/mt76/patches/100-api_update.patch deleted file mode 100644 index 4cd19f65b2..0000000000 --- a/package/kernel/mt76/patches/100-api_update.patch +++ /dev/null @@ -1,64 +0,0 @@ ---- a/tx.c -+++ b/tx.c -@@ -350,7 +350,7 @@ mt76_tx(struct mt76_phy *phy, struct iee - info->hw_queue |= FIELD_PREP(MT_TX_HW_QUEUE_PHY, phy->band_idx); - - if ((info->flags & IEEE80211_TX_CTL_TX_OFFCHAN) || -- (info->control.flags & IEEE80211_TX_CTRL_SCAN_TX)) -+ (info->control.flags & IEEE80211_TX_CTRL_DONT_USE_RATE_MASK)) - head = &wcid->tx_offchannel; - else - head = &wcid->tx_pending; ---- a/mt7615/mcu.c -+++ b/mt7615/mcu.c -@@ -394,7 +394,7 @@ mt7615_mcu_rx_radar_detected(struct mt76 - if (mt76_phy_dfs_state(mphy) < MT_DFS_STATE_CAC) - return; - -- ieee80211_radar_detected(mphy->hw); -+ ieee80211_radar_detected(mphy->hw, NULL); - dev->hw_pattern++; - } - ---- a/mt76x02_dfs.c -+++ b/mt76x02_dfs.c -@@ -630,7 +630,7 @@ static void mt76x02_dfs_tasklet(struct t - radar_detected = mt76x02_dfs_check_detection(dev); - if (radar_detected) { - /* sw detector rx radar pattern */ -- ieee80211_radar_detected(dev->mt76.hw); -+ ieee80211_radar_detected(dev->mt76.hw, NULL); - mt76x02_dfs_detector_reset(dev); - - return; -@@ -658,7 +658,7 @@ static void mt76x02_dfs_tasklet(struct t - - /* hw detector rx radar pattern */ - dfs_pd->stats[i].hw_pattern++; -- ieee80211_radar_detected(dev->mt76.hw); -+ ieee80211_radar_detected(dev->mt76.hw, NULL); - mt76x02_dfs_detector_reset(dev); - - return; ---- a/mt7915/mcu.c -+++ b/mt7915/mcu.c -@@ -297,7 +297,7 @@ mt7915_mcu_rx_radar_detected(struct mt79 - &dev->rdd2_chandef, - GFP_ATOMIC); - else -- ieee80211_radar_detected(mphy->hw); -+ ieee80211_radar_detected(mphy->hw, NULL); - dev->hw_pattern++; - } - ---- a/mt7996/mcu.c -+++ b/mt7996/mcu.c -@@ -383,7 +383,7 @@ mt7996_mcu_rx_radar_detected(struct mt79 - &dev->rdd2_chandef, - GFP_ATOMIC); - else -- ieee80211_radar_detected(mphy->hw); -+ ieee80211_radar_detected(mphy->hw, NULL); - dev->hw_pattern++; - } - From 9b66c7dfa50e31141b22769a9be706e0dc95ab24 Mon Sep 17 00:00:00 2001 From: Robert Marko Date: Thu, 10 Oct 2024 11:30:40 +0200 Subject: [PATCH 05/15] realtek: refresh patches CI is saying that patches need to be refreshed, so refresh them. Link: https://github.com/openwrt/openwrt/pull/16653 Signed-off-by: Robert Marko --- .../708-drivers-net-phy-eee-support-for-rtl838x.patch | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/target/linux/realtek/patches-6.6/708-drivers-net-phy-eee-support-for-rtl838x.patch b/target/linux/realtek/patches-6.6/708-drivers-net-phy-eee-support-for-rtl838x.patch index 305981c3ee..89a1d9583f 100644 --- a/target/linux/realtek/patches-6.6/708-drivers-net-phy-eee-support-for-rtl838x.patch +++ b/target/linux/realtek/patches-6.6/708-drivers-net-phy-eee-support-for-rtl838x.patch @@ -21,7 +21,7 @@ Submitted-by: John Crispin --- a/drivers/net/phy/phylink.c +++ b/drivers/net/phy/phylink.c -@@ -2484,6 +2484,11 @@ int phylink_ethtool_ksettings_set(struct +@@ -2491,6 +2491,11 @@ int phylink_ethtool_ksettings_set(struct * the presence of a PHY, this should not be changed as that * should be determined from the media side advertisement. */ @@ -33,7 +33,7 @@ Submitted-by: John Crispin return phy_ethtool_ksettings_set(pl->phydev, &phy_kset); } -@@ -2786,8 +2791,11 @@ int phylink_ethtool_get_eee(struct phyli +@@ -2793,8 +2798,11 @@ int phylink_ethtool_get_eee(struct phyli ASSERT_RTNL(); @@ -46,7 +46,7 @@ Submitted-by: John Crispin return ret; } -@@ -2804,8 +2812,11 @@ int phylink_ethtool_set_eee(struct phyli +@@ -2811,8 +2819,11 @@ int phylink_ethtool_set_eee(struct phyli ASSERT_RTNL(); From 51e083426b8b9343a253597baa286b76e9232194 Mon Sep 17 00:00:00 2001 From: Thomas Richard Date: Tue, 24 Sep 2024 18:27:16 +0200 Subject: [PATCH 06/15] scripts/feeds: force kernel package scan after a target installation When a target is installed from a feed, the linux kernel package is scanned before the installation of this target. If some kernel module packages are defined in this feeds at the target level, there were not parsed during the scan of linux kernel package, as the target didn't exist yet. So these kernel module packages don't exist. Once the target is installed, clean the linux kernel packageinfo to force the scan of the linux kernel package next time this script (or the make command) is called. Signed-off-by: Thomas Richard Link: https://patchwork.ozlabs.org/project/openwrt/patch/mailman.117548.1727195440.1280.openwrt-devel@lists.openwrt.org/ Signed-off-by: Hauke Mehrtens --- scripts/feeds | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/scripts/feeds b/scripts/feeds index 7cbe07f58e..d07c28bc50 100755 --- a/scripts/feeds +++ b/scripts/feeds @@ -461,6 +461,11 @@ sub do_install_target($) { return 1; } + # Clean packageinfo of linux kernel to force the scan. + # Otherwise kernel modules defined at target level are not scanned, as the + # linux kernel package was scanned before the installation of the target. + unlink "tmp/info/.packageinfo-kernel_linux"; + return 0; } From e00b6ba0c8eac45bf8b878a44c1bb5f0b90f8a8e Mon Sep 17 00:00:00 2001 From: Tianling Shen Date: Wed, 9 Oct 2024 20:47:34 +0800 Subject: [PATCH 07/15] uboot-rockchip: Update to 2024.10 Removed upstreamed patches. Signed-off-by: Tianling Shen Link: https://github.com/openwrt/openwrt/pull/16647 Signed-off-by: Nick Hainke --- package/boot/uboot-rockchip/Makefile | 4 +- ...24.10-rc1-backport-upstream-dts-sync.patch | 3687 ----------------- ...add-support-for-Radxa-ROCK-Pi-E-v3.0.patch | 248 -- ...rd-rockchip-add-Radxa-ROCK-3-Model-C.patch | 178 - ...DC-Kconfig-symbol-for-use-of-ADC-in-.patch | 67 - ...-board-rockchip-Add-Radxa-ZERO-3W-3E.patch | 295 -- ...rc3-board-rockchip-Add-Radxa-ROCK-3B.patch | 179 - ...ip-correct-the-model-name-for-Radxa-.patch | 29 - ...ip-Correct-the-model-names-for-Radxa.patch | 43 - ...rockchip-Add-FriendlyElec-NanoPi-R6S.patch | 193 - ...rockchip-Add-FriendlyElec-NanoPi-R6C.patch | 213 - ...ckchip-add-ArmSoM-Sige7-Rk3588-board.patch | 257 -- 12 files changed, 2 insertions(+), 5391 deletions(-) delete mode 100644 package/boot/uboot-rockchip/patches/000-v2024.10-rc1-backport-upstream-dts-sync.patch delete mode 100644 package/boot/uboot-rockchip/patches/001-v2024.10-rc3-rockchip-add-support-for-Radxa-ROCK-Pi-E-v3.0.patch delete mode 100644 package/boot/uboot-rockchip/patches/002-v2024.10-rc3-board-rockchip-add-Radxa-ROCK-3-Model-C.patch delete mode 100644 package/boot/uboot-rockchip/patches/003-v2024.10-rc3-dm-adc-Add-SPL_ADC-Kconfig-symbol-for-use-of-ADC-in-.patch delete mode 100644 package/boot/uboot-rockchip/patches/004-v2024.10-rc3-board-rockchip-Add-Radxa-ZERO-3W-3E.patch delete mode 100644 package/boot/uboot-rockchip/patches/005-v2024.10-rc3-board-rockchip-Add-Radxa-ROCK-3B.patch delete mode 100644 package/boot/uboot-rockchip/patches/010-v2024.10-rc3-arm64-dts-rockchip-correct-the-model-name-for-Radxa-.patch delete mode 100644 package/boot/uboot-rockchip/patches/011-v2024.10-rc3-arm64-dts-rockchip-Correct-the-model-names-for-Radxa.patch delete mode 100644 package/boot/uboot-rockchip/patches/106-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6S.patch delete mode 100644 package/boot/uboot-rockchip/patches/107-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6C.patch delete mode 100644 package/boot/uboot-rockchip/patches/108-v2024.10-rc1-board-rockchip-add-ArmSoM-Sige7-Rk3588-board.patch diff --git a/package/boot/uboot-rockchip/Makefile b/package/boot/uboot-rockchip/Makefile index a4d81a94e1..dd22ac390e 100644 --- a/package/boot/uboot-rockchip/Makefile +++ b/package/boot/uboot-rockchip/Makefile @@ -5,9 +5,9 @@ include $(TOPDIR)/rules.mk include $(INCLUDE_DIR)/kernel.mk -PKG_VERSION:=2024.07 +PKG_VERSION:=2024.10 PKG_RELEASE:=1 -PKG_HASH:=f591da9ab90ef3d6b3d173766d0ddff90c4ed7330680897486117df390d83c8f +PKG_HASH:=b28daf4ac17e43156363078bf510297584137f6df50fced9b12df34f61a92fb0 PKG_MAINTAINER:=Sarah Maedel diff --git a/package/boot/uboot-rockchip/patches/000-v2024.10-rc1-backport-upstream-dts-sync.patch b/package/boot/uboot-rockchip/patches/000-v2024.10-rc1-backport-upstream-dts-sync.patch deleted file mode 100644 index afe651afc8..0000000000 --- a/package/boot/uboot-rockchip/patches/000-v2024.10-rc1-backport-upstream-dts-sync.patch +++ /dev/null @@ -1,3687 +0,0 @@ -From 6bb92fcf7d2fea2314d616e5e2391a8bf2b0fdfa Mon Sep 17 00:00:00 2001 -From: Tom Rini -Date: Mon, 20 May 2024 09:54:58 -0600 -Subject: [PATCH] Squashed 'dts/upstream/' changes from - b35b9bd1d4ee..7e08733c96c8 ---- - .../src/arm64/rockchip/rk3588s-nanopi-r6c.dts | 14 + - .../src/arm64/rockchip/rk3588s-nanopi-r6s.dts | 764 ++++++++++++++++++ - 2 files changed, 778 insertions(+) - create mode 100644 dts/upstream/src/arm64/rockchip/rk3588s-nanopi-r6c.dts - create mode 100644 dts/upstream/src/arm64/rockchip/rk3588s-nanopi-r6s.dts - ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3588-armsom-sige7.dts -@@ -0,0 +1,691 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+ -+#include -+#include -+#include "rk3588.dtsi" -+ -+/ { -+ model = "ArmSoM Sige7"; -+ compatible = "armsom,sige7", "rockchip,rk3588"; -+ -+ aliases { -+ mmc0 = &sdhci; -+ mmc1 = &sdmmc; -+ }; -+ -+ chosen { -+ stdout-path = "serial2:1500000n8"; -+ }; -+ -+ analog-sound { -+ compatible = "audio-graph-card"; -+ dais = <&i2s0_8ch_p0>; -+ label = "rk3588-es8316"; -+ hp-det-gpio = <&gpio1 RK_PD5 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&hp_detect>; -+ routing = "MIC2", "Mic Jack", -+ "Headphones", "HPOL", -+ "Headphones", "HPOR"; -+ widgets = "Microphone", "Mic Jack", -+ "Headphone", "Headphones"; -+ }; -+ -+ leds { -+ compatible = "gpio-leds"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&led_rgb_g>; -+ -+ led_green: led-0 { -+ color = ; -+ function = LED_FUNCTION_STATUS; -+ gpios = <&gpio0 RK_PB7 GPIO_ACTIVE_HIGH>; -+ linux,default-trigger = "heartbeat"; -+ }; -+ -+ led_red: led-1 { -+ color = ; -+ function = LED_FUNCTION_STATUS; -+ gpios = <&gpio4 RK_PC5 GPIO_ACTIVE_HIGH>; -+ linux,default-trigger = "none"; -+ }; -+ }; -+ -+ fan: pwm-fan { -+ compatible = "pwm-fan"; -+ cooling-levels = <0 95 145 195 255>; -+ fan-supply = <&vcc5v0_sys>; -+ pwms = <&pwm1 0 50000 0>; -+ #cooling-cells = <2>; -+ }; -+ -+ vcc3v3_pcie2x1l2: vcc3v3-pcie2x1l2-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc3v3_pcie2x1l2"; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ startup-delay-us = <5000>; -+ vin-supply = <&vcc_3v3_s3>; -+ }; -+ -+ vcc3v3_pcie30: vcc3v3-pcie30-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio1 RK_PA4 GPIO_ACTIVE_HIGH>; -+ regulator-name = "vcc3v3_pcie30"; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ startup-delay-us = <5000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc5v0_host: vcc5v0-host-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc5v0_host"; -+ regulator-boot-on; -+ regulator-always-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ enable-active-high; -+ gpio = <&gpio4 RK_PB0 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&vcc5v0_host_en>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc5v0_sys: vcc5v0-sys-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc5v0_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ }; -+ -+ vcc_1v1_nldo_s3: vcc-1v1-nldo-s3-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc_1v1_nldo_s3"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1100000>; -+ regulator-max-microvolt = <1100000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+}; -+ -+&combphy0_ps { -+ status = "okay"; -+}; -+ -+&combphy1_ps { -+ status = "okay"; -+}; -+ -+&combphy2_psu { -+ status = "okay"; -+}; -+ -+&cpu_b0 { -+ cpu-supply = <&vdd_cpu_big0_s0>; -+}; -+ -+&cpu_b1 { -+ cpu-supply = <&vdd_cpu_big0_s0>; -+}; -+ -+&cpu_b2 { -+ cpu-supply = <&vdd_cpu_big1_s0>; -+}; -+ -+&cpu_b3 { -+ cpu-supply = <&vdd_cpu_big1_s0>; -+}; -+ -+&cpu_l0 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&cpu_l1 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&cpu_l2 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&cpu_l3 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&i2c0 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&i2c0m2_xfer>; -+ status = "okay"; -+ -+ vdd_cpu_big0_s0: regulator@42 { -+ compatible = "rockchip,rk8602"; -+ reg = <0x42>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_cpu_big0_s0"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <1050000>; -+ regulator-ramp-delay = <2300>; -+ vin-supply = <&vcc5v0_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_cpu_big1_s0: regulator@43 { -+ compatible = "rockchip,rk8603", "rockchip,rk8602"; -+ reg = <0x43>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_cpu_big1_s0"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <1050000>; -+ regulator-ramp-delay = <2300>; -+ vin-supply = <&vcc5v0_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+}; -+ -+&i2c6 { -+ status = "okay"; -+ -+ hym8563: rtc@51 { -+ compatible = "haoyu,hym8563"; -+ reg = <0x51>; -+ interrupt-parent = <&gpio0>; -+ interrupts = ; -+ #clock-cells = <0>; -+ clock-output-names = "hym8563"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&hym8563_int>; -+ wakeup-source; -+ }; -+}; -+ -+&i2c7 { -+ status = "okay"; -+ -+ es8316: audio-codec@11 { -+ compatible = "everest,es8316"; -+ reg = <0x11>; -+ assigned-clocks = <&cru I2S0_8CH_MCLKOUT>; -+ assigned-clock-rates = <12288000>; -+ clocks = <&cru I2S0_8CH_MCLKOUT>; -+ clock-names = "mclk"; -+ #sound-dai-cells = <0>; -+ -+ port { -+ es8316_p0_0: endpoint { -+ remote-endpoint = <&i2s0_8ch_p0_0>; -+ }; -+ }; -+ }; -+}; -+ -+&i2s0_8ch { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&i2s0_lrck -+ &i2s0_mclk -+ &i2s0_sclk -+ &i2s0_sdi0 -+ &i2s0_sdo0>; -+ status = "okay"; -+ -+ i2s0_8ch_p0: port { -+ i2s0_8ch_p0_0: endpoint { -+ dai-format = "i2s"; -+ mclk-fs = <256>; -+ remote-endpoint = <&es8316_p0_0>; -+ }; -+ }; -+}; -+ -+/* phy1 - right ethernet port */ -+&pcie2x1l0 { -+ reset-gpios = <&gpio4 RK_PA5 GPIO_ACTIVE_HIGH>; -+ status = "okay"; -+}; -+ -+/* phy2 - WiFi */ -+&pcie2x1l1 { -+ reset-gpios = <&gpio3 RK_PD4 GPIO_ACTIVE_HIGH>; -+ status = "okay"; -+}; -+ -+/* phy0 - left ethernet port */ -+&pcie2x1l2 { -+ reset-gpios = <&gpio3 RK_PB0 GPIO_ACTIVE_HIGH>; -+ status = "okay"; -+}; -+ -+&pcie30phy { -+ status = "okay"; -+}; -+ -+&pcie3x4 { -+ reset-gpios = <&gpio4 RK_PB6 GPIO_ACTIVE_HIGH>; -+ vpcie3v3-supply = <&vcc3v3_pcie30>; -+ status = "okay"; -+}; -+ -+&pinctrl { -+ hym8563 { -+ hym8563_int: hym8563-int { -+ rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ leds { -+ led_rgb_g: led-rgb-g { -+ rockchip,pins = <0 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ led_rgb_r: led-rgb-r { -+ rockchip,pins = <0 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ sound { -+ hp_detect: hp-detect { -+ rockchip,pins = <1 RK_PD5 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ usb { -+ vcc5v0_host_en: vcc5v0-host-en { -+ rockchip,pins = <4 RK_PB0 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+}; -+ -+&pwm1 { -+ status = "okay"; -+}; -+ -+&saradc { -+ vref-supply = <&avcc_1v8_s0>; -+ status = "okay"; -+}; -+ -+&sdhci { -+ bus-width = <8>; -+ no-sdio; -+ no-sd; -+ non-removable; -+ mmc-hs200-1_8v; -+ status = "okay"; -+}; -+ -+&sdmmc { -+ bus-width = <4>; -+ cap-mmc-highspeed; -+ cap-sd-highspeed; -+ disable-wp; -+ max-frequency = <200000000>; -+ no-sdio; -+ no-mmc; -+ sd-uhs-sdr104; -+ vmmc-supply = <&vcc_3v3_s3>; -+ vqmmc-supply = <&vccio_sd_s0>; -+ status = "okay"; -+}; -+ -+&spi2 { -+ assigned-clocks = <&cru CLK_SPI2>; -+ assigned-clock-rates = <200000000>; -+ num-cs = <1>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&spi2m2_cs0 &spi2m2_pins>; -+ status = "okay"; -+ -+ pmic@0 { -+ compatible = "rockchip,rk806"; -+ spi-max-frequency = <1000000>; -+ reg = <0x0>; -+ -+ interrupt-parent = <&gpio0>; -+ interrupts = <7 IRQ_TYPE_LEVEL_LOW>; -+ -+ gpio-controller; -+ #gpio-cells = <2>; -+ -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pmic_pins>, <&rk806_dvs1_null>, -+ <&rk806_dvs2_null>, <&rk806_dvs3_null>; -+ -+ system-power-controller; -+ -+ vcc1-supply = <&vcc5v0_sys>; -+ vcc2-supply = <&vcc5v0_sys>; -+ vcc3-supply = <&vcc5v0_sys>; -+ vcc4-supply = <&vcc5v0_sys>; -+ vcc5-supply = <&vcc5v0_sys>; -+ vcc6-supply = <&vcc5v0_sys>; -+ vcc7-supply = <&vcc5v0_sys>; -+ vcc8-supply = <&vcc5v0_sys>; -+ vcc9-supply = <&vcc5v0_sys>; -+ vcc10-supply = <&vcc5v0_sys>; -+ vcc11-supply = <&vcc_2v0_pldo_s3>; -+ vcc12-supply = <&vcc5v0_sys>; -+ vcc13-supply = <&vcc_1v1_nldo_s3>; -+ vcc14-supply = <&vcc_1v1_nldo_s3>; -+ vcca-supply = <&vcc5v0_sys>; -+ -+ rk806_dvs1_null: dvs1-null-pins { -+ pins = "gpio_pwrctrl1"; -+ function = "pin_fun0"; -+ }; -+ -+ rk806_dvs2_null: dvs2-null-pins { -+ pins = "gpio_pwrctrl2"; -+ function = "pin_fun0"; -+ }; -+ -+ rk806_dvs3_null: dvs3-null-pins { -+ pins = "gpio_pwrctrl3"; -+ function = "pin_fun0"; -+ }; -+ -+ regulators { -+ vdd_gpu_s0: vdd_gpu_mem_s0: dcdc-reg1 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <950000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_gpu_s0"; -+ regulator-enable-ramp-delay = <400>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_cpu_lit_s0: vdd_cpu_lit_mem_s0: dcdc-reg2 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <950000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_cpu_lit_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_log_s0: dcdc-reg3 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <675000>; -+ regulator-max-microvolt = <750000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_log_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <750000>; -+ }; -+ }; -+ -+ vdd_vdenc_s0: vdd_vdenc_mem_s0: dcdc-reg4 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <950000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_vdenc_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_ddr_s0: dcdc-reg5 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <675000>; -+ regulator-max-microvolt = <900000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_ddr_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <850000>; -+ }; -+ }; -+ -+ vdd2_ddr_s3: dcdc-reg6 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-name = "vdd2_ddr_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ }; -+ }; -+ -+ vcc_2v0_pldo_s3: dcdc-reg7 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <2000000>; -+ regulator-max-microvolt = <2000000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_2v0_pldo_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <2000000>; -+ }; -+ }; -+ -+ vcc_3v3_s3: dcdc-reg8 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ regulator-name = "vcc_3v3_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <3300000>; -+ }; -+ }; -+ -+ vddq_ddr_s0: dcdc-reg9 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-name = "vddq_ddr_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_1v8_s3: dcdc-reg10 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "vcc_1v8_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ avcc_1v8_s0: pldo-reg1 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "avcc_1v8_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_1v8_s0: pldo-reg2 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "vcc_1v8_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ avdd_1v2_s0: pldo-reg3 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1200000>; -+ regulator-max-microvolt = <1200000>; -+ regulator-name = "avdd_1v2_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_3v3_s0: pldo-reg4 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vcc_3v3_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vccio_sd_s0: pldo-reg5 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <3300000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vccio_sd_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ pldo6_s3: pldo-reg6 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "pldo6_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ vdd_0v75_s3: nldo-reg1 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <750000>; -+ regulator-max-microvolt = <750000>; -+ regulator-name = "vdd_0v75_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <750000>; -+ }; -+ }; -+ -+ vdd_ddr_pll_s0: nldo-reg2 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <850000>; -+ regulator-max-microvolt = <850000>; -+ regulator-name = "vdd_ddr_pll_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <850000>; -+ }; -+ }; -+ -+ avdd_0v75_s0: nldo-reg3 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <750000>; -+ regulator-max-microvolt = <750000>; -+ regulator-name = "avdd_0v75_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_0v85_s0: nldo-reg4 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <850000>; -+ regulator-max-microvolt = <850000>; -+ regulator-name = "vdd_0v85_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_0v75_s0: nldo-reg5 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <750000>; -+ regulator-max-microvolt = <750000>; -+ regulator-name = "vdd_0v75_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ }; -+ }; -+}; -+ -+&u2phy3 { -+ status = "okay"; -+}; -+ -+&u2phy3_host { -+ phy-supply = <&vcc5v0_host>; -+ status = "okay"; -+}; -+ -+&uart2 { -+ pinctrl-0 = <&uart2m0_xfer>; -+ status = "okay"; -+}; -+ -+&usb_host1_ehci { -+ status = "okay"; -+}; -+ -+&usb_host1_ohci { -+ status = "okay"; -+}; ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3588s-nanopi-r6c.dts -@@ -0,0 +1,14 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+ -+#include "rk3588s-nanopi-r6s.dts" -+ -+/ { -+ model = "FriendlyElec NanoPi R6C"; -+ compatible = "friendlyarm,nanopi-r6c", "rockchip,rk3588s"; -+}; -+ -+&lan2_led { -+ label = "user_led"; -+}; ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3588s-nanopi-r6s.dts -@@ -0,0 +1,764 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+ -+#include -+#include -+#include -+#include "rk3588s.dtsi" -+ -+/ { -+ model = "FriendlyElec NanoPi R6S"; -+ compatible = "friendlyarm,nanopi-r6s", "rockchip,rk3588s"; -+ -+ aliases { -+ ethernet0 = &gmac1; -+ mmc0 = &sdmmc; -+ mmc1 = &sdhci; -+ }; -+ -+ chosen { -+ stdout-path = "serial2:1500000n8"; -+ }; -+ -+ adc-keys { -+ compatible = "adc-keys"; -+ io-channels = <&saradc 0>; -+ io-channel-names = "buttons"; -+ keyup-threshold-microvolt = <1800000>; -+ poll-interval = <100>; -+ -+ button-maskrom { -+ label = "Maskrom"; -+ linux,code = ; -+ press-threshold-microvolt = <1800>; -+ }; -+ }; -+ -+ gpio-keys { -+ compatible = "gpio-keys"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&key1_pin>; -+ -+ button-user { -+ label = "User"; -+ linux,code = ; -+ gpios = <&gpio1 RK_PC0 GPIO_ACTIVE_LOW>; -+ debounce-interval = <50>; -+ }; -+ }; -+ -+ leds { -+ compatible = "gpio-leds"; -+ -+ sys_led: led-0 { -+ label = "sys_led"; -+ gpios = <&gpio1 RK_PC1 GPIO_ACTIVE_HIGH>; -+ linux,default-trigger = "heartbeat"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sys_led_pin>; -+ }; -+ -+ wan_led: led-1 { -+ label = "wan_led"; -+ gpios = <&gpio1 RK_PC2 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&wan_led_pin>; -+ }; -+ -+ lan1_led: led-2 { -+ label = "lan1_led"; -+ gpios = <&gpio1 RK_PC3 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&lan1_led_pin>; -+ }; -+ -+ lan2_led: led-3 { -+ label = "lan2_led"; -+ gpios = <&gpio1 RK_PC4 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&lan2_led_pin>; -+ }; -+ }; -+ -+ vcc5v0_sys: vcc5v0-sys-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc5v0_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ }; -+ -+ vcc_1v1_nldo_s3: vcc-1v1-nldo-s3-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc_1v1_nldo_s3"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1100000>; -+ regulator-max-microvolt = <1100000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc_3v3_s0: vcc-3v3-s0-regulator { -+ compatible = "regulator-fixed"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ regulator-name = "vcc_3v3_s0"; -+ vin-supply = <&vcc_3v3_s3>; -+ }; -+ -+ vcc_3v3_sd_s0: vcc-3v3-sd-s0-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio4 RK_PB4 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sd_s0_pwr>; -+ regulator-name = "vcc_3v3_sd_s0"; -+ regulator-boot-on; -+ regulator-max-microvolt = <3000000>; -+ regulator-min-microvolt = <3000000>; -+ vin-supply = <&vcc_3v3_s3>; -+ }; -+ -+ vcc_3v3_pcie20: vcc3v3-pcie20-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc_3v3_pcie20"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc_3v3_s3>; -+ }; -+ -+ vcc5v0_usb: vcc5v0-usb-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc5v0_usb"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc5v0_usb_otg0: vcc5v0-usb-otg0-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio1 RK_PD2 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&typec5v_pwren>; -+ regulator-name = "vcc5v0_usb_otg0"; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v0_usb>; -+ }; -+ -+ vcc5v0_host_20: vcc5v0-host-20-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio4 RK_PB5 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&vcc5v0_host20_en>; -+ regulator-name = "vcc5v0_host_20"; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v0_usb>; -+ }; -+}; -+ -+&combphy0_ps { -+ status = "okay"; -+}; -+ -+&combphy2_psu { -+ status = "okay"; -+}; -+ -+&cpu_b0 { -+ cpu-supply = <&vdd_cpu_big0_s0>; -+}; -+ -+&cpu_b1 { -+ cpu-supply = <&vdd_cpu_big0_s0>; -+}; -+ -+&cpu_b2 { -+ cpu-supply = <&vdd_cpu_big1_s0>; -+}; -+ -+&cpu_b3 { -+ cpu-supply = <&vdd_cpu_big1_s0>; -+}; -+ -+&cpu_l0 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&cpu_l1 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&cpu_l2 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&cpu_l3 { -+ cpu-supply = <&vdd_cpu_lit_s0>; -+}; -+ -+&gmac1 { -+ clock_in_out = "output"; -+ phy-handle = <&rgmii_phy1>; -+ phy-mode = "rgmii-rxid"; -+ pinctrl-0 = <&gmac1_miim -+ &gmac1_tx_bus2 -+ &gmac1_rx_bus2 -+ &gmac1_rgmii_clk -+ &gmac1_rgmii_bus>; -+ pinctrl-names = "default"; -+ tx_delay = <0x42>; -+ status = "okay"; -+}; -+ -+&i2c0 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&i2c0m2_xfer>; -+ status = "okay"; -+ -+ vdd_cpu_big0_s0: regulator@42 { -+ compatible = "rockchip,rk8602"; -+ reg = <0x42>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_cpu_big0_s0"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <1050000>; -+ regulator-ramp-delay = <2300>; -+ vin-supply = <&vcc5v0_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_cpu_big1_s0: regulator@43 { -+ compatible = "rockchip,rk8603", "rockchip,rk8602"; -+ reg = <0x43>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_cpu_big1_s0"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <1050000>; -+ regulator-ramp-delay = <2300>; -+ vin-supply = <&vcc5v0_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+}; -+ -+&i2c2 { -+ status = "okay"; -+ -+ vdd_npu_s0: regulator@42 { -+ compatible = "rockchip,rk8602"; -+ reg = <0x42>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_npu_s0"; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <950000>; -+ regulator-ramp-delay = <2300>; -+ regulator-boot-on; -+ regulator-always-on; -+ vin-supply = <&vcc5v0_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+}; -+ -+&i2c6 { -+ clock-frequency = <200000>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&i2c6m0_xfer>; -+ status = "okay"; -+ -+ hym8563: rtc@51 { -+ compatible = "haoyu,hym8563"; -+ reg = <0x51>; -+ #clock-cells = <0>; -+ clock-output-names = "hym8563"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&rtc_int>; -+ interrupt-parent = <&gpio0>; -+ interrupts = ; -+ wakeup-source; -+ }; -+}; -+ -+&mdio1 { -+ rgmii_phy1: ethernet-phy@1 { -+ compatible = "ethernet-phy-id001c.c916"; -+ reg = <0x1>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&rtl8211f_rst>; -+ reset-assert-us = <20000>; -+ reset-deassert-us = <100000>; -+ reset-gpios = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>; -+ }; -+}; -+ -+&pcie2x1l1 { -+ reset-gpios = <&gpio1 RK_PA7 GPIO_ACTIVE_HIGH>; -+ vpcie3v3-supply = <&vcc_3v3_pcie20>; -+ status = "okay"; -+}; -+ -+&pcie2x1l2 { -+ reset-gpios = <&gpio3 RK_PD1 GPIO_ACTIVE_HIGH>; -+ vpcie3v3-supply = <&vcc_3v3_pcie20>; -+ status = "okay"; -+}; -+ -+&pinctrl { -+ gpio-key { -+ key1_pin: key1-pin { -+ rockchip,pins = <1 RK_PC0 RK_FUNC_GPIO &pcfg_pull_up>; -+ }; -+ }; -+ -+ gpio-leds { -+ sys_led_pin: sys-led-pin { -+ rockchip,pins = -+ <1 RK_PC1 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ wan_led_pin: wan-led-pin { -+ rockchip,pins = -+ <1 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ lan1_led_pin: lan1-led-pin { -+ rockchip,pins = -+ <1 RK_PC3 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ lan2_led_pin: lan2-led-pin { -+ rockchip,pins = -+ <1 RK_PC4 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ hym8563 { -+ rtc_int: rtc-int { -+ rockchip,pins = <0 RK_PB0 RK_FUNC_GPIO &pcfg_pull_up>; -+ }; -+ }; -+ -+ sdmmc { -+ sd_s0_pwr: sd-s0-pwr { -+ rockchip,pins = <4 RK_PB4 RK_FUNC_GPIO &pcfg_pull_up>; -+ }; -+ }; -+ -+ usb { -+ typec5v_pwren: typec5v-pwren { -+ rockchip,pins = <1 RK_PD2 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ vcc5v0_host20_en: vcc5v0-host20-en { -+ rockchip,pins = <4 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ rtl8211f { -+ rtl8211f_rst: rtl8211f-rst { -+ rockchip,pins = <3 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+}; -+ -+&saradc { -+ vref-supply = <&avcc_1v8_s0>; -+ status = "okay"; -+}; -+ -+&sdhci { -+ bus-width = <8>; -+ no-sdio; -+ no-sd; -+ non-removable; -+ mmc-hs200-1_8v; -+ status = "okay"; -+}; -+ -+&sdmmc { -+ bus-width = <4>; -+ cap-sd-highspeed; -+ disable-wp; -+ max-frequency = <150000000>; -+ no-mmc; -+ no-sdio; -+ sd-uhs-sdr104; -+ vmmc-supply = <&vcc_3v3_sd_s0>; -+ vqmmc-supply = <&vccio_sd_s0>; -+ status = "okay"; -+}; -+ -+&spi2 { -+ status = "okay"; -+ assigned-clocks = <&cru CLK_SPI2>; -+ assigned-clock-rates = <200000000>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&spi2m2_cs0 &spi2m2_pins>; -+ num-cs = <1>; -+ -+ pmic@0 { -+ compatible = "rockchip,rk806"; -+ spi-max-frequency = <1000000>; -+ reg = <0x0>; -+ -+ interrupt-parent = <&gpio0>; -+ interrupts = <7 IRQ_TYPE_LEVEL_LOW>; -+ -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pmic_pins>, <&rk806_dvs1_null>, -+ <&rk806_dvs2_null>, <&rk806_dvs3_null>; -+ -+ system-power-controller; -+ -+ vcc1-supply = <&vcc5v0_sys>; -+ vcc2-supply = <&vcc5v0_sys>; -+ vcc3-supply = <&vcc5v0_sys>; -+ vcc4-supply = <&vcc5v0_sys>; -+ vcc5-supply = <&vcc5v0_sys>; -+ vcc6-supply = <&vcc5v0_sys>; -+ vcc7-supply = <&vcc5v0_sys>; -+ vcc8-supply = <&vcc5v0_sys>; -+ vcc9-supply = <&vcc5v0_sys>; -+ vcc10-supply = <&vcc5v0_sys>; -+ vcc11-supply = <&vcc_2v0_pldo_s3>; -+ vcc12-supply = <&vcc5v0_sys>; -+ vcc13-supply = <&vcc_1v1_nldo_s3>; -+ vcc14-supply = <&vcc_1v1_nldo_s3>; -+ vcca-supply = <&vcc5v0_sys>; -+ -+ gpio-controller; -+ #gpio-cells = <2>; -+ -+ rk806_dvs1_null: dvs1-null-pins { -+ pins = "gpio_pwrctrl1"; -+ function = "pin_fun0"; -+ }; -+ -+ rk806_dvs2_null: dvs2-null-pins { -+ pins = "gpio_pwrctrl2"; -+ function = "pin_fun0"; -+ }; -+ -+ rk806_dvs3_null: dvs3-null-pins { -+ pins = "gpio_pwrctrl3"; -+ function = "pin_fun0"; -+ }; -+ -+ regulators { -+ vdd_gpu_s0: vdd_gpu_mem_s0: dcdc-reg1 { -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <950000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_gpu_s0"; -+ regulator-enable-ramp-delay = <400>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_cpu_lit_s0: vdd_cpu_lit_mem_s0: dcdc-reg2 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <950000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_cpu_lit_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_log_s0: dcdc-reg3 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <675000>; -+ regulator-max-microvolt = <750000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_log_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <750000>; -+ }; -+ }; -+ -+ vdd_vdenc_s0: vdd_vdenc_mem_s0: dcdc-reg4 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <550000>; -+ regulator-max-microvolt = <950000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_vdenc_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_ddr_s0: dcdc-reg5 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <675000>; -+ regulator-max-microvolt = <900000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_ddr_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <850000>; -+ }; -+ }; -+ -+ vdd2_ddr_s3: dcdc-reg6 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-name = "vdd2_ddr_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ }; -+ }; -+ -+ vcc_2v0_pldo_s3: dcdc-reg7 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <2000000>; -+ regulator-max-microvolt = <2000000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vdd_2v0_pldo_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <2000000>; -+ }; -+ }; -+ -+ vcc_3v3_s3: dcdc-reg8 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ regulator-name = "vcc_3v3_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <3300000>; -+ }; -+ }; -+ -+ vddq_ddr_s0: dcdc-reg9 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-name = "vddq_ddr_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_1v8_s3: dcdc-reg10 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "vcc_1v8_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ avcc_1v8_s0: pldo-reg1 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "avcc_1v8_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ vcc_1v8_s0: pldo-reg2 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "vcc_1v8_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ avdd_1v2_s0: pldo-reg3 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1200000>; -+ regulator-max-microvolt = <1200000>; -+ regulator-name = "avdd_1v2_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ avcc_3v3_s0: pldo-reg4 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "avcc_3v3_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vccio_sd_s0: pldo-reg5 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <3300000>; -+ regulator-ramp-delay = <12500>; -+ regulator-name = "vccio_sd_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ pldo6_s3: pldo-reg6 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ regulator-name = "pldo6_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ vdd_0v75_s3: nldo-reg1 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <750000>; -+ regulator-max-microvolt = <750000>; -+ regulator-name = "vdd_0v75_s3"; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <750000>; -+ }; -+ }; -+ -+ avdd_ddr_pll_s0: nldo-reg2 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <850000>; -+ regulator-max-microvolt = <850000>; -+ regulator-name = "avdd_ddr_pll_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <850000>; -+ }; -+ }; -+ -+ avdd_0v75_s0: nldo-reg3 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <750000>; -+ regulator-max-microvolt = <750000>; -+ regulator-name = "avdd_0v75_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ avdd_0v85_s0: nldo-reg4 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <850000>; -+ regulator-max-microvolt = <850000>; -+ regulator-name = "avdd_0v85_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_0v75_s0: nldo-reg5 { -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <750000>; -+ regulator-max-microvolt = <750000>; -+ regulator-name = "vdd_0v75_s0"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ }; -+ }; -+}; -+ -+&tsadc { -+ status = "okay"; -+}; -+ -+&u2phy2 { -+ status = "okay"; -+}; -+ -+&u2phy2_host { -+ phy-supply = <&vcc5v0_host_20>; -+ status = "okay"; -+}; -+ -+&uart2 { -+ pinctrl-0 = <&uart2m0_xfer>; -+ status = "okay"; -+}; -+ -+&usb_host0_ehci { -+ status = "okay"; -+}; -+ -+&usb_host0_ohci { -+ status = "okay"; -+}; ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3566-rock-3c.dts -@@ -0,0 +1,726 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+#include -+#include -+#include -+#include -+#include "rk3566.dtsi" -+ -+/ { -+ model = "Radxa ROCK 3C"; -+ compatible = "radxa,rock-3c", "rockchip,rk3566"; -+ -+ aliases { -+ ethernet0 = &gmac1; -+ mmc0 = &sdhci; -+ mmc1 = &sdmmc0; -+ mmc2 = &sdmmc1; -+ }; -+ -+ chosen: chosen { -+ stdout-path = "serial2:1500000n8"; -+ }; -+ -+ gmac1_clkin: external-gmac1-clock { -+ compatible = "fixed-clock"; -+ clock-frequency = <125000000>; -+ clock-output-names = "gmac1_clkin"; -+ #clock-cells = <0>; -+ }; -+ -+ hdmi-con { -+ compatible = "hdmi-connector"; -+ type = "a"; -+ -+ port { -+ hdmi_con_in: endpoint { -+ remote-endpoint = <&hdmi_out_con>; -+ }; -+ }; -+ }; -+ -+ leds { -+ compatible = "gpio-leds"; -+ -+ led-0 { -+ gpios = <&gpio0 RK_PA0 GPIO_ACTIVE_HIGH>; -+ function = LED_FUNCTION_HEARTBEAT; -+ color = ; -+ linux,default-trigger = "heartbeat"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&user_led2>; -+ }; -+ }; -+ -+ sdio_pwrseq: sdio-pwrseq { -+ compatible = "mmc-pwrseq-simple"; -+ clocks = <&rk809 1>; -+ clock-names = "ext_clock"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&wifi_reg_on_h>; -+ post-power-on-delay-ms = <100>; -+ power-off-delay-us = <5000000>; -+ reset-gpios = <&gpio0 RK_PC0 GPIO_ACTIVE_LOW>; -+ }; -+ -+ vcc5v_dcin: vcc5v-dcin-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc5v_dcin"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ }; -+ -+ vcc3v3_pcie: vcc3v3-pcie-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio0 RK_PA6 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pcie_pwr_en>; -+ regulator-name = "vcc3v3_pcie"; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc3v3_sys>; -+ }; -+ -+ vcc3v3_sys: vcc3v3-sys-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc3v3_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc5v0_sys: vcc5v0-sys-regulator { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc5v0_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v_dcin>; -+ }; -+ -+ vcc5v0_usb30_host: vcc5v0-usb30-host-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpio = <&gpio0 RK_PC5 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&vcc5v0_usb30_host_en>; -+ regulator-name = "vcc5v0_usb30_host"; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc5v0_usb_otg: vcc5v0-usb-otg-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpio = <&gpio0 RK_PC6 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&vcc5v0_usb_otg_en>; -+ regulator-name = "vcc5v0_usb_otg"; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc_cam: vcc-cam-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpio = <&gpio0 RK_PC4 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&vcc_cam_en>; -+ regulator-name = "vcc_cam"; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc3v3_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_mipi: vcc-mipi-regulator { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpio = <&gpio0 RK_PC7 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&vcc_mipi_en>; -+ regulator-name = "vcc_mipi"; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc3v3_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+}; -+ -+&combphy1 { -+ status = "okay"; -+}; -+ -+&combphy2 { -+ status = "okay"; -+}; -+ -+&cpu0 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu1 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu2 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu3 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&gmac1 { -+ assigned-clocks = <&cru SCLK_GMAC1_RX_TX>, <&cru SCLK_GMAC1>; -+ assigned-clock-parents = <&cru SCLK_GMAC1_RGMII_SPEED>, <&gmac1_clkin>; -+ clock_in_out = "input"; -+ phy-handle = <&rgmii_phy1>; -+ phy-mode = "rgmii-id"; -+ phy-supply = <&vcc_3v3>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&gmac1m1_miim -+ &gmac1m1_tx_bus2 -+ &gmac1m1_rx_bus2 -+ &gmac1m1_rgmii_clk -+ &gmac1m1_rgmii_bus -+ &gmac1m1_clkinout>; -+ status = "okay"; -+}; -+ -+&gpu { -+ mali-supply = <&vdd_gpu>; -+ status = "okay"; -+}; -+ -+&hdmi { -+ avdd-0v9-supply = <&vdda0v9_image>; -+ avdd-1v8-supply = <&vcca1v8_image>; -+ status = "okay"; -+}; -+ -+&hdmi_in { -+ hdmi_in_vp0: endpoint { -+ remote-endpoint = <&vp0_out_hdmi>; -+ }; -+}; -+ -+&hdmi_out { -+ hdmi_out_con: endpoint { -+ remote-endpoint = <&hdmi_con_in>; -+ }; -+}; -+ -+&hdmi_sound { -+ status = "okay"; -+}; -+ -+&i2c0 { -+ status = "okay"; -+ -+ vdd_cpu: regulator@1c { -+ compatible = "tcs,tcs4525"; -+ reg = <0x1c>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_cpu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <800000>; -+ regulator-max-microvolt = <1150000>; -+ regulator-ramp-delay = <2300>; -+ vin-supply = <&vcc5v0_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ rk809: pmic@20 { -+ compatible = "rockchip,rk809"; -+ reg = <0x20>; -+ interrupt-parent = <&gpio0>; -+ interrupts = ; -+ clock-output-names = "rk808-clkout1", "rk808-clkout2"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pmic_int_l>, <&i2s1m0_mclk>; -+ system-power-controller; -+ vcc1-supply = <&vcc3v3_sys>; -+ vcc2-supply = <&vcc3v3_sys>; -+ vcc3-supply = <&vcc3v3_sys>; -+ vcc4-supply = <&vcc3v3_sys>; -+ vcc5-supply = <&vcc3v3_sys>; -+ vcc6-supply = <&vcc3v3_sys>; -+ vcc7-supply = <&vcc3v3_sys>; -+ vcc8-supply = <&vcc3v3_sys>; -+ vcc9-supply = <&vcc3v3_sys>; -+ wakeup-source; -+ #clock-cells = <1>; -+ -+ regulators { -+ vdd_logic: DCDC_REG1 { -+ regulator-name = "vdd_logic"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <900000>; -+ }; -+ }; -+ -+ vdd_gpu: DCDC_REG2 { -+ regulator-name = "vdd_gpu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <900000>; -+ }; -+ }; -+ -+ vcc_ddr: DCDC_REG3 { -+ regulator-name = "vcc_ddr"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ }; -+ }; -+ -+ vdd_npu: DCDC_REG4 { -+ regulator-name = "vdd_npu"; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_1v8: DCDC_REG5 { -+ regulator-name = "vcc_1v8"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdda0v9_image: LDO_REG1 { -+ regulator-name = "vdda0v9_image"; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdda_0v9: LDO_REG2 { -+ regulator-name = "vdda_0v9"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdda0v9_pmu: LDO_REG3 { -+ regulator-name = "vdda0v9_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <900000>; -+ }; -+ }; -+ -+ vccio_acodec: LDO_REG4 { -+ regulator-name = "vccio_acodec"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vccio_sd: LDO_REG5 { -+ regulator-name = "vccio_sd"; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc3v3_pmu: LDO_REG6 { -+ regulator-name = "vcc3v3_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <3300000>; -+ }; -+ }; -+ -+ vcca_1v8: LDO_REG7 { -+ regulator-name = "vcca_1v8"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcca1v8_pmu: LDO_REG8 { -+ regulator-name = "vcca1v8_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ vcca1v8_image: LDO_REG9 { -+ regulator-name = "vcca1v8_image"; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_3v3: SWITCH_REG1 { -+ regulator-name = "vcc_3v3"; -+ regulator-always-on; -+ regulator-boot-on; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc3v3_sd: SWITCH_REG2 { -+ regulator-name = "vcc3v3_sd"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ }; -+ }; -+ -+ eeprom: eeprom@50 { -+ compatible = "belling,bl24c16a", "atmel,24c16"; -+ reg = <0x50>; -+ pagesize = <16>; -+ }; -+}; -+ -+&i2s0_8ch { -+ status = "okay"; -+}; -+ -+&i2s1_8ch { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&i2s1m0_sclktx &i2s1m0_lrcktx &i2s1m0_sdi0 &i2s1m0_sdo0>; -+ rockchip,trcm-sync-tx-only; -+ status = "okay"; -+}; -+ -+&mdio1 { -+ rgmii_phy1: ethernet-phy@1 { -+ compatible = "ethernet-phy-ieee802.3-c22"; -+ reg = <0x1>; -+ reset-assert-us = <20000>; -+ reset-deassert-us = <100000>; -+ reset-gpios = <&gpio3 RK_PC0 GPIO_ACTIVE_LOW>; -+ }; -+}; -+ -+&pcie2x1 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pcie_reset_h>; -+ reset-gpios = <&gpio1 RK_PB2 GPIO_ACTIVE_HIGH>; -+ vpcie3v3-supply = <&vcc3v3_pcie>; -+ status = "okay"; -+}; -+ -+&pinctrl { -+ bluetooth { -+ bt_reg_on_h: bt-reg-on-h { -+ rockchip,pins = <0 RK_PC1 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ bt_wake_host_h: bt-wake-host-h { -+ rockchip,pins = <0 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ bt_host_wake_h: bt-host-wake-h { -+ rockchip,pins = <0 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ cam { -+ vcc_cam_en: vcc_cam_en { -+ rockchip,pins = <0 RK_PC4 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ display { -+ vcc_mipi_en: vcc_mipi_en { -+ rockchip,pins = <0 RK_PC7 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ leds { -+ user_led2: user-led2 { -+ rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ pcie { -+ pcie_pwr_en: pcie-pwr-en { -+ rockchip,pins = <0 RK_PA6 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ pcie_reset_h: pcie-reset-h { -+ rockchip,pins = <1 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ pmic { -+ pmic_int_l: pmic-int-l { -+ rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>; -+ }; -+ }; -+ -+ usb { -+ vcc5v0_usb30_host_en: vcc5v0-usb30-host-en { -+ rockchip,pins = <0 RK_PC5 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ vcc5v0_usb_otg_en: vcc5v0-usb-otg-en { -+ rockchip,pins = <0 RK_PC6 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ wifi { -+ wifi_host_wake_h: wifi-host-wake-h { -+ rockchip,pins = <0 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ wifi_reg_on_h: wifi-reg-on-h { -+ rockchip,pins = <0 RK_PC0 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+}; -+ -+&pmu_io_domains { -+ pmuio1-supply = <&vcc3v3_pmu>; -+ pmuio2-supply = <&vcca1v8_pmu>; -+ vccio1-supply = <&vccio_acodec>; -+ vccio2-supply = <&vcc_1v8>; -+ vccio3-supply = <&vccio_sd>; -+ vccio4-supply = <&vcca1v8_pmu>; -+ vccio5-supply = <&vcc_3v3>; -+ vccio6-supply = <&vcc_3v3>; -+ vccio7-supply = <&vcc_3v3>; -+ status = "okay"; -+}; -+ -+&saradc { -+ vref-supply = <&vcca_1v8>; -+ status = "okay"; -+}; -+ -+&sdhci { -+ bus-width = <8>; -+ max-frequency = <200000000>; -+ mmc-hs200-1_8v; -+ non-removable; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; -+ vmmc-supply = <&vcc_3v3>; -+ vqmmc-supply = <&vcc_1v8>; -+ status = "okay"; -+}; -+ -+&sdmmc0 { -+ bus-width = <4>; -+ cap-sd-highspeed; -+ disable-wp; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sdmmc0_bus4 &sdmmc0_clk &sdmmc0_cmd &sdmmc0_det>; -+ sd-uhs-sdr50; -+ vmmc-supply = <&vcc3v3_sys>; -+ vqmmc-supply = <&vccio_sd>; -+ status = "okay"; -+}; -+ -+&sdmmc1 { -+ bus-width = <4>; -+ cap-sd-highspeed; -+ cap-sdio-irq; -+ keep-power-in-suspend; -+ mmc-pwrseq = <&sdio_pwrseq>; -+ non-removable; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sdmmc1_bus4 &sdmmc1_clk &sdmmc1_cmd>; -+ sd-uhs-sdr104; -+ vmmc-supply = <&vcc3v3_sys>; -+ vqmmc-supply = <&vcca1v8_pmu>; -+ status = "okay"; -+}; -+ -+&sfc { -+ #address-cells = <1>; -+ #size-cells = <0>; -+ status = "okay"; -+ -+ flash@0 { -+ compatible = "jedec,spi-nor"; -+ reg = <0x0>; -+ spi-max-frequency = <104000000>; -+ spi-rx-bus-width = <4>; -+ spi-tx-bus-width = <1>; -+ }; -+}; -+ -+&tsadc { -+ rockchip,hw-tshut-mode = <1>; -+ rockchip,hw-tshut-polarity = <0>; -+ status = "okay"; -+}; -+ -+&uart1 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&uart1m0_ctsn &uart1m0_rtsn &uart1m0_xfer>; -+ status = "okay"; -+}; -+ -+&uart2 { -+ status = "okay"; -+}; -+ -+&usb_host0_ehci { -+ status = "okay"; -+}; -+ -+&usb_host0_ohci { -+ status = "okay"; -+}; -+ -+&usb_host0_xhci { -+ dr_mode = "host"; -+ status = "okay"; -+}; -+ -+&usb_host1_ehci { -+ status = "okay"; -+}; -+ -+&usb_host1_ohci { -+ status = "okay"; -+}; -+ -+&usb_host1_xhci { -+ status = "okay"; -+}; -+ -+&usb2phy0 { -+ status = "okay"; -+}; -+ -+&usb2phy0_host { -+ phy-supply = <&vcc5v0_usb30_host>; -+ status = "okay"; -+}; -+ -+&usb2phy0_otg { -+ phy-supply = <&vcc5v0_usb_otg>; -+ status = "okay"; -+}; -+ -+&usb2phy1 { -+ status = "okay"; -+}; -+ -+&usb2phy1_host { -+ phy-supply = <&vcc5v0_usb30_host>; -+ status = "okay"; -+}; -+ -+&usb2phy1_otg { -+ phy-supply = <&vcc5v0_usb30_host>; -+ status = "okay"; -+}; -+ -+&vop { -+ assigned-clocks = <&cru DCLK_VOP0>, <&cru DCLK_VOP1>; -+ assigned-clock-parents = <&pmucru PLL_HPLL>, <&cru PLL_VPLL>; -+ status = "okay"; -+}; -+ -+&vop_mmu { -+ status = "okay"; -+}; -+ -+&vp0 { -+ vp0_out_hdmi: endpoint@ROCKCHIP_VOP2_EP_HDMI0 { -+ reg = ; -+ remote-endpoint = <&hdmi_in_vp0>; -+ }; -+}; ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3566-radxa-zero-3.dtsi -@@ -0,0 +1,531 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+#include -+#include -+#include -+#include "rk3566.dtsi" -+ -+/ { -+ chosen { -+ stdout-path = "serial2:1500000n8"; -+ }; -+ -+ hdmi-con { -+ compatible = "hdmi-connector"; -+ type = "d"; -+ -+ port { -+ hdmi_con_in: endpoint { -+ remote-endpoint = <&hdmi_out_con>; -+ }; -+ }; -+ }; -+ -+ leds { -+ compatible = "gpio-leds"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&user_led2>; -+ -+ led-green { -+ color = ; -+ default-state = "on"; -+ function = LED_FUNCTION_HEARTBEAT; -+ gpios = <&gpio0 RK_PA0 GPIO_ACTIVE_HIGH>; -+ linux,default-trigger = "heartbeat"; -+ }; -+ }; -+ -+ vcc_1v8: regulator-1v8-vcc { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc_1v8"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ vin-supply = <&vcc_1v8_p>; -+ }; -+ -+ vcca_1v8: regulator-1v8-vcca { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcca_1v8"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ vin-supply = <&vcc_1v8_p>; -+ }; -+ -+ vcca1v8_image: regulator-1v8-vcca-image { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcca1v8_image"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ vin-supply = <&vcc_1v8_p>; -+ }; -+ -+ vcc_3v3: regulator-3v3-vcc { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc_3v3"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc3v3_sys>; -+ }; -+ -+ vcc_sys: regulator-5v0-vcc-sys { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ }; -+}; -+ -+&combphy1 { -+ status = "okay"; -+}; -+ -+&cpu0 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu1 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu2 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu3 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&gpio0 { -+ gpio-line-names = -+ /* GPIO0_A0 - A7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO0_B0 - B7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO0_C0 - C7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO0_D0 - D7 */ -+ "pin-10 [GPIO0_D0]", "pin-08 [GPIO0_D1]", "", -+ "", "", "", "", ""; -+}; -+ -+&gpio1 { -+ gpio-line-names = -+ /* GPIO1_A0 - A7 */ -+ "pin-03 [GPIO1_A0]", "pin-05 [GPIO1_A1]", "", -+ "", "pin-37 [GPIO1_A4]", "", -+ "", "", -+ /* GPIO1_B0 - B7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO1_C0 - C7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO1_D0 - D7 */ -+ "", "", "", "", "", "", "", ""; -+}; -+ -+&gpio2 { -+ gpio-line-names = -+ /* GPIO2_A0 - A7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO2_B0 - B7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO2_C0 - C7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO2_D0 - D7 */ -+ "", "", "", "", "", "", "", ""; -+}; -+ -+&gpio3 { -+ gpio-line-names = -+ /* GPIO3_A0 - A7 */ -+ "", "pin-11 [GPIO3_A1]", "pin-13 [GPIO3_A2]", -+ "pin-12 [GPIO3_A3]", "pin-35 [GPIO3_A4]", "pin-40 [GPIO3_A5]", -+ "pin-38 [GPIO3_A6]", "pin-36 [GPIO3_A7]", -+ /* GPIO3_B0 - B7 */ -+ "pin-15 [GPIO3_B0]", "pin-16 [GPIO3_B1]", "pin-18 [GPIO3_B2]", -+ "pin-29 [GPIO3_B3]", "pin-31 [GPIO3_B4]", "", -+ "", "", -+ /* GPIO3_C0 - C7 */ -+ "", "pin-22 [GPIO3_C1]", "pin-32 [GPIO3_C2]", -+ "pin-33 [GPIO3_C3]", "pin-07 [GPIO3_C4]", "", -+ "", "", -+ /* GPIO3_D0 - D7 */ -+ "", "", "", "", "", "", "", ""; -+}; -+ -+&gpio4 { -+ gpio-line-names = -+ /* GPIO4_A0 - A7 */ -+ "", "", "", "", "", "", "", "", -+ /* GPIO4_B0 - B7 */ -+ "", "", "pin-27 [GPIO4_B2]", -+ "pin-28 [GPIO4_B3]", "", "", "", "", -+ /* GPIO4_C0 - C7 */ -+ "", "", "pin-23 [GPIO4_C2]", -+ "pin-19 [GPIO4_C3]", "", "pin-21 [GPIO4_C5]", -+ "pin-24 [GPIO4_C6]", "", -+ /* GPIO4_D0 - D7 */ -+ "", "", "", "", "", "", "", ""; -+}; -+ -+&gpu { -+ mali-supply = <&vdd_gpu_npu>; -+ status = "okay"; -+}; -+ -+&hdmi { -+ avdd-0v9-supply = <&vdda_0v9>; -+ avdd-1v8-supply = <&vcca1v8_image>; -+ status = "okay"; -+}; -+ -+&hdmi_in { -+ hdmi_in_vp0: endpoint { -+ remote-endpoint = <&vp0_out_hdmi>; -+ }; -+}; -+ -+&hdmi_out { -+ hdmi_out_con: endpoint { -+ remote-endpoint = <&hdmi_con_in>; -+ }; -+}; -+ -+&hdmi_sound { -+ status = "okay"; -+}; -+ -+&i2c0 { -+ status = "okay"; -+ -+ rk817: pmic@20 { -+ compatible = "rockchip,rk817"; -+ reg = <0x20>; -+ #clock-cells = <1>; -+ clock-output-names = "rk817-clkout1", "rk817-clkout2"; -+ interrupt-parent = <&gpio0>; -+ interrupts = ; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pmic_int_l>; -+ system-power-controller; -+ wakeup-source; -+ -+ vcc1-supply = <&vcc_sys>; -+ vcc2-supply = <&vcc_sys>; -+ vcc3-supply = <&vcc_sys>; -+ vcc4-supply = <&vcc_sys>; -+ vcc5-supply = <&vcc_sys>; -+ vcc6-supply = <&vcc_sys>; -+ vcc7-supply = <&vcc_sys>; -+ vcc8-supply = <&vcc_sys>; -+ vcc9-supply = <&vcc5v_midu>; -+ -+ regulators { -+ vdd_logic: DCDC_REG1 { -+ regulator-name = "vdd_logic"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ regulator-suspend-microvolt = <900000>; -+ }; -+ }; -+ -+ vdd_gpu_npu: DCDC_REG2 { -+ regulator-name = "vdd_gpu_npu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_ddr: DCDC_REG3 { -+ regulator-name = "vcc_ddr"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ }; -+ }; -+ -+ vcc3v3_sys: DCDC_REG4 { -+ regulator-name = "vcc3v3_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <3300000>; -+ }; -+ }; -+ -+ vcca1v8_pmu: LDO_REG1 { -+ regulator-name = "vcca1v8_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ vdda_0v9: LDO_REG2 { -+ regulator-name = "vdda_0v9"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdda0v9_pmu: LDO_REG3 { -+ regulator-name = "vdda0v9_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <900000>; -+ }; -+ }; -+ -+ vccio_acodec: LDO_REG4 { -+ regulator-name = "vccio_acodec"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vccio_sd: LDO_REG5 { -+ regulator-name = "vccio_sd"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc3v3_pmu: LDO_REG6 { -+ regulator-name = "vcc3v3_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <3300000>; -+ }; -+ }; -+ -+ vcc_1v8_p: LDO_REG7 { -+ regulator-name = "vcc_1v8_p"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc1v8_dvp: LDO_REG8 { -+ regulator-name = "vcc1v8_dvp"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc2v8_dvp: LDO_REG9 { -+ regulator-name = "vcc2v8_dvp"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <2800000>; -+ regulator-max-microvolt = <2800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc5v_midu: BOOST { -+ regulator-name = "vcc5v_midu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vbus: OTG_SWITCH { -+ regulator-name = "vbus"; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ }; -+ }; -+ -+ vdd_cpu: regulator@40 { -+ compatible = "rockchip,rk8600"; -+ reg = <0x40>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_cpu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <712500>; -+ regulator-max-microvolt = <1390000>; -+ regulator-ramp-delay = <2300>; -+ vin-supply = <&vcc_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+}; -+ -+&i2s0_8ch { -+ status = "okay"; -+}; -+ -+&pinctrl { -+ leds { -+ user_led2: user-led2 { -+ rockchip,pins = <0 RK_PA0 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ pmic { -+ pmic_int_l: pmic-int-l { -+ rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>; -+ }; -+ }; -+}; -+ -+&pmu_io_domains { -+ pmuio1-supply = <&vcc3v3_pmu>; -+ pmuio2-supply = <&vcca1v8_pmu>; -+ vccio1-supply = <&vccio_acodec>; -+ vccio2-supply = <&vcc_1v8>; -+ vccio3-supply = <&vccio_sd>; -+ vccio4-supply = <&vcc_1v8>; -+ vccio5-supply = <&vcc_3v3>; -+ vccio6-supply = <&vcc_3v3>; -+ vccio7-supply = <&vcc_3v3>; -+ status = "okay"; -+}; -+ -+&saradc { -+ vref-supply = <&vcca_1v8>; -+ status = "okay"; -+}; -+ -+&sdmmc0 { -+ bus-width = <4>; -+ cap-sd-highspeed; -+ disable-wp; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sdmmc0_bus4 &sdmmc0_clk &sdmmc0_cmd &sdmmc0_det>; -+ vmmc-supply = <&vcc3v3_sys>; -+ vqmmc-supply = <&vccio_sd>; -+ status = "okay"; -+}; -+ -+&tsadc { -+ rockchip,hw-tshut-mode = <1>; -+ rockchip,hw-tshut-polarity = <0>; -+ status = "okay"; -+}; -+ -+&uart2 { -+ status = "okay"; -+}; -+ -+&usb_host0_xhci { -+ dr_mode = "peripheral"; -+ status = "okay"; -+}; -+ -+&usb_host1_xhci { -+ status = "okay"; -+}; -+ -+&usb2phy0 { -+ status = "okay"; -+}; -+ -+&usb2phy0_host { -+ status = "okay"; -+}; -+ -+&usb2phy0_otg { -+ status = "okay"; -+}; -+ -+&vop { -+ assigned-clocks = <&cru DCLK_VOP0>, <&cru DCLK_VOP1>; -+ assigned-clock-parents = <&pmucru PLL_HPLL>, <&cru PLL_VPLL>; -+ status = "okay"; -+}; -+ -+&vop_mmu { -+ status = "okay"; -+}; -+ -+&vp0 { -+ vp0_out_hdmi: endpoint@ROCKCHIP_VOP2_EP_HDMI0 { -+ reg = ; -+ remote-endpoint = <&hdmi_in_vp0>; -+ }; -+}; ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3566-radxa-zero-3e.dts -@@ -0,0 +1,52 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+ -+#include "rk3566-radxa-zero-3.dtsi" -+ -+/ { -+ model = "Radxa ZERO 3E"; -+ compatible = "radxa,zero-3e", "rockchip,rk3566"; -+ -+ aliases { -+ ethernet0 = &gmac1; -+ mmc0 = &sdmmc0; -+ }; -+}; -+ -+&gmac1 { -+ assigned-clocks = <&cru SCLK_GMAC1_RX_TX>, <&cru SCLK_GMAC1>; -+ assigned-clock-parents = <&cru SCLK_GMAC1_RGMII_SPEED>, <&cru CLK_MAC1_2TOP>; -+ clock_in_out = "input"; -+ phy-handle = <&rgmii_phy1>; -+ phy-mode = "rgmii-id"; -+ phy-supply = <&vcc_3v3>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&gmac1m1_miim -+ &gmac1m1_tx_bus2 -+ &gmac1m1_rx_bus2 -+ &gmac1m1_rgmii_clk -+ &gmac1m1_rgmii_bus -+ &gmac1m1_clkinout>; -+ status = "okay"; -+}; -+ -+&mdio1 { -+ rgmii_phy1: ethernet-phy@1 { -+ compatible = "ethernet-phy-ieee802.3-c22"; -+ reg = <1>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&gmac1_rstn>; -+ reset-assert-us = <20000>; -+ reset-deassert-us = <50000>; -+ reset-gpios = <&gpio3 RK_PC0 GPIO_ACTIVE_LOW>; -+ }; -+}; -+ -+&pinctrl { -+ gmac1 { -+ gmac1_rstn: gmac1-rstn { -+ rockchip,pins = <3 RK_PC0 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+}; ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3566-radxa-zero-3w.dts -@@ -0,0 +1,92 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+ -+#include "rk3566-radxa-zero-3.dtsi" -+ -+/ { -+ model = "Radxa ZERO 3W"; -+ compatible = "radxa,zero-3w", "rockchip,rk3566"; -+ -+ aliases { -+ mmc0 = &sdhci; -+ mmc1 = &sdmmc0; -+ mmc2 = &sdmmc1; -+ }; -+ -+ sdio_pwrseq: sdio-pwrseq { -+ compatible = "mmc-pwrseq-simple"; -+ clocks = <&rk817 1>; -+ clock-names = "ext_clock"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&wifi_reg_on_h>; -+ post-power-on-delay-ms = <100>; -+ power-off-delay-us = <5000000>; -+ reset-gpios = <&gpio0 RK_PC0 GPIO_ACTIVE_LOW>; -+ }; -+}; -+ -+&pinctrl { -+ bluetooth { -+ bt_reg_on_h: bt-reg-on-h { -+ rockchip,pins = <0 RK_PC1 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ bt_wake_host_h: bt-wake-host-h { -+ rockchip,pins = <0 RK_PB3 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ host_wake_bt_h: host-wake-bt-h { -+ rockchip,pins = <0 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ wifi { -+ wifi_reg_on_h: wifi-reg-on-h { -+ rockchip,pins = <0 RK_PC0 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ wifi_wake_host_h: wifi-wake-host-h { -+ rockchip,pins = <0 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+}; -+ -+&sdhci { -+ bus-width = <8>; -+ cap-mmc-highspeed; -+ max-frequency = <200000000>; -+ mmc-hs200-1_8v; -+ no-sd; -+ no-sdio; -+ non-removable; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; -+ vmmc-supply = <&vcc_3v3>; -+ vqmmc-supply = <&vcc_1v8>; -+ status = "okay"; -+}; -+ -+&sdmmc1 { -+ bus-width = <4>; -+ cap-sd-highspeed; -+ cap-sdio-irq; -+ keep-power-in-suspend; -+ mmc-pwrseq = <&sdio_pwrseq>; -+ no-mmc; -+ no-sd; -+ non-removable; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sdmmc1_bus4 &sdmmc1_clk &sdmmc1_cmd>; -+ sd-uhs-sdr104; -+ vmmc-supply = <&vcc_3v3>; -+ vqmmc-supply = <&vcc_1v8>; -+ status = "okay"; -+}; -+ -+&uart1 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&uart1m0_xfer &uart1m0_ctsn &uart1m0_rtsn>; -+ uart-has-rtscts; -+ status = "okay"; -+}; ---- /dev/null -+++ b/dts/upstream/src/arm64/rockchip/rk3568-rock-3b.dts -@@ -0,0 +1,781 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+ -+#include -+#include -+#include -+#include -+#include "rk3568.dtsi" -+ -+/ { -+ model = "Radxa ROCK 3B"; -+ compatible = "radxa,rock-3b", "rockchip,rk3568"; -+ -+ aliases { -+ ethernet0 = &gmac0; -+ ethernet1 = &gmac1; -+ mmc0 = &sdhci; -+ mmc1 = &sdmmc0; -+ mmc2 = &sdmmc2; -+ }; -+ -+ chosen { -+ stdout-path = "serial2:1500000n8"; -+ }; -+ -+ hdmi-con { -+ compatible = "hdmi-connector"; -+ type = "a"; -+ -+ port { -+ hdmi_con_in: endpoint { -+ remote-endpoint = <&hdmi_out_con>; -+ }; -+ }; -+ }; -+ -+ ir-receiver { -+ compatible = "gpio-ir-receiver"; -+ gpios = <&gpio0 RK_PC2 GPIO_ACTIVE_LOW>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pwm3_ir>; -+ }; -+ -+ leds { -+ compatible = "gpio-leds"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&led>; -+ -+ led-0 { -+ color = ; -+ default-state = "on"; -+ function = LED_FUNCTION_HEARTBEAT; -+ gpios = <&gpio0 RK_PB7 GPIO_ACTIVE_HIGH>; -+ linux,default-trigger = "heartbeat"; -+ }; -+ }; -+ -+ /* pi6c pcie clock generator */ -+ vcc3v3_pi6c_03: regulator-3v3-vcc-pi6c-03 { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio0 RK_PD4 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pcie_pwren_h>; -+ regulator-name = "vcc3v3_pi6c_03"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ startup-delay-us = <10000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc3v3_sys: regulator-3v3-vcc-sys { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc3v3_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc3v3_sys2: regulator-3v3-vcc-sys2 { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc3v3_sys2"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc5v0_sys: regulator-5v0-vcc-sys { -+ compatible = "regulator-fixed"; -+ regulator-name = "vcc5v0_sys"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ }; -+ -+ vcc5v0_usb_host: regulator-5v0-vcc-usb-host { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio0 RK_PA6 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&usb_host_pwren_h>; -+ regulator-name = "vcc5v0_usb_host"; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ vcc5v0_usb_otg: regulator-5v0-vcc-usb-otg { -+ compatible = "regulator-fixed"; -+ enable-active-high; -+ gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_HIGH>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&usb_otg_pwren_h>; -+ regulator-name = "vcc5v0_usb_otg"; -+ regulator-min-microvolt = <5000000>; -+ regulator-max-microvolt = <5000000>; -+ vin-supply = <&vcc5v0_sys>; -+ }; -+ -+ sdio_pwrseq: sdio-pwrseq { -+ compatible = "mmc-pwrseq-simple"; -+ clocks = <&rk809 1>; -+ clock-names = "ext_clock"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&wifi_reg_on_h>; -+ post-power-on-delay-ms = <100>; -+ power-off-delay-us = <5000000>; -+ reset-gpios = <&gpio3 RK_PD4 GPIO_ACTIVE_LOW>; -+ }; -+ -+ sound { -+ compatible = "simple-audio-card"; -+ simple-audio-card,format = "i2s"; -+ simple-audio-card,name = "Analog RK809"; -+ simple-audio-card,mclk-fs = <256>; -+ -+ simple-audio-card,cpu { -+ sound-dai = <&i2s1_8ch>; -+ }; -+ -+ simple-audio-card,codec { -+ sound-dai = <&rk809>; -+ }; -+ }; -+}; -+ -+&combphy0 { -+ status = "okay"; -+}; -+ -+&combphy1 { -+ status = "okay"; -+}; -+ -+&combphy2 { -+ status = "okay"; -+}; -+ -+&cpu0 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu1 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu2 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&cpu3 { -+ cpu-supply = <&vdd_cpu>; -+}; -+ -+&gmac0 { -+ assigned-clocks = <&cru SCLK_GMAC0_RX_TX>, <&cru SCLK_GMAC0>; -+ assigned-clock-parents = <&cru SCLK_GMAC0_RGMII_SPEED>, <&cru CLK_MAC0_2TOP>; -+ clock_in_out = "input"; -+ phy-handle = <&rgmii_phy0>; -+ phy-mode = "rgmii-id"; -+ phy-supply = <&vcc_3v3>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&gmac0_miim -+ &gmac0_tx_bus2 -+ &gmac0_rx_bus2 -+ &gmac0_rgmii_clk -+ &gmac0_rgmii_bus -+ &gmac0_clkinout>; -+ status = "okay"; -+}; -+ -+&gmac1 { -+ assigned-clocks = <&cru SCLK_GMAC1_RX_TX>, <&cru SCLK_GMAC1>; -+ assigned-clock-parents = <&cru SCLK_GMAC1_RGMII_SPEED>, <&cru CLK_MAC1_2TOP>; -+ clock_in_out = "input"; -+ phy-handle = <&rgmii_phy1>; -+ phy-mode = "rgmii-id"; -+ phy-supply = <&vcc_3v3>; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&gmac1m1_miim -+ &gmac1m1_tx_bus2 -+ &gmac1m1_rx_bus2 -+ &gmac1m1_rgmii_clk -+ &gmac1m1_rgmii_bus -+ &gmac1m1_clkinout>; -+ status = "okay"; -+}; -+ -+&gpu { -+ mali-supply = <&vdd_gpu>; -+ status = "okay"; -+}; -+ -+&hdmi { -+ avdd-0v9-supply = <&vdda0v9_image>; -+ avdd-1v8-supply = <&vcca1v8_image>; -+ status = "okay"; -+}; -+ -+&hdmi_in { -+ hdmi_in_vp0: endpoint { -+ remote-endpoint = <&vp0_out_hdmi>; -+ }; -+}; -+ -+&hdmi_out { -+ hdmi_out_con: endpoint { -+ remote-endpoint = <&hdmi_con_in>; -+ }; -+}; -+ -+&hdmi_sound { -+ status = "okay"; -+}; -+ -+&i2c0 { -+ status = "okay"; -+ -+ vdd_cpu: regulator@1c { -+ compatible = "tcs,tcs4525"; -+ reg = <0x1c>; -+ fcs,suspend-voltage-selector = <1>; -+ regulator-name = "vdd_cpu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <800000>; -+ regulator-max-microvolt = <1150000>; -+ regulator-ramp-delay = <2300>; -+ vin-supply = <&vcc5v0_sys>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ rk809: pmic@20 { -+ compatible = "rockchip,rk809"; -+ reg = <0x20>; -+ assigned-clocks = <&cru I2S1_MCLKOUT_TX>; -+ assigned-clock-parents = <&cru CLK_I2S1_8CH_TX>; -+ #clock-cells = <1>; -+ clocks = <&cru I2S1_MCLKOUT_TX>; -+ clock-names = "mclk"; -+ clock-output-names = "rk809-clkout1", "rk809-clkout2"; -+ interrupt-parent = <&gpio0>; -+ interrupts = ; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pmic_int_l>, <&i2s1m0_mclk>; -+ #sound-dai-cells = <0>; -+ system-power-controller; -+ wakeup-source; -+ -+ vcc1-supply = <&vcc3v3_sys>; -+ vcc2-supply = <&vcc3v3_sys>; -+ vcc3-supply = <&vcc3v3_sys>; -+ vcc4-supply = <&vcc3v3_sys>; -+ vcc5-supply = <&vcc3v3_sys>; -+ vcc6-supply = <&vcc3v3_sys>; -+ vcc7-supply = <&vcc3v3_sys>; -+ vcc8-supply = <&vcc3v3_sys>; -+ vcc9-supply = <&vcc3v3_sys>; -+ -+ regulators { -+ vdd_logic: DCDC_REG1 { -+ regulator-name = "vdd_logic"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdd_gpu: DCDC_REG2 { -+ regulator-name = "vdd_gpu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_ddr: DCDC_REG3 { -+ regulator-name = "vcc_ddr"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-initial-mode = <0x2>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ }; -+ }; -+ -+ vdd_npu: DCDC_REG4 { -+ regulator-name = "vdd_npu"; -+ regulator-initial-mode = <0x2>; -+ regulator-min-microvolt = <500000>; -+ regulator-max-microvolt = <1350000>; -+ regulator-ramp-delay = <6001>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_1v8: DCDC_REG5 { -+ regulator-name = "vcc_1v8"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdda0v9_image: LDO_REG1 { -+ regulator-name = "vdda0v9_image"; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdda_0v9: LDO_REG2 { -+ regulator-name = "vdda_0v9"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vdda0v9_pmu: LDO_REG3 { -+ regulator-name = "vdda0v9_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <900000>; -+ regulator-max-microvolt = <900000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <900000>; -+ }; -+ }; -+ -+ vccio_acodec: LDO_REG4 { -+ regulator-name = "vccio_acodec"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vccio_sd: LDO_REG5 { -+ regulator-name = "vccio_sd"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc3v3_pmu: LDO_REG6 { -+ regulator-name = "vcc3v3_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <3300000>; -+ regulator-max-microvolt = <3300000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <3300000>; -+ }; -+ }; -+ -+ vcca_1v8: LDO_REG7 { -+ regulator-name = "vcca_1v8"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcca1v8_pmu: LDO_REG8 { -+ regulator-name = "vcca1v8_pmu"; -+ regulator-always-on; -+ regulator-boot-on; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-on-in-suspend; -+ regulator-suspend-microvolt = <1800000>; -+ }; -+ }; -+ -+ vcca1v8_image: LDO_REG9 { -+ regulator-name = "vcca1v8_image"; -+ regulator-min-microvolt = <1800000>; -+ regulator-max-microvolt = <1800000>; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc_3v3: SWITCH_REG1 { -+ regulator-name = "vcc_3v3"; -+ regulator-always-on; -+ regulator-boot-on; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ -+ vcc3v3_sd: SWITCH_REG2 { -+ regulator-name = "vcc3v3_sd"; -+ regulator-always-on; -+ regulator-boot-on; -+ -+ regulator-state-mem { -+ regulator-off-in-suspend; -+ }; -+ }; -+ }; -+ }; -+}; -+ -+&i2c5 { -+ status = "okay"; -+ -+ hym8563: rtc@51 { -+ compatible = "haoyu,hym8563"; -+ reg = <0x51>; -+ interrupt-parent = <&gpio0>; -+ interrupts = ; -+ #clock-cells = <0>; -+ clock-output-names = "rtcic_32kout"; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&rtcic_int_l>; -+ wakeup-source; -+ }; -+}; -+ -+&i2s0_8ch { -+ status = "okay"; -+}; -+ -+&i2s1_8ch { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&i2s1m0_sclktx -+ &i2s1m0_lrcktx -+ &i2s1m0_sdi0 -+ &i2s1m0_sdo0>; -+ rockchip,trcm-sync-tx-only; -+ status = "okay"; -+}; -+ -+&mdio0 { -+ rgmii_phy0: ethernet-phy@1 { -+ compatible = "ethernet-phy-ieee802.3-c22"; -+ reg = <1>; -+ reset-assert-us = <20000>; -+ reset-deassert-us = <50000>; -+ reset-gpios = <&gpio3 RK_PB7 GPIO_ACTIVE_LOW>; -+ }; -+}; -+ -+&mdio1 { -+ rgmii_phy1: ethernet-phy@1 { -+ compatible = "ethernet-phy-ieee802.3-c22"; -+ reg = <1>; -+ reset-assert-us = <20000>; -+ reset-deassert-us = <50000>; -+ reset-gpios = <&gpio3 RK_PB0 GPIO_ACTIVE_LOW>; -+ }; -+}; -+ -+&pcie2x1 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pcie20m1_pins>; -+ reset-gpios = <&gpio3 RK_PC1 GPIO_ACTIVE_HIGH>; -+ vpcie3v3-supply = <&vcc3v3_sys2>; -+ status = "okay"; -+}; -+ -+&pcie30phy { -+ status = "okay"; -+}; -+ -+&pcie3x2 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&pcie30x2m1_pins>; -+ reset-gpios = <&gpio2 RK_PD6 GPIO_ACTIVE_HIGH>; -+ status = "okay"; -+}; -+ -+&pinctrl { -+ bluetooth { -+ bt_reg_on_h: bt-reg-on-h { -+ rockchip,pins = <4 RK_PB2 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ bt_wake_host_h: bt-wake-host-h { -+ rockchip,pins = <4 RK_PB4 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ host_wake_bt_h: host-wake-bt-h { -+ rockchip,pins = <4 RK_PB5 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ ir-receiver { -+ pwm3_ir: pwm3-ir { -+ rockchip,pins = <0 RK_PC2 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ leds { -+ led: led { -+ rockchip,pins = <0 RK_PB7 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ pcie { -+ pcie_pwren_h: pcie-pwren-h { -+ rockchip,pins = <0 RK_PD4 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ pcie20 { -+ pcie20m1_pins: pcie20m1-pins { -+ rockchip,pins = -+ <2 RK_PD0 4 &pcfg_pull_none>, -+ <3 RK_PC1 RK_FUNC_GPIO &pcfg_pull_none>, -+ <2 RK_PD1 4 &pcfg_pull_none>; -+ }; -+ }; -+ -+ pcie30x2 { -+ pcie30x2m1_pins: pcie30x2m1-pins { -+ rockchip,pins = -+ <2 RK_PD4 4 &pcfg_pull_none>, -+ <2 RK_PD6 RK_FUNC_GPIO &pcfg_pull_none>, -+ <2 RK_PD5 4 &pcfg_pull_none>; -+ }; -+ }; -+ -+ pmic { -+ pmic_int_l: pmic-int-l { -+ rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_up>; -+ }; -+ }; -+ -+ rtc { -+ rtcic_int_l: rtcic-int-l { -+ rockchip,pins = <0 RK_PD3 RK_FUNC_GPIO &pcfg_pull_up>; -+ }; -+ }; -+ -+ usb { -+ usb_host_pwren_h: usb-host-pwren-h { -+ rockchip,pins = <0 RK_PA6 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ usb_otg_pwren_h: usb-otg-pwren-h { -+ rockchip,pins = <0 RK_PA5 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+ -+ wifi { -+ wifi_reg_on_h: wifi-reg-on-h { -+ rockchip,pins = <3 RK_PD4 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ -+ wifi_wake_host_h: wifi-wake-host-h { -+ rockchip,pins = <3 RK_PD5 RK_FUNC_GPIO &pcfg_pull_none>; -+ }; -+ }; -+}; -+ -+&pmu_io_domains { -+ pmuio1-supply = <&vcc3v3_pmu>; -+ pmuio2-supply = <&vcc3v3_pmu>; -+ vccio1-supply = <&vccio_acodec>; -+ vccio2-supply = <&vcc_1v8>; -+ vccio3-supply = <&vccio_sd>; -+ vccio4-supply = <&vcc_1v8>; -+ vccio5-supply = <&vcc_3v3>; -+ vccio6-supply = <&vcc_1v8>; -+ vccio7-supply = <&vcc_3v3>; -+ status = "okay"; -+}; -+ -+&saradc { -+ vref-supply = <&vcca_1v8>; -+ status = "okay"; -+}; -+ -+&sdhci { -+ bus-width = <8>; -+ cap-mmc-highspeed; -+ max-frequency = <200000000>; -+ mmc-hs200-1_8v; -+ non-removable; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&emmc_bus8 &emmc_clk &emmc_cmd &emmc_datastrobe>; -+ vmmc-supply = <&vcc_3v3>; -+ vqmmc-supply = <&vcc_1v8>; -+ status = "okay"; -+}; -+ -+&sdmmc0 { -+ bus-width = <4>; -+ cap-sd-highspeed; -+ disable-wp; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sdmmc0_bus4 &sdmmc0_clk &sdmmc0_cmd &sdmmc0_det>; -+ vmmc-supply = <&vcc3v3_sd>; -+ vqmmc-supply = <&vccio_sd>; -+ status = "okay"; -+}; -+ -+&sdmmc2 { -+ bus-width = <4>; -+ cap-sd-highspeed; -+ cap-sdio-irq; -+ keep-power-in-suspend; -+ mmc-pwrseq = <&sdio_pwrseq>; -+ non-removable; -+ pinctrl-names = "default"; -+ pinctrl-0 = <&sdmmc2m0_bus4 &sdmmc2m0_clk &sdmmc2m0_cmd>; -+ sd-uhs-sdr104; -+ vmmc-supply = <&vcc3v3_sys2>; -+ vqmmc-supply = <&vcc_1v8>; -+ status = "disabled"; -+}; -+ -+&sfc { -+ #address-cells = <1>; -+ #size-cells = <0>; -+ status = "okay"; -+ -+ flash@0 { -+ compatible = "jedec,spi-nor"; -+ reg = <0>; -+ spi-max-frequency = <104000000>; -+ spi-rx-bus-width = <4>; -+ spi-tx-bus-width = <1>; -+ }; -+}; -+ -+&tsadc { -+ rockchip,hw-tshut-mode = <1>; -+ rockchip,hw-tshut-polarity = <0>; -+ status = "okay"; -+}; -+ -+&uart2 { -+ status = "okay"; -+}; -+ -+&uart8 { -+ pinctrl-names = "default"; -+ pinctrl-0 = <&uart8m0_xfer &uart8m0_ctsn &uart8m0_rtsn>; -+ uart-has-rtscts; -+ status = "disabled"; -+}; -+ -+&usb_host0_ehci { -+ status = "okay"; -+}; -+ -+&usb_host0_ohci { -+ status = "okay"; -+}; -+ -+&usb_host0_xhci { -+ extcon = <&usb2phy0>; -+ status = "okay"; -+}; -+ -+&usb_host1_xhci { -+ status = "okay"; -+}; -+ -+&usb2phy0 { -+ status = "okay"; -+}; -+ -+&usb2phy0_host { -+ phy-supply = <&vcc5v0_usb_host>; -+ status = "okay"; -+}; -+ -+&usb2phy0_otg { -+ phy-supply = <&vcc5v0_usb_otg>; -+ status = "okay"; -+}; -+ -+&usb2phy1 { -+ status = "okay"; -+}; -+ -+&usb2phy1_otg { -+ phy-supply = <&vcc5v0_usb_host>; -+ status = "okay"; -+}; -+ -+&vop { -+ assigned-clocks = <&cru DCLK_VOP0>, <&cru DCLK_VOP1>; -+ assigned-clock-parents = <&pmucru PLL_HPLL>, <&cru PLL_VPLL>; -+ status = "okay"; -+}; -+ -+&vop_mmu { -+ status = "okay"; -+}; -+ -+&vp0 { -+ vp0_out_hdmi: endpoint@ROCKCHIP_VOP2_EP_HDMI0 { -+ reg = ; -+ remote-endpoint = <&hdmi_in_vp0>; -+ }; -+}; diff --git a/package/boot/uboot-rockchip/patches/001-v2024.10-rc3-rockchip-add-support-for-Radxa-ROCK-Pi-E-v3.0.patch b/package/boot/uboot-rockchip/patches/001-v2024.10-rc3-rockchip-add-support-for-Radxa-ROCK-Pi-E-v3.0.patch deleted file mode 100644 index 515e07c3f8..0000000000 --- a/package/boot/uboot-rockchip/patches/001-v2024.10-rc3-rockchip-add-support-for-Radxa-ROCK-Pi-E-v3.0.patch +++ /dev/null @@ -1,248 +0,0 @@ -From 8ca5e0e4d6ed084d2321584e8cdc8105c60b9aa1 Mon Sep 17 00:00:00 2001 -From: FUKAUMI Naoki -Date: Tue, 25 Jun 2024 05:45:29 +0900 -Subject: [PATCH] rockchip: add support for Radxa ROCK Pi E v3.0 - -ROCK Pi E v3.0 uses DDR4 SDRAM instead of DDR3 SDRAM used in v1.2x. - -prepare new rk3328-rock-pi-e-v3.dts in u-boot which just includes -upstream rk3328-rock-pi-e.dts. - -defconfig still uses - CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-rock-pi-e.dtb" - -because v3.0 and prior are compatible. - -Suggested-by: Jonas Karlman -Signed-off-by: FUKAUMI Naoki -Reviewed-by: Kever Yang ---- - ...dtsi => rk3328-rock-pi-e-base-u-boot.dtsi} | 1 - - arch/arm/dts/rk3328-rock-pi-e-u-boot.dtsi | 47 +-------- - arch/arm/dts/rk3328-rock-pi-e-v3-u-boot.dtsi | 4 + - arch/arm/dts/rk3328-rock-pi-e-v3.dts | 4 + - board/rockchip/evb_rk3328/MAINTAINERS | 4 +- - configs/rock-pi-e-v3-rk3328_defconfig | 97 +++++++++++++++++++ - 6 files changed, 111 insertions(+), 46 deletions(-) - copy arch/arm/dts/{rk3328-rock-pi-e-u-boot.dtsi => rk3328-rock-pi-e-base-u-boot.dtsi} (94%) - rewrite arch/arm/dts/rk3328-rock-pi-e-u-boot.dtsi (88%) - create mode 100644 arch/arm/dts/rk3328-rock-pi-e-v3-u-boot.dtsi - create mode 100644 arch/arm/dts/rk3328-rock-pi-e-v3.dts - create mode 100644 configs/rock-pi-e-v3-rk3328_defconfig - ---- a/arch/arm/dts/rk3328-rock-pi-e-u-boot.dtsi -+++ b/arch/arm/dts/rk3328-rock-pi-e-u-boot.dtsi -@@ -1,43 +1,4 @@ - // SPDX-License-Identifier: GPL-2.0+ --/* -- * (C) Copyright 2020 Radxa -- */ - --#include "rk3328-u-boot.dtsi" -+#include "rk3328-rock-pi-e-base-u-boot.dtsi" - #include "rk3328-sdram-ddr3-666.dtsi" -- --/ { -- smbios { -- compatible = "u-boot,sysinfo-smbios"; -- -- smbios { -- system { -- manufacturer = "radxa"; -- product = "rock-pi-e_rk3328"; -- }; -- -- baseboard { -- manufacturer = "radxa"; -- product = "rock-pi-e_rk3328"; -- }; -- -- chassis { -- manufacturer = "radxa"; -- product = "rock-pi-e_rk3328"; -- }; -- }; -- }; --}; -- --&u2phy_host { -- phy-supply = <&vcc_host_5v>; --}; -- --&vcc_host_5v { -- /delete-property/ regulator-always-on; -- /delete-property/ regulator-boot-on; --}; -- --&vcc_sd { -- bootph-pre-ram; --}; ---- /dev/null -+++ b/arch/arm/dts/rk3328-rock-pi-e-base-u-boot.dtsi -@@ -0,0 +1,42 @@ -+// SPDX-License-Identifier: GPL-2.0+ -+/* -+ * (C) Copyright 2020 Radxa -+ */ -+ -+#include "rk3328-u-boot.dtsi" -+ -+/ { -+ smbios { -+ compatible = "u-boot,sysinfo-smbios"; -+ -+ smbios { -+ system { -+ manufacturer = "radxa"; -+ product = "rock-pi-e_rk3328"; -+ }; -+ -+ baseboard { -+ manufacturer = "radxa"; -+ product = "rock-pi-e_rk3328"; -+ }; -+ -+ chassis { -+ manufacturer = "radxa"; -+ product = "rock-pi-e_rk3328"; -+ }; -+ }; -+ }; -+}; -+ -+&u2phy_host { -+ phy-supply = <&vcc_host_5v>; -+}; -+ -+&vcc_host_5v { -+ /delete-property/ regulator-always-on; -+ /delete-property/ regulator-boot-on; -+}; -+ -+&vcc_sd { -+ bootph-pre-ram; -+}; ---- /dev/null -+++ b/arch/arm/dts/rk3328-rock-pi-e-v3-u-boot.dtsi -@@ -0,0 +1,4 @@ -+// SPDX-License-Identifier: GPL-2.0+ -+ -+#include "rk3328-rock-pi-e-base-u-boot.dtsi" -+#include "rk3328-sdram-ddr4-666.dtsi" ---- /dev/null -+++ b/arch/arm/dts/rk3328-rock-pi-e-v3.dts -@@ -0,0 +1,4 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+/dts-v1/; -+#include "rk3328-rock-pi-e.dts" ---- a/board/rockchip/evb_rk3328/MAINTAINERS -+++ b/board/rockchip/evb_rk3328/MAINTAINERS -@@ -64,5 +64,5 @@ M: Banglang Huang - S: Maintained - F: configs/rock-pi-e-rk3328_defconfig --F: arch/arm/dts/rk3328-rock-pi-e.dts --F: arch/arm/dts/rk3328-rock-pi-e-u-boot.dtsi -+F: configs/rock-pi-e-v3-rk3328_defconfig -+F: arch/arm/dts/rk3328-rock-pi-e* ---- /dev/null -+++ b/configs/rock-pi-e-v3-rk3328_defconfig -@@ -0,0 +1,97 @@ -+CONFIG_ARM=y -+CONFIG_SKIP_LOWLEVEL_INIT=y -+CONFIG_COUNTER_FREQUENCY=24000000 -+CONFIG_ARCH_ROCKCHIP=y -+CONFIG_SPL_GPIO=y -+CONFIG_NR_DRAM_BANKS=1 -+CONFIG_SF_DEFAULT_SPEED=20000000 -+CONFIG_ENV_OFFSET=0x3F8000 -+CONFIG_DEFAULT_DEVICE_TREE="rk3328-rock-pi-e-v3" -+CONFIG_DM_RESET=y -+CONFIG_ROCKCHIP_RK3328=y -+CONFIG_DEBUG_UART_BASE=0xFF130000 -+CONFIG_DEBUG_UART_CLOCK=24000000 -+CONFIG_SYS_LOAD_ADDR=0x800800 -+CONFIG_DEBUG_UART=y -+CONFIG_FIT=y -+CONFIG_FIT_VERBOSE=y -+CONFIG_SPL_FIT_SIGNATURE=y -+CONFIG_SPL_LOAD_FIT=y -+CONFIG_LEGACY_IMAGE_FORMAT=y -+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3328-rock-pi-e.dtb" -+# CONFIG_DISPLAY_CPUINFO is not set -+CONFIG_DISPLAY_BOARDINFO_LATE=y -+CONFIG_SPL_MAX_SIZE=0x40000 -+CONFIG_SPL_PAD_TO=0x7f8000 -+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set -+CONFIG_SPL_POWER=y -+CONFIG_SPL_ATF=y -+CONFIG_SPL_ATF_NO_PLATFORM_PARAM=y -+CONFIG_CMD_BOOTZ=y -+CONFIG_CMD_GPIO=y -+CONFIG_CMD_GPT=y -+CONFIG_CMD_MMC=y -+CONFIG_CMD_USB=y -+CONFIG_CMD_TIME=y -+CONFIG_CMD_REGULATOR=y -+CONFIG_SPL_OF_CONTROL=y -+CONFIG_TPL_OF_CONTROL=y -+# CONFIG_OF_UPSTREAM is not set -+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents" -+CONFIG_TPL_OF_PLATDATA=y -+CONFIG_ENV_IS_IN_MMC=y -+CONFIG_SYS_RELOC_GD_ENV_ADDR=y -+CONFIG_SYS_MMC_ENV_DEV=1 -+CONFIG_TPL_DM=y -+CONFIG_SPL_DM_SEQ_ALIAS=y -+CONFIG_REGMAP=y -+CONFIG_SPL_REGMAP=y -+CONFIG_TPL_REGMAP=y -+CONFIG_SYSCON=y -+CONFIG_SPL_SYSCON=y -+CONFIG_TPL_SYSCON=y -+CONFIG_CLK=y -+CONFIG_SPL_CLK=y -+CONFIG_ROCKCHIP_GPIO=y -+CONFIG_SYS_I2C_ROCKCHIP=y -+CONFIG_MMC_DW=y -+CONFIG_MMC_DW_ROCKCHIP=y -+CONFIG_PHY_REALTEK=y -+CONFIG_DM_MDIO=y -+CONFIG_DM_ETH_PHY=y -+CONFIG_PHY_GIGE=y -+CONFIG_ETH_DESIGNWARE=y -+CONFIG_GMAC_ROCKCHIP=y -+CONFIG_PHY_ROCKCHIP_INNO_USB2=y -+CONFIG_PINCTRL=y -+CONFIG_SPL_PINCTRL=y -+CONFIG_DM_PMIC=y -+CONFIG_PMIC_RK8XX=y -+CONFIG_SPL_DM_REGULATOR=y -+CONFIG_DM_REGULATOR_FIXED=y -+CONFIG_SPL_DM_REGULATOR_FIXED=y -+CONFIG_REGULATOR_RK8XX=y -+CONFIG_PWM_ROCKCHIP=y -+CONFIG_RAM=y -+CONFIG_SPL_RAM=y -+CONFIG_TPL_RAM=y -+CONFIG_DM_RNG=y -+CONFIG_RNG_ROCKCHIP=y -+CONFIG_BAUDRATE=1500000 -+CONFIG_DEBUG_UART_SHIFT=2 -+CONFIG_SYS_NS16550_MEM32=y -+CONFIG_SYSINFO=y -+CONFIG_SYSINFO_SMBIOS=y -+CONFIG_SYSRESET=y -+# CONFIG_TPL_SYSRESET is not set -+CONFIG_USB=y -+CONFIG_USB_XHCI_HCD=y -+CONFIG_USB_EHCI_HCD=y -+CONFIG_USB_EHCI_GENERIC=y -+CONFIG_USB_OHCI_HCD=y -+CONFIG_USB_OHCI_GENERIC=y -+CONFIG_USB_DWC3=y -+CONFIG_USB_DWC3_GENERIC=y -+CONFIG_SPL_TINY_MEMSET=y -+CONFIG_TPL_TINY_MEMSET=y -+CONFIG_ERRNO_STR=y diff --git a/package/boot/uboot-rockchip/patches/002-v2024.10-rc3-board-rockchip-add-Radxa-ROCK-3-Model-C.patch b/package/boot/uboot-rockchip/patches/002-v2024.10-rc3-board-rockchip-add-Radxa-ROCK-3-Model-C.patch deleted file mode 100644 index 22ced545fe..0000000000 --- a/package/boot/uboot-rockchip/patches/002-v2024.10-rc3-board-rockchip-add-Radxa-ROCK-3-Model-C.patch +++ /dev/null @@ -1,178 +0,0 @@ -From e6e82ce24d4e9d20c232db2a95b2d10faf8f2bcf Mon Sep 17 00:00:00 2001 -From: Maxim Moskalets -Date: Thu, 8 Aug 2024 22:37:10 +0300 -Subject: [PATCH] board: rockchip: add Radxa ROCK 3 Model C - -Based on rock-3a-rk3568_defconfig. -Tested on v1.31 revision. - -Board Specifications: -- Rockchip RK3566 -- 1/2/4GB LPDDR4 2112MT/s -- eMMC socket -- uSD card slot -- M.2 2230 Connector -- GbE LAN with POE -- 3.5mm jack with mic -- HDMI 2.0, MIPI DSI/CSI -- USB 3.0 Host, USB 2.0 Host/OTG -- 40-pin GPIO expansion ports - -Signed-off-by: Maxim Moskalets -Suggested-by: Jonas Karlman -Reviewed-by: Jonas Karlman -Tested-by: FUKAUMI Naoki -Reviewed-by: Kever Yang ---- - arch/arm/dts/rk3566-rock-3c-u-boot.dtsi | 18 +++++ - board/rockchip/evb_rk3568/MAINTAINERS | 7 ++ - configs/rock-3c-rk3566_defconfig | 97 +++++++++++++++++++++++++ - doc/board/rockchip/rockchip.rst | 1 + - 4 files changed, 123 insertions(+) - create mode 100644 arch/arm/dts/rk3566-rock-3c-u-boot.dtsi - create mode 100644 configs/rock-3c-rk3566_defconfig - ---- /dev/null -+++ b/arch/arm/dts/rk3566-rock-3c-u-boot.dtsi -@@ -0,0 +1,18 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+#include "rk356x-u-boot.dtsi" -+ -+&sfc { -+ flash@0 { -+ bootph-pre-ram; -+ bootph-some-ram; -+ }; -+}; -+ -+/ { -+ leds { -+ led-0 { -+ default-state = "on"; -+ }; -+ }; -+}; ---- a/board/rockchip/evb_rk3568/MAINTAINERS -+++ b/board/rockchip/evb_rk3568/MAINTAINERS -@@ -69,3 +69,10 @@ S: Maintained - F: configs/rock-3a-rk3568_defconfig - F: arch/arm/dts/rk3568-rock-3a.dts - F: arch/arm/dts/rk3568-rock-3a-u-boot.dtsi -+ -+ROCK-3C -+M: Jonas Karlman -+M: Maxim Moskalets -+S: Maintained -+F: arch/arm/dts/rk3566-rock-3c-u-boot.dtsi -+F: configs/rock-3c-rk3566_defconfig ---- /dev/null -+++ b/configs/rock-3c-rk3566_defconfig -@@ -0,0 +1,97 @@ -+CONFIG_ARM=y -+CONFIG_SKIP_LOWLEVEL_INIT=y -+CONFIG_COUNTER_FREQUENCY=24000000 -+CONFIG_ARCH_ROCKCHIP=y -+CONFIG_SF_DEFAULT_SPEED=24000000 -+CONFIG_SF_DEFAULT_MODE=0x2000 -+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3566-rock-3c" -+CONFIG_ROCKCHIP_RK3568=y -+CONFIG_ROCKCHIP_SPI_IMAGE=y -+CONFIG_SPL_SERIAL=y -+CONFIG_DEBUG_UART_BASE=0xFE660000 -+CONFIG_DEBUG_UART_CLOCK=24000000 -+CONFIG_SPL_SPI_FLASH_SUPPORT=y -+CONFIG_SPL_SPI=y -+CONFIG_SYS_LOAD_ADDR=0xc00800 -+CONFIG_PCI=y -+CONFIG_DEBUG_UART=y -+CONFIG_AHCI=y -+CONFIG_FIT=y -+CONFIG_FIT_VERBOSE=y -+CONFIG_SPL_FIT_SIGNATURE=y -+CONFIG_SPL_LOAD_FIT=y -+CONFIG_LEGACY_IMAGE_FORMAT=y -+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-rock-3c.dtb" -+# CONFIG_DISPLAY_CPUINFO is not set -+CONFIG_DISPLAY_BOARDINFO_LATE=y -+CONFIG_SPL_MAX_SIZE=0x40000 -+CONFIG_SPL_PAD_TO=0x7f8000 -+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set -+CONFIG_SPL_SPI_LOAD=y -+CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000 -+CONFIG_SPL_ATF=y -+CONFIG_CMD_GPIO=y -+CONFIG_CMD_GPT=y -+CONFIG_CMD_I2C=y -+CONFIG_CMD_MMC=y -+CONFIG_CMD_PCI=y -+CONFIG_CMD_POWEROFF=y -+CONFIG_CMD_USB=y -+# CONFIG_CMD_SETEXPR is not set -+CONFIG_CMD_PMIC=y -+CONFIG_CMD_REGULATOR=y -+# CONFIG_SPL_DOS_PARTITION is not set -+CONFIG_SPL_OF_CONTROL=y -+CONFIG_OF_LIVE=y -+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents" -+CONFIG_SYS_RELOC_GD_ENV_ADDR=y -+CONFIG_SPL_DM_SEQ_ALIAS=y -+CONFIG_SPL_REGMAP=y -+CONFIG_SPL_SYSCON=y -+CONFIG_SCSI_AHCI=y -+CONFIG_AHCI_PCI=y -+CONFIG_SPL_CLK=y -+CONFIG_ROCKCHIP_GPIO=y -+CONFIG_SYS_I2C_ROCKCHIP=y -+CONFIG_LED=y -+CONFIG_LED_GPIO=y -+CONFIG_MISC=y -+CONFIG_SUPPORT_EMMC_RPMB=y -+CONFIG_MMC_DW=y -+CONFIG_MMC_DW_ROCKCHIP=y -+CONFIG_MMC_SDHCI=y -+CONFIG_MMC_SDHCI_SDMA=y -+CONFIG_MMC_SDHCI_ROCKCHIP=y -+CONFIG_SF_DEFAULT_BUS=4 -+CONFIG_SPI_FLASH_SFDP_SUPPORT=y -+CONFIG_SPI_FLASH_GIGADEVICE=y -+CONFIG_SPI_FLASH_MACRONIX=y -+CONFIG_SPI_FLASH_WINBOND=y -+CONFIG_SPI_FLASH_XTX=y -+CONFIG_PHY_REALTEK=y -+CONFIG_DWC_ETH_QOS=y -+CONFIG_DWC_ETH_QOS_ROCKCHIP=y -+CONFIG_NVME_PCI=y -+CONFIG_PCIE_DW_ROCKCHIP=y -+CONFIG_PHY_ROCKCHIP_INNO_USB2=y -+CONFIG_PHY_ROCKCHIP_NANENG_COMBOPHY=y -+CONFIG_SPL_PINCTRL=y -+CONFIG_DM_PMIC=y -+CONFIG_PMIC_RK8XX=y -+CONFIG_REGULATOR_RK8XX=y -+CONFIG_SPL_RAM=y -+CONFIG_SCSI=y -+CONFIG_BAUDRATE=1500000 -+CONFIG_DEBUG_UART_SHIFT=2 -+CONFIG_SYS_NS16550_MEM32=y -+CONFIG_ROCKCHIP_SFC=y -+CONFIG_SYSRESET=y -+CONFIG_USB=y -+CONFIG_USB_XHCI_HCD=y -+CONFIG_USB_EHCI_HCD=y -+CONFIG_USB_EHCI_GENERIC=y -+CONFIG_USB_OHCI_HCD=y -+CONFIG_USB_OHCI_GENERIC=y -+CONFIG_USB_DWC3=y -+CONFIG_USB_DWC3_GENERIC=y -+CONFIG_ERRNO_STR=y ---- a/doc/board/rockchip/rockchip.rst -+++ b/doc/board/rockchip/rockchip.rst -@@ -106,6 +106,7 @@ List of mainline supported Rockchip boar - - Pine64 SOQuartz on Model A (soquartz-model-a-rk3566) - - Powkiddy X55 (powkiddy-x55-rk3566) - - Radxa CM3 IO Board (radxa-cm3-io-rk3566) -+ - Radxa ROCK 3C (rock-3c-rk3566) - - * rk3568 - - Rockchip Evb-RK3568 (evb-rk3568) diff --git a/package/boot/uboot-rockchip/patches/003-v2024.10-rc3-dm-adc-Add-SPL_ADC-Kconfig-symbol-for-use-of-ADC-in-.patch b/package/boot/uboot-rockchip/patches/003-v2024.10-rc3-dm-adc-Add-SPL_ADC-Kconfig-symbol-for-use-of-ADC-in-.patch deleted file mode 100644 index c62c378980..0000000000 --- a/package/boot/uboot-rockchip/patches/003-v2024.10-rc3-dm-adc-Add-SPL_ADC-Kconfig-symbol-for-use-of-ADC-in-.patch +++ /dev/null @@ -1,67 +0,0 @@ -From 232af1e58a977f3857074d3aba3709c860bd8058 Mon Sep 17 00:00:00 2001 -From: Jonas Karlman -Date: Fri, 2 Aug 2024 22:12:22 +0000 -Subject: [PATCH] dm: adc: Add SPL_ADC Kconfig symbol for use of ADC in SPL - -What model of Radxa ZERO 3W/3E board can be identified using ADC at -runtime, add a Kconfig symbol to allow use of ADC in SPL. - -This will be used to identify board model in SPL to allow loading -correct FIT configuration and FDT for U-Boot proper at SPL phase. - -Signed-off-by: Jonas Karlman -Reviewed-by: Kever Yang ---- - drivers/Makefile | 2 +- - drivers/adc/Kconfig | 5 +++++ - drivers/adc/Makefile | 2 +- - 3 files changed, 7 insertions(+), 2 deletions(-) - ---- a/drivers/Makefile -+++ b/drivers/Makefile -@@ -1,5 +1,6 @@ - # SPDX-License-Identifier: GPL-2.0+ - -+obj-$(CONFIG_$(SPL_TPL_)ADC) += adc/ - obj-$(CONFIG_$(SPL_TPL_)BIOSEMU) += bios_emulator/ - obj-$(CONFIG_$(SPL_TPL_)BLK) += block/ - obj-$(CONFIG_$(SPL_TPL_)BOOTCOUNT_LIMIT) += bootcount/ -@@ -81,7 +82,6 @@ endif - - ifeq ($(CONFIG_SPL_BUILD)$(CONFIG_TPL_BUILD),) - --obj-y += adc/ - obj-y += ata/ - obj-$(CONFIG_DM_DEMO) += demo/ - obj-y += block/ ---- a/drivers/adc/Kconfig -+++ b/drivers/adc/Kconfig -@@ -1,5 +1,6 @@ - config ADC - bool "Enable ADC drivers using Driver Model" -+ depends on DM - help - This enables ADC API for drivers, which allows driving ADC features - by single and multi-channel methods for: -@@ -11,6 +12,10 @@ config ADC - - support supply's phandle with auto-enable - - supply polarity setting in fdt - -+config SPL_ADC -+ bool "Enable ADC drivers using Driver Model in SPL" -+ depends on SPL_DM -+ - config ADC_EXYNOS - bool "Enable Exynos 54xx ADC driver" - depends on ADC ---- a/drivers/adc/Makefile -+++ b/drivers/adc/Makefile -@@ -4,7 +4,7 @@ - # Przemyslaw Marczak - # - --obj-$(CONFIG_ADC) += adc-uclass.o -+obj-$(CONFIG_$(SPL_TPL_)ADC) += adc-uclass.o - obj-$(CONFIG_ADC_EXYNOS) += exynos-adc.o - obj-$(CONFIG_ADC_SANDBOX) += sandbox.o - obj-$(CONFIG_SARADC_ROCKCHIP) += rockchip-saradc.o diff --git a/package/boot/uboot-rockchip/patches/004-v2024.10-rc3-board-rockchip-Add-Radxa-ZERO-3W-3E.patch b/package/boot/uboot-rockchip/patches/004-v2024.10-rc3-board-rockchip-Add-Radxa-ZERO-3W-3E.patch deleted file mode 100644 index cbd6995874..0000000000 --- a/package/boot/uboot-rockchip/patches/004-v2024.10-rc3-board-rockchip-Add-Radxa-ZERO-3W-3E.patch +++ /dev/null @@ -1,295 +0,0 @@ -From 5d199ad9a6bb43dbf43efe45ec37002c4ae305a0 Mon Sep 17 00:00:00 2001 -From: Jonas Karlman -Date: Fri, 2 Aug 2024 22:12:23 +0000 -Subject: [PATCH] board: rockchip: Add Radxa ZERO 3W/3E - -The Radxa ZERO 3W/3E is an ultra-small, high-performance single board -computer based on the Rockchip RK3566, with a compact form factor and -rich interfaces. - -Implement rk_board_late_init() to set correct fdtfile env var and -board_fit_config_name_match() to load correct FIT config based on what -board is detected at runtime so a single board target can be used for -both board models. - -Features tested on a ZERO 3W 8GB v1.11: -- SD-card boot -- eMMC boot -- USB gadget -- USB host - -Features tested on a ZERO 3E 4GB v1.2: -- SD-card boot -- Ethernet -- USB gadget -- USB host - -Signed-off-by: Jonas Karlman -Tested-by: FUKAUMI Naoki -Reviewed-by: Kever Yang ---- - arch/arm/dts/rk3566-radxa-zero-3e-u-boot.dtsi | 15 ++++ - arch/arm/dts/rk3566-radxa-zero-3w-u-boot.dtsi | 15 ++++ - arch/arm/mach-rockchip/rk3568/Kconfig | 6 ++ - board/radxa/zero3-rk3566/Kconfig | 12 +++ - board/radxa/zero3-rk3566/MAINTAINERS | 6 ++ - board/radxa/zero3-rk3566/Makefile | 3 + - board/radxa/zero3-rk3566/zero3-rk3566.c | 59 +++++++++++++ - configs/radxa-zero-3-rk3566_defconfig | 85 +++++++++++++++++++ - doc/board/rockchip/rockchip.rst | 1 + - 9 files changed, 202 insertions(+) - create mode 100644 arch/arm/dts/rk3566-radxa-zero-3e-u-boot.dtsi - create mode 100644 arch/arm/dts/rk3566-radxa-zero-3w-u-boot.dtsi - create mode 100644 board/radxa/zero3-rk3566/Kconfig - create mode 100644 board/radxa/zero3-rk3566/MAINTAINERS - create mode 100644 board/radxa/zero3-rk3566/Makefile - create mode 100644 board/radxa/zero3-rk3566/zero3-rk3566.c - create mode 100644 configs/radxa-zero-3-rk3566_defconfig - ---- /dev/null -+++ b/arch/arm/dts/rk3566-radxa-zero-3e-u-boot.dtsi -@@ -0,0 +1,15 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+#include "rk356x-u-boot.dtsi" -+ -+&saradc { -+ bootph-pre-ram; -+}; -+ -+&usb_host0_xhci { -+ dr_mode = "otg"; -+}; -+ -+&vcca_1v8 { -+ bootph-pre-ram; -+}; ---- /dev/null -+++ b/arch/arm/dts/rk3566-radxa-zero-3w-u-boot.dtsi -@@ -0,0 +1,15 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+#include "rk356x-u-boot.dtsi" -+ -+&saradc { -+ bootph-pre-ram; -+}; -+ -+&usb_host0_xhci { -+ dr_mode = "otg"; -+}; -+ -+&vcca_1v8 { -+ bootph-pre-ram; -+}; ---- a/arch/arm/mach-rockchip/rk3568/Kconfig -+++ b/arch/arm/mach-rockchip/rk3568/Kconfig -@@ -32,6 +32,11 @@ config TARGET_QUARTZ64_RK3566 - help - Pine64 Quartz64 single board computer with a RK3566 SoC. - -+config TARGET_RADXA_ZERO_3_RK3566 -+ bool "Radxa ZERO 3W/3E" -+ help -+ Radxa ZERO 3W/3E single board computers with a RK3566 SoC. -+ - endchoice - - config ROCKCHIP_BOOT_MODE_REG -@@ -54,5 +59,6 @@ source "board/anbernic/rgxx3_rk3566/Kcon - source "board/hardkernel/odroid_m1/Kconfig" - source "board/pine64/quartz64_rk3566/Kconfig" - source "board/powkiddy/x55/Kconfig" -+source "board/radxa/zero3-rk3566/Kconfig" - - endif ---- /dev/null -+++ b/board/radxa/zero3-rk3566/Kconfig -@@ -0,0 +1,12 @@ -+if TARGET_RADXA_ZERO_3_RK3566 -+ -+config SYS_BOARD -+ default "zero3-rk3566" -+ -+config SYS_VENDOR -+ default "radxa" -+ -+config SYS_CONFIG_NAME -+ default "evb_rk3568" -+ -+endif ---- /dev/null -+++ b/board/radxa/zero3-rk3566/MAINTAINERS -@@ -0,0 +1,6 @@ -+RADXA-ZERO-3-RK3566 -+M: Jonas Karlman -+S: Maintained -+F: board/radxa/zero3-rk3566 -+F: configs/radxa-zero-3-rk3566_defconfig -+F: arch/arm/dts/rk3566-radxa-zero-3* ---- /dev/null -+++ b/board/radxa/zero3-rk3566/Makefile -@@ -0,0 +1,3 @@ -+# SPDX-License-Identifier: GPL-2.0+ -+ -+obj-y += zero3-rk3566.o ---- /dev/null -+++ b/board/radxa/zero3-rk3566/zero3-rk3566.c -@@ -0,0 +1,59 @@ -+// SPDX-License-Identifier: GPL-2.0+ -+ -+#include -+#include -+#include -+#include -+ -+#define HW_ID_CHANNEL 1 -+ -+struct board_model { -+ unsigned int low; -+ unsigned int high; -+ const char *fdtfile; -+}; -+ -+static const struct board_model board_models[] = { -+ { 230, 270, "rockchip/rk3566-radxa-zero-3w.dtb" }, -+ { 400, 450, "rockchip/rk3566-radxa-zero-3e.dtb" }, -+}; -+ -+static const struct board_model *get_board_model(void) -+{ -+ unsigned int val; -+ int i, ret; -+ -+ ret = adc_channel_single_shot("saradc@fe720000", HW_ID_CHANNEL, &val); -+ if (ret) -+ return NULL; -+ -+ for (i = 0; i < ARRAY_SIZE(board_models); i++) { -+ unsigned int min = board_models[i].low; -+ unsigned int max = board_models[i].high; -+ -+ if (min <= val && val <= max) -+ return &board_models[i]; -+ } -+ -+ return NULL; -+} -+ -+int rk_board_late_init(void) -+{ -+ const struct board_model *model = get_board_model(); -+ -+ if (model) -+ env_set("fdtfile", model->fdtfile); -+ -+ return 0; -+} -+ -+int board_fit_config_name_match(const char *name) -+{ -+ const struct board_model *model = get_board_model(); -+ -+ if (model && !strcmp(name, model->fdtfile)) -+ return 0; -+ -+ return -EINVAL; -+} ---- /dev/null -+++ b/configs/radxa-zero-3-rk3566_defconfig -@@ -0,0 +1,85 @@ -+CONFIG_ARM=y -+CONFIG_SKIP_LOWLEVEL_INIT=y -+CONFIG_COUNTER_FREQUENCY=24000000 -+CONFIG_ARCH_ROCKCHIP=y -+CONFIG_SPL_GPIO=y -+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3566-radxa-zero-3w" -+CONFIG_ROCKCHIP_RK3568=y -+CONFIG_SPL_SERIAL=y -+CONFIG_TARGET_RADXA_ZERO_3_RK3566=y -+CONFIG_DEBUG_UART_BASE=0xFE660000 -+CONFIG_DEBUG_UART_CLOCK=24000000 -+CONFIG_SYS_LOAD_ADDR=0xc00800 -+CONFIG_DEBUG_UART=y -+CONFIG_FIT=y -+CONFIG_FIT_VERBOSE=y -+CONFIG_SPL_FIT_SIGNATURE=y -+CONFIG_SPL_LOAD_FIT=y -+CONFIG_LEGACY_IMAGE_FORMAT=y -+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3566-radxa-zero-3w.dtb" -+# CONFIG_DISPLAY_CPUINFO is not set -+CONFIG_DISPLAY_BOARDINFO_LATE=y -+CONFIG_SPL_MAX_SIZE=0x40000 -+CONFIG_SPL_PAD_TO=0x7f8000 -+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set -+CONFIG_SPL_POWER=y -+CONFIG_SPL_ATF=y -+CONFIG_CMD_GPIO=y -+CONFIG_CMD_GPT=y -+CONFIG_CMD_I2C=y -+CONFIG_CMD_MMC=y -+CONFIG_CMD_USB=y -+CONFIG_CMD_ROCKUSB=y -+CONFIG_CMD_USB_MASS_STORAGE=y -+# CONFIG_CMD_SETEXPR is not set -+CONFIG_CMD_PMIC=y -+CONFIG_CMD_REGULATOR=y -+# CONFIG_SPL_DOS_PARTITION is not set -+CONFIG_SPL_OF_CONTROL=y -+CONFIG_OF_LIVE=y -+CONFIG_OF_LIST="rockchip/rk3566-radxa-zero-3w rockchip/rk3566-radxa-zero-3e" -+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents" -+CONFIG_SYS_RELOC_GD_ENV_ADDR=y -+CONFIG_SPL_DM_SEQ_ALIAS=y -+CONFIG_SPL_REGMAP=y -+CONFIG_SPL_SYSCON=y -+CONFIG_SPL_ADC=y -+CONFIG_SPL_CLK=y -+# CONFIG_USB_FUNCTION_FASTBOOT is not set -+CONFIG_ROCKCHIP_GPIO=y -+CONFIG_SYS_I2C_ROCKCHIP=y -+CONFIG_LED=y -+CONFIG_LED_GPIO=y -+CONFIG_MISC=y -+CONFIG_SUPPORT_EMMC_RPMB=y -+CONFIG_MMC_DW=y -+CONFIG_MMC_DW_ROCKCHIP=y -+CONFIG_MMC_SDHCI=y -+CONFIG_MMC_SDHCI_SDMA=y -+CONFIG_MMC_SDHCI_ROCKCHIP=y -+CONFIG_PHY_REALTEK=y -+CONFIG_DWC_ETH_QOS=y -+CONFIG_DWC_ETH_QOS_ROCKCHIP=y -+CONFIG_PHY_ROCKCHIP_INNO_USB2=y -+CONFIG_PHY_ROCKCHIP_NANENG_COMBOPHY=y -+CONFIG_SPL_PINCTRL=y -+CONFIG_DM_PMIC=y -+CONFIG_DM_PMIC_FAN53555=y -+CONFIG_PMIC_RK8XX=y -+CONFIG_SPL_DM_REGULATOR=y -+CONFIG_SPL_DM_REGULATOR_FIXED=y -+CONFIG_REGULATOR_RK8XX=y -+CONFIG_SPL_RAM=y -+CONFIG_BAUDRATE=1500000 -+CONFIG_DEBUG_UART_SHIFT=2 -+CONFIG_SYS_NS16550_MEM32=y -+CONFIG_SYSRESET=y -+CONFIG_SYSRESET_PSCI=y -+CONFIG_USB=y -+CONFIG_USB_XHCI_HCD=y -+CONFIG_USB_DWC3=y -+CONFIG_USB_DWC3_GENERIC=y -+CONFIG_USB_GADGET=y -+CONFIG_USB_GADGET_DOWNLOAD=y -+CONFIG_USB_FUNCTION_ROCKUSB=y -+CONFIG_ERRNO_STR=y ---- a/doc/board/rockchip/rockchip.rst -+++ b/doc/board/rockchip/rockchip.rst -@@ -107,6 +107,7 @@ List of mainline supported Rockchip boar - - Powkiddy X55 (powkiddy-x55-rk3566) - - Radxa CM3 IO Board (radxa-cm3-io-rk3566) - - Radxa ROCK 3C (rock-3c-rk3566) -+ - Radxa ZERO 3W/3E (radxa-zero-3-rk3566) - - * rk3568 - - Rockchip Evb-RK3568 (evb-rk3568) diff --git a/package/boot/uboot-rockchip/patches/005-v2024.10-rc3-board-rockchip-Add-Radxa-ROCK-3B.patch b/package/boot/uboot-rockchip/patches/005-v2024.10-rc3-board-rockchip-Add-Radxa-ROCK-3B.patch deleted file mode 100644 index 0fe8bfd52d..0000000000 --- a/package/boot/uboot-rockchip/patches/005-v2024.10-rc3-board-rockchip-Add-Radxa-ROCK-3B.patch +++ /dev/null @@ -1,179 +0,0 @@ -From e20d57ae7e0c28f2d770a7d18c1501d332e8766a Mon Sep 17 00:00:00 2001 -From: Jonas Karlman -Date: Wed, 31 Jul 2024 07:28:54 +0000 -Subject: [PATCH] board: rockchip: Add Radxa ROCK 3B - -The Radxa ROCK 3B is a single-board computer based on the Pico-ITX form -factor (100mm x 75mm). Two versions of the ROCK 3B exists, a community -version based on the RK3568 SoC and an industrial version based on the -RK3568J SoC. - -Features tested on ROCK 3B 8GB v1.51 (both variants): -- SD-card boot -- eMMC boot -- SPI Flash boot -- Ethernet -- PCIe/NVMe -- USB gadget -- USB host - -Signed-off-by: Jonas Karlman -Tested-by: FUKAUMI Naoki -Reviewed-by: Kever Yang ---- - arch/arm/dts/rk3568-rock-3b-u-boot.dtsi | 15 ++++ - board/rockchip/evb_rk3568/MAINTAINERS | 6 ++ - configs/rock-3b-rk3568_defconfig | 100 ++++++++++++++++++++++++ - doc/board/rockchip/rockchip.rst | 3 +- - 4 files changed, 123 insertions(+), 1 deletion(-) - create mode 100644 arch/arm/dts/rk3568-rock-3b-u-boot.dtsi - create mode 100644 configs/rock-3b-rk3568_defconfig - ---- /dev/null -+++ b/arch/arm/dts/rk3568-rock-3b-u-boot.dtsi -@@ -0,0 +1,15 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+#include "rk356x-u-boot.dtsi" -+ -+&sdhci { -+ mmc-hs400-1_8v; -+ mmc-hs400-enhanced-strobe; -+}; -+ -+&sfc { -+ flash@0 { -+ bootph-pre-ram; -+ bootph-some-ram; -+ }; -+}; ---- a/board/rockchip/evb_rk3568/MAINTAINERS -+++ b/board/rockchip/evb_rk3568/MAINTAINERS -@@ -70,6 +70,12 @@ F: configs/rock-3a-rk3568_defconfig - F: arch/arm/dts/rk3568-rock-3a.dts - F: arch/arm/dts/rk3568-rock-3a-u-boot.dtsi - -+ROCK-3B -+M: Jonas Karlman -+S: Maintained -+F: configs/rock-3b-rk3568_defconfig -+F: arch/arm/dts/rk3568-rock-3b* -+ - ROCK-3C - M: Jonas Karlman - M: Maxim Moskalets ---- /dev/null -+++ b/configs/rock-3b-rk3568_defconfig -@@ -0,0 +1,100 @@ -+CONFIG_ARM=y -+CONFIG_SKIP_LOWLEVEL_INIT=y -+CONFIG_COUNTER_FREQUENCY=24000000 -+CONFIG_ARCH_ROCKCHIP=y -+CONFIG_SF_DEFAULT_SPEED=24000000 -+CONFIG_SF_DEFAULT_MODE=0x2000 -+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3568-rock-3b" -+CONFIG_ROCKCHIP_RK3568=y -+CONFIG_ROCKCHIP_SPI_IMAGE=y -+CONFIG_SPL_SERIAL=y -+CONFIG_DEBUG_UART_BASE=0xFE660000 -+CONFIG_DEBUG_UART_CLOCK=24000000 -+CONFIG_SPL_SPI_FLASH_SUPPORT=y -+CONFIG_SPL_SPI=y -+CONFIG_SYS_LOAD_ADDR=0xc00800 -+CONFIG_PCI=y -+CONFIG_DEBUG_UART=y -+CONFIG_AHCI=y -+CONFIG_FIT=y -+CONFIG_FIT_VERBOSE=y -+CONFIG_SPL_FIT_SIGNATURE=y -+CONFIG_SPL_LOAD_FIT=y -+CONFIG_LEGACY_IMAGE_FORMAT=y -+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3568-rock-3b.dtb" -+# CONFIG_DISPLAY_CPUINFO is not set -+CONFIG_DISPLAY_BOARDINFO_LATE=y -+CONFIG_SPL_MAX_SIZE=0x40000 -+CONFIG_SPL_PAD_TO=0x7f8000 -+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set -+CONFIG_SPL_SPI_LOAD=y -+CONFIG_SYS_SPI_U_BOOT_OFFS=0x60000 -+CONFIG_SPL_ATF=y -+CONFIG_CMD_GPIO=y -+CONFIG_CMD_GPT=y -+CONFIG_CMD_I2C=y -+CONFIG_CMD_MMC=y -+CONFIG_CMD_PCI=y -+CONFIG_CMD_POWEROFF=y -+CONFIG_CMD_USB=y -+CONFIG_CMD_ROCKUSB=y -+CONFIG_CMD_USB_MASS_STORAGE=y -+# CONFIG_CMD_SETEXPR is not set -+CONFIG_CMD_PMIC=y -+CONFIG_CMD_REGULATOR=y -+# CONFIG_SPL_DOS_PARTITION is not set -+CONFIG_SPL_OF_CONTROL=y -+CONFIG_OF_LIVE=y -+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents" -+CONFIG_SYS_RELOC_GD_ENV_ADDR=y -+CONFIG_SPL_DM_SEQ_ALIAS=y -+CONFIG_SPL_REGMAP=y -+CONFIG_SPL_SYSCON=y -+CONFIG_SCSI_AHCI=y -+CONFIG_AHCI_PCI=y -+CONFIG_SPL_CLK=y -+# CONFIG_USB_FUNCTION_FASTBOOT is not set -+CONFIG_ROCKCHIP_GPIO=y -+CONFIG_SYS_I2C_ROCKCHIP=y -+CONFIG_LED=y -+CONFIG_LED_GPIO=y -+CONFIG_MISC=y -+CONFIG_SUPPORT_EMMC_RPMB=y -+CONFIG_MMC_DW=y -+CONFIG_MMC_DW_ROCKCHIP=y -+CONFIG_MMC_SDHCI=y -+CONFIG_MMC_SDHCI_SDMA=y -+CONFIG_MMC_SDHCI_ROCKCHIP=y -+CONFIG_SF_DEFAULT_BUS=4 -+CONFIG_SPI_FLASH_SFDP_SUPPORT=y -+CONFIG_SPI_FLASH_MACRONIX=y -+CONFIG_SPI_FLASH_XTX=y -+CONFIG_PHY_REALTEK=y -+CONFIG_DWC_ETH_QOS=y -+CONFIG_DWC_ETH_QOS_ROCKCHIP=y -+CONFIG_NVME_PCI=y -+CONFIG_PCIE_DW_ROCKCHIP=y -+CONFIG_PHY_ROCKCHIP_INNO_USB2=y -+CONFIG_PHY_ROCKCHIP_NANENG_COMBOPHY=y -+CONFIG_SPL_PINCTRL=y -+CONFIG_DM_PMIC=y -+CONFIG_DM_PMIC_FAN53555=y -+CONFIG_PMIC_RK8XX=y -+CONFIG_REGULATOR_RK8XX=y -+CONFIG_SPL_RAM=y -+CONFIG_SCSI=y -+CONFIG_BAUDRATE=1500000 -+CONFIG_DEBUG_UART_SHIFT=2 -+CONFIG_SYS_NS16550_MEM32=y -+CONFIG_ROCKCHIP_SFC=y -+CONFIG_SYSRESET=y -+CONFIG_USB=y -+CONFIG_USB_XHCI_HCD=y -+CONFIG_USB_EHCI_HCD=y -+CONFIG_USB_EHCI_GENERIC=y -+CONFIG_USB_DWC3=y -+CONFIG_USB_DWC3_GENERIC=y -+CONFIG_USB_GADGET=y -+CONFIG_USB_GADGET_DOWNLOAD=y -+CONFIG_USB_FUNCTION_ROCKUSB=y -+CONFIG_ERRNO_STR=y ---- a/doc/board/rockchip/rockchip.rst -+++ b/doc/board/rockchip/rockchip.rst -@@ -118,7 +118,8 @@ List of mainline supported Rockchip boar - - Generic RK3566/RK3568 (generic-rk3568) - - Hardkernel ODROID-M1 (odroid-m1-rk3568) - - Radxa E25 Carrier Board (radxa-e25-rk3568) -- - Radxa ROCK 3 Model A (rock-3a-rk3568) -+ - Radxa ROCK 3A (rock-3a-rk3568) -+ - Radxa ROCK 3B (rock-3b-rk3568) - - * rk3588 - - Rockchip EVB (evb-rk3588) diff --git a/package/boot/uboot-rockchip/patches/010-v2024.10-rc3-arm64-dts-rockchip-correct-the-model-name-for-Radxa-.patch b/package/boot/uboot-rockchip/patches/010-v2024.10-rc3-arm64-dts-rockchip-correct-the-model-name-for-Radxa-.patch deleted file mode 100644 index 6bf47e2a5b..0000000000 --- a/package/boot/uboot-rockchip/patches/010-v2024.10-rc3-arm64-dts-rockchip-correct-the-model-name-for-Radxa-.patch +++ /dev/null @@ -1,29 +0,0 @@ -From 626a479873b6a680b3227c4852bde4a1f2c17fdf Mon Sep 17 00:00:00 2001 -From: Chukun Pan -Date: Fri, 19 Apr 2024 18:30:19 +0800 -Subject: [PATCH 1/3] arm64: dts: rockchip: correct the model name for Radxa - ROCK 3A - -According to https://radxa.com/products/rock3/3a, -the name of this board should be "Radxa ROCK 3A". - -Suggested-by: FUKAUMI Naoki -Signed-off-by: Chukun Pan -Reviewed-by: Dragan Simic -Link: https://lore.kernel.org/r/20240419103019.992586-3-amadeus@jmu.edu.cn -Signed-off-by: Heiko Stuebner ---- - arch/arm64/boot/dts/rockchip/rk3568-rock-3a.dts | 2 +- - 1 file changed, 1 insertion(+), 1 deletion(-) - ---- a/dts/upstream/src/arm64/rockchip/rk3568-rock-3a.dts -+++ b/dts/upstream/src/arm64/rockchip/rk3568-rock-3a.dts -@@ -8,7 +8,7 @@ - #include "rk3568.dtsi" - - / { -- model = "Radxa ROCK3 Model A"; -+ model = "Radxa ROCK 3A"; - compatible = "radxa,rock3a", "rockchip,rk3568"; - - aliases { diff --git a/package/boot/uboot-rockchip/patches/011-v2024.10-rc3-arm64-dts-rockchip-Correct-the-model-names-for-Radxa.patch b/package/boot/uboot-rockchip/patches/011-v2024.10-rc3-arm64-dts-rockchip-Correct-the-model-names-for-Radxa.patch deleted file mode 100644 index 82918e3899..0000000000 --- a/package/boot/uboot-rockchip/patches/011-v2024.10-rc3-arm64-dts-rockchip-Correct-the-model-names-for-Radxa.patch +++ /dev/null @@ -1,43 +0,0 @@ -From 45e831033f7a00a14f64afa1e34c476a9ff0f9f0 Mon Sep 17 00:00:00 2001 -From: Dragan Simic -Date: Thu, 18 Apr 2024 18:26:20 +0200 -Subject: [PATCH] arm64: dts: rockchip: Correct the model names for Radxa ROCK - 5 boards - -Correct the descriptions of a few Radxa boards, according to the up-to-date -documentation from Radxa and the detailed explanation from Naoki. [1] To sum -it up, the short naming, as specified by Radxa, is preferred. - -[1] https://lore.kernel.org/linux-rockchip/B26C732A4DCEA9B3+282b8775-601b-4d4a-a513-4924b7940076@radxa.com/ - -Suggested-by: FUKAUMI Naoki -Signed-off-by: Dragan Simic -Link: https://lore.kernel.org/r/6931289a252dc2d6c7bfd2388835c5e98ba0d8c9.1713457260.git.dsimic@manjaro.org -Signed-off-by: Heiko Stuebner ---- - arch/arm64/boot/dts/rockchip/rk3588-rock-5b.dts | 2 +- - arch/arm64/boot/dts/rockchip/rk3588s-rock-5a.dts | 2 +- - 2 files changed, 2 insertions(+), 2 deletions(-) - ---- a/dts/upstream/src/arm64/rockchip/rk3588-rock-5b.dts -+++ b/dts/upstream/src/arm64/rockchip/rk3588-rock-5b.dts -@@ -7,7 +7,7 @@ - #include "rk3588.dtsi" - - / { -- model = "Radxa ROCK 5 Model B"; -+ model = "Radxa ROCK 5B"; - compatible = "radxa,rock-5b", "rockchip,rk3588"; - - aliases { ---- a/dts/upstream/src/arm64/rockchip/rk3588s-rock-5a.dts -+++ b/dts/upstream/src/arm64/rockchip/rk3588s-rock-5a.dts -@@ -8,7 +8,7 @@ - #include "rk3588s.dtsi" - - / { -- model = "Radxa ROCK 5 Model A"; -+ model = "Radxa ROCK 5A"; - compatible = "radxa,rock-5a", "rockchip,rk3588s"; - - aliases { diff --git a/package/boot/uboot-rockchip/patches/106-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6S.patch b/package/boot/uboot-rockchip/patches/106-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6S.patch deleted file mode 100644 index 68958d87c9..0000000000 --- a/package/boot/uboot-rockchip/patches/106-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6S.patch +++ /dev/null @@ -1,193 +0,0 @@ -From 7db9ff164813afb343024d37731ab797ed7f507e Mon Sep 17 00:00:00 2001 -From: Sebastian Kropatsch -Date: Thu, 11 Jul 2024 12:15:18 +0200 -Subject: [PATCH] board: rockchip: Add FriendlyElec NanoPi R6S - -The NanoPi R6S is a SBC by FriendlyElec based on the Rockchip RK3588s. -It comes with 4GB or 8GB of RAM, a microSD card slot, 32GB eMMC storage, -one RTL8211F 1GbE and two RTL8125 2.5GbE Ethernet ports, one USB 2.0 -Type-A and one USB 3.0 Type-A port, a HDMI port, a 12-pin GPIO FPC -connector, a fan connector, IR receiver as well as some buttons and LEDs. - -Add initial support for this board using the upstream devicetree sources. - -Kernel commit: -f1b11f43b3e9 ("arm64: dts: rockchip: Add support for NanoPi R6S") - -Reviewed-by: Kever Yang -Signed-off-by: Sebastian Kropatsch ---- - arch/arm/dts/rk3588s-nanopi-r6s-u-boot.dtsi | 3 + - arch/arm/mach-rockchip/rk3588/Kconfig | 13 +++ - board/friendlyelec/nanopi-r6s-rk3588s/Kconfig | 12 +++ - .../nanopi-r6s-rk3588s/MAINTAINERS | 7 ++ - configs/nanopi-r6s-rk3588s_defconfig | 82 +++++++++++++++++++ - doc/board/rockchip/rockchip.rst | 1 + - include/configs/nanopi-r6s-rk3588s.h | 12 +++ - 7 files changed, 130 insertions(+) - create mode 100644 arch/arm/dts/rk3588s-nanopi-r6s-u-boot.dtsi - create mode 100644 board/friendlyelec/nanopi-r6s-rk3588s/Kconfig - create mode 100644 board/friendlyelec/nanopi-r6s-rk3588s/MAINTAINERS - create mode 100644 configs/nanopi-r6s-rk3588s_defconfig - create mode 100644 include/configs/nanopi-r6s-rk3588s.h - ---- /dev/null -+++ b/arch/arm/dts/rk3588s-nanopi-r6s-u-boot.dtsi -@@ -0,0 +1,3 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+#include "rk3588s-u-boot.dtsi" ---- a/arch/arm/mach-rockchip/rk3588/Kconfig -+++ b/arch/arm/mach-rockchip/rk3588/Kconfig -@@ -78,6 +78,18 @@ config TARGET_NANOPCT6_RK3588 - Power: 5.5*2.1mm DC Jack, 12VDC input - Dimensions: 110x80x1.6mm (without case) / 86x114.5x30mm (with case) - -+config TARGET_NANOPI_R6S_RK3588S -+ bool "FriendlyElec NanoPi R6S" -+ select BOARD_LATE_INIT -+ help -+ The NanoPi R6S is a SBC by FriendlyElec based on the Rockchip -+ RK3588s. -+ It comes with 4GB or 8GB of RAM, a microSD card slot, 32GB eMMC -+ storage, one RTL8211F 1GbE and two RTL8125 2.5GbE Ethernet ports, -+ one USB 2.0 Type-A and one USB 3.0 Type-A port, a HDMI port, a -+ 12-pin GPIO FPC connector, a fan connector, IR receiver as well -+ as some buttons and LEDs. -+ - config TARGET_NOVA_RK3588 - bool "Indiedroid Nova RK3588" - select BOARD_LATE_INIT -@@ -232,6 +244,7 @@ config TEXT_BASE - - source "board/edgeble/neural-compute-module-6/Kconfig" - source "board/friendlyelec/nanopc-t6-rk3588/Kconfig" -+source "board/friendlyelec/nanopi-r6s-rk3588s/Kconfig" - source "board/indiedroid/nova/Kconfig" - source "board/pine64/quartzpro64-rk3588/Kconfig" - source "board/turing/turing-rk1-rk3588/Kconfig" ---- /dev/null -+++ b/board/friendlyelec/nanopi-r6s-rk3588s/Kconfig -@@ -0,0 +1,12 @@ -+if TARGET_NANOPI_R6S_RK3588S -+ -+config SYS_BOARD -+ default "nanopi-r6s-rk3588s" -+ -+config SYS_VENDOR -+ default "friendlyelec" -+ -+config SYS_CONFIG_NAME -+ default "nanopi-r6s-rk3588s" -+ -+endif ---- /dev/null -+++ b/board/friendlyelec/nanopi-r6s-rk3588s/MAINTAINERS -@@ -0,0 +1,7 @@ -+NANOPI-R6S -+M: Sebastian Kropatsch -+S: Maintained -+F: arch/arm/dts/rk3588s-nanopi-r6s-u-boot.dtsi -+F: board/friendlyelec/nanopi-r6s-rk3588s -+F: configs/nanopi-r6s-rk3588s_defconfig -+F: include/configs/nanopi-r6s-rk3588s.h ---- /dev/null -+++ b/configs/nanopi-r6s-rk3588s_defconfig -@@ -0,0 +1,82 @@ -+CONFIG_ARM=y -+CONFIG_SKIP_LOWLEVEL_INIT=y -+CONFIG_SYS_HAS_NONCACHED_MEMORY=y -+CONFIG_COUNTER_FREQUENCY=24000000 -+CONFIG_ARCH_ROCKCHIP=y -+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3588s-nanopi-r6s" -+CONFIG_ROCKCHIP_RK3588=y -+CONFIG_SPL_SERIAL=y -+CONFIG_TARGET_NANOPI_R6S_RK3588S=y -+CONFIG_DEBUG_UART_BASE=0xFEB50000 -+CONFIG_DEBUG_UART_CLOCK=24000000 -+CONFIG_SYS_LOAD_ADDR=0xc00800 -+CONFIG_PCI=y -+CONFIG_DEBUG_UART=y -+CONFIG_FIT=y -+CONFIG_FIT_VERBOSE=y -+CONFIG_SPL_FIT_SIGNATURE=y -+CONFIG_SPL_LOAD_FIT=y -+CONFIG_LEGACY_IMAGE_FORMAT=y -+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-nanopi-r6s.dtb" -+# CONFIG_DISPLAY_CPUINFO is not set -+CONFIG_DISPLAY_BOARDINFO_LATE=y -+CONFIG_SPL_MAX_SIZE=0x40000 -+CONFIG_SPL_PAD_TO=0x7f8000 -+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set -+CONFIG_SPL_ATF=y -+CONFIG_CMD_GPIO=y -+CONFIG_CMD_PWM=y -+CONFIG_CMD_GPT=y -+CONFIG_CMD_I2C=y -+CONFIG_CMD_MMC=y -+CONFIG_CMD_PCI=y -+CONFIG_CMD_USB=y -+CONFIG_CMD_ROCKUSB=y -+# CONFIG_CMD_SETEXPR is not set -+CONFIG_CMD_REGULATOR=y -+# CONFIG_SPL_DOS_PARTITION is not set -+CONFIG_SPL_OF_CONTROL=y -+CONFIG_OF_LIVE=y -+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents" -+CONFIG_SPL_DM_SEQ_ALIAS=y -+CONFIG_SPL_REGMAP=y -+CONFIG_SPL_SYSCON=y -+CONFIG_SPL_CLK=y -+# CONFIG_USB_FUNCTION_FASTBOOT is not set -+CONFIG_ROCKCHIP_GPIO=y -+CONFIG_SYS_I2C_ROCKCHIP=y -+CONFIG_MISC=y -+CONFIG_SUPPORT_EMMC_RPMB=y -+CONFIG_MMC_DW=y -+CONFIG_MMC_DW_ROCKCHIP=y -+CONFIG_MMC_SDHCI=y -+CONFIG_MMC_SDHCI_SDMA=y -+CONFIG_MMC_SDHCI_ROCKCHIP=y -+# CONFIG_SPI_FLASH is not set -+CONFIG_PHY_REALTEK=y -+CONFIG_DWC_ETH_QOS=y -+CONFIG_DWC_ETH_QOS_ROCKCHIP=y -+CONFIG_RTL8169=y -+CONFIG_PCIE_DW_ROCKCHIP=y -+CONFIG_PHY_ROCKCHIP_INNO_USB2=y -+CONFIG_PHY_ROCKCHIP_NANENG_COMBOPHY=y -+CONFIG_PHY_ROCKCHIP_USBDP=y -+CONFIG_SPL_PINCTRL=y -+CONFIG_PWM_ROCKCHIP=y -+CONFIG_SPL_RAM=y -+CONFIG_BAUDRATE=1500000 -+CONFIG_DEBUG_UART_SHIFT=2 -+CONFIG_SYS_NS16550_MEM32=y -+CONFIG_SYSRESET=y -+CONFIG_USB=y -+CONFIG_USB_XHCI_HCD=y -+CONFIG_USB_EHCI_HCD=y -+CONFIG_USB_EHCI_GENERIC=y -+CONFIG_USB_OHCI_HCD=y -+CONFIG_USB_OHCI_GENERIC=y -+CONFIG_USB_DWC3=y -+CONFIG_USB_DWC3_GENERIC=y -+CONFIG_USB_GADGET=y -+CONFIG_USB_GADGET_DOWNLOAD=y -+CONFIG_USB_FUNCTION_ROCKUSB=y -+CONFIG_ERRNO_STR=y ---- /dev/null -+++ b/include/configs/nanopi-r6s-rk3588s.h -@@ -0,0 +1,12 @@ -+/* SPDX-License-Identifier: GPL-2.0+ */ -+ -+#ifndef __NANOPI_R6S_RK3588S_H -+#define __NANOPI_R6S_RK3588S_H -+ -+#define ROCKCHIP_DEVICE_SETTINGS \ -+ "stdout=serial,vidconsole\0" \ -+ "stderr=serial,vidconsole\0" -+ -+#include -+ -+#endif /* __NANOPI_R6S_RK3588S_H */ diff --git a/package/boot/uboot-rockchip/patches/107-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6C.patch b/package/boot/uboot-rockchip/patches/107-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6C.patch deleted file mode 100644 index ba00a5c9de..0000000000 --- a/package/boot/uboot-rockchip/patches/107-v2024.10-rc1-board-rockchip-Add-FriendlyElec-NanoPi-R6C.patch +++ /dev/null @@ -1,213 +0,0 @@ -From f59d40aa5598063396164b3248f0f8ed6591e3db Mon Sep 17 00:00:00 2001 -From: Sebastian Kropatsch -Date: Thu, 11 Jul 2024 12:15:17 +0200 -Subject: [PATCH] board: rockchip: Add FriendlyElec NanoPi R6C - -The NanoPi R6C is a SBC by FriendlyElec based on the Rockchip RK3588s. -It comes with 4GB or 8GB of RAM, a microSD card slot, optional 32GB eMMC -storage, one M.2 M-Key connector, one RTL8211F 1GbE and one RTL8125 -2.5GbE Ethernet port, one USB 2.0 Type-A and one USB 3.0 Type-A port, a -HDMI port, a 30-pin GPIO header as well as multiple buttons and LEDs. - -Add initial support for this board using the upstream devicetree sources. - -Tested in U-Boot proper: -- Booting from eMMC works -- 1GbE Ethernet works using the eth_eqos driver (tested by ping) -- 2.5GbE Ethernet works using the eth_rtl8169 driver (tested by ping), - but the status LEDs on this specific port currently aren't working -- NVMe SSD in M.2 socket does get recognized (tested with `nvme scan` - followed by `nvme details`) - -Kernel commit: -d5f1d7437451 ("arm64: dts: rockchip: Add support for NanoPi R6C") - -Reviewed-by: Quentin Schulz -Reviewed-by: Kever Yang -Signed-off-by: Sebastian Kropatsch ---- - arch/arm/dts/rk3588s-nanopi-r6c-u-boot.dtsi | 3 + - arch/arm/mach-rockchip/rk3588/Kconfig | 13 +++ - board/friendlyelec/nanopi-r6c-rk3588s/Kconfig | 12 +++ - .../nanopi-r6c-rk3588s/MAINTAINERS | 7 ++ - configs/nanopi-r6c-rk3588s_defconfig | 83 +++++++++++++++++++ - doc/board/rockchip/rockchip.rst | 1 + - include/configs/nanopi-r6c-rk3588s.h | 12 +++ - 7 files changed, 131 insertions(+) - create mode 100644 arch/arm/dts/rk3588s-nanopi-r6c-u-boot.dtsi - create mode 100644 board/friendlyelec/nanopi-r6c-rk3588s/Kconfig - create mode 100644 board/friendlyelec/nanopi-r6c-rk3588s/MAINTAINERS - create mode 100644 configs/nanopi-r6c-rk3588s_defconfig - create mode 100644 include/configs/nanopi-r6c-rk3588s.h - ---- /dev/null -+++ b/arch/arm/dts/rk3588s-nanopi-r6c-u-boot.dtsi -@@ -0,0 +1,3 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+ -+#include "rk3588s-u-boot.dtsi" ---- a/arch/arm/mach-rockchip/rk3588/Kconfig -+++ b/arch/arm/mach-rockchip/rk3588/Kconfig -@@ -90,6 +90,18 @@ config TARGET_NANOPI_R6S_RK3588S - 12-pin GPIO FPC connector, a fan connector, IR receiver as well - as some buttons and LEDs. - -+config TARGET_NANOPI_R6C_RK3588S -+ bool "FriendlyElec NanoPi R6C" -+ select BOARD_LATE_INIT -+ help -+ The NanoPi R6C is a SBC by FriendlyElec based on the Rockchip -+ RK3588s. -+ It comes with 4GB or 8GB of RAM, a microSD card slot, optional 32GB -+ eMMC storage, one M.2 M-Key connector, one RTL8211F 1GbE and one -+ RTL8125 2.5GbE Ethernet port, one USB 2.0 Type-A and one USB 3.0 -+ Type-A port, a HDMI port, a 30-pin GPIO header as well as some -+ buttons and LEDs. -+ - config TARGET_NOVA_RK3588 - bool "Indiedroid Nova RK3588" - select BOARD_LATE_INIT -@@ -245,6 +257,7 @@ config TEXT_BASE - source "board/edgeble/neural-compute-module-6/Kconfig" - source "board/friendlyelec/nanopc-t6-rk3588/Kconfig" - source "board/friendlyelec/nanopi-r6s-rk3588s/Kconfig" -+source "board/friendlyelec/nanopi-r6c-rk3588s/Kconfig" - source "board/indiedroid/nova/Kconfig" - source "board/pine64/quartzpro64-rk3588/Kconfig" - source "board/turing/turing-rk1-rk3588/Kconfig" ---- /dev/null -+++ b/board/friendlyelec/nanopi-r6c-rk3588s/Kconfig -@@ -0,0 +1,12 @@ -+if TARGET_NANOPI_R6C_RK3588S -+ -+config SYS_BOARD -+ default "nanopi-r6c-rk3588s" -+ -+config SYS_VENDOR -+ default "friendlyelec" -+ -+config SYS_CONFIG_NAME -+ default "nanopi-r6c-rk3588s" -+ -+endif ---- /dev/null -+++ b/board/friendlyelec/nanopi-r6c-rk3588s/MAINTAINERS -@@ -0,0 +1,7 @@ -+NANOPI-R6C -+M: Sebastian Kropatsch -+S: Maintained -+F: arch/arm/dts/rk3588s-nanopi-r6c-u-boot.dtsi -+F: board/friendlyelec/nanopi-r6c-rk3588s -+F: configs/nanopi-r6c-rk3588s_defconfig -+F: include/configs/nanopi-r6c-rk3588s.h ---- /dev/null -+++ b/configs/nanopi-r6c-rk3588s_defconfig -@@ -0,0 +1,83 @@ -+CONFIG_ARM=y -+CONFIG_SKIP_LOWLEVEL_INIT=y -+CONFIG_SYS_HAS_NONCACHED_MEMORY=y -+CONFIG_COUNTER_FREQUENCY=24000000 -+CONFIG_ARCH_ROCKCHIP=y -+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3588s-nanopi-r6c" -+CONFIG_ROCKCHIP_RK3588=y -+CONFIG_SPL_SERIAL=y -+CONFIG_TARGET_NANOPI_R6C_RK3588S=y -+CONFIG_DEBUG_UART_BASE=0xFEB50000 -+CONFIG_DEBUG_UART_CLOCK=24000000 -+CONFIG_SYS_LOAD_ADDR=0xc00800 -+CONFIG_PCI=y -+CONFIG_DEBUG_UART=y -+CONFIG_FIT=y -+CONFIG_FIT_VERBOSE=y -+CONFIG_SPL_FIT_SIGNATURE=y -+CONFIG_SPL_LOAD_FIT=y -+CONFIG_LEGACY_IMAGE_FORMAT=y -+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588s-nanopi-r6c.dtb" -+# CONFIG_DISPLAY_CPUINFO is not set -+CONFIG_DISPLAY_BOARDINFO_LATE=y -+CONFIG_SPL_MAX_SIZE=0x40000 -+CONFIG_SPL_PAD_TO=0x7f8000 -+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set -+CONFIG_SPL_ATF=y -+CONFIG_CMD_GPIO=y -+CONFIG_CMD_PWM=y -+CONFIG_CMD_GPT=y -+CONFIG_CMD_I2C=y -+CONFIG_CMD_MMC=y -+CONFIG_CMD_PCI=y -+CONFIG_CMD_USB=y -+CONFIG_CMD_ROCKUSB=y -+# CONFIG_CMD_SETEXPR is not set -+CONFIG_CMD_REGULATOR=y -+# CONFIG_SPL_DOS_PARTITION is not set -+CONFIG_SPL_OF_CONTROL=y -+CONFIG_OF_LIVE=y -+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents" -+CONFIG_SPL_DM_SEQ_ALIAS=y -+CONFIG_SPL_REGMAP=y -+CONFIG_SPL_SYSCON=y -+CONFIG_SPL_CLK=y -+# CONFIG_USB_FUNCTION_FASTBOOT is not set -+CONFIG_ROCKCHIP_GPIO=y -+CONFIG_SYS_I2C_ROCKCHIP=y -+CONFIG_MISC=y -+CONFIG_SUPPORT_EMMC_RPMB=y -+CONFIG_MMC_DW=y -+CONFIG_MMC_DW_ROCKCHIP=y -+CONFIG_MMC_SDHCI=y -+CONFIG_MMC_SDHCI_SDMA=y -+CONFIG_MMC_SDHCI_ROCKCHIP=y -+# CONFIG_SPI_FLASH is not set -+CONFIG_PHY_REALTEK=y -+CONFIG_DWC_ETH_QOS=y -+CONFIG_DWC_ETH_QOS_ROCKCHIP=y -+CONFIG_RTL8169=y -+CONFIG_NVME_PCI=y -+CONFIG_PCIE_DW_ROCKCHIP=y -+CONFIG_PHY_ROCKCHIP_INNO_USB2=y -+CONFIG_PHY_ROCKCHIP_NANENG_COMBOPHY=y -+CONFIG_PHY_ROCKCHIP_USBDP=y -+CONFIG_SPL_PINCTRL=y -+CONFIG_PWM_ROCKCHIP=y -+CONFIG_SPL_RAM=y -+CONFIG_BAUDRATE=1500000 -+CONFIG_DEBUG_UART_SHIFT=2 -+CONFIG_SYS_NS16550_MEM32=y -+CONFIG_SYSRESET=y -+CONFIG_USB=y -+CONFIG_USB_XHCI_HCD=y -+CONFIG_USB_EHCI_HCD=y -+CONFIG_USB_EHCI_GENERIC=y -+CONFIG_USB_OHCI_HCD=y -+CONFIG_USB_OHCI_GENERIC=y -+CONFIG_USB_DWC3=y -+CONFIG_USB_DWC3_GENERIC=y -+CONFIG_USB_GADGET=y -+CONFIG_USB_GADGET_DOWNLOAD=y -+CONFIG_USB_FUNCTION_ROCKUSB=y -+CONFIG_ERRNO_STR=y ---- a/doc/board/rockchip/rockchip.rst -+++ b/doc/board/rockchip/rockchip.rst -@@ -126,6 +126,7 @@ List of mainline supported Rockchip boar - - Edgeble Neural Compute Module 6A SoM - Neu6a (neu6a-io-rk3588) - - Edgeble Neural Compute Module 6B SoM - Neu6b (neu6b-io-rk3588) - - FriendlyElec NanoPC-T6 (nanopc-t6-rk3588) -+ - FriendlyElec NanoPi R6C (nanopi-r6c-rk3588s) - - Generic RK3588S/RK3588 (generic-rk3588) - - Indiedroid Nova (nova-rk3588s) - - Pine64 QuartzPro64 (quartzpro64-rk3588) ---- /dev/null -+++ b/include/configs/nanopi-r6c-rk3588s.h -@@ -0,0 +1,12 @@ -+/* SPDX-License-Identifier: GPL-2.0+ */ -+ -+#ifndef __NANOPI_R6C_RK3588S_H -+#define __NANOPI_R6C_RK3588S_H -+ -+#define ROCKCHIP_DEVICE_SETTINGS \ -+ "stdout=serial,vidconsole\0" \ -+ "stderr=serial,vidconsole\0" -+ -+#include -+ -+#endif /* __NANOPI_R6C_RK3588S_H */ diff --git a/package/boot/uboot-rockchip/patches/108-v2024.10-rc1-board-rockchip-add-ArmSoM-Sige7-Rk3588-board.patch b/package/boot/uboot-rockchip/patches/108-v2024.10-rc1-board-rockchip-add-ArmSoM-Sige7-Rk3588-board.patch deleted file mode 100644 index 7fa4d679e4..0000000000 --- a/package/boot/uboot-rockchip/patches/108-v2024.10-rc1-board-rockchip-add-ArmSoM-Sige7-Rk3588-board.patch +++ /dev/null @@ -1,257 +0,0 @@ -From 40b573e4f6ed629eab54633f8836a2be5e5aa75a Mon Sep 17 00:00:00 2001 -From: Jianfeng Liu -Date: Wed, 29 May 2024 01:04:06 +0800 -Subject: [PATCH] board: rockchip: add ArmSoM Sige7 Rk3588 board - -ArmSoM Sige7 is a Rockchip RK3588 based SBC (Single Board Computer) by -ArmSoM. - -There are two variants depending on the DRAM size : 8G and 16G. - -Specification: - - Rockchip Rk3588 SoC - 4x ARM Cortex-A76, 4x ARM Cortex-A55 - 8/16GB memory LPDDR4x - Mali G610MC4 GPU - 2x MIPI CSI 2 multiple lanes connector - 64GB/128GB on board eMMC - uSD slot - 1x USB 2.0 Type-A, 1x USB 3.0 Type-A, 1x USB 3.0 Type-C - 1x HDMI 2.1 output - 2x 2.5 Gbps Ethernet port - 40-pin IO header including UART, SPI and I2C - USB PD over USB Type-C - Size: 92mm x 62mm - -Kernel commit: -81c828a67c78 (arm64: dts: rockchip: Add ArmSom Sige7 board) - -Signed-off-by: Jianfeng Liu -Reviewed-by: Kever Yang ---- - MAINTAINERS | 1 + - arch/arm/dts/rk3588-armsom-sige7-u-boot.dtsi | 6 ++ - arch/arm/mach-rockchip/rk3588/Kconfig | 26 ++++++ - board/armsom/sige7-rk3588/Kconfig | 12 +++ - board/armsom/sige7-rk3588/MAINTAINERS | 7 ++ - configs/sige7-rk3588_defconfig | 93 ++++++++++++++++++++ - doc/board/rockchip/rockchip.rst | 1 + - include/configs/sige7-rk3588.h | 15 ++++ - 8 files changed, 161 insertions(+) - create mode 100644 arch/arm/dts/rk3588-armsom-sige7-u-boot.dtsi - create mode 100644 board/armsom/sige7-rk3588/Kconfig - create mode 100644 board/armsom/sige7-rk3588/MAINTAINERS - create mode 100644 configs/sige7-rk3588_defconfig - create mode 100644 include/configs/sige7-rk3588.h - ---- a/MAINTAINERS -+++ b/MAINTAINERS -@@ -533,6 +533,7 @@ F: arch/arm/include/asm/arch-rockchip/ - F: arch/arm/mach-rockchip/ - F: board/amarula/vyasa-rk3288/ - F: board/anbernic/rgxx3_rk3566/ -+F: board/armsom/sige7-rk3588/ - F: board/chipspark/popmetal_rk3288 - F: board/engicam/px30_core/ - F: board/firefly/ ---- /dev/null -+++ b/arch/arm/dts/rk3588-armsom-sige7-u-boot.dtsi -@@ -0,0 +1,6 @@ -+// SPDX-License-Identifier: (GPL-2.0+ OR MIT) -+/* -+ * Copyright (c) 2024 ArmSoM Technology Co., Ltd. -+ */ -+ -+#include "rk3588-u-boot.dtsi" ---- a/arch/arm/mach-rockchip/rk3588/Kconfig -+++ b/arch/arm/mach-rockchip/rk3588/Kconfig -@@ -185,6 +185,31 @@ config TARGET_ROCK5B_RK3588 - USB PD over USB Type-C - Size: 100mm x 72mm (Pico-ITX form factor) - -+config TARGET_SIGE7_RK3588 -+ bool "ArmSoM Sige7 RK3588 board" -+ select BOARD_LATE_INIT -+ help -+ ArmSoM Sige7 is a Rockchip RK3588 based SBC (Single Board Computer) -+ by ArmSoM. -+ -+ There are two variants depending on the DRAM size : 8G and 16G. -+ -+ Specification: -+ -+ Rockchip Rk3588 SoC -+ 4x ARM Cortex-A76, 4x ARM Cortex-A55 -+ 8/16GB memory LPDDR4x -+ Mali G610MC4 GPU -+ 2x MIPI CSI 2 multiple lanes connector -+ 64GB/128GB on board eMMC -+ uSD slot -+ 1x USB 2.0 Type-A, 1x USB 3.0 Type-A, 1x USB 3.0 Type-C -+ 1x HDMI 2.1 output -+ 2x 2.5 Gbps Ethernet port -+ 40-pin IO header including UART, SPI and I2C -+ USB PD over USB Type-C -+ Size: 92mm x 62mm -+ - config TARGET_QUARTZPRO64_RK3588 - bool "Pine64 QuartzPro64 RK3588 board" - select BOARD_LATE_INIT -@@ -254,6 +279,7 @@ config ROCKCHIP_COMMON_STACK_ADDR - config TEXT_BASE - default 0x00a00000 - -+source "board/armsom/sige7-rk3588/Kconfig" - source "board/edgeble/neural-compute-module-6/Kconfig" - source "board/friendlyelec/nanopc-t6-rk3588/Kconfig" - source "board/friendlyelec/nanopi-r6s-rk3588s/Kconfig" ---- /dev/null -+++ b/board/armsom/sige7-rk3588/Kconfig -@@ -0,0 +1,12 @@ -+if TARGET_SIGE7_RK3588 -+ -+config SYS_BOARD -+ default "sige7-rk3588" -+ -+config SYS_VENDOR -+ default "armsom" -+ -+config SYS_CONFIG_NAME -+ default "sige7-rk3588" -+ -+endif ---- /dev/null -+++ b/board/armsom/sige7-rk3588/MAINTAINERS -@@ -0,0 +1,7 @@ -+SIGE7-RK3588 -+M: Jianfeng Liu -+S: Maintained -+F: board/armsom/sige7-rk3588 -+F: include/configs/sige7-rk3588.h -+F: configs/sige7-rk3588_defconfig -+F: arch/arm/dts/rk3588-armsom-sige7* ---- /dev/null -+++ b/configs/sige7-rk3588_defconfig -@@ -0,0 +1,93 @@ -+CONFIG_ARM=y -+CONFIG_SKIP_LOWLEVEL_INIT=y -+CONFIG_SYS_HAS_NONCACHED_MEMORY=y -+CONFIG_COUNTER_FREQUENCY=24000000 -+CONFIG_ARCH_ROCKCHIP=y -+CONFIG_DEFAULT_DEVICE_TREE="rockchip/rk3588-armsom-sige7" -+CONFIG_ROCKCHIP_RK3588=y -+CONFIG_SPL_SERIAL=y -+CONFIG_TARGET_SIGE7_RK3588=y -+CONFIG_DEBUG_UART_BASE=0xFEB50000 -+CONFIG_DEBUG_UART_CLOCK=24000000 -+CONFIG_SPL_SPI=y -+CONFIG_SYS_LOAD_ADDR=0xc00800 -+CONFIG_PCI=y -+CONFIG_DEBUG_UART=y -+CONFIG_AHCI=y -+CONFIG_FIT=y -+CONFIG_FIT_VERBOSE=y -+CONFIG_SPL_FIT_SIGNATURE=y -+CONFIG_SPL_LOAD_FIT=y -+CONFIG_LEGACY_IMAGE_FORMAT=y -+CONFIG_DEFAULT_FDT_FILE="rockchip/rk3588-armsom-sige7.dtb" -+# CONFIG_DISPLAY_CPUINFO is not set -+CONFIG_DISPLAY_BOARDINFO_LATE=y -+CONFIG_SPL_MAX_SIZE=0x40000 -+CONFIG_SPL_PAD_TO=0x7f8000 -+# CONFIG_SPL_RAW_IMAGE_SUPPORT is not set -+CONFIG_SPL_ATF=y -+CONFIG_CMD_GPIO=y -+CONFIG_CMD_GPT=y -+CONFIG_CMD_I2C=y -+CONFIG_CMD_MMC=y -+CONFIG_CMD_PCI=y -+CONFIG_CMD_USB=y -+CONFIG_CMD_ROCKUSB=y -+# CONFIG_CMD_SETEXPR is not set -+CONFIG_CMD_REGULATOR=y -+# CONFIG_SPL_DOS_PARTITION is not set -+CONFIG_SPL_OF_CONTROL=y -+CONFIG_OF_LIVE=y -+CONFIG_OF_SPL_REMOVE_PROPS="clock-names interrupt-parent assigned-clocks assigned-clock-rates assigned-clock-parents" -+CONFIG_SPL_DM_SEQ_ALIAS=y -+CONFIG_SPL_REGMAP=y -+CONFIG_SPL_SYSCON=y -+CONFIG_AHCI_PCI=y -+CONFIG_DWC_AHCI=y -+CONFIG_SPL_CLK=y -+# CONFIG_USB_FUNCTION_FASTBOOT is not set -+CONFIG_ROCKCHIP_GPIO=y -+CONFIG_SYS_I2C_ROCKCHIP=y -+CONFIG_MISC=y -+CONFIG_SUPPORT_EMMC_RPMB=y -+CONFIG_MMC_DW=y -+CONFIG_MMC_DW_ROCKCHIP=y -+CONFIG_MMC_SDHCI=y -+CONFIG_MMC_SDHCI_SDMA=y -+CONFIG_MMC_SDHCI_ROCKCHIP=y -+CONFIG_PHYLIB=y -+CONFIG_RTL8169=y -+CONFIG_NVME_PCI=y -+CONFIG_PCIE_DW_ROCKCHIP=y -+CONFIG_PHY_ROCKCHIP_INNO_USB2=y -+CONFIG_PHY_ROCKCHIP_NANENG_COMBOPHY=y -+CONFIG_PHY_ROCKCHIP_USBDP=y -+CONFIG_SPL_PINCTRL=y -+CONFIG_PWM_ROCKCHIP=y -+CONFIG_SPL_RAM=y -+CONFIG_SCSI=y -+CONFIG_BAUDRATE=1500000 -+CONFIG_DEBUG_UART_SHIFT=2 -+CONFIG_SYS_NS16550_MEM32=y -+CONFIG_SYSRESET=y -+CONFIG_USB=y -+CONFIG_USB_XHCI_HCD=y -+CONFIG_USB_EHCI_HCD=y -+CONFIG_USB_EHCI_GENERIC=y -+CONFIG_USB_OHCI_HCD=y -+CONFIG_USB_OHCI_GENERIC=y -+CONFIG_USB_DWC3=y -+CONFIG_USB_DWC3_GENERIC=y -+CONFIG_SPL_USB_DWC3_GENERIC=y -+CONFIG_USB_HOST_ETHER=y -+CONFIG_USB_ETHER_ASIX=y -+CONFIG_USB_ETHER_ASIX88179=y -+CONFIG_USB_ETHER_LAN75XX=y -+CONFIG_USB_ETHER_LAN78XX=y -+CONFIG_USB_ETHER_MCS7830=y -+CONFIG_USB_ETHER_RTL8152=y -+CONFIG_USB_ETHER_SMSC95XX=y -+CONFIG_USB_GADGET=y -+CONFIG_USB_GADGET_DOWNLOAD=y -+CONFIG_USB_FUNCTION_ROCKUSB=y -+CONFIG_ERRNO_STR=y ---- a/doc/board/rockchip/rockchip.rst -+++ b/doc/board/rockchip/rockchip.rst -@@ -122,6 +122,7 @@ List of mainline supported Rockchip boar - - Radxa ROCK 3B (rock-3b-rk3568) - - * rk3588 -+ - ArmSoM Sige7 (sige7-rk3588) - - Rockchip EVB (evb-rk3588) - - Edgeble Neural Compute Module 6A SoM - Neu6a (neu6a-io-rk3588) - - Edgeble Neural Compute Module 6B SoM - Neu6b (neu6b-io-rk3588) ---- /dev/null -+++ b/include/configs/sige7-rk3588.h -@@ -0,0 +1,15 @@ -+/* SPDX-License-Identifier: GPL-2.0+ */ -+/* -+ * Copyright (c) 2024 ArmSoM Technology Co., Ltd. -+ */ -+ -+#ifndef __SIGE7_RK3588_H -+#define __SIGE7_RK3588_H -+ -+#define ROCKCHIP_DEVICE_SETTINGS \ -+ "stdout=serial,vidconsole\0" \ -+ "stderr=serial,vidconsole\0" -+ -+#include -+ -+#endif /* __SIGE7_RK3588_H */ From 7e942c53b2eb3a3f55503fd2c6aabb00a35e5ebf Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Fri, 11 Oct 2024 14:39:54 +0200 Subject: [PATCH 08/15] netifd: update to Git HEAD (2024-10-06) 3c6265fdbd02 wireless: reload wireless device if any vif network bridge changes ifindex Signed-off-by: Felix Fietkau --- package/network/config/netifd/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/network/config/netifd/Makefile b/package/network/config/netifd/Makefile index 649b7ccd85..771d7dadaf 100644 --- a/package/network/config/netifd/Makefile +++ b/package/network/config/netifd/Makefile @@ -5,9 +5,9 @@ PKG_RELEASE:=1 PKG_SOURCE_PROTO:=git PKG_SOURCE_URL=$(PROJECT_GIT)/project/netifd.git -PKG_SOURCE_DATE:=2024-09-21 -PKG_SOURCE_VERSION:=24f9a93a9559c93cf1e794fdfcd87a38d27a8e0e -PKG_MIRROR_HASH:=a3baa049b86f65cf9709d57bb5a9ea7a5b7405f63c77e2bd641fe9b59865838c +PKG_SOURCE_DATE:=2024-10-06 +PKG_SOURCE_VERSION:=3c6265fdbd02ebd35fa3e7a58d6dfeed081a09d7 +PKG_MIRROR_HASH:=00b01243b99995dc52a047e5663cf5c7732f8defd6b726f73ac15e142b02b4fa PKG_MAINTAINER:=Felix Fietkau PKG_LICENSE:=GPL-2.0 From 48b8c602d01286e8b2f72eee5a645220c87bf73d Mon Sep 17 00:00:00 2001 From: Shiji Yang Date: Fri, 11 Oct 2024 18:40:16 +0800 Subject: [PATCH 09/15] ipq40xx: switch to zImage kernel for SKSpruce WIA3300-20 The bootloader can support zImage linux kernel which can decrease the firmware image size. Signed-off-by: Shiji Yang Link: https://github.com/openwrt/openwrt/pull/16662 Signed-off-by: Robert Marko --- target/linux/ipq40xx/image/generic.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/target/linux/ipq40xx/image/generic.mk b/target/linux/ipq40xx/image/generic.mk index b5d387b14a..478e399d0c 100644 --- a/target/linux/ipq40xx/image/generic.mk +++ b/target/linux/ipq40xx/image/generic.mk @@ -1093,7 +1093,7 @@ endef TARGET_DEVICES += qxwlan_e2600ac-c2 define Device/skspruce_wia3300-20 - $(call Device/FitImage) + $(call Device/FitzImage) BLOCKSIZE := 64k IMAGE_SIZE := 55104k SOC := qcom-ipq4019 From f9a70a20c53f439e97a49f72770a6b15d2b7de67 Mon Sep 17 00:00:00 2001 From: Christian Marangi Date: Fri, 11 Oct 2024 14:05:40 +0200 Subject: [PATCH 10/15] generic: backport BLOCK OF support patch Backport BLOCK OF support patch merged upstream and refresh pending BLOCK patches. This is a new way to declare partition table for BLOCK device (eMMC currently supported) with the use of DTS. Current pending patch are adapted to not cause regression with current downstream implementation of a similar functionality. Also enable the new OF_PARTITION config by default. Link: https://github.com/openwrt/openwrt/pull/16663 Signed-off-by: Christian Marangi --- ...092-MMC-added-alternative-MMC-driver.patch | 6 +- ...rt-for-defining-read-only-partitions.patch | 53 +++++ ...3-03-block-introduce-add_disk_fwnode.patch | 94 ++++++++ ...-partitions-fwnode-if-found-in-mmc-c.patch | 104 +++++++++ ...rt-for-partition-table-defined-in-OF.patch | 200 ++++++++++++++++++ target/linux/generic/config-6.6 | 1 + ...451-block-partitions-populate-fwnode.patch | 4 +- ...-block-add-support-for-notifications.patch | 2 +- ...mmc-block-set-fwnode-of-disk-devices.patch | 32 +-- .../458-mmc-block-set-GENHD_FL_NVMEM.patch | 2 +- 10 files changed, 470 insertions(+), 28 deletions(-) create mode 100644 target/linux/generic/backport-6.6/410-v6.13-01-block-add-support-for-defining-read-only-partitions.patch create mode 100644 target/linux/generic/backport-6.6/410-v6.13-03-block-introduce-add_disk_fwnode.patch create mode 100644 target/linux/generic/backport-6.6/410-v6.13-04-mmc-block-attach-partitions-fwnode-if-found-in-mmc-c.patch create mode 100644 target/linux/generic/backport-6.6/410-v6.13-05-block-add-support-for-partition-table-defined-in-OF.patch diff --git a/target/linux/bcm27xx/patches-6.6/950-0092-MMC-added-alternative-MMC-driver.patch b/target/linux/bcm27xx/patches-6.6/950-0092-MMC-added-alternative-MMC-driver.patch index 48baa90403..aebb491f32 100644 --- a/target/linux/bcm27xx/patches-6.6/950-0092-MMC-added-alternative-MMC-driver.patch +++ b/target/linux/bcm27xx/patches-6.6/950-0092-MMC-added-alternative-MMC-driver.patch @@ -285,7 +285,7 @@ Signed-off-by: Phil Elwell static inline int mmc_blk_part_switch(struct mmc_card *card, unsigned int part_type); static void mmc_blk_rw_rq_prep(struct mmc_queue_req *mqrq, -@@ -3016,6 +3023,8 @@ static int mmc_blk_probe(struct mmc_card +@@ -3066,6 +3073,8 @@ static int mmc_blk_probe(struct mmc_card { struct mmc_blk_data *md; int ret = 0; @@ -294,7 +294,7 @@ Signed-off-by: Phil Elwell /* * Check that the card supports the command class(es) we need. -@@ -3023,7 +3032,16 @@ static int mmc_blk_probe(struct mmc_card +@@ -3073,7 +3082,16 @@ static int mmc_blk_probe(struct mmc_card if (!(card->csd.cmdclass & CCC_BLOCK_READ)) return -ENODEV; @@ -312,7 +312,7 @@ Signed-off-by: Phil Elwell card->complete_wq = alloc_workqueue("mmc_complete", WQ_MEM_RECLAIM | WQ_HIGHPRI, 0); -@@ -3038,6 +3056,17 @@ static int mmc_blk_probe(struct mmc_card +@@ -3088,6 +3106,17 @@ static int mmc_blk_probe(struct mmc_card goto out_free; } diff --git a/target/linux/generic/backport-6.6/410-v6.13-01-block-add-support-for-defining-read-only-partitions.patch b/target/linux/generic/backport-6.6/410-v6.13-01-block-add-support-for-defining-read-only-partitions.patch new file mode 100644 index 0000000000..fabf16a2e6 --- /dev/null +++ b/target/linux/generic/backport-6.6/410-v6.13-01-block-add-support-for-defining-read-only-partitions.patch @@ -0,0 +1,53 @@ +From 03cb793b26834ddca170ba87057c8f883772dd45 Mon Sep 17 00:00:00 2001 +From: Christian Marangi +Date: Thu, 3 Oct 2024 00:11:41 +0200 +Subject: [PATCH 1/5] block: add support for defining read-only partitions + +Add support for defining read-only partitions and complete support for +it in the cmdline partition parser as the additional "ro" after a +partition is scanned but never actually applied. + +Signed-off-by: Christian Marangi +Reviewed-by: Christoph Hellwig +Link: https://lore.kernel.org/r/20241002221306.4403-2-ansuelsmth@gmail.com +Signed-off-by: Jens Axboe +--- + block/blk.h | 1 + + block/partitions/cmdline.c | 3 +++ + block/partitions/core.c | 3 +++ + 3 files changed, 7 insertions(+) + +--- a/block/blk.h ++++ b/block/blk.h +@@ -424,6 +424,7 @@ void blk_free_ext_minor(unsigned int min + #define ADDPART_FLAG_NONE 0 + #define ADDPART_FLAG_RAID 1 + #define ADDPART_FLAG_WHOLEDISK 2 ++#define ADDPART_FLAG_READONLY 4 + int bdev_add_partition(struct gendisk *disk, int partno, sector_t start, + sector_t length); + int bdev_del_partition(struct gendisk *disk, int partno); +--- a/block/partitions/cmdline.c ++++ b/block/partitions/cmdline.c +@@ -237,6 +237,9 @@ static int add_part(int slot, struct cmd + put_partition(state, slot, subpart->from >> 9, + subpart->size >> 9); + ++ if (subpart->flags & PF_RDONLY) ++ state->parts[slot].flags |= ADDPART_FLAG_READONLY; ++ + info = &state->parts[slot].info; + + strscpy(info->volname, subpart->name, sizeof(info->volname)); +--- a/block/partitions/core.c ++++ b/block/partitions/core.c +@@ -392,6 +392,9 @@ static struct block_device *add_partitio + goto out_del; + } + ++ if (flags & ADDPART_FLAG_READONLY) ++ bdev->bd_read_only = true; ++ + /* everything is up and running, commence */ + err = xa_insert(&disk->part_tbl, partno, bdev, GFP_KERNEL); + if (err) diff --git a/target/linux/generic/backport-6.6/410-v6.13-03-block-introduce-add_disk_fwnode.patch b/target/linux/generic/backport-6.6/410-v6.13-03-block-introduce-add_disk_fwnode.patch new file mode 100644 index 0000000000..41b51ab215 --- /dev/null +++ b/target/linux/generic/backport-6.6/410-v6.13-03-block-introduce-add_disk_fwnode.patch @@ -0,0 +1,94 @@ +From e5f587242b6072ffab4f4a084a459a59f3035873 Mon Sep 17 00:00:00 2001 +From: Christian Marangi +Date: Thu, 3 Oct 2024 00:11:43 +0200 +Subject: [PATCH 3/5] block: introduce add_disk_fwnode() + +Introduce add_disk_fwnode() as a replacement of device_add_disk() that +permits to pass and attach a fwnode to disk dev. + +This variant can be useful for eMMC that might have the partition table +for the disk defined in DT. A parser can later make use of the attached +fwnode to parse the related table and init the hardcoded partition for +the disk. + +device_add_disk() is converted to a simple wrapper of add_disk_fwnode() +with the fwnode entry set as NULL. + +Signed-off-by: Christian Marangi +Reviewed-by: Christoph Hellwig +Link: https://lore.kernel.org/r/20241002221306.4403-4-ansuelsmth@gmail.com +Signed-off-by: Jens Axboe +--- + block/genhd.c | 28 ++++++++++++++++++++++++---- + include/linux/blkdev.h | 3 +++ + 2 files changed, 27 insertions(+), 4 deletions(-) + +--- a/block/genhd.c ++++ b/block/genhd.c +@@ -383,16 +383,18 @@ int disk_scan_partitions(struct gendisk + } + + /** +- * device_add_disk - add disk information to kernel list ++ * add_disk_fwnode - add disk information to kernel list with fwnode + * @parent: parent device for the disk + * @disk: per-device partitioning information + * @groups: Additional per-device sysfs groups ++ * @fwnode: attached disk fwnode + * + * This function registers the partitioning information in @disk +- * with the kernel. ++ * with the kernel. Also attach a fwnode to the disk device. + */ +-int __must_check device_add_disk(struct device *parent, struct gendisk *disk, +- const struct attribute_group **groups) ++int __must_check add_disk_fwnode(struct device *parent, struct gendisk *disk, ++ const struct attribute_group **groups, ++ struct fwnode_handle *fwnode) + + { + struct device *ddev = disk_to_dev(disk); +@@ -451,6 +453,8 @@ int __must_check device_add_disk(struct + ddev->parent = parent; + ddev->groups = groups; + dev_set_name(ddev, "%s", disk->disk_name); ++ if (fwnode) ++ device_set_node(ddev, fwnode); + if (!(disk->flags & GENHD_FL_HIDDEN)) + ddev->devt = MKDEV(disk->major, disk->first_minor); + ret = device_add(ddev); +@@ -552,6 +556,22 @@ out_exit_elevator: + elevator_exit(disk->queue); + return ret; + } ++EXPORT_SYMBOL_GPL(add_disk_fwnode); ++ ++/** ++ * device_add_disk - add disk information to kernel list ++ * @parent: parent device for the disk ++ * @disk: per-device partitioning information ++ * @groups: Additional per-device sysfs groups ++ * ++ * This function registers the partitioning information in @disk ++ * with the kernel. ++ */ ++int __must_check device_add_disk(struct device *parent, struct gendisk *disk, ++ const struct attribute_group **groups) ++{ ++ return add_disk_fwnode(parent, disk, groups, NULL); ++} + EXPORT_SYMBOL(device_add_disk); + + static void blk_report_disk_dead(struct gendisk *disk, bool surprise) +--- a/include/linux/blkdev.h ++++ b/include/linux/blkdev.h +@@ -741,6 +741,9 @@ static inline unsigned int blk_queue_dep + #define for_each_bio(_bio) \ + for (; _bio; _bio = _bio->bi_next) + ++int __must_check add_disk_fwnode(struct device *parent, struct gendisk *disk, ++ const struct attribute_group **groups, ++ struct fwnode_handle *fwnode); + int __must_check device_add_disk(struct device *parent, struct gendisk *disk, + const struct attribute_group **groups); + static inline int __must_check add_disk(struct gendisk *disk) diff --git a/target/linux/generic/backport-6.6/410-v6.13-04-mmc-block-attach-partitions-fwnode-if-found-in-mmc-c.patch b/target/linux/generic/backport-6.6/410-v6.13-04-mmc-block-attach-partitions-fwnode-if-found-in-mmc-c.patch new file mode 100644 index 0000000000..cf0d18cf06 --- /dev/null +++ b/target/linux/generic/backport-6.6/410-v6.13-04-mmc-block-attach-partitions-fwnode-if-found-in-mmc-c.patch @@ -0,0 +1,104 @@ +From 45ff6c340ddfc2dade74d5b7a8962c778ab7042c Mon Sep 17 00:00:00 2001 +From: Christian Marangi +Date: Thu, 3 Oct 2024 00:11:44 +0200 +Subject: [PATCH 4/5] mmc: block: attach partitions fwnode if found in mmc-card + +Attach partitions fwnode if found in mmc-card and register disk with it. + +This permits block partition to reference the node and register a +partition table defined in DT for the special case for embedded device +that doesn't have a partition table flashed but have an hardcoded +partition table passed from the system. + +JEDEC BOOT partition boot0/boot1 are supported but in DT we refer with +the JEDEC name of boot1 and boot2 to better adhere to documentation. + +Also JEDEC GP partition gp0/1/2/3 are supported but in DT we refer with +the JEDEC name of gp1/2/3/4 to better adhere to documentration. + +Signed-off-by: Christian Marangi +Reviewed-by: Linus Walleij +Link: https://lore.kernel.org/r/20241002221306.4403-5-ansuelsmth@gmail.com +Signed-off-by: Jens Axboe +--- + drivers/mmc/core/block.c | 55 +++++++++++++++++++++++++++++++++++++++- + 1 file changed, 54 insertions(+), 1 deletion(-) + +--- a/drivers/mmc/core/block.c ++++ b/drivers/mmc/core/block.c +@@ -2455,6 +2455,56 @@ static inline int mmc_blk_readonly(struc + !(card->csd.cmdclass & CCC_BLOCK_WRITE); + } + ++/* ++ * Search for a declared partitions node for the disk in mmc-card related node. ++ * ++ * This is to permit support for partition table defined in DT in special case ++ * where a partition table is not written in the disk and is expected to be ++ * passed from the running system. ++ * ++ * For the user disk, "partitions" node is searched. ++ * For the special HW disk, "partitions-" node with the appended name is used ++ * following this conversion table (to adhere to JEDEC naming) ++ * - boot0 -> partitions-boot1 ++ * - boot1 -> partitions-boot2 ++ * - gp0 -> partitions-gp1 ++ * - gp1 -> partitions-gp2 ++ * - gp2 -> partitions-gp3 ++ * - gp3 -> partitions-gp4 ++ */ ++static struct fwnode_handle *mmc_blk_get_partitions_node(struct device *mmc_dev, ++ const char *subname) ++{ ++ const char *node_name = "partitions"; ++ ++ if (subname) { ++ mmc_dev = mmc_dev->parent; ++ ++ /* ++ * Check if we are allocating a BOOT disk boot0/1 disk. ++ * In DT we use the JEDEC naming boot1/2. ++ */ ++ if (!strcmp(subname, "boot0")) ++ node_name = "partitions-boot1"; ++ if (!strcmp(subname, "boot1")) ++ node_name = "partitions-boot2"; ++ /* ++ * Check if we are allocating a GP disk gp0/1/2/3 disk. ++ * In DT we use the JEDEC naming gp1/2/3/4. ++ */ ++ if (!strcmp(subname, "gp0")) ++ node_name = "partitions-gp1"; ++ if (!strcmp(subname, "gp1")) ++ node_name = "partitions-gp2"; ++ if (!strcmp(subname, "gp2")) ++ node_name = "partitions-gp3"; ++ if (!strcmp(subname, "gp3")) ++ node_name = "partitions-gp4"; ++ } ++ ++ return device_get_named_child_node(mmc_dev, node_name); ++} ++ + static struct mmc_blk_data *mmc_blk_alloc_req(struct mmc_card *card, + struct device *parent, + sector_t size, +@@ -2463,6 +2513,7 @@ static struct mmc_blk_data *mmc_blk_allo + int area_type, + unsigned int part_type) + { ++ struct fwnode_handle *disk_fwnode; + struct mmc_blk_data *md; + int devidx, ret; + char cap_str[10]; +@@ -2568,7 +2619,9 @@ static struct mmc_blk_data *mmc_blk_allo + /* used in ->open, must be set before add_disk: */ + if (area_type == MMC_BLK_DATA_AREA_MAIN) + dev_set_drvdata(&card->dev, md); +- ret = device_add_disk(md->parent, md->disk, mmc_disk_attr_groups); ++ disk_fwnode = mmc_blk_get_partitions_node(parent, subname); ++ ret = add_disk_fwnode(md->parent, md->disk, mmc_disk_attr_groups, ++ disk_fwnode); + if (ret) + goto err_put_disk; + return md; diff --git a/target/linux/generic/backport-6.6/410-v6.13-05-block-add-support-for-partition-table-defined-in-OF.patch b/target/linux/generic/backport-6.6/410-v6.13-05-block-add-support-for-partition-table-defined-in-OF.patch new file mode 100644 index 0000000000..d260be168c --- /dev/null +++ b/target/linux/generic/backport-6.6/410-v6.13-05-block-add-support-for-partition-table-defined-in-OF.patch @@ -0,0 +1,200 @@ +From 884555b557e5e6d41c866e2cd8d7b32f50ec974b Mon Sep 17 00:00:00 2001 +From: Christian Marangi +Date: Thu, 3 Oct 2024 00:11:45 +0200 +Subject: [PATCH 5/5] block: add support for partition table defined in OF + +Add support for partition table defined in Device Tree. Similar to how +it's done with MTD, add support for defining a fixed partition table in +device tree. + +A common scenario for this is fixed block (eMMC) embedded devices that +have no MBR or GPT partition table to save storage space. Bootloader +access the block device with absolute address of data. + +This is to complete the functionality with an equivalent implementation +with providing partition table with bootargs, for case where the booargs +can't be modified and tweaking the Device Tree is the only solution to +have an usabe partition table. + +The implementation follow the fixed-partitions parser used on MTD +devices where a "partitions" node is expected to be declared with +"fixed-partitions" compatible in the OF node of the disk device +(mmc-card for eMMC for example) and each child node declare a label +and a reg with offset and size. If label is not declared, the node name +is used as fallback. Eventually is also possible to declare the read-only +property to flag the partition as read-only. + +Signed-off-by: Christian Marangi +Reviewed-by: Christoph Hellwig +Link: https://lore.kernel.org/r/20241002221306.4403-6-ansuelsmth@gmail.com +Signed-off-by: Jens Axboe +--- + block/partitions/Kconfig | 9 ++++ + block/partitions/Makefile | 1 + + block/partitions/check.h | 1 + + block/partitions/core.c | 3 ++ + block/partitions/of.c | 110 ++++++++++++++++++++++++++++++++++++++ + 5 files changed, 124 insertions(+) + create mode 100644 block/partitions/of.c + +--- a/block/partitions/Kconfig ++++ b/block/partitions/Kconfig +@@ -270,4 +270,13 @@ config CMDLINE_PARTITION + Say Y here if you want to read the partition table from bootargs. + The format for the command line is just like mtdparts. + ++config OF_PARTITION ++ bool "Device Tree partition support" if PARTITION_ADVANCED ++ depends on OF ++ help ++ Say Y here if you want to enable support for partition table ++ defined in Device Tree. (mainly for eMMC) ++ The format for the device tree node is just like MTD fixed-partition ++ schema. ++ + endmenu +--- a/block/partitions/Makefile ++++ b/block/partitions/Makefile +@@ -12,6 +12,7 @@ obj-$(CONFIG_CMDLINE_PARTITION) += cmdli + obj-$(CONFIG_MAC_PARTITION) += mac.o + obj-$(CONFIG_LDM_PARTITION) += ldm.o + obj-$(CONFIG_MSDOS_PARTITION) += msdos.o ++obj-$(CONFIG_OF_PARTITION) += of.o + obj-$(CONFIG_OSF_PARTITION) += osf.o + obj-$(CONFIG_SGI_PARTITION) += sgi.o + obj-$(CONFIG_SUN_PARTITION) += sun.o +--- a/block/partitions/check.h ++++ b/block/partitions/check.h +@@ -62,6 +62,7 @@ int karma_partition(struct parsed_partit + int ldm_partition(struct parsed_partitions *state); + int mac_partition(struct parsed_partitions *state); + int msdos_partition(struct parsed_partitions *state); ++int of_partition(struct parsed_partitions *state); + int osf_partition(struct parsed_partitions *state); + int sgi_partition(struct parsed_partitions *state); + int sun_partition(struct parsed_partitions *state); +--- a/block/partitions/core.c ++++ b/block/partitions/core.c +@@ -43,6 +43,9 @@ static int (*const check_part[])(struct + #ifdef CONFIG_CMDLINE_PARTITION + cmdline_partition, + #endif ++#ifdef CONFIG_OF_PARTITION ++ of_partition, /* cmdline have priority to OF */ ++#endif + #ifdef CONFIG_EFI_PARTITION + efi_partition, /* this must come before msdos */ + #endif +--- /dev/null ++++ b/block/partitions/of.c +@@ -0,0 +1,110 @@ ++// SPDX-License-Identifier: GPL-2.0 ++ ++#include ++#include ++#include ++#include ++#include "check.h" ++ ++static int validate_of_partition(struct device_node *np, int slot) ++{ ++ u64 offset, size; ++ int len; ++ ++ const __be32 *reg = of_get_property(np, "reg", &len); ++ int a_cells = of_n_addr_cells(np); ++ int s_cells = of_n_size_cells(np); ++ ++ /* Make sure reg len match the expected addr and size cells */ ++ if (len / sizeof(*reg) != a_cells + s_cells) ++ return -EINVAL; ++ ++ /* Validate offset conversion from bytes to sectors */ ++ offset = of_read_number(reg, a_cells); ++ if (offset % SECTOR_SIZE) ++ return -EINVAL; ++ ++ /* Validate size conversion from bytes to sectors */ ++ size = of_read_number(reg + a_cells, s_cells); ++ if (!size || size % SECTOR_SIZE) ++ return -EINVAL; ++ ++ return 0; ++} ++ ++static void add_of_partition(struct parsed_partitions *state, int slot, ++ struct device_node *np) ++{ ++ struct partition_meta_info *info; ++ char tmp[sizeof(info->volname) + 4]; ++ const char *partname; ++ int len; ++ ++ const __be32 *reg = of_get_property(np, "reg", &len); ++ int a_cells = of_n_addr_cells(np); ++ int s_cells = of_n_size_cells(np); ++ ++ /* Convert bytes to sector size */ ++ u64 offset = of_read_number(reg, a_cells) / SECTOR_SIZE; ++ u64 size = of_read_number(reg + a_cells, s_cells) / SECTOR_SIZE; ++ ++ put_partition(state, slot, offset, size); ++ ++ if (of_property_read_bool(np, "read-only")) ++ state->parts[slot].flags |= ADDPART_FLAG_READONLY; ++ ++ /* ++ * Follow MTD label logic, search for label property, ++ * fallback to node name if not found. ++ */ ++ info = &state->parts[slot].info; ++ partname = of_get_property(np, "label", &len); ++ if (!partname) ++ partname = of_get_property(np, "name", &len); ++ strscpy(info->volname, partname, sizeof(info->volname)); ++ ++ snprintf(tmp, sizeof(tmp), "(%s)", info->volname); ++ strlcat(state->pp_buf, tmp, PAGE_SIZE); ++} ++ ++int of_partition(struct parsed_partitions *state) ++{ ++ struct device *ddev = disk_to_dev(state->disk); ++ struct device_node *np; ++ int slot; ++ ++ struct device_node *partitions_np = of_node_get(ddev->of_node); ++ ++ if (!partitions_np || ++ !of_device_is_compatible(partitions_np, "fixed-partitions")) ++ return 0; ++ ++ slot = 1; ++ /* Validate parition offset and size */ ++ for_each_child_of_node(partitions_np, np) { ++ if (validate_of_partition(np, slot)) { ++ of_node_put(np); ++ of_node_put(partitions_np); ++ ++ return -1; ++ } ++ ++ slot++; ++ } ++ ++ slot = 1; ++ for_each_child_of_node(partitions_np, np) { ++ if (slot >= state->limit) { ++ of_node_put(np); ++ break; ++ } ++ ++ add_of_partition(state, slot, np); ++ ++ slot++; ++ } ++ ++ strlcat(state->pp_buf, "\n", PAGE_SIZE); ++ ++ return 1; ++} diff --git a/target/linux/generic/config-6.6 b/target/linux/generic/config-6.6 index c8bca0d0ff..f41446be6e 100644 --- a/target/linux/generic/config-6.6 +++ b/target/linux/generic/config-6.6 @@ -4358,6 +4358,7 @@ CONFIG_NLS_DEFAULT="iso8859-1" # CONFIG_OCTEONTX2_PF is not set # CONFIG_OCTEON_EP is not set # CONFIG_OF_OVERLAY is not set +CONFIG_OF_PARTITION=y CONFIG_OF_RESERVED_MEM=y # CONFIG_OF_UNITTEST is not set # CONFIG_OID_REGISTRY is not set diff --git a/target/linux/generic/pending-6.6/451-block-partitions-populate-fwnode.patch b/target/linux/generic/pending-6.6/451-block-partitions-populate-fwnode.patch index e279b71173..35b908ca6d 100644 --- a/target/linux/generic/pending-6.6/451-block-partitions-populate-fwnode.patch +++ b/target/linux/generic/pending-6.6/451-block-partitions-populate-fwnode.patch @@ -49,7 +49,7 @@ Signed-off-by: Daniel Golle #include "check.h" static int (*const check_part[])(struct parsed_partitions *) = { -@@ -292,6 +294,74 @@ static ssize_t whole_disk_show(struct de +@@ -295,6 +297,74 @@ static ssize_t whole_disk_show(struct de } static const DEVICE_ATTR(whole_disk, 0444, whole_disk_show, NULL); @@ -124,7 +124,7 @@ Signed-off-by: Daniel Golle /* * Must be called either with open_mutex held, before a disk can be opened or * after all disk users are gone. -@@ -374,6 +444,8 @@ static struct block_device *add_partitio +@@ -377,6 +447,8 @@ static struct block_device *add_partitio goto out_put; } diff --git a/target/linux/generic/pending-6.6/452-block-add-support-for-notifications.patch b/target/linux/generic/pending-6.6/452-block-add-support-for-notifications.patch index cad3fbfa90..667852e387 100644 --- a/target/linux/generic/pending-6.6/452-block-add-support-for-notifications.patch +++ b/target/linux/generic/pending-6.6/452-block-add-support-for-notifications.patch @@ -156,7 +156,7 @@ Signed-off-by: Daniel Golle +device_initcall(blk_notifications_init); --- a/include/linux/blkdev.h +++ b/include/linux/blkdev.h -@@ -1564,4 +1564,15 @@ struct io_comp_batch { +@@ -1567,4 +1567,15 @@ struct io_comp_batch { #define DEFINE_IO_COMP_BATCH(name) struct io_comp_batch name = { } diff --git a/target/linux/generic/pending-6.6/457-mmc-block-set-fwnode-of-disk-devices.patch b/target/linux/generic/pending-6.6/457-mmc-block-set-fwnode-of-disk-devices.patch index b45a0ebb1a..66f3515621 100644 --- a/target/linux/generic/pending-6.6/457-mmc-block-set-fwnode-of-disk-devices.patch +++ b/target/linux/generic/pending-6.6/457-mmc-block-set-fwnode-of-disk-devices.patch @@ -14,24 +14,14 @@ Signed-off-by: Daniel Golle --- a/drivers/mmc/core/block.c +++ b/drivers/mmc/core/block.c -@@ -2463,6 +2463,7 @@ static struct mmc_blk_data *mmc_blk_allo - int area_type, - unsigned int part_type) - { -+ struct fwnode_handle *fwnode; - struct mmc_blk_data *md; - int devidx, ret; - char cap_str[10]; -@@ -2559,6 +2560,12 @@ static struct mmc_blk_data *mmc_blk_allo - - blk_queue_write_cache(md->queue.queue, cache_enabled, fua_enabled); - -+ fwnode = device_get_named_child_node(subname ? md->parent->parent : -+ md->parent, -+ subname ? subname : "block"); -+ if (fwnode) -+ device_set_node(disk_to_dev(md->disk), fwnode); -+ - string_get_size((u64)size, 512, STRING_UNITS_2, - cap_str, sizeof(cap_str)); - pr_info("%s: %s %s %s%s\n", +@@ -2620,6 +2620,10 @@ static struct mmc_blk_data *mmc_blk_allo + if (area_type == MMC_BLK_DATA_AREA_MAIN) + dev_set_drvdata(&card->dev, md); + disk_fwnode = mmc_blk_get_partitions_node(parent, subname); ++ if (!disk_fwnode) ++ disk_fwnode = device_get_named_child_node(subname ? md->parent->parent : ++ md->parent, ++ subname ? subname : "block"); + ret = add_disk_fwnode(md->parent, md->disk, mmc_disk_attr_groups, + disk_fwnode); + if (ret) diff --git a/target/linux/generic/pending-6.6/458-mmc-block-set-GENHD_FL_NVMEM.patch b/target/linux/generic/pending-6.6/458-mmc-block-set-GENHD_FL_NVMEM.patch index 713401f104..7f9c512e45 100644 --- a/target/linux/generic/pending-6.6/458-mmc-block-set-GENHD_FL_NVMEM.patch +++ b/target/linux/generic/pending-6.6/458-mmc-block-set-GENHD_FL_NVMEM.patch @@ -12,7 +12,7 @@ Signed-off-by: Daniel Golle --- a/drivers/mmc/core/block.c +++ b/drivers/mmc/core/block.c -@@ -2516,6 +2516,7 @@ static struct mmc_blk_data *mmc_blk_allo +@@ -2566,6 +2566,7 @@ static struct mmc_blk_data *mmc_blk_allo md->disk->major = MMC_BLOCK_MAJOR; md->disk->minors = perdev_minors; md->disk->first_minor = devidx * perdev_minors; From 6b7d549dd0b9bdefdf32dfd86ad4be8cdb58cd83 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Fri, 11 Oct 2024 18:50:32 +0200 Subject: [PATCH 11/15] mt76: update to Git HEAD (2024-10-11) 513bd7683746 Revert "wifi: mt76: mt7915: disable the second PCIe link for MT7915" 703c6b78c133 wifi: mt76: mt7915: firmware restart on devices with a second pcie link Signed-off-by: Felix Fietkau --- package/kernel/mt76/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/kernel/mt76/Makefile b/package/kernel/mt76/Makefile index 957159201c..854691dbdb 100644 --- a/package/kernel/mt76/Makefile +++ b/package/kernel/mt76/Makefile @@ -8,9 +8,9 @@ PKG_LICENSE_FILES:= PKG_SOURCE_URL:=https://github.com/openwrt/mt76 PKG_SOURCE_PROTO:=git -PKG_SOURCE_DATE:=2024-10-10 -PKG_SOURCE_VERSION:=6a1199463fc8f7758c32122613288ed95c09e3bd -PKG_MIRROR_HASH:=4b42a586e098c1dc5970fbd3190ac2faf67992c7357161a3ef3040817a8ed8d6 +PKG_SOURCE_DATE:=2024-10-11 +PKG_SOURCE_VERSION:=703c6b78c133643a0e53dbd3a76d9e19f5dc3e30 +PKG_MIRROR_HASH:=df0cfa351f044d2b7083d2c27b68fd7a818bac2ea4ede7dbdea7af256e568d8e PKG_MAINTAINER:=Felix Fietkau PKG_USE_NINJA:=0 From 12f12df569ec42648ae657a280682a72cd990a70 Mon Sep 17 00:00:00 2001 From: John Audia Date: Thu, 10 Oct 2024 16:06:27 -0400 Subject: [PATCH 12/15] kernel: bump 6.6 to 6.6.55 Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.55 Added the following default ksym to target/linux/generic/config-6.6: CONFIG_PROC_MEM_ALWAYS_FORCE=y # CONFIG_PROC_MEM_FORCE_PTRACE is not set # CONFIG_PROC_MEM_NO_FORCE is not set Removed upstreamed: generic/backport-6.6/780-23-v6.12-r8169-Fix-spelling-mistake-tx_underun-tx_underrun.patch[1] generic/backport-6.6/780-25-v6.12-r8169-add-tally-counter-fields-added-with-RTL8125.patch[2] generic/pending-6.6/684-gso-fix-gso-fraglist-segmentation-after-pull-from-fr.patch[3] lantiq/patches-6.6/0025-v6.12-net-ethernet-lantiq_etop-fix-memory-disclosure.patch[4] Manually rebased: bcm27xx/patches-6.6/950-0086-Main-bcm2708-bcm2709-linux-port.patch bcm27xx/patches-6.6/950-0998-i2c-designware-Add-support-for-bus-clear-feature.patch All other patches automatically rebased. 1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.56&id=f02fcb7283b1c25f7e3ae07d7a2c830e06eb1a62 2. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.56&id=1c723d785adb711496bc64c24240f952f4faaabf 3. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.56&id=af3122f5fdc0d00581d6e598a668df6bf54c9daa 4. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v6.6.56&id=e66e38d07b31e177ca430758ed97fbc79f27d966 Build system: x86/64 Build-tested: x86/64/AMD Cezanne, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3 Run-tested: x86/64/AMD Cezanne, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3 Signed-off-by: John Audia Link: https://github.com/openwrt/openwrt/pull/16655 Signed-off-by: Nick Hainke --- include/kernel-6.6 | 4 +- ...0086-Main-bcm2708-bcm2709-linux-port.patch | 6 +- ...all-the-downstream-rpi-sound-card-dr.patch | 4 +- ...ce-quirks-for-Freeway-Airmouse-T3-an.patch | 2 +- ...ware-Add-SMBUS-quick-command-support.patch | 8 +-- ...ware-Support-non-standard-bus-speeds.patch | 2 +- ...re-Add-support-for-bus-clear-feature.patch | 18 +++--- ...tional-threaded-NAPI-wakeup-based-on.patch | 6 +- ...-to-use-SMP-threads-for-backlog-NAPI.patch | 22 ++++---- ...klog-NAPI-to-clean-up-the-defer_list.patch | 2 +- ...-net-Rename-rps_lock-to-backlog_lock.patch | 18 +++--- ...ansmit-from-devices-with-no-checksum.patch | 2 +- ...-net-Make-USO-depend-on-CSUM-offload.patch | 6 +- ...64-if-device-if-driver-is-configured.patch | 2 +- ...t-introduce-napi_is_scheduled-helper.patch | 2 +- ...8169-improve-RTL8411b-phy-down-fixup.patch | 4 +- ...-r8169-remove-multicast-filter-limit.patch | 2 +- ...169-improve-handling-task-scheduling.patch | 4 +- ...support-for-LED-s-on-RTL8168-RTL8101.patch | 8 +-- ...ix-building-with-CONFIG_LEDS_CLASS-m.patch | 2 +- ...-07-v6.9-r8169-simplify-EEE-handling.patch | 12 ++-- ...-v6.9-r8169-add-support-for-RTL8126A.patch | 44 +++++++-------- ...ode-by-using-core-provided-pcpu-stat.patch | 4 +- ...-add-LED-support-for-RTL8125-RTL8126.patch | 4 +- ...ic-rtl_set_eee_txidle_timer-function.patch | 10 ++-- ...tting-the-EEE-tx-idle-timer-on-RTL81.patch | 2 +- ...t-for-returning-tx_lpi_timer-in-etht.patch | 2 +- ...d-MODULE_FIRMWARE-entry-for-RTL8126A.patch | 2 +- ...D-related-deadlock-on-module-removal.patch | 6 +- ...g-conditional-compiling-for-call-to-.patch | 2 +- ...v6.10-r8169-add-support-for-RTL8168M.patch | 2 +- ...rites-on-dev-mtu-from-ndo_change_mtu.patch | 2 +- ...-disable-interrupt-source-RxOverflow.patch | 2 +- ...ection-of-chip-version-11-early-RTL8.patch | 2 +- ...r8169-add-support-for-RTL8126A-rev.b.patch | 42 +++++++------- ...lling-mistake-tx_underun-tx_underrun.patch | 38 ------------- ...ly-counter-fields-added-with-RTL8125.patch | 56 ------------------- ...et-free_netdev-exit-earlier-if-dummy.patch | 2 +- target/linux/generic/config-6.6 | 3 + ...680-net-add-TCP-fraglist-GRO-support.patch | 4 +- ...list-segmentation-after-pull-from-fr.patch | 53 ------------------ ...les-ignore-EOPNOTSUPP-on-flowtable-d.patch | 2 +- ...et-lantiq_etop-fix-memory-disclosure.patch | 42 -------------- .../901-arm-add-cmdline-override.patch | 2 +- ...e-unleashed-define-opp-table-cpufreq.patch | 2 +- 45 files changed, 139 insertions(+), 327 deletions(-) delete mode 100644 target/linux/generic/backport-6.6/780-23-v6.12-r8169-Fix-spelling-mistake-tx_underun-tx_underrun.patch delete mode 100644 target/linux/generic/backport-6.6/780-25-v6.12-r8169-add-tally-counter-fields-added-with-RTL8125.patch delete mode 100644 target/linux/generic/pending-6.6/684-gso-fix-gso-fraglist-segmentation-after-pull-from-fr.patch delete mode 100644 target/linux/lantiq/patches-6.6/0025-v6.12-net-ethernet-lantiq_etop-fix-memory-disclosure.patch diff --git a/include/kernel-6.6 b/include/kernel-6.6 index ee524ccdd6..49beb279c0 100644 --- a/include/kernel-6.6 +++ b/include/kernel-6.6 @@ -1,2 +1,2 @@ -LINUX_VERSION-6.6 = .54 -LINUX_KERNEL_HASH-6.6.54 = 5fae869d6a24055c16ffc2d92669e3fb2b258e34d36c850bb8cf9def417ecfa0 +LINUX_VERSION-6.6 = .55 +LINUX_KERNEL_HASH-6.6.55 = cb636a09575d0aa06dc586433a3081a3f39ed2a7fdaa3d927df7385c0fd1e09d diff --git a/target/linux/bcm27xx/patches-6.6/950-0086-Main-bcm2708-bcm2709-linux-port.patch b/target/linux/bcm27xx/patches-6.6/950-0086-Main-bcm2708-bcm2709-linux-port.patch index 22e182ba48..ad005dc2e1 100644 --- a/target/linux/bcm27xx/patches-6.6/950-0086-Main-bcm2708-bcm2709-linux-port.patch +++ b/target/linux/bcm27xx/patches-6.6/950-0086-Main-bcm2708-bcm2709-linux-port.patch @@ -125,10 +125,10 @@ board_bcm2835: Remove coherent dma pool increase - API has gone - ret = devm_request_irq(dev, irq_of_parse_and_map(dev->of_node, 0), + ret = devm_request_irq(dev, platform_get_irq(pdev, 0), - bcm2835_mbox_irq, 0, dev_name(dev), mbox); + bcm2835_mbox_irq, IRQF_NO_SUSPEND, dev_name(dev), + mbox); if (ret) { - dev_err(dev, "Failed to register a mailbox IRQ handler: %d\n", -@@ -192,7 +195,18 @@ static struct platform_driver bcm2835_mb +@@ -193,7 +196,18 @@ static struct platform_driver bcm2835_mb }, .probe = bcm2835_mbox_probe, }; diff --git a/target/linux/bcm27xx/patches-6.6/950-0106-Add-support-for-all-the-downstream-rpi-sound-card-dr.patch b/target/linux/bcm27xx/patches-6.6/950-0106-Add-support-for-all-the-downstream-rpi-sound-card-dr.patch index b35df5a381..8685508ddf 100644 --- a/target/linux/bcm27xx/patches-6.6/950-0106-Add-support-for-all-the-downstream-rpi-sound-card-dr.patch +++ b/target/linux/bcm27xx/patches-6.6/950-0106-Add-support-for-all-the-downstream-rpi-sound-card-dr.patch @@ -17565,7 +17565,7 @@ Signed-off-by: Phil Elwell } --- a/sound/usb/card.c +++ b/sound/usb/card.c -@@ -857,8 +857,14 @@ static int usb_audio_probe(struct usb_in +@@ -863,8 +863,14 @@ static int usb_audio_probe(struct usb_in if (ignore_ctl_error) chip->quirk_flags |= QUIRK_FLAG_IGNORE_CTL_ERROR; @@ -17583,7 +17583,7 @@ Signed-off-by: Phil Elwell * For devices with more than one control interface, we assume the --- a/sound/usb/quirks.c +++ b/sound/usb/quirks.c -@@ -2191,6 +2191,8 @@ static const struct usb_audio_quirk_flag +@@ -2195,6 +2195,8 @@ static const struct usb_audio_quirk_flag QUIRK_FLAG_ALIGN_TRANSFER), DEVICE_FLG(0x534d, 0x2109, /* MacroSilicon MS2109 */ QUIRK_FLAG_ALIGN_TRANSFER), diff --git a/target/linux/bcm27xx/patches-6.6/950-0169-hid-usb-Add-device-quirks-for-Freeway-Airmouse-T3-an.patch b/target/linux/bcm27xx/patches-6.6/950-0169-hid-usb-Add-device-quirks-for-Freeway-Airmouse-T3-an.patch index b102bc33fc..8a04903f7d 100644 --- a/target/linux/bcm27xx/patches-6.6/950-0169-hid-usb-Add-device-quirks-for-Freeway-Airmouse-T3-an.patch +++ b/target/linux/bcm27xx/patches-6.6/950-0169-hid-usb-Add-device-quirks-for-Freeway-Airmouse-T3-an.patch @@ -33,7 +33,7 @@ Signed-off-by: Jonathan Bell #define USB_VENDOR_ID_BELKIN 0x050d #define USB_DEVICE_ID_FLIP_KVM 0x3201 -@@ -1409,6 +1412,9 @@ +@@ -1394,6 +1397,9 @@ #define USB_VENDOR_ID_XIAOMI 0x2717 #define USB_DEVICE_ID_MI_SILENT_MOUSE 0x5014 diff --git a/target/linux/bcm27xx/patches-6.6/950-0535-i2c-designware-Add-SMBUS-quick-command-support.patch b/target/linux/bcm27xx/patches-6.6/950-0535-i2c-designware-Add-SMBUS-quick-command-support.patch index 329b837573..ed57365598 100644 --- a/target/linux/bcm27xx/patches-6.6/950-0535-i2c-designware-Add-SMBUS-quick-command-support.patch +++ b/target/linux/bcm27xx/patches-6.6/950-0535-i2c-designware-Add-SMBUS-quick-command-support.patch @@ -17,7 +17,7 @@ Signed-off-by: Phil Elwell --- a/drivers/i2c/busses/i2c-designware-core.h +++ b/drivers/i2c/busses/i2c-designware-core.h -@@ -122,7 +122,9 @@ +@@ -123,7 +123,9 @@ #define DW_IC_ERR_TX_ABRT 0x1 @@ -40,7 +40,7 @@ Signed-off-by: Phil Elwell regmap_update_bits(dev->map, DW_IC_CON, DW_IC_CON_10BITADDR_MASTER, ic_con); -@@ -472,6 +476,14 @@ i2c_dw_xfer_msg(struct dw_i2c_dev *dev) +@@ -500,6 +504,14 @@ i2c_dw_xfer_msg(struct dw_i2c_dev *dev) regmap_read(dev->map, DW_IC_RXFLR, &flr); rx_limit = dev->rx_fifo_depth - flr; @@ -55,7 +55,7 @@ Signed-off-by: Phil Elwell while (buf_len > 0 && tx_limit > 0 && rx_limit > 0) { u32 cmd = 0; -@@ -743,7 +755,7 @@ static const struct i2c_algorithm i2c_dw +@@ -781,7 +793,7 @@ static const struct i2c_algorithm i2c_dw }; static const struct i2c_adapter_quirks i2c_dw_quirks = { @@ -64,7 +64,7 @@ Signed-off-by: Phil Elwell }; static u32 i2c_dw_read_clear_intrbits(struct dw_i2c_dev *dev) -@@ -876,7 +888,8 @@ void i2c_dw_configure_master(struct dw_i +@@ -914,7 +926,8 @@ void i2c_dw_configure_master(struct dw_i { struct i2c_timings *t = &dev->timings; diff --git a/target/linux/bcm27xx/patches-6.6/950-0864-i2c-designware-Support-non-standard-bus-speeds.patch b/target/linux/bcm27xx/patches-6.6/950-0864-i2c-designware-Support-non-standard-bus-speeds.patch index 6bc3ca65d4..0e1cd5bf2a 100644 --- a/target/linux/bcm27xx/patches-6.6/950-0864-i2c-designware-Support-non-standard-bus-speeds.patch +++ b/target/linux/bcm27xx/patches-6.6/950-0864-i2c-designware-Support-non-standard-bus-speeds.patch @@ -59,7 +59,7 @@ Signed-off-by: Phil Elwell --- a/drivers/i2c/busses/i2c-designware-core.h +++ b/drivers/i2c/busses/i2c-designware-core.h -@@ -291,6 +291,7 @@ struct dw_i2c_dev { +@@ -292,6 +292,7 @@ struct dw_i2c_dev { u16 fp_lcnt; u16 hs_hcnt; u16 hs_lcnt; diff --git a/target/linux/bcm27xx/patches-6.6/950-0998-i2c-designware-Add-support-for-bus-clear-feature.patch b/target/linux/bcm27xx/patches-6.6/950-0998-i2c-designware-Add-support-for-bus-clear-feature.patch index 15bce96265..5eb4bcc5d2 100644 --- a/target/linux/bcm27xx/patches-6.6/950-0998-i2c-designware-Add-support-for-bus-clear-feature.patch +++ b/target/linux/bcm27xx/patches-6.6/950-0998-i2c-designware-Add-support-for-bus-clear-feature.patch @@ -33,7 +33,7 @@ Signed-off-by: Phil Elwell }; static int dw_reg_read(void *context, unsigned int reg, unsigned int *val) -@@ -593,8 +595,16 @@ int i2c_dw_wait_bus_not_busy(struct dw_i +@@ -607,8 +609,16 @@ int i2c_dw_wait_bus_not_busy(struct dw_i int i2c_dw_handle_tx_abort(struct dw_i2c_dev *dev) { unsigned long abort_source = dev->abort_source; @@ -50,7 +50,7 @@ Signed-off-by: Phil Elwell if (abort_source & DW_IC_TX_ABRT_NOACK) { for_each_set_bit(i, &abort_source, ARRAY_SIZE(abort_sources)) dev_dbg(dev->dev, -@@ -609,6 +619,8 @@ int i2c_dw_handle_tx_abort(struct dw_i2c +@@ -623,6 +633,8 @@ int i2c_dw_handle_tx_abort(struct dw_i2c return -EAGAIN; else if (abort_source & DW_IC_TX_ABRT_GCALL_READ) return -EINVAL; /* wrong msgs[] data */ @@ -74,11 +74,9 @@ Signed-off-by: Phil Elwell #define DW_IC_COMP_TYPE 0xfc #define DW_IC_COMP_TYPE_VALUE 0x44570140 /* "DW" + 0x0140 */ -@@ -109,13 +112,16 @@ - DW_IC_INTR_RX_UNDER | \ - DW_IC_INTR_RD_REQ) +@@ -111,12 +114,14 @@ -+#define DW_IC_ENABLE_ENABLE BIT(0) + #define DW_IC_ENABLE_ENABLE BIT(0) #define DW_IC_ENABLE_ABORT BIT(1) +#define DW_IC_ENABLE_BUS_RECOVERY BIT(3) @@ -91,7 +89,7 @@ Signed-off-by: Phil Elwell #define DW_IC_SDA_HOLD_RX_SHIFT 16 #define DW_IC_SDA_HOLD_RX_MASK GENMASK(23, 16) -@@ -163,6 +169,7 @@ +@@ -164,6 +169,7 @@ #define ABRT_SLAVE_FLUSH_TXFIFO 13 #define ABRT_SLAVE_ARBLOST 14 #define ABRT_SLAVE_RD_INTX 15 @@ -99,7 +97,7 @@ Signed-off-by: Phil Elwell #define DW_IC_TX_ABRT_7B_ADDR_NOACK BIT(ABRT_7B_ADDR_NOACK) #define DW_IC_TX_ABRT_10ADDR1_NOACK BIT(ABRT_10ADDR1_NOACK) -@@ -178,6 +185,7 @@ +@@ -179,6 +185,7 @@ #define DW_IC_RX_ABRT_SLAVE_RD_INTX BIT(ABRT_SLAVE_RD_INTX) #define DW_IC_RX_ABRT_SLAVE_ARBLOST BIT(ABRT_SLAVE_ARBLOST) #define DW_IC_RX_ABRT_SLAVE_FLUSH_TXFIFO BIT(ABRT_SLAVE_FLUSH_TXFIFO) @@ -135,7 +133,7 @@ Signed-off-by: Phil Elwell /* Write SDA hold time if supported */ if (dev->sda_hold_time) regmap_write(dev->map, DW_IC_SDA_HOLD, dev->sda_hold_time); -@@ -1033,6 +1045,7 @@ int i2c_dw_probe_master(struct dw_i2c_de +@@ -1071,6 +1083,7 @@ int i2c_dw_probe_master(struct dw_i2c_de struct i2c_adapter *adap = &dev->adapter; unsigned long irq_flags; unsigned int ic_con; @@ -143,7 +141,7 @@ Signed-off-by: Phil Elwell int ret; init_completion(&dev->cmd_complete); -@@ -1068,7 +1081,11 @@ int i2c_dw_probe_master(struct dw_i2c_de +@@ -1106,7 +1119,11 @@ int i2c_dw_probe_master(struct dw_i2c_de if (ret) return ret; diff --git a/target/linux/generic/backport-6.6/600-v6.10-net-Remove-conditional-threaded-NAPI-wakeup-based-on.patch b/target/linux/generic/backport-6.6/600-v6.10-net-Remove-conditional-threaded-NAPI-wakeup-based-on.patch index ef7963b601..3f75dffde7 100644 --- a/target/linux/generic/backport-6.6/600-v6.10-net-Remove-conditional-threaded-NAPI-wakeup-based-on.patch +++ b/target/linux/generic/backport-6.6/600-v6.10-net-Remove-conditional-threaded-NAPI-wakeup-based-on.patch @@ -32,7 +32,7 @@ Signed-off-by: Paolo Abeni --- a/net/core/dev.c +++ b/net/core/dev.c -@@ -4473,13 +4473,7 @@ static inline void ____napi_schedule(str +@@ -4477,13 +4477,7 @@ static inline void ____napi_schedule(str */ thread = READ_ONCE(napi->thread); if (thread) { @@ -47,7 +47,7 @@ Signed-off-by: Paolo Abeni wake_up_process(thread); return; } -@@ -6635,8 +6629,6 @@ static int napi_poll(struct napi_struct +@@ -6639,8 +6633,6 @@ static int napi_poll(struct napi_struct static int napi_thread_wait(struct napi_struct *napi) { @@ -56,7 +56,7 @@ Signed-off-by: Paolo Abeni set_current_state(TASK_INTERRUPTIBLE); while (!kthread_should_stop()) { -@@ -6645,15 +6637,13 @@ static int napi_thread_wait(struct napi_ +@@ -6649,15 +6641,13 @@ static int napi_thread_wait(struct napi_ * Testing SCHED bit is not enough because SCHED bit might be * set by some other busy poll thread or by napi_disable(). */ diff --git a/target/linux/generic/backport-6.6/601-v6.10-net-Allow-to-use-SMP-threads-for-backlog-NAPI.patch b/target/linux/generic/backport-6.6/601-v6.10-net-Allow-to-use-SMP-threads-for-backlog-NAPI.patch index 40e6514264..b343a3f964 100644 --- a/target/linux/generic/backport-6.6/601-v6.10-net-Allow-to-use-SMP-threads-for-backlog-NAPI.patch +++ b/target/linux/generic/backport-6.6/601-v6.10-net-Allow-to-use-SMP-threads-for-backlog-NAPI.patch @@ -108,7 +108,7 @@ Signed-off-by: Paolo Abeni static inline void rps_lock_irqsave(struct softnet_data *sd, unsigned long *flags) { -@@ -4441,6 +4467,7 @@ EXPORT_SYMBOL(__dev_direct_xmit); +@@ -4445,6 +4471,7 @@ EXPORT_SYMBOL(__dev_direct_xmit); /************************************************************************* * Receiver routines *************************************************************************/ @@ -116,7 +116,7 @@ Signed-off-by: Paolo Abeni int netdev_max_backlog __read_mostly = 1000; EXPORT_SYMBOL(netdev_max_backlog); -@@ -4473,12 +4500,16 @@ static inline void ____napi_schedule(str +@@ -4477,12 +4504,16 @@ static inline void ____napi_schedule(str */ thread = READ_ONCE(napi->thread); if (thread) { @@ -133,7 +133,7 @@ Signed-off-by: Paolo Abeni list_add_tail(&napi->poll_list, &sd->poll_list); WRITE_ONCE(napi->list_owner, smp_processor_id()); /* If not called from net_rx_action() -@@ -4724,6 +4755,11 @@ static void napi_schedule_rps(struct sof +@@ -4728,6 +4759,11 @@ static void napi_schedule_rps(struct sof #ifdef CONFIG_RPS if (sd != mysd) { @@ -145,7 +145,7 @@ Signed-off-by: Paolo Abeni sd->rps_ipi_next = mysd->rps_ipi_list; mysd->rps_ipi_list = sd; -@@ -5947,7 +5983,7 @@ static void net_rps_action_and_irq_enabl +@@ -5951,7 +5987,7 @@ static void net_rps_action_and_irq_enabl #ifdef CONFIG_RPS struct softnet_data *remsd = sd->rps_ipi_list; @@ -154,7 +154,7 @@ Signed-off-by: Paolo Abeni sd->rps_ipi_list = NULL; local_irq_enable(); -@@ -5962,7 +5998,7 @@ static void net_rps_action_and_irq_enabl +@@ -5966,7 +6002,7 @@ static void net_rps_action_and_irq_enabl static bool sd_has_rps_ipi_waiting(struct softnet_data *sd) { #ifdef CONFIG_RPS @@ -163,7 +163,7 @@ Signed-off-by: Paolo Abeni #else return false; #endif -@@ -6006,7 +6042,7 @@ static int process_backlog(struct napi_s +@@ -6010,7 +6046,7 @@ static int process_backlog(struct napi_s * We can use a plain write instead of clear_bit(), * and we dont need an smp_mb() memory barrier. */ @@ -172,7 +172,7 @@ Signed-off-by: Paolo Abeni again = false; } else { skb_queue_splice_tail_init(&sd->input_pkt_queue, -@@ -6672,43 +6708,48 @@ static void skb_defer_free_flush(struct +@@ -6676,43 +6712,48 @@ static void skb_defer_free_flush(struct } } @@ -250,7 +250,7 @@ Signed-off-by: Paolo Abeni return 0; } -@@ -11289,7 +11330,7 @@ static int dev_cpu_dead(unsigned int old +@@ -11293,7 +11334,7 @@ static int dev_cpu_dead(unsigned int old list_del_init(&napi->poll_list); if (napi->poll == process_backlog) @@ -259,7 +259,7 @@ Signed-off-by: Paolo Abeni else ____napi_schedule(sd, napi); } -@@ -11297,12 +11338,14 @@ static int dev_cpu_dead(unsigned int old +@@ -11301,12 +11342,14 @@ static int dev_cpu_dead(unsigned int old raise_softirq_irqoff(NET_TX_SOFTIRQ); local_irq_enable(); @@ -278,7 +278,7 @@ Signed-off-by: Paolo Abeni /* Process offline CPU's input_pkt_queue */ while ((skb = __skb_dequeue(&oldsd->process_queue))) { -@@ -11565,6 +11608,38 @@ static struct pernet_operations __net_in +@@ -11569,6 +11612,38 @@ static struct pernet_operations __net_in * */ @@ -317,7 +317,7 @@ Signed-off-by: Paolo Abeni /* * This is called single threaded during boot, so no need * to take the rtnl semaphore. -@@ -11615,7 +11690,10 @@ static int __init net_dev_init(void) +@@ -11619,7 +11694,10 @@ static int __init net_dev_init(void) init_gro_hash(&sd->backlog); sd->backlog.poll = process_backlog; sd->backlog.weight = weight_p; diff --git a/target/linux/generic/backport-6.6/602-v6.10-net-Use-backlog-NAPI-to-clean-up-the-defer_list.patch b/target/linux/generic/backport-6.6/602-v6.10-net-Use-backlog-NAPI-to-clean-up-the-defer_list.patch index 6a9c113124..3b1a64e4c6 100644 --- a/target/linux/generic/backport-6.6/602-v6.10-net-Use-backlog-NAPI-to-clean-up-the-defer_list.patch +++ b/target/linux/generic/backport-6.6/602-v6.10-net-Use-backlog-NAPI-to-clean-up-the-defer_list.patch @@ -82,7 +82,7 @@ Signed-off-by: Paolo Abeni spin_unlock_irq(&sd->input_pkt_queue.lock); else if (!IS_ENABLED(CONFIG_PREEMPT_RT)) local_irq_enable(); -@@ -4774,6 +4774,23 @@ static void napi_schedule_rps(struct sof +@@ -4778,6 +4778,23 @@ static void napi_schedule_rps(struct sof __napi_schedule_irqoff(&mysd->backlog); } diff --git a/target/linux/generic/backport-6.6/603-v6.10-net-Rename-rps_lock-to-backlog_lock.patch b/target/linux/generic/backport-6.6/603-v6.10-net-Rename-rps_lock-to-backlog_lock.patch index 801067287b..dab96763fc 100644 --- a/target/linux/generic/backport-6.6/603-v6.10-net-Rename-rps_lock-to-backlog_lock.patch +++ b/target/linux/generic/backport-6.6/603-v6.10-net-Rename-rps_lock-to-backlog_lock.patch @@ -67,7 +67,7 @@ Signed-off-by: Paolo Abeni { if (IS_ENABLED(CONFIG_RPS) || use_backlog_threads()) spin_unlock_irq(&sd->input_pkt_queue.lock); -@@ -4779,12 +4779,12 @@ void kick_defer_list_purge(struct softne +@@ -4783,12 +4783,12 @@ void kick_defer_list_purge(struct softne unsigned long flags; if (use_backlog_threads()) { @@ -82,7 +82,7 @@ Signed-off-by: Paolo Abeni } else if (!cmpxchg(&sd->defer_ipi_scheduled, 0, 1)) { smp_call_function_single_async(cpu, &sd->defer_csd); -@@ -4846,7 +4846,7 @@ static int enqueue_to_backlog(struct sk_ +@@ -4850,7 +4850,7 @@ static int enqueue_to_backlog(struct sk_ reason = SKB_DROP_REASON_NOT_SPECIFIED; sd = &per_cpu(softnet_data, cpu); @@ -91,7 +91,7 @@ Signed-off-by: Paolo Abeni if (!netif_running(skb->dev)) goto drop; qlen = skb_queue_len(&sd->input_pkt_queue); -@@ -4855,7 +4855,7 @@ static int enqueue_to_backlog(struct sk_ +@@ -4859,7 +4859,7 @@ static int enqueue_to_backlog(struct sk_ enqueue: __skb_queue_tail(&sd->input_pkt_queue, skb); input_queue_tail_incr_save(sd, qtail); @@ -100,7 +100,7 @@ Signed-off-by: Paolo Abeni return NET_RX_SUCCESS; } -@@ -4870,7 +4870,7 @@ enqueue: +@@ -4874,7 +4874,7 @@ enqueue: drop: sd->dropped++; @@ -109,7 +109,7 @@ Signed-off-by: Paolo Abeni dev_core_stats_rx_dropped_inc(skb->dev); kfree_skb_reason(skb, reason); -@@ -5901,7 +5901,7 @@ static void flush_backlog(struct work_st +@@ -5905,7 +5905,7 @@ static void flush_backlog(struct work_st local_bh_disable(); sd = this_cpu_ptr(&softnet_data); @@ -118,7 +118,7 @@ Signed-off-by: Paolo Abeni skb_queue_walk_safe(&sd->input_pkt_queue, skb, tmp) { if (skb->dev->reg_state == NETREG_UNREGISTERING) { __skb_unlink(skb, &sd->input_pkt_queue); -@@ -5909,7 +5909,7 @@ static void flush_backlog(struct work_st +@@ -5913,7 +5913,7 @@ static void flush_backlog(struct work_st input_queue_head_incr(sd); } } @@ -127,7 +127,7 @@ Signed-off-by: Paolo Abeni skb_queue_walk_safe(&sd->process_queue, skb, tmp) { if (skb->dev->reg_state == NETREG_UNREGISTERING) { -@@ -5927,14 +5927,14 @@ static bool flush_required(int cpu) +@@ -5931,14 +5931,14 @@ static bool flush_required(int cpu) struct softnet_data *sd = &per_cpu(softnet_data, cpu); bool do_flush; @@ -144,7 +144,7 @@ Signed-off-by: Paolo Abeni return do_flush; #endif -@@ -6049,7 +6049,7 @@ static int process_backlog(struct napi_s +@@ -6053,7 +6053,7 @@ static int process_backlog(struct napi_s } @@ -153,7 +153,7 @@ Signed-off-by: Paolo Abeni if (skb_queue_empty(&sd->input_pkt_queue)) { /* * Inline a custom version of __napi_complete(). -@@ -6065,7 +6065,7 @@ static int process_backlog(struct napi_s +@@ -6069,7 +6069,7 @@ static int process_backlog(struct napi_s skb_queue_splice_tail_init(&sd->input_pkt_queue, &sd->process_queue); } diff --git a/target/linux/generic/backport-6.6/611-01-v6.11-udp-Allow-GSO-transmit-from-devices-with-no-checksum.patch b/target/linux/generic/backport-6.6/611-01-v6.11-udp-Allow-GSO-transmit-from-devices-with-no-checksum.patch index 4a71d1203a..2f03074bc9 100644 --- a/target/linux/generic/backport-6.6/611-01-v6.11-udp-Allow-GSO-transmit-from-devices-with-no-checksum.patch +++ b/target/linux/generic/backport-6.6/611-01-v6.11-udp-Allow-GSO-transmit-from-devices-with-no-checksum.patch @@ -65,7 +65,7 @@ Signed-off-by: Jakub Kicinski } --- a/net/ipv4/udp_offload.c +++ b/net/ipv4/udp_offload.c -@@ -362,6 +362,14 @@ struct sk_buff *__udp_gso_segment(struct +@@ -380,6 +380,14 @@ struct sk_buff *__udp_gso_segment(struct else uh->check = gso_make_checksum(seg, ~check) ? : CSUM_MANGLED_0; diff --git a/target/linux/generic/backport-6.6/611-02-v6.11-net-Make-USO-depend-on-CSUM-offload.patch b/target/linux/generic/backport-6.6/611-02-v6.11-net-Make-USO-depend-on-CSUM-offload.patch index 8eecb06304..30758f180f 100644 --- a/target/linux/generic/backport-6.6/611-02-v6.11-net-Make-USO-depend-on-CSUM-offload.patch +++ b/target/linux/generic/backport-6.6/611-02-v6.11-net-Make-USO-depend-on-CSUM-offload.patch @@ -20,7 +20,7 @@ Signed-off-by: Jakub Kicinski --- a/net/core/dev.c +++ b/net/core/dev.c -@@ -9751,6 +9751,15 @@ static void netdev_sync_lower_features(s +@@ -9755,6 +9755,15 @@ static void netdev_sync_lower_features(s } } @@ -36,7 +36,7 @@ Signed-off-by: Jakub Kicinski static netdev_features_t netdev_fix_features(struct net_device *dev, netdev_features_t features) { -@@ -9832,15 +9841,9 @@ static netdev_features_t netdev_fix_feat +@@ -9836,15 +9845,9 @@ static netdev_features_t netdev_fix_feat features &= ~NETIF_F_LRO; } @@ -55,7 +55,7 @@ Signed-off-by: Jakub Kicinski } if ((features & NETIF_F_HW_TLS_RX) && !(features & NETIF_F_RXCSUM)) { -@@ -9848,6 +9851,11 @@ static netdev_features_t netdev_fix_feat +@@ -9852,6 +9855,11 @@ static netdev_features_t netdev_fix_feat features &= ~NETIF_F_HW_TLS_RX; } diff --git a/target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch b/target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch index 871154ecf8..2db89c5a05 100644 --- a/target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch +++ b/target/linux/generic/backport-6.6/612-v6.9-net-get-stats64-if-device-if-driver-is-configured.patch @@ -18,7 +18,7 @@ Signed-off-by: Paolo Abeni --- a/net/core/dev.c +++ b/net/core/dev.c -@@ -10658,6 +10658,8 @@ struct rtnl_link_stats64 *dev_get_stats( +@@ -10662,6 +10662,8 @@ struct rtnl_link_stats64 *dev_get_stats( ops->ndo_get_stats64(dev, storage); } else if (ops->ndo_get_stats) { netdev_stats_to_stats64(storage, ops->ndo_get_stats(dev)); diff --git a/target/linux/generic/backport-6.6/770-net-introduce-napi_is_scheduled-helper.patch b/target/linux/generic/backport-6.6/770-net-introduce-napi_is_scheduled-helper.patch index 6449cd6a3a..838bd03c8c 100644 --- a/target/linux/generic/backport-6.6/770-net-introduce-napi_is_scheduled-helper.patch +++ b/target/linux/generic/backport-6.6/770-net-introduce-napi_is_scheduled-helper.patch @@ -85,7 +85,7 @@ Signed-off-by: Paolo Abeni /** --- a/net/core/dev.c +++ b/net/core/dev.c -@@ -6602,7 +6602,7 @@ static int __napi_poll(struct napi_struc +@@ -6606,7 +6606,7 @@ static int __napi_poll(struct napi_struc * accidentally calling ->poll() when NAPI is not scheduled. */ work = 0; diff --git a/target/linux/generic/backport-6.6/780-01-v6.8-r8169-improve-RTL8411b-phy-down-fixup.patch b/target/linux/generic/backport-6.6/780-01-v6.8-r8169-improve-RTL8411b-phy-down-fixup.patch index 9a17fe4f78..b44627ea29 100644 --- a/target/linux/generic/backport-6.6/780-01-v6.8-r8169-improve-RTL8411b-phy-down-fixup.patch +++ b/target/linux/generic/backport-6.6/780-01-v6.8-r8169-improve-RTL8411b-phy-down-fixup.patch @@ -18,7 +18,7 @@ Signed-off-by: David S. Miller --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -3129,6 +3129,33 @@ static void rtl_hw_start_8168g_2(struct +@@ -3156,6 +3156,33 @@ static void rtl_hw_start_8168g_2(struct rtl_ephy_init(tp, e_info_8168g_2); } @@ -52,7 +52,7 @@ Signed-off-by: David S. Miller static void rtl_hw_start_8411_2(struct rtl8169_private *tp) { static const struct ephy_info e_info_8411_2[] = { -@@ -3162,117 +3189,7 @@ static void rtl_hw_start_8411_2(struct r +@@ -3189,117 +3216,7 @@ static void rtl_hw_start_8411_2(struct r mdelay(3); r8168_mac_ocp_write(tp, 0xFC26, 0x0000); diff --git a/target/linux/generic/backport-6.6/780-03-v6.8-r8169-remove-multicast-filter-limit.patch b/target/linux/generic/backport-6.6/780-03-v6.8-r8169-remove-multicast-filter-limit.patch index 4186e14e17..ad36db1372 100644 --- a/target/linux/generic/backport-6.6/780-03-v6.8-r8169-remove-multicast-filter-limit.patch +++ b/target/linux/generic/backport-6.6/780-03-v6.8-r8169-remove-multicast-filter-limit.patch @@ -35,7 +35,7 @@ Signed-off-by: Jakub Kicinski #define TX_DMA_BURST 7 /* Maximum PCI burst, '7' is unlimited */ #define InterFrameGap 0x03 /* 3 means InterFrameGap = the shortest one */ -@@ -2626,8 +2622,7 @@ static void rtl_set_rx_mode(struct net_d +@@ -2653,8 +2649,7 @@ static void rtl_set_rx_mode(struct net_d rx_mode |= AcceptAllPhys; } else if (!(dev->flags & IFF_MULTICAST)) { rx_mode &= ~AcceptMulticast; diff --git a/target/linux/generic/backport-6.6/780-04-v6.8-r8169-improve-handling-task-scheduling.patch b/target/linux/generic/backport-6.6/780-04-v6.8-r8169-improve-handling-task-scheduling.patch index a809e8213a..f020284cc8 100644 --- a/target/linux/generic/backport-6.6/780-04-v6.8-r8169-improve-handling-task-scheduling.patch +++ b/target/linux/generic/backport-6.6/780-04-v6.8-r8169-improve-handling-task-scheduling.patch @@ -19,7 +19,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -2252,6 +2252,9 @@ u16 rtl8168h_2_get_adc_bias_ioffset(stru +@@ -2279,6 +2279,9 @@ u16 rtl8168h_2_get_adc_bias_ioffset(stru static void rtl_schedule_task(struct rtl8169_private *tp, enum rtl_flag flag) { @@ -29,7 +29,7 @@ Signed-off-by: Jakub Kicinski set_bit(flag, tp->wk.flags); schedule_work(&tp->wk.work); } -@@ -4491,8 +4494,7 @@ static void rtl_task(struct work_struct +@@ -4518,8 +4521,7 @@ static void rtl_task(struct work_struct rtnl_lock(); diff --git a/target/linux/generic/backport-6.6/780-05-v6.8-r8169-add-support-for-LED-s-on-RTL8168-RTL8101.patch b/target/linux/generic/backport-6.6/780-05-v6.8-r8169-add-support-for-LED-s-on-RTL8168-RTL8101.patch index 7a5d5a66a1..95245b9a54 100644 --- a/target/linux/generic/backport-6.6/780-05-v6.8-r8169-add-support-for-LED-s-on-RTL8168-RTL8101.patch +++ b/target/linux/generic/backport-6.6/780-05-v6.8-r8169-add-support-for-LED-s-on-RTL8168-RTL8101.patch @@ -225,7 +225,7 @@ Signed-off-by: David S. Miller LED_FREQ = 0x1a, EEE_LED = 0x1b, ERIDR = 0x70, -@@ -616,6 +617,7 @@ struct rtl8169_private { +@@ -643,6 +644,7 @@ struct rtl8169_private { raw_spinlock_t config25_lock; raw_spinlock_t mac_ocp_lock; @@ -233,7 +233,7 @@ Signed-off-by: David S. Miller raw_spinlock_t cfg9346_usage_lock; int cfg9346_usage_count; -@@ -788,6 +790,62 @@ static const struct rtl_cond name = { +@@ -815,6 +817,62 @@ static const struct rtl_cond name = { \ static bool name ## _check(struct rtl8169_private *tp) @@ -296,7 +296,7 @@ Signed-off-by: David S. Miller static void r8168fp_adjust_ocp_cmd(struct rtl8169_private *tp, u32 *cmd, int type) { /* based on RTL8168FP_OOBMAC_BASE in vendor driver */ -@@ -5168,6 +5226,7 @@ static int rtl_init_one(struct pci_dev * +@@ -5195,6 +5253,7 @@ static int rtl_init_one(struct pci_dev * raw_spin_lock_init(&tp->cfg9346_usage_lock); raw_spin_lock_init(&tp->config25_lock); raw_spin_lock_init(&tp->mac_ocp_lock); @@ -304,7 +304,7 @@ Signed-off-by: David S. Miller dev->tstats = devm_netdev_alloc_pcpu_stats(&pdev->dev, struct pcpu_sw_netstats); -@@ -5324,6 +5383,12 @@ static int rtl_init_one(struct pci_dev * +@@ -5351,6 +5410,12 @@ static int rtl_init_one(struct pci_dev * if (rc) return rc; diff --git a/target/linux/generic/backport-6.6/780-06-v6.8-r8169-fix-building-with-CONFIG_LEDS_CLASS-m.patch b/target/linux/generic/backport-6.6/780-06-v6.8-r8169-fix-building-with-CONFIG_LEDS_CLASS-m.patch index 67f215cadf..819a611cb3 100644 --- a/target/linux/generic/backport-6.6/780-06-v6.8-r8169-fix-building-with-CONFIG_LEDS_CLASS-m.patch +++ b/target/linux/generic/backport-6.6/780-06-v6.8-r8169-fix-building-with-CONFIG_LEDS_CLASS-m.patch @@ -59,7 +59,7 @@ Signed-off-by: Jakub Kicinski obj-$(CONFIG_R8169) += r8169.o --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -5383,11 +5383,10 @@ static int rtl_init_one(struct pci_dev * +@@ -5410,11 +5410,10 @@ static int rtl_init_one(struct pci_dev * if (rc) return rc; diff --git a/target/linux/generic/backport-6.6/780-07-v6.9-r8169-simplify-EEE-handling.patch b/target/linux/generic/backport-6.6/780-07-v6.9-r8169-simplify-EEE-handling.patch index bdd3330580..d3a26303ef 100644 --- a/target/linux/generic/backport-6.6/780-07-v6.9-r8169-simplify-EEE-handling.patch +++ b/target/linux/generic/backport-6.6/780-07-v6.9-r8169-simplify-EEE-handling.patch @@ -16,7 +16,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -629,7 +629,6 @@ struct rtl8169_private { +@@ -656,7 +656,6 @@ struct rtl8169_private { struct rtl8169_counters *counters; struct rtl8169_tc_offsets tc_offset; u32 saved_wolopts; @@ -24,7 +24,7 @@ Signed-off-by: Jakub Kicinski const char *fw_name; struct rtl_fw *rtl_fw; -@@ -2010,17 +2009,11 @@ static int rtl8169_get_eee(struct net_de +@@ -2037,17 +2036,11 @@ static int rtl8169_get_eee(struct net_de static int rtl8169_set_eee(struct net_device *dev, struct ethtool_eee *data) { struct rtl8169_private *tp = netdev_priv(dev); @@ -43,7 +43,7 @@ Signed-off-by: Jakub Kicinski } static void rtl8169_get_ringparam(struct net_device *dev, -@@ -2085,21 +2078,6 @@ static const struct ethtool_ops rtl8169_ +@@ -2112,21 +2105,6 @@ static const struct ethtool_ops rtl8169_ .set_pauseparam = rtl8169_set_pauseparam, }; @@ -65,7 +65,7 @@ Signed-off-by: Jakub Kicinski static enum mac_version rtl8169_get_mac_version(u16 xid, bool gmii) { /* -@@ -2336,9 +2314,6 @@ static void rtl8169_init_phy(struct rtl8 +@@ -2363,9 +2341,6 @@ static void rtl8169_init_phy(struct rtl8 /* We may have called phy_speed_down before */ phy_speed_up(tp->phydev); @@ -75,7 +75,7 @@ Signed-off-by: Jakub Kicinski genphy_soft_reset(tp->phydev); } -@@ -5085,7 +5060,9 @@ static int r8169_mdio_register(struct rt +@@ -5112,7 +5087,9 @@ static int r8169_mdio_register(struct rt } tp->phydev->mac_managed_pm = true; @@ -86,7 +86,7 @@ Signed-off-by: Jakub Kicinski phy_support_asym_pause(tp->phydev); /* PHY will be woken up in rtl_open() */ -@@ -5220,7 +5197,6 @@ static int rtl_init_one(struct pci_dev * +@@ -5247,7 +5224,6 @@ static int rtl_init_one(struct pci_dev * tp->dev = dev; tp->pci_dev = pdev; tp->supports_gmii = ent->driver_data == RTL_CFG_NO_GBIT ? 0 : 1; diff --git a/target/linux/generic/backport-6.6/780-08-v6.9-r8169-add-support-for-RTL8126A.patch b/target/linux/generic/backport-6.6/780-08-v6.9-r8169-add-support-for-RTL8126A.patch index 63f135e393..6dfaa904a1 100644 --- a/target/linux/generic/backport-6.6/780-08-v6.9-r8169-add-support-for-RTL8126A.patch +++ b/target/linux/generic/backport-6.6/780-08-v6.9-r8169-add-support-for-RTL8126A.patch @@ -65,7 +65,7 @@ Signed-off-by: David S. Miller TxPoll_8125 = 0x90, MAC0_BKP = 0x19e0, EEE_TXIDLE_TIMER_8125 = 0x6048, -@@ -1139,7 +1146,7 @@ static void rtl_writephy(struct rtl8169_ +@@ -1166,7 +1173,7 @@ static void rtl_writephy(struct rtl8169_ case RTL_GIGA_MAC_VER_31: r8168dp_2_mdio_write(tp, location, val); break; @@ -74,7 +74,7 @@ Signed-off-by: David S. Miller r8168g_mdio_write(tp, location, val); break; default: -@@ -1154,7 +1161,7 @@ static int rtl_readphy(struct rtl8169_pr +@@ -1181,7 +1188,7 @@ static int rtl_readphy(struct rtl8169_pr case RTL_GIGA_MAC_VER_28: case RTL_GIGA_MAC_VER_31: return r8168dp_2_mdio_read(tp, location); @@ -83,7 +83,7 @@ Signed-off-by: David S. Miller return r8168g_mdio_read(tp, location); default: return r8169_mdio_read(tp, location); -@@ -1363,7 +1370,7 @@ static void rtl_set_d3_pll_down(struct r +@@ -1390,7 +1397,7 @@ static void rtl_set_d3_pll_down(struct r case RTL_GIGA_MAC_VER_25 ... RTL_GIGA_MAC_VER_26: case RTL_GIGA_MAC_VER_29 ... RTL_GIGA_MAC_VER_30: case RTL_GIGA_MAC_VER_32 ... RTL_GIGA_MAC_VER_37: @@ -92,7 +92,7 @@ Signed-off-by: David S. Miller if (enable) RTL_W8(tp, PMCH, RTL_R8(tp, PMCH) & ~D3_NO_PLL_DOWN); else -@@ -1530,7 +1537,7 @@ static void __rtl8169_set_wol(struct rtl +@@ -1557,7 +1564,7 @@ static void __rtl8169_set_wol(struct rtl break; case RTL_GIGA_MAC_VER_34: case RTL_GIGA_MAC_VER_37: @@ -101,7 +101,7 @@ Signed-off-by: David S. Miller if (wolopts) rtl_mod_config2(tp, 0, PME_SIGNAL); else -@@ -2096,6 +2103,9 @@ static enum mac_version rtl8169_get_mac_ +@@ -2123,6 +2130,9 @@ static enum mac_version rtl8169_get_mac_ u16 val; enum mac_version ver; } mac_info[] = { @@ -111,7 +111,7 @@ Signed-off-by: David S. Miller /* 8125B family. */ { 0x7cf, 0x641, RTL_GIGA_MAC_VER_63 }, -@@ -2366,6 +2376,7 @@ static void rtl_init_rxcfg(struct rtl816 +@@ -2393,6 +2403,7 @@ static void rtl_init_rxcfg(struct rtl816 RTL_W32(tp, RxConfig, RX_FETCH_DFLT_8125 | RX_DMA_BURST); break; case RTL_GIGA_MAC_VER_63: @@ -119,7 +119,7 @@ Signed-off-by: David S. Miller RTL_W32(tp, RxConfig, RX_FETCH_DFLT_8125 | RX_DMA_BURST | RX_PAUSE_SLOT_ON); break; -@@ -2552,7 +2563,7 @@ static void rtl_wait_txrx_fifo_empty(str +@@ -2579,7 +2590,7 @@ static void rtl_wait_txrx_fifo_empty(str case RTL_GIGA_MAC_VER_61 ... RTL_GIGA_MAC_VER_61: rtl_loop_wait_high(tp, &rtl_rxtx_empty_cond, 100, 42); break; @@ -128,7 +128,7 @@ Signed-off-by: David S. Miller RTL_W8(tp, ChipCmd, RTL_R8(tp, ChipCmd) | StopReq); rtl_loop_wait_high(tp, &rtl_rxtx_empty_cond, 100, 42); rtl_loop_wait_high(tp, &rtl_rxtx_empty_cond_2, 100, 42); -@@ -2795,7 +2806,7 @@ static void rtl_enable_exit_l1(struct rt +@@ -2822,7 +2833,7 @@ static void rtl_enable_exit_l1(struct rt case RTL_GIGA_MAC_VER_37 ... RTL_GIGA_MAC_VER_38: rtl_eri_set_bits(tp, 0xd4, 0x0c00); break; @@ -137,7 +137,7 @@ Signed-off-by: David S. Miller r8168_mac_ocp_modify(tp, 0xc0ac, 0, 0x1f80); break; default: -@@ -2809,7 +2820,7 @@ static void rtl_disable_exit_l1(struct r +@@ -2836,7 +2847,7 @@ static void rtl_disable_exit_l1(struct r case RTL_GIGA_MAC_VER_34 ... RTL_GIGA_MAC_VER_38: rtl_eri_clear_bits(tp, 0xd4, 0x1f00); break; @@ -146,7 +146,7 @@ Signed-off-by: David S. Miller r8168_mac_ocp_modify(tp, 0xc0ac, 0x1f80, 0); break; default: -@@ -2819,6 +2830,8 @@ static void rtl_disable_exit_l1(struct r +@@ -2846,6 +2857,8 @@ static void rtl_disable_exit_l1(struct r static void rtl_hw_aspm_clkreq_enable(struct rtl8169_private *tp, bool enable) { @@ -155,7 +155,7 @@ Signed-off-by: David S. Miller if (tp->mac_version < RTL_GIGA_MAC_VER_32) return; -@@ -2832,11 +2845,19 @@ static void rtl_hw_aspm_clkreq_enable(st +@@ -2859,11 +2872,19 @@ static void rtl_hw_aspm_clkreq_enable(st return; rtl_mod_config5(tp, 0, ASPM_en); @@ -177,7 +177,7 @@ Signed-off-by: David S. Miller /* reset ephy tx/rx disable timer */ r8168_mac_ocp_modify(tp, 0xe094, 0xff00, 0); /* chip can trigger L1.2 */ -@@ -2848,14 +2869,22 @@ static void rtl_hw_aspm_clkreq_enable(st +@@ -2875,14 +2896,22 @@ static void rtl_hw_aspm_clkreq_enable(st } else { switch (tp->mac_version) { case RTL_GIGA_MAC_VER_46 ... RTL_GIGA_MAC_VER_48: @@ -202,7 +202,7 @@ Signed-off-by: David S. Miller rtl_mod_config5(tp, ASPM_en, 0); } } -@@ -3568,10 +3597,15 @@ static void rtl_hw_start_8125_common(str +@@ -3595,10 +3624,15 @@ static void rtl_hw_start_8125_common(str /* disable new tx descriptor format */ r8168_mac_ocp_modify(tp, 0xeb58, 0x0001, 0x0000); @@ -220,7 +220,7 @@ Signed-off-by: David S. Miller if (tp->mac_version == RTL_GIGA_MAC_VER_63) r8168_mac_ocp_modify(tp, 0xe63e, 0x0c30, 0x0000); -@@ -3584,6 +3618,10 @@ static void rtl_hw_start_8125_common(str +@@ -3611,6 +3645,10 @@ static void rtl_hw_start_8125_common(str r8168_mac_ocp_modify(tp, 0xe056, 0x00f0, 0x0030); r8168_mac_ocp_modify(tp, 0xe040, 0x1000, 0x0000); r8168_mac_ocp_modify(tp, 0xea1c, 0x0003, 0x0001); @@ -231,7 +231,7 @@ Signed-off-by: David S. Miller r8168_mac_ocp_modify(tp, 0xe0c0, 0x4f0f, 0x4403); r8168_mac_ocp_modify(tp, 0xe052, 0x0080, 0x0068); r8168_mac_ocp_modify(tp, 0xd430, 0x0fff, 0x047f); -@@ -3598,10 +3636,10 @@ static void rtl_hw_start_8125_common(str +@@ -3625,10 +3663,10 @@ static void rtl_hw_start_8125_common(str rtl_loop_wait_low(tp, &rtl_mac_ocp_e00e_cond, 1000, 10); @@ -245,7 +245,7 @@ Signed-off-by: David S. Miller rtl_disable_rxdvgate(tp); } -@@ -3645,6 +3683,12 @@ static void rtl_hw_start_8125b(struct rt +@@ -3672,6 +3710,12 @@ static void rtl_hw_start_8125b(struct rt rtl_hw_start_8125_common(tp); } @@ -258,7 +258,7 @@ Signed-off-by: David S. Miller static void rtl_hw_config(struct rtl8169_private *tp) { static const rtl_generic_fct hw_configs[] = { -@@ -3687,6 +3731,7 @@ static void rtl_hw_config(struct rtl8169 +@@ -3714,6 +3758,7 @@ static void rtl_hw_config(struct rtl8169 [RTL_GIGA_MAC_VER_53] = rtl_hw_start_8117, [RTL_GIGA_MAC_VER_61] = rtl_hw_start_8125a_2, [RTL_GIGA_MAC_VER_63] = rtl_hw_start_8125b, @@ -266,7 +266,7 @@ Signed-off-by: David S. Miller }; if (hw_configs[tp->mac_version]) -@@ -3697,9 +3742,23 @@ static void rtl_hw_start_8125(struct rtl +@@ -3724,9 +3769,23 @@ static void rtl_hw_start_8125(struct rtl { int i; @@ -292,7 +292,7 @@ Signed-off-by: David S. Miller rtl_hw_config(tp); } -@@ -3777,8 +3836,7 @@ static int rtl8169_change_mtu(struct net +@@ -3804,8 +3863,7 @@ static int rtl8169_change_mtu(struct net rtl_jumbo_config(tp); switch (tp->mac_version) { @@ -302,7 +302,7 @@ Signed-off-by: David S. Miller rtl8125_set_eee_txidle_timer(tp); break; default: -@@ -3927,7 +3985,7 @@ static void rtl8169_cleanup(struct rtl81 +@@ -3954,7 +4012,7 @@ static void rtl8169_cleanup(struct rtl81 RTL_W8(tp, ChipCmd, RTL_R8(tp, ChipCmd) | StopReq); rtl_loop_wait_high(tp, &rtl_txcfg_empty_cond, 100, 666); break; @@ -311,7 +311,7 @@ Signed-off-by: David S. Miller rtl_enable_rxdvgate(tp); fsleep(2000); break; -@@ -4078,8 +4136,7 @@ static unsigned int rtl_quirk_packet_pad +@@ -4105,8 +4163,7 @@ static unsigned int rtl_quirk_packet_pad switch (tp->mac_version) { case RTL_GIGA_MAC_VER_34: @@ -321,7 +321,7 @@ Signed-off-by: David S. Miller padto = max_t(unsigned int, padto, ETH_ZLEN); break; default: -@@ -5112,7 +5169,7 @@ static void rtl_hw_initialize(struct rtl +@@ -5139,7 +5196,7 @@ static void rtl_hw_initialize(struct rtl case RTL_GIGA_MAC_VER_40 ... RTL_GIGA_MAC_VER_48: rtl_hw_init_8168g(tp); break; diff --git a/target/linux/generic/backport-6.6/780-10-v6.9-r8169-simplify-code-by-using-core-provided-pcpu-stat.patch b/target/linux/generic/backport-6.6/780-10-v6.9-r8169-simplify-code-by-using-core-provided-pcpu-stat.patch index 510123767a..0288dcb11e 100644 --- a/target/linux/generic/backport-6.6/780-10-v6.9-r8169-simplify-code-by-using-core-provided-pcpu-stat.patch +++ b/target/linux/generic/backport-6.6/780-10-v6.9-r8169-simplify-code-by-using-core-provided-pcpu-stat.patch @@ -16,7 +16,7 @@ Signed-off-by: Paolo Abeni --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -5261,11 +5261,6 @@ static int rtl_init_one(struct pci_dev * +@@ -5288,11 +5288,6 @@ static int rtl_init_one(struct pci_dev * raw_spin_lock_init(&tp->mac_ocp_lock); mutex_init(&tp->led_lock); @@ -28,7 +28,7 @@ Signed-off-by: Paolo Abeni /* Get the *optional* external "ether_clk" used on some boards */ tp->clk = devm_clk_get_optional_enabled(&pdev->dev, "ether_clk"); if (IS_ERR(tp->clk)) -@@ -5380,6 +5375,8 @@ static int rtl_init_one(struct pci_dev * +@@ -5407,6 +5402,8 @@ static int rtl_init_one(struct pci_dev * dev->hw_features |= NETIF_F_RXALL; dev->hw_features |= NETIF_F_RXFCS; diff --git a/target/linux/generic/backport-6.6/780-11-v6.9-r8169-add-LED-support-for-RTL8125-RTL8126.patch b/target/linux/generic/backport-6.6/780-11-v6.9-r8169-add-LED-support-for-RTL8125-RTL8126.patch index 2059551b50..449aa11591 100644 --- a/target/linux/generic/backport-6.6/780-11-v6.9-r8169-add-LED-support-for-RTL8125-RTL8126.patch +++ b/target/linux/generic/backport-6.6/780-11-v6.9-r8169-add-LED-support-for-RTL8125-RTL8126.patch @@ -173,7 +173,7 @@ Signed-off-by: Jakub Kicinski #define RX_VLAN_INNER_8125 BIT(22) #define RX_VLAN_OUTER_8125 BIT(23) #define RX_VLAN_8125 (RX_VLAN_INNER_8125 | RX_VLAN_OUTER_8125) -@@ -830,6 +836,51 @@ int rtl8168_get_led_mode(struct rtl8169_ +@@ -857,6 +863,51 @@ int rtl8168_get_led_mode(struct rtl8169_ return ret; } @@ -225,7 +225,7 @@ Signed-off-by: Jakub Kicinski void r8169_get_led_name(struct rtl8169_private *tp, int idx, char *buf, int buf_len) { -@@ -5413,10 +5464,12 @@ static int rtl_init_one(struct pci_dev * +@@ -5440,10 +5491,12 @@ static int rtl_init_one(struct pci_dev * if (rc) return rc; diff --git a/target/linux/generic/backport-6.6/780-12-v6.9-r8169-add-generic-rtl_set_eee_txidle_timer-function.patch b/target/linux/generic/backport-6.6/780-12-v6.9-r8169-add-generic-rtl_set_eee_txidle_timer-function.patch index 1a7eed191f..5f762f7729 100644 --- a/target/linux/generic/backport-6.6/780-12-v6.9-r8169-add-generic-rtl_set_eee_txidle_timer-function.patch +++ b/target/linux/generic/backport-6.6/780-12-v6.9-r8169-add-generic-rtl_set_eee_txidle_timer-function.patch @@ -18,7 +18,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -619,6 +619,7 @@ struct rtl8169_private { +@@ -646,6 +646,7 @@ struct rtl8169_private { struct page *Rx_databuff[NUM_RX_DESC]; /* Rx data buffers */ struct ring_info tx_skb[NUM_TX_DESC]; /* Tx data buffers */ u16 cp_cmd; @@ -26,7 +26,7 @@ Signed-off-by: Jakub Kicinski u32 irq_mask; int irq; struct clk *clk; -@@ -2054,6 +2055,22 @@ static int rtl_set_coalesce(struct net_d +@@ -2081,6 +2082,22 @@ static int rtl_set_coalesce(struct net_d return 0; } @@ -49,7 +49,7 @@ Signed-off-by: Jakub Kicinski static int rtl8169_get_eee(struct net_device *dev, struct ethtool_eee *data) { struct rtl8169_private *tp = netdev_priv(dev); -@@ -2312,14 +2329,8 @@ static void rtl8125a_config_eee_mac(stru +@@ -2339,14 +2356,8 @@ static void rtl8125a_config_eee_mac(stru r8168_mac_ocp_modify(tp, 0xeb62, 0, BIT(2) | BIT(1)); } @@ -64,7 +64,7 @@ Signed-off-by: Jakub Kicinski r8168_mac_ocp_modify(tp, 0xe040, 0, BIT(1) | BIT(0)); } -@@ -3852,6 +3863,8 @@ static void rtl_hw_start(struct rtl8169 +@@ -3879,6 +3890,8 @@ static void rtl_hw_start(struct rtl8169 rtl_hw_aspm_clkreq_enable(tp, false); RTL_W16(tp, CPlusCmd, tp->cp_cmd); @@ -73,7 +73,7 @@ Signed-off-by: Jakub Kicinski if (tp->mac_version <= RTL_GIGA_MAC_VER_06) rtl_hw_start_8169(tp); else if (rtl_is_8125(tp)) -@@ -3885,14 +3898,7 @@ static int rtl8169_change_mtu(struct net +@@ -3912,14 +3925,7 @@ static int rtl8169_change_mtu(struct net dev->mtu = new_mtu; netdev_update_features(dev); rtl_jumbo_config(tp); diff --git a/target/linux/generic/backport-6.6/780-13-v6.9-r8169-support-setting-the-EEE-tx-idle-timer-on-RTL81.patch b/target/linux/generic/backport-6.6/780-13-v6.9-r8169-support-setting-the-EEE-tx-idle-timer-on-RTL81.patch index 917c7c194f..8669dd2fea 100644 --- a/target/linux/generic/backport-6.6/780-13-v6.9-r8169-support-setting-the-EEE-tx-idle-timer-on-RTL81.patch +++ b/target/linux/generic/backport-6.6/780-13-v6.9-r8169-support-setting-the-EEE-tx-idle-timer-on-RTL81.patch @@ -16,7 +16,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -2060,6 +2060,11 @@ static void rtl_set_eee_txidle_timer(str +@@ -2087,6 +2087,11 @@ static void rtl_set_eee_txidle_timer(str unsigned int timer_val = READ_ONCE(tp->dev->mtu) + ETH_HLEN + 0x20; switch (tp->mac_version) { diff --git a/target/linux/generic/backport-6.6/780-14-v6.9-r8169-add-support-for-returning-tx_lpi_timer-in-etht.patch b/target/linux/generic/backport-6.6/780-14-v6.9-r8169-add-support-for-returning-tx_lpi_timer-in-etht.patch index 51477d0142..1a27bd190f 100644 --- a/target/linux/generic/backport-6.6/780-14-v6.9-r8169-add-support-for-returning-tx_lpi_timer-in-etht.patch +++ b/target/linux/generic/backport-6.6/780-14-v6.9-r8169-add-support-for-returning-tx_lpi_timer-in-etht.patch @@ -17,7 +17,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -2076,14 +2076,34 @@ static void rtl_set_eee_txidle_timer(str +@@ -2103,14 +2103,34 @@ static void rtl_set_eee_txidle_timer(str } } diff --git a/target/linux/generic/backport-6.6/780-15-v6.9-r8169-add-MODULE_FIRMWARE-entry-for-RTL8126A.patch b/target/linux/generic/backport-6.6/780-15-v6.9-r8169-add-MODULE_FIRMWARE-entry-for-RTL8126A.patch index 6a7ebc885b..da33372306 100644 --- a/target/linux/generic/backport-6.6/780-15-v6.9-r8169-add-MODULE_FIRMWARE-entry-for-RTL8126A.patch +++ b/target/linux/generic/backport-6.6/780-15-v6.9-r8169-add-MODULE_FIRMWARE-entry-for-RTL8126A.patch @@ -15,7 +15,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -676,6 +676,7 @@ MODULE_FIRMWARE(FIRMWARE_8168FP_3); +@@ -703,6 +703,7 @@ MODULE_FIRMWARE(FIRMWARE_8168FP_3); MODULE_FIRMWARE(FIRMWARE_8107E_2); MODULE_FIRMWARE(FIRMWARE_8125A_3); MODULE_FIRMWARE(FIRMWARE_8125B_2); diff --git a/target/linux/generic/backport-6.6/780-16-v6.9-r8169-fix-LED-related-deadlock-on-module-removal.patch b/target/linux/generic/backport-6.6/780-16-v6.9-r8169-fix-LED-related-deadlock-on-module-removal.patch index d8e4a4f6ff..6e0ff9b14b 100644 --- a/target/linux/generic/backport-6.6/780-16-v6.9-r8169-fix-LED-related-deadlock-on-module-removal.patch +++ b/target/linux/generic/backport-6.6/780-16-v6.9-r8169-fix-LED-related-deadlock-on-module-removal.patch @@ -115,7 +115,7 @@ Signed-off-by: David S. Miller } --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -647,6 +647,8 @@ struct rtl8169_private { +@@ -674,6 +674,8 @@ struct rtl8169_private { const char *fw_name; struct rtl_fw *rtl_fw; @@ -124,7 +124,7 @@ Signed-off-by: David S. Miller u32 ocp_base; }; -@@ -5040,6 +5042,8 @@ static void rtl_remove_one(struct pci_de +@@ -5067,6 +5069,8 @@ static void rtl_remove_one(struct pci_de cancel_work_sync(&tp->wk.work); @@ -133,7 +133,7 @@ Signed-off-by: David S. Miller unregister_netdev(tp->dev); if (tp->dash_type != RTL_DASH_NONE) -@@ -5498,9 +5502,9 @@ static int rtl_init_one(struct pci_dev * +@@ -5525,9 +5529,9 @@ static int rtl_init_one(struct pci_dev * if (IS_ENABLED(CONFIG_R8169_LEDS)) { if (rtl_is_8125(tp)) diff --git a/target/linux/generic/backport-6.6/780-17-v6.9-r8169-add-missing-conditional-compiling-for-call-to-.patch b/target/linux/generic/backport-6.6/780-17-v6.9-r8169-add-missing-conditional-compiling-for-call-to-.patch index 366ae803f9..e647e18167 100644 --- a/target/linux/generic/backport-6.6/780-17-v6.9-r8169-add-missing-conditional-compiling-for-call-to-.patch +++ b/target/linux/generic/backport-6.6/780-17-v6.9-r8169-add-missing-conditional-compiling-for-call-to-.patch @@ -19,7 +19,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -5042,7 +5042,8 @@ static void rtl_remove_one(struct pci_de +@@ -5069,7 +5069,8 @@ static void rtl_remove_one(struct pci_de cancel_work_sync(&tp->wk.work); diff --git a/target/linux/generic/backport-6.6/780-18-v6.10-r8169-add-support-for-RTL8168M.patch b/target/linux/generic/backport-6.6/780-18-v6.10-r8169-add-support-for-RTL8168M.patch index 2abbe2ccf1..95455ee2cb 100644 --- a/target/linux/generic/backport-6.6/780-18-v6.10-r8169-add-support-for-RTL8168M.patch +++ b/target/linux/generic/backport-6.6/780-18-v6.10-r8169-add-support-for-RTL8168M.patch @@ -19,7 +19,7 @@ Signed-off-by: David S. Miller --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -2230,6 +2230,8 @@ static enum mac_version rtl8169_get_mac_ +@@ -2257,6 +2257,8 @@ static enum mac_version rtl8169_get_mac_ * the wild. Let's disable detection. * { 0x7cf, 0x540, RTL_GIGA_MAC_VER_45 }, */ diff --git a/target/linux/generic/backport-6.6/780-19-v6.10-net-annotate-writes-on-dev-mtu-from-ndo_change_mtu.patch b/target/linux/generic/backport-6.6/780-19-v6.10-net-annotate-writes-on-dev-mtu-from-ndo_change_mtu.patch index cad1210e4d..4c05976d2e 100644 --- a/target/linux/generic/backport-6.6/780-19-v6.10-net-annotate-writes-on-dev-mtu-from-ndo_change_mtu.patch +++ b/target/linux/generic/backport-6.6/780-19-v6.10-net-annotate-writes-on-dev-mtu-from-ndo_change_mtu.patch @@ -49,7 +49,7 @@ Signed-off-by: Jakub Kicinski } --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -3925,7 +3925,7 @@ static int rtl8169_change_mtu(struct net +@@ -3952,7 +3952,7 @@ static int rtl8169_change_mtu(struct net { struct rtl8169_private *tp = netdev_priv(dev); diff --git a/target/linux/generic/backport-6.6/780-20-v6.11-r8169-disable-interrupt-source-RxOverflow.patch b/target/linux/generic/backport-6.6/780-20-v6.11-r8169-disable-interrupt-source-RxOverflow.patch index cef5d95252..9389585f16 100644 --- a/target/linux/generic/backport-6.6/780-20-v6.11-r8169-disable-interrupt-source-RxOverflow.patch +++ b/target/linux/generic/backport-6.6/780-20-v6.11-r8169-disable-interrupt-source-RxOverflow.patch @@ -18,7 +18,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -5083,12 +5083,10 @@ static void rtl_set_irq_mask(struct rtl8 +@@ -5110,12 +5110,10 @@ static void rtl_set_irq_mask(struct rtl8 tp->irq_mask = RxOK | RxErr | TxOK | TxErr | LinkChg; if (tp->mac_version <= RTL_GIGA_MAC_VER_06) diff --git a/target/linux/generic/backport-6.6/780-21-v6.11-r8169-remove-detection-of-chip-version-11-early-RTL8.patch b/target/linux/generic/backport-6.6/780-21-v6.11-r8169-remove-detection-of-chip-version-11-early-RTL8.patch index 7f0f23fccb..5e9e765a7e 100644 --- a/target/linux/generic/backport-6.6/780-21-v6.11-r8169-remove-detection-of-chip-version-11-early-RTL8.patch +++ b/target/linux/generic/backport-6.6/780-21-v6.11-r8169-remove-detection-of-chip-version-11-early-RTL8.patch @@ -19,7 +19,7 @@ Signed-off-by: Jakub Kicinski --- a/drivers/net/ethernet/realtek/r8169_main.c +++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -2275,7 +2275,9 @@ static enum mac_version rtl8169_get_mac_ +@@ -2302,7 +2302,9 @@ static enum mac_version rtl8169_get_mac_ /* 8168B family. */ { 0x7c8, 0x380, RTL_GIGA_MAC_VER_17 }, diff --git a/target/linux/generic/backport-6.6/780-22-v6.12-r8169-add-support-for-RTL8126A-rev.b.patch b/target/linux/generic/backport-6.6/780-22-v6.12-r8169-add-support-for-RTL8126A-rev.b.patch index d15edf85e1..0915cb729f 100644 --- a/target/linux/generic/backport-6.6/780-22-v6.12-r8169-add-support-for-RTL8126A-rev.b.patch +++ b/target/linux/generic/backport-6.6/780-22-v6.12-r8169-add-support-for-RTL8126A-rev.b.patch @@ -44,7 +44,7 @@ Signed-off-by: Jakub Kicinski }; static const struct pci_device_id rtl8169_pci_tbl[] = { -@@ -1201,7 +1203,7 @@ static void rtl_writephy(struct rtl8169_ +@@ -1228,7 +1230,7 @@ static void rtl_writephy(struct rtl8169_ case RTL_GIGA_MAC_VER_31: r8168dp_2_mdio_write(tp, location, val); break; @@ -53,7 +53,7 @@ Signed-off-by: Jakub Kicinski r8168g_mdio_write(tp, location, val); break; default: -@@ -1216,7 +1218,7 @@ static int rtl_readphy(struct rtl8169_pr +@@ -1243,7 +1245,7 @@ static int rtl_readphy(struct rtl8169_pr case RTL_GIGA_MAC_VER_28: case RTL_GIGA_MAC_VER_31: return r8168dp_2_mdio_read(tp, location); @@ -62,7 +62,7 @@ Signed-off-by: Jakub Kicinski return r8168g_mdio_read(tp, location); default: return r8169_mdio_read(tp, location); -@@ -1425,7 +1427,7 @@ static void rtl_set_d3_pll_down(struct r +@@ -1452,7 +1454,7 @@ static void rtl_set_d3_pll_down(struct r case RTL_GIGA_MAC_VER_25 ... RTL_GIGA_MAC_VER_26: case RTL_GIGA_MAC_VER_29 ... RTL_GIGA_MAC_VER_30: case RTL_GIGA_MAC_VER_32 ... RTL_GIGA_MAC_VER_37: @@ -71,7 +71,7 @@ Signed-off-by: Jakub Kicinski if (enable) RTL_W8(tp, PMCH, RTL_R8(tp, PMCH) & ~D3_NO_PLL_DOWN); else -@@ -1592,7 +1594,7 @@ static void __rtl8169_set_wol(struct rtl +@@ -1619,7 +1621,7 @@ static void __rtl8169_set_wol(struct rtl break; case RTL_GIGA_MAC_VER_34: case RTL_GIGA_MAC_VER_37: @@ -80,7 +80,7 @@ Signed-off-by: Jakub Kicinski if (wolopts) rtl_mod_config2(tp, 0, PME_SIGNAL); else -@@ -2071,6 +2073,7 @@ static void rtl_set_eee_txidle_timer(str +@@ -2098,6 +2100,7 @@ static void rtl_set_eee_txidle_timer(str case RTL_GIGA_MAC_VER_61: case RTL_GIGA_MAC_VER_63: case RTL_GIGA_MAC_VER_65: @@ -88,7 +88,7 @@ Signed-off-by: Jakub Kicinski tp->tx_lpi_timer = timer_val; RTL_W16(tp, EEE_TXIDLE_TIMER_8125, timer_val); break; -@@ -2200,6 +2203,7 @@ static enum mac_version rtl8169_get_mac_ +@@ -2227,6 +2230,7 @@ static enum mac_version rtl8169_get_mac_ enum mac_version ver; } mac_info[] = { /* 8126A family. */ @@ -96,7 +96,7 @@ Signed-off-by: Jakub Kicinski { 0x7cf, 0x649, RTL_GIGA_MAC_VER_65 }, /* 8125B family. */ -@@ -2471,6 +2475,7 @@ static void rtl_init_rxcfg(struct rtl816 +@@ -2498,6 +2502,7 @@ static void rtl_init_rxcfg(struct rtl816 break; case RTL_GIGA_MAC_VER_63: case RTL_GIGA_MAC_VER_65: @@ -104,7 +104,7 @@ Signed-off-by: Jakub Kicinski RTL_W32(tp, RxConfig, RX_FETCH_DFLT_8125 | RX_DMA_BURST | RX_PAUSE_SLOT_ON); break; -@@ -2657,7 +2662,7 @@ static void rtl_wait_txrx_fifo_empty(str +@@ -2684,7 +2689,7 @@ static void rtl_wait_txrx_fifo_empty(str case RTL_GIGA_MAC_VER_61 ... RTL_GIGA_MAC_VER_61: rtl_loop_wait_high(tp, &rtl_rxtx_empty_cond, 100, 42); break; @@ -113,7 +113,7 @@ Signed-off-by: Jakub Kicinski RTL_W8(tp, ChipCmd, RTL_R8(tp, ChipCmd) | StopReq); rtl_loop_wait_high(tp, &rtl_rxtx_empty_cond, 100, 42); rtl_loop_wait_high(tp, &rtl_rxtx_empty_cond_2, 100, 42); -@@ -2900,7 +2905,7 @@ static void rtl_enable_exit_l1(struct rt +@@ -2927,7 +2932,7 @@ static void rtl_enable_exit_l1(struct rt case RTL_GIGA_MAC_VER_37 ... RTL_GIGA_MAC_VER_38: rtl_eri_set_bits(tp, 0xd4, 0x0c00); break; @@ -122,7 +122,7 @@ Signed-off-by: Jakub Kicinski r8168_mac_ocp_modify(tp, 0xc0ac, 0, 0x1f80); break; default: -@@ -2914,7 +2919,7 @@ static void rtl_disable_exit_l1(struct r +@@ -2941,7 +2946,7 @@ static void rtl_disable_exit_l1(struct r case RTL_GIGA_MAC_VER_34 ... RTL_GIGA_MAC_VER_38: rtl_eri_clear_bits(tp, 0xd4, 0x1f00); break; @@ -131,7 +131,7 @@ Signed-off-by: Jakub Kicinski r8168_mac_ocp_modify(tp, 0xc0ac, 0x1f80, 0); break; default: -@@ -2941,6 +2946,7 @@ static void rtl_hw_aspm_clkreq_enable(st +@@ -2968,6 +2973,7 @@ static void rtl_hw_aspm_clkreq_enable(st rtl_mod_config5(tp, 0, ASPM_en); switch (tp->mac_version) { case RTL_GIGA_MAC_VER_65: @@ -139,7 +139,7 @@ Signed-off-by: Jakub Kicinski val8 = RTL_R8(tp, INT_CFG0_8125) | INT_CFG0_CLKREQEN; RTL_W8(tp, INT_CFG0_8125, val8); break; -@@ -2951,7 +2957,7 @@ static void rtl_hw_aspm_clkreq_enable(st +@@ -2978,7 +2984,7 @@ static void rtl_hw_aspm_clkreq_enable(st switch (tp->mac_version) { case RTL_GIGA_MAC_VER_46 ... RTL_GIGA_MAC_VER_48: @@ -148,7 +148,7 @@ Signed-off-by: Jakub Kicinski /* reset ephy tx/rx disable timer */ r8168_mac_ocp_modify(tp, 0xe094, 0xff00, 0); /* chip can trigger L1.2 */ -@@ -2963,7 +2969,7 @@ static void rtl_hw_aspm_clkreq_enable(st +@@ -2990,7 +2996,7 @@ static void rtl_hw_aspm_clkreq_enable(st } else { switch (tp->mac_version) { case RTL_GIGA_MAC_VER_46 ... RTL_GIGA_MAC_VER_48: @@ -157,7 +157,7 @@ Signed-off-by: Jakub Kicinski r8168_mac_ocp_modify(tp, 0xe092, 0x00ff, 0); break; default: -@@ -2972,6 +2978,7 @@ static void rtl_hw_aspm_clkreq_enable(st +@@ -2999,6 +3005,7 @@ static void rtl_hw_aspm_clkreq_enable(st switch (tp->mac_version) { case RTL_GIGA_MAC_VER_65: @@ -165,7 +165,7 @@ Signed-off-by: Jakub Kicinski val8 = RTL_R8(tp, INT_CFG0_8125) & ~INT_CFG0_CLKREQEN; RTL_W8(tp, INT_CFG0_8125, val8); break; -@@ -3691,10 +3698,12 @@ static void rtl_hw_start_8125_common(str +@@ -3718,10 +3725,12 @@ static void rtl_hw_start_8125_common(str /* disable new tx descriptor format */ r8168_mac_ocp_modify(tp, 0xeb58, 0x0001, 0x0000); @@ -180,7 +180,7 @@ Signed-off-by: Jakub Kicinski r8168_mac_ocp_modify(tp, 0xe614, 0x0700, 0x0400); else if (tp->mac_version == RTL_GIGA_MAC_VER_63) r8168_mac_ocp_modify(tp, 0xe614, 0x0700, 0x0200); -@@ -3712,7 +3721,8 @@ static void rtl_hw_start_8125_common(str +@@ -3739,7 +3748,8 @@ static void rtl_hw_start_8125_common(str r8168_mac_ocp_modify(tp, 0xe056, 0x00f0, 0x0030); r8168_mac_ocp_modify(tp, 0xe040, 0x1000, 0x0000); r8168_mac_ocp_modify(tp, 0xea1c, 0x0003, 0x0001); @@ -190,7 +190,7 @@ Signed-off-by: Jakub Kicinski r8168_mac_ocp_modify(tp, 0xea1c, 0x0300, 0x0000); else r8168_mac_ocp_modify(tp, 0xea1c, 0x0004, 0x0000); -@@ -3826,6 +3836,7 @@ static void rtl_hw_config(struct rtl8169 +@@ -3853,6 +3863,7 @@ static void rtl_hw_config(struct rtl8169 [RTL_GIGA_MAC_VER_61] = rtl_hw_start_8125a_2, [RTL_GIGA_MAC_VER_63] = rtl_hw_start_8125b, [RTL_GIGA_MAC_VER_65] = rtl_hw_start_8126a, @@ -198,7 +198,7 @@ Signed-off-by: Jakub Kicinski }; if (hw_configs[tp->mac_version]) -@@ -3846,6 +3857,7 @@ static void rtl_hw_start_8125(struct rtl +@@ -3873,6 +3884,7 @@ static void rtl_hw_start_8125(struct rtl break; case RTL_GIGA_MAC_VER_63: case RTL_GIGA_MAC_VER_65: @@ -206,7 +206,7 @@ Signed-off-by: Jakub Kicinski for (i = 0xa00; i < 0xa80; i += 4) RTL_W32(tp, i, 0); RTL_W16(tp, INT_CFG1_8125, 0x0000); -@@ -4074,7 +4086,7 @@ static void rtl8169_cleanup(struct rtl81 +@@ -4101,7 +4113,7 @@ static void rtl8169_cleanup(struct rtl81 RTL_W8(tp, ChipCmd, RTL_R8(tp, ChipCmd) | StopReq); rtl_loop_wait_high(tp, &rtl_txcfg_empty_cond, 100, 666); break; @@ -215,7 +215,7 @@ Signed-off-by: Jakub Kicinski rtl_enable_rxdvgate(tp); fsleep(2000); break; -@@ -4225,7 +4237,7 @@ static unsigned int rtl_quirk_packet_pad +@@ -4252,7 +4264,7 @@ static unsigned int rtl_quirk_packet_pad switch (tp->mac_version) { case RTL_GIGA_MAC_VER_34: @@ -224,7 +224,7 @@ Signed-off-by: Jakub Kicinski padto = max_t(unsigned int, padto, ETH_ZLEN); break; default: -@@ -5259,7 +5271,7 @@ static void rtl_hw_initialize(struct rtl +@@ -5286,7 +5298,7 @@ static void rtl_hw_initialize(struct rtl case RTL_GIGA_MAC_VER_40 ... RTL_GIGA_MAC_VER_48: rtl_hw_init_8168g(tp); break; diff --git a/target/linux/generic/backport-6.6/780-23-v6.12-r8169-Fix-spelling-mistake-tx_underun-tx_underrun.patch b/target/linux/generic/backport-6.6/780-23-v6.12-r8169-Fix-spelling-mistake-tx_underun-tx_underrun.patch deleted file mode 100644 index 9d0992fcbb..0000000000 --- a/target/linux/generic/backport-6.6/780-23-v6.12-r8169-Fix-spelling-mistake-tx_underun-tx_underrun.patch +++ /dev/null @@ -1,38 +0,0 @@ -From 8df9439389a44fb2cc4ef695e08d6a8870b1616c Mon Sep 17 00:00:00 2001 -From: Colin Ian King -Date: Mon, 9 Sep 2024 15:00:21 +0100 -Subject: [PATCH 44/47] r8169: Fix spelling mistake: "tx_underun" -> - "tx_underrun" - -There is a spelling mistake in the struct field tx_underun, rename -it to tx_underrun. - -Signed-off-by: Colin Ian King -Reviewed-by: Simon Horman -Reviewed-by: Heiner Kallweit -Link: https://patch.msgid.link/20240909140021.64884-1-colin.i.king@gmail.com -Signed-off-by: Jakub Kicinski ---- - drivers/net/ethernet/realtek/r8169_main.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - ---- a/drivers/net/ethernet/realtek/r8169_main.c -+++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -578,7 +578,7 @@ struct rtl8169_counters { - __le64 rx_broadcast; - __le32 rx_multicast; - __le16 tx_aborted; -- __le16 tx_underun; -+ __le16 tx_underrun; - }; - - struct rtl8169_tc_offsets { -@@ -1843,7 +1843,7 @@ static void rtl8169_get_ethtool_stats(st - data[9] = le64_to_cpu(counters->rx_broadcast); - data[10] = le32_to_cpu(counters->rx_multicast); - data[11] = le16_to_cpu(counters->tx_aborted); -- data[12] = le16_to_cpu(counters->tx_underun); -+ data[12] = le16_to_cpu(counters->tx_underrun); - } - - static void rtl8169_get_strings(struct net_device *dev, u32 stringset, u8 *data) diff --git a/target/linux/generic/backport-6.6/780-25-v6.12-r8169-add-tally-counter-fields-added-with-RTL8125.patch b/target/linux/generic/backport-6.6/780-25-v6.12-r8169-add-tally-counter-fields-added-with-RTL8125.patch deleted file mode 100644 index 3b1110fb67..0000000000 --- a/target/linux/generic/backport-6.6/780-25-v6.12-r8169-add-tally-counter-fields-added-with-RTL8125.patch +++ /dev/null @@ -1,56 +0,0 @@ -From ced8e8b8f40accfcce4a2bbd8b150aa76d5eff9a Mon Sep 17 00:00:00 2001 -From: Heiner Kallweit -Date: Tue, 17 Sep 2024 23:04:46 +0200 -Subject: [PATCH 46/47] r8169: add tally counter fields added with RTL8125 - -RTL8125 added fields to the tally counter, what may result in the chip -dma'ing these new fields to unallocated memory. Therefore make sure -that the allocated memory area is big enough to hold all of the -tally counter values, even if we use only parts of it. - -Fixes: f1bce4ad2f1c ("r8169: add support for RTL8125") -Cc: stable@vger.kernel.org -Signed-off-by: Heiner Kallweit -Reviewed-by: Simon Horman -Link: https://patch.msgid.link/741d26a9-2b2b-485d-91d9-ecb302e345b5@gmail.com -Signed-off-by: Paolo Abeni ---- - drivers/net/ethernet/realtek/r8169_main.c | 27 +++++++++++++++++++++++ - 1 file changed, 27 insertions(+) - ---- a/drivers/net/ethernet/realtek/r8169_main.c -+++ b/drivers/net/ethernet/realtek/r8169_main.c -@@ -579,6 +579,33 @@ struct rtl8169_counters { - __le32 rx_multicast; - __le16 tx_aborted; - __le16 tx_underrun; -+ /* new since RTL8125 */ -+ __le64 tx_octets; -+ __le64 rx_octets; -+ __le64 rx_multicast64; -+ __le64 tx_unicast64; -+ __le64 tx_broadcast64; -+ __le64 tx_multicast64; -+ __le32 tx_pause_on; -+ __le32 tx_pause_off; -+ __le32 tx_pause_all; -+ __le32 tx_deferred; -+ __le32 tx_late_collision; -+ __le32 tx_all_collision; -+ __le32 tx_aborted32; -+ __le32 align_errors32; -+ __le32 rx_frame_too_long; -+ __le32 rx_runt; -+ __le32 rx_pause_on; -+ __le32 rx_pause_off; -+ __le32 rx_pause_all; -+ __le32 rx_unknown_opcode; -+ __le32 rx_mac_error; -+ __le32 tx_underrun32; -+ __le32 rx_mac_missed; -+ __le32 rx_tcam_dropped; -+ __le32 tdu; -+ __le32 rdu; - }; - - struct rtl8169_tc_offsets { diff --git a/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch b/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch index 53f313044a..52d6ff1e44 100644 --- a/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch +++ b/target/linux/generic/backport-6.6/900-v6.11-net-free_netdev-exit-earlier-if-dummy.patch @@ -23,7 +23,7 @@ Signed-off-by: David S. Miller --- a/net/core/dev.c +++ b/net/core/dev.c -@@ -10968,7 +10968,8 @@ void free_netdev(struct net_device *dev) +@@ -10972,7 +10972,8 @@ void free_netdev(struct net_device *dev) dev->xdp_bulkq = NULL; /* Compatibility with error handling in drivers */ diff --git a/target/linux/generic/config-6.6 b/target/linux/generic/config-6.6 index f41446be6e..0118b8dfba 100644 --- a/target/linux/generic/config-6.6 +++ b/target/linux/generic/config-6.6 @@ -4732,6 +4732,9 @@ CONFIG_PRINT_STACK_DEPTH=64 # CONFIG_PROC_CHILDREN is not set CONFIG_PROC_FS=y # CONFIG_PROC_KCORE is not set +CONFIG_PROC_MEM_ALWAYS_FORCE=y +# CONFIG_PROC_MEM_FORCE_PTRACE is not set +# CONFIG_PROC_MEM_NO_FORCE is not set # CONFIG_PROC_PAGE_MONITOR is not set # CONFIG_PROC_STRIPPED is not set CONFIG_PROC_SYSCTL=y diff --git a/target/linux/generic/pending-6.6/680-net-add-TCP-fraglist-GRO-support.patch b/target/linux/generic/pending-6.6/680-net-add-TCP-fraglist-GRO-support.patch index 68ebf4e68a..b810e7ec91 100644 --- a/target/linux/generic/pending-6.6/680-net-add-TCP-fraglist-GRO-support.patch +++ b/target/linux/generic/pending-6.6/680-net-add-TCP-fraglist-GRO-support.patch @@ -45,7 +45,7 @@ Signe-off-by: Felix Fietkau INDIRECT_CALLABLE_DECLARE(int tcp6_gro_complete(struct sk_buff *skb, int thoff)); --- a/net/core/gro.c +++ b/net/core/gro.c -@@ -233,6 +233,33 @@ done: +@@ -228,6 +228,33 @@ done: return 0; } @@ -379,7 +379,7 @@ Signe-off-by: Felix Fietkau skb_shinfo(skb)->gso_type |= SKB_GSO_TCPV4; --- a/net/ipv4/udp_offload.c +++ b/net/ipv4/udp_offload.c -@@ -452,33 +452,6 @@ out: +@@ -470,33 +470,6 @@ out: return segs; } diff --git a/target/linux/generic/pending-6.6/684-gso-fix-gso-fraglist-segmentation-after-pull-from-fr.patch b/target/linux/generic/pending-6.6/684-gso-fix-gso-fraglist-segmentation-after-pull-from-fr.patch deleted file mode 100644 index 5a7ba07fd0..0000000000 --- a/target/linux/generic/pending-6.6/684-gso-fix-gso-fraglist-segmentation-after-pull-from-fr.patch +++ /dev/null @@ -1,53 +0,0 @@ -From: Willem de Bruijn -Date: Sun, 22 Sep 2024 11:03:45 -0400 -Subject: [PATCH] gso: fix gso fraglist segmentation after pull from - frag_list - -Detect gso fraglist skbs with corrupted geometry (see below) and -pass these to skb_segment instead of skb_segment_list, as the first -can segment them correctly. - -Valid SKB_GSO_FRAGLIST skbs -- consist of two or more segments -- the head_skb holds the protocol headers plus first gso_size -- one or more frag_list skbs hold exactly one segment -- all but the last must be gso_size - -Optional datapath hooks such as NAT and BPF (bpf_skb_pull_data) can -modify these skbs, breaking these invariants. - -In extreme cases they pull all data into skb linear. For UDP, this -causes a NULL ptr deref in __udpv4_gso_segment_list_csum at -udp_hdr(seg->next)->dest. - -Detect invalid geometry due to pull, by checking head_skb size. -Don't just drop, as this may blackhole a destination. Convert to be -able to pass to regular skb_segment. - -Link: https://lore.kernel.org/netdev/20240428142913.18666-1-shiming.cheng@mediatek.com/ -Fixes: 3a1296a38d0c ("net: Support GRO/GSO fraglist chaining.") -Signed-off-by: Willem de Bruijn -Cc: stable@vger.kernel.org ---- - ---- a/net/ipv4/udp_offload.c -+++ b/net/ipv4/udp_offload.c -@@ -296,8 +296,16 @@ struct sk_buff *__udp_gso_segment(struct - return NULL; - } - -- if (skb_shinfo(gso_skb)->gso_type & SKB_GSO_FRAGLIST) -- return __udp_gso_segment_list(gso_skb, features, is_ipv6); -+ if (skb_shinfo(gso_skb)->gso_type & SKB_GSO_FRAGLIST) { -+ /* Detect modified geometry and pass these to skb_segment. */ -+ if (skb_pagelen(gso_skb) - sizeof(*uh) == skb_shinfo(gso_skb)->gso_size) -+ return __udp_gso_segment_list(gso_skb, features, is_ipv6); -+ -+ /* Setup csum, as fraglist skips this in udp4_gro_receive. */ -+ gso_skb->csum_start = skb_transport_header(gso_skb) - gso_skb->head; -+ gso_skb->csum_offset = offsetof(struct udphdr, check); -+ gso_skb->ip_summed = CHECKSUM_PARTIAL; -+ } - - skb_pull(gso_skb, sizeof(*uh)); - diff --git a/target/linux/generic/pending-6.6/701-netfilter-nf_tables-ignore-EOPNOTSUPP-on-flowtable-d.patch b/target/linux/generic/pending-6.6/701-netfilter-nf_tables-ignore-EOPNOTSUPP-on-flowtable-d.patch index 2b9543da6d..f27581d3e9 100644 --- a/target/linux/generic/pending-6.6/701-netfilter-nf_tables-ignore-EOPNOTSUPP-on-flowtable-d.patch +++ b/target/linux/generic/pending-6.6/701-netfilter-nf_tables-ignore-EOPNOTSUPP-on-flowtable-d.patch @@ -18,7 +18,7 @@ Signed-off-by: Felix Fietkau --- a/net/netfilter/nf_tables_api.c +++ b/net/netfilter/nf_tables_api.c -@@ -8333,7 +8333,7 @@ static int nft_register_flowtable_net_ho +@@ -8376,7 +8376,7 @@ static int nft_register_flowtable_net_ho err = flowtable->data.type->setup(&flowtable->data, hook->ops.dev, FLOW_BLOCK_BIND); diff --git a/target/linux/lantiq/patches-6.6/0025-v6.12-net-ethernet-lantiq_etop-fix-memory-disclosure.patch b/target/linux/lantiq/patches-6.6/0025-v6.12-net-ethernet-lantiq_etop-fix-memory-disclosure.patch deleted file mode 100644 index 3b2ac25065..0000000000 --- a/target/linux/lantiq/patches-6.6/0025-v6.12-net-ethernet-lantiq_etop-fix-memory-disclosure.patch +++ /dev/null @@ -1,42 +0,0 @@ -From 45c0de18ff2dc9af01236380404bbd6a46502c69 Mon Sep 17 00:00:00 2001 -From: Aleksander Jan Bajkowski -Date: Mon, 23 Sep 2024 23:49:49 +0200 -Subject: net: ethernet: lantiq_etop: fix memory disclosure - -When applying padding, the buffer is not zeroed, which results in memory -disclosure. The mentioned data is observed on the wire. This patch uses -skb_put_padto() to pad Ethernet frames properly. The mentioned function -zeroes the expanded buffer. - -In case the packet cannot be padded it is silently dropped. Statistics -are also not incremented. This driver does not support statistics in the -old 32-bit format or the new 64-bit format. These will be added in the -future. In its current form, the patch should be easily backported to -stable versions. - -Ethernet MACs on Amazon-SE and Danube cannot do padding of the packets -in hardware, so software padding must be applied. - -Fixes: 504d4721ee8e ("MIPS: Lantiq: Add ethernet driver") -Signed-off-by: Aleksander Jan Bajkowski -Reviewed-by: Jacob Keller -Reviewed-by: Florian Fainelli -Link: https://patch.msgid.link/20240923214949.231511-2-olek2@wp.pl -Signed-off-by: Paolo Abeni ---- - drivers/net/ethernet/lantiq_etop.c | 4 +++- - 1 file changed, 3 insertions(+), 1 deletion(-) - ---- a/drivers/net/ethernet/lantiq_etop.c -+++ b/drivers/net/ethernet/lantiq_etop.c -@@ -482,7 +482,9 @@ ltq_etop_tx(struct sk_buff *skb, struct - unsigned long flags; - u32 byte_offset; - -- len = skb->len < ETH_ZLEN ? ETH_ZLEN : skb->len; -+ if (skb_put_padto(skb, ETH_ZLEN)) -+ return NETDEV_TX_OK; -+ len = skb->len; - - if ((desc->ctl & (LTQ_DMA_OWN | LTQ_DMA_C)) || ch->skb[ch->dma.desc]) { - netdev_err(dev, "tx ring full\n"); diff --git a/target/linux/mediatek/patches-6.6/901-arm-add-cmdline-override.patch b/target/linux/mediatek/patches-6.6/901-arm-add-cmdline-override.patch index 21bbed88d7..034826253d 100644 --- a/target/linux/mediatek/patches-6.6/901-arm-add-cmdline-override.patch +++ b/target/linux/mediatek/patches-6.6/901-arm-add-cmdline-override.patch @@ -37,7 +37,7 @@ * CONFIG_CMDLINE is meant to be a default in case nothing else --- a/arch/arm64/Kconfig +++ b/arch/arm64/Kconfig -@@ -2307,6 +2307,14 @@ config CMDLINE_FORCE +@@ -2308,6 +2308,14 @@ config CMDLINE_FORCE endchoice diff --git a/target/linux/sifiveu/patches-6.6/0005-riscv-sifive-unleashed-define-opp-table-cpufreq.patch b/target/linux/sifiveu/patches-6.6/0005-riscv-sifive-unleashed-define-opp-table-cpufreq.patch index 90dcb0e3e4..905e3cccb7 100644 --- a/target/linux/sifiveu/patches-6.6/0005-riscv-sifive-unleashed-define-opp-table-cpufreq.patch +++ b/target/linux/sifiveu/patches-6.6/0005-riscv-sifive-unleashed-define-opp-table-cpufreq.patch @@ -14,7 +14,7 @@ Signed-off-by: David Abdurachmanov --- a/arch/riscv/Kconfig +++ b/arch/riscv/Kconfig -@@ -897,6 +897,14 @@ config PORTABLE +@@ -901,6 +901,14 @@ config PORTABLE select MMU select OF From 16bf650d50c5609b3855820d0ade84444e4d320f Mon Sep 17 00:00:00 2001 From: John Audia Date: Thu, 10 Oct 2024 17:20:15 -0400 Subject: [PATCH 13/15] kernel: bump 6.6 to 6.6.56 Changelog: https://cdn.kernel.org/pub/linux/kernel/v6.x/ChangeLog-6.6.56 No patches needed a rebase Build system: x86/64 Build-tested: x86/64/AMD Cezanne, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3 Run-tested: x86/64/AMD Cezanne, flogic/xiaomi_redmi-router-ax6000-ubootmod, ramips/tplink_archer-a6-v3 Signed-off-by: John Audia Link: https://github.com/openwrt/openwrt/pull/16655 Signed-off-by: Nick Hainke --- include/kernel-6.6 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/include/kernel-6.6 b/include/kernel-6.6 index 49beb279c0..6f72804b87 100644 --- a/include/kernel-6.6 +++ b/include/kernel-6.6 @@ -1,2 +1,2 @@ -LINUX_VERSION-6.6 = .55 -LINUX_KERNEL_HASH-6.6.55 = cb636a09575d0aa06dc586433a3081a3f39ed2a7fdaa3d927df7385c0fd1e09d +LINUX_VERSION-6.6 = .56 +LINUX_KERNEL_HASH-6.6.56 = f74812f78e88992c416434cb107639e13a551dbaff36bb90d6346ab16ab71a95 From 6c35333316c4a59f0648a6a27f09c282039844f2 Mon Sep 17 00:00:00 2001 From: Felix Fietkau Date: Fri, 11 Oct 2024 20:03:23 +0200 Subject: [PATCH 14/15] mt76: update to Git HEAD (2024-10-11.1) ecca0e77b4bc wifi: mt76: mt7915: fix omac index assignment after hardware reset Signed-off-by: Felix Fietkau --- package/kernel/mt76/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/package/kernel/mt76/Makefile b/package/kernel/mt76/Makefile index 854691dbdb..73f34d8eda 100644 --- a/package/kernel/mt76/Makefile +++ b/package/kernel/mt76/Makefile @@ -8,9 +8,9 @@ PKG_LICENSE_FILES:= PKG_SOURCE_URL:=https://github.com/openwrt/mt76 PKG_SOURCE_PROTO:=git -PKG_SOURCE_DATE:=2024-10-11 -PKG_SOURCE_VERSION:=703c6b78c133643a0e53dbd3a76d9e19f5dc3e30 -PKG_MIRROR_HASH:=df0cfa351f044d2b7083d2c27b68fd7a818bac2ea4ede7dbdea7af256e568d8e +PKG_SOURCE_DATE:=2024-10-11.1 +PKG_SOURCE_VERSION:=ecca0e77b4bce629ec1f79d83bbd14a68f919188 +PKG_MIRROR_HASH:=770823f282c76532567a651bb020208c3ddd5a728c656fcde43129fc95edf538 PKG_MAINTAINER:=Felix Fietkau PKG_USE_NINJA:=0 From 3d7040b7d69cefaccbd7f58c686853e6d3db31f8 Mon Sep 17 00:00:00 2001 From: Markus Stockhausen Date: Fri, 11 Oct 2024 15:11:43 -0400 Subject: [PATCH 15/15] realtek: scripts: fix error in belkin-header For some reason the new belkin-header.py script works without issues in a local Fedora build environment. In the OpenWrt build pipeline it produces the following errors: Traceback (most recent call last): File "/builder/shared-workdir/build/scripts/belkin-header.py", line 92, in head = create_header(buf, args.belkin_header, args.belkin_model) File "/builder/shared-workdir/build/scripts/belkin-header.py", line 68, in create_header head[28:29] = VERSION1.to_bytes(1) TypeError: to_bytes() missing required argument 'byteorder' (pos 2) This may be related due to different python version. Fix this by handing over the needed parameters Signed-off-by: Markus Stockhausen Link: https://github.com/openwrt/openwrt/pull/16667 Signed-off-by: Robert Marko --- scripts/belkin-header.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/scripts/belkin-header.py b/scripts/belkin-header.py index 4dc3d2652e..f62d55cab7 100755 --- a/scripts/belkin-header.py +++ b/scripts/belkin-header.py @@ -35,7 +35,7 @@ COMPANY = "belkin" MODULE = "IMG" def xcrc32(buf): - return (0xffffffff - zlib.crc32(buf, 0xffffffff)).to_bytes(4, 'big') + return (0xffffffff - zlib.crc32(buf, 0xffffffff)).to_bytes(4, byteorder='big') def encode_model(model): map = " 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-" @@ -63,12 +63,12 @@ def create_header(buf, belkin_header, belkin_model): head[0:4] = int(belkin_header, 0).to_bytes(4, 'big') head[8:12] = int(time.time()).to_bytes(4, 'big') - head[12:16] = len(buf).to_bytes(4, 'big') + head[12:16] = len(buf).to_bytes(4, byteorder='big') head[24:28] = xcrc32(buf) - head[28:29] = VERSION1.to_bytes(1) - head[29:30] = VERSION2.to_bytes(1) - head[30:31] = VERSION3.to_bytes(1) - head[31:32] = VERSION4.to_bytes(1) + head[28:29] = VERSION1.to_bytes(1, byteorder='big') + head[29:30] = VERSION2.to_bytes(1, byteorder='big') + head[30:31] = VERSION3.to_bytes(1, byteorder='big') + head[31:32] = VERSION4.to_bytes(1, byteorder='big') head[16:16 + len(COMPANY)] = bytes(COMPANY,'ascii') mod = MODULE + "-{:1d}.{:02d}.{:02d}.{:02d}".format(VERSION1, VERSION2, VERSION3, VERSION4)