From 242527372d690c529eedecc2bae02be8181e36de Mon Sep 17 00:00:00 2001 From: elecboy Date: Thu, 13 Jul 2023 09:53:02 +0800 Subject: [PATCH] 5.10 switch to v5.10/standard/base; add uart_ao_b-pins --- .../0001-add-sports-cle-v40-v41-dts.patch | 1094 +++++++++++++++++ recipes-kernel/linux/linux-yocto_5.10.bb | 10 +- .../linux/linux-yocto_5.10.bbappend | 2 +- 3 files changed, 1100 insertions(+), 6 deletions(-) create mode 100644 recipes-kernel/linux/linux-yocto/0001-add-sports-cle-v40-v41-dts.patch diff --git a/recipes-kernel/linux/linux-yocto/0001-add-sports-cle-v40-v41-dts.patch b/recipes-kernel/linux/linux-yocto/0001-add-sports-cle-v40-v41-dts.patch new file mode 100644 index 0000000..9196fdc --- /dev/null +++ b/recipes-kernel/linux/linux-yocto/0001-add-sports-cle-v40-v41-dts.patch @@ -0,0 +1,1094 @@ +From cd7a8efb5cdcf54ad3ccd5bb30aca385ef81f2fb Mon Sep 17 00:00:00 2001 +From: elecboy +Date: Thu, 13 Jul 2023 08:14:15 +0800 +Subject: [PATCH] add sports cle v40/v41 dts + +--- + arch/arm64/boot/dts/amlogic/Makefile | 3 + + .../dts/amlogic/meson-g12b-sports-cle-v41.dts | 248 ++++++++++ + .../boot/dts/amlogic/meson-qihua-s905d3.dtsi | 435 ++++++++++++++++++ + .../dts/amlogic/meson-sm1-qihua-s905d3.dts | 102 ++++ + .../dts/amlogic/meson-sm1-sports-cle-v4.dts | 254 ++++++++++ + 5 files changed, 1042 insertions(+) + create mode 100644 arch/arm64/boot/dts/amlogic/meson-g12b-sports-cle-v41.dts + create mode 100644 arch/arm64/boot/dts/amlogic/meson-qihua-s905d3.dtsi + create mode 100644 arch/arm64/boot/dts/amlogic/meson-sm1-qihua-s905d3.dts + create mode 100644 arch/arm64/boot/dts/amlogic/meson-sm1-sports-cle-v4.dts + +diff --git a/arch/arm64/boot/dts/amlogic/Makefile b/arch/arm64/boot/dts/amlogic/Makefile +index ced03946314f..4300ecdfdf06 100644 +--- a/arch/arm64/boot/dts/amlogic/Makefile ++++ b/arch/arm64/boot/dts/amlogic/Makefile +@@ -48,3 +48,6 @@ dtb-$(CONFIG_ARCH_MESON) += meson-sm1-sei610.dtb + dtb-$(CONFIG_ARCH_MESON) += meson-sm1-khadas-vim3l.dtb + dtb-$(CONFIG_ARCH_MESON) += meson-sm1-odroid-c4.dtb + dtb-$(CONFIG_ARCH_MESON) += meson-a1-ad401.dtb ++dtb-$(CONFIG_ARCH_MESON) += meson-sm1-sports-cle-v4.dtb ++dtb-$(CONFIG_ARCH_MESON) += meson-sm1-qihua-s905d3.dtb ++dtb-$(CONFIG_ARCH_MESON) += meson-g12b-sports-cle-v41.dtb +diff --git a/arch/arm64/boot/dts/amlogic/meson-g12b-sports-cle-v41.dts b/arch/arm64/boot/dts/amlogic/meson-g12b-sports-cle-v41.dts +new file mode 100644 +index 000000000000..ce5aeda1144d +--- /dev/null ++++ b/arch/arm64/boot/dts/amlogic/meson-g12b-sports-cle-v41.dts +@@ -0,0 +1,248 @@ ++// SPDX-License-Identifier: (GPL-2.0+ OR MIT) ++/* ++ * Copyright (c) 2019 BayLibre, SAS ++ * Author: Neil Armstrong ++ */ ++ ++/dts-v1/; ++ ++#include "meson-g12b-w400.dtsi" ++#include ++ ++ ++/ { ++ compatible = "qihua,s922x", "amlogic,s922x", "amlogic,g12b"; ++ model = "MT Sports CLE V41"; ++ ++ aliases { ++ mmc0 = &sd_emmc_a; ++ mmc1 = &sd_emmc_b; ++ mmc2 = &sd_emmc_c; ++ serial0 = &uart_AO; ++ serial1 = &uart_AO_B; ++ serial2 = &uart_C; ++ ethernet0 = ðmac; ++ i2c0 = &i2c3; ++ }; ++ ++ chosen { ++ stdout-path = "serial0:115200n8"; ++ }; ++ ++ dc_in: regulator-dc_in { ++ compatible = "regulator-fixed"; ++ regulator-name = "DC_IN"; ++ regulator-min-microvolt = <5000000>; ++ regulator-max-microvolt = <5000000>; ++ regulator-always-on; ++ }; ++ ++ vddcpu: regulator-vddcpu { ++ /* ++ * Silergy SY8030DEC Regulator. ++ */ ++ compatible = "pwm-regulator"; ++ ++ regulator-name = "VDDCPU"; ++ regulator-min-microvolt = <690000>; ++ regulator-max-microvolt = <1050000>; ++ ++ vin-supply = <&vcc_3v3>; ++ ++ pwms = <&pwm_AO_cd 1 1250 0>; ++ pwm-dutycycle-range = <100 0>; ++ ++ regulator-boot-on; ++ regulator-always-on; ++ }; ++ ++ lte_vdd: regulator-tflash_vdd { ++ compatible = "regulator-fixed"; ++ ++ regulator-name = "LTE_VDD"; ++ regulator-min-microvolt = <3300000>; ++ regulator-max-microvolt = <3300000>; ++ ++ gpio = <&gpio GPIOA_11 GPIO_ACTIVE_HIGH>; ++ enable-active-high; ++ vin-supply = <&dc_in>; ++ regulator-always-on; ++ }; ++ ++ nrf_pwr: regulator-nrf_pwr { ++ compatible = "regulator-fixed"; ++ regulator-name = "NRF_PWR"; ++ regulator-min-microvolt = <5000000>; ++ regulator-max-microvolt = <5000000>; ++ vin-supply = <&vcc_5v>; ++ ++ gpio = <&gpio GPIOA_9 GPIO_ACTIVE_HIGH>; ++ enable-active-high; ++ regulator-always-on; ++ }; ++ ++ leds { ++ compatible = "gpio-leds"; ++ ++ led-wan { ++ label = "mt-sports:wan"; ++ gpios = <&gpio GPIOA_12 GPIO_ACTIVE_HIGH>; ++ default-state = "off"; ++ }; ++ ++ led-ble { ++ label = "mt-sports:ble"; ++ gpios = <&gpio GPIOA_13 GPIO_ACTIVE_HIGH>; ++ default-state = "off"; ++ }; ++ }; ++ ++ // gpio-restart { ++ // compatible = "gpio-restart"; ++ // gpios = <&gpio GPIOA_3 GPIO_ACTIVE_HIGH>; ++ // priority = <128>; ++ // active-delay = <450>; ++ // inactive-delay = <100>; ++ // wait-delay = <3000>; ++ // line-name = "lte-reset"; ++ // }; ++}; ++ ++&pwm_AO_cd { ++ pinctrl-0 = <&pwm_ao_d_e_pins>; ++ pinctrl-names = "default"; ++ clocks = <&xtal>; ++ clock-names = "clkin1"; ++ status = "okay"; ++}; ++ ++ðmac { ++ status = "disable"; ++}; ++ ++&uart_AO_B { ++ status = "okay"; ++ pinctrl-0 = <&uart_ao_b_tx_8_pins>, <&uart_ao_b_rx_9_pins>; ++ pinctrl-names = "default"; ++}; ++ ++&uart_C { ++ status = "okay"; ++ pinctrl-0 = <&uart_c_pins>; ++ pinctrl-names = "default"; ++}; ++ ++&usb2_phy0 { ++ phy-supply = <&dc_in>; ++ vbus-supply = <&nrf_pwr>; ++ status = "okay"; ++}; ++ ++&usb2_phy1 { ++ phy-supply = <&dc_in>; ++ status = "okay"; ++}; ++ ++&usb3_pcie_phy { ++ phy-supply = <&dc_in>; ++}; ++ ++&usb { ++ status = "okay"; ++ dr_mode = "host"; ++}; ++ ++&gpio { ++ gpio-line-names = ++ /* GPIOZ */ ++ "", "", "", "", "", "", "", "", ++ "", "", "", "", "", "", "","", ++ /* GPIOH */ ++ "", "", "", "", ++ "ESP_PRG_EN", /* GPIOH_4 */ ++ "ESP_PRG_ID0", /* GPIOH_5 */ ++ "UART_EE_C_RX", /* GPIOH_6 */ ++ "UART_EE_C_TX", /* GPIOH_7 */ ++ "", ++ /* BOOT */ ++ "", "", "", "", "", "", "", "", ++ "", "", "", "", "", "", "", "", ++ /* GPIOC */ ++ "", "", "", "", "", "", "", "", ++ /* GPIOA */ ++ "nFORCE_NRF_3.3V", /* GPIOA_0 */ ++ "", ++ "NCHG_DET", /* GPIOA_2 */ ++ "", "", "", ++ "LTE_RST", /* GPIOA_6 */ ++ "NRF_SWD", /* GPIOA_7 */ ++ "NRF_SWC", /* GPIOA_8 */ ++ "NRF_PWR_EN", /* GPIOA_9 */ ++ "NRF_DFU", /* GPIOA_10 */ ++ "PWR_LTE_ON", /* GPIOA_11 */ ++ "WAN_LED", /* GPIOA_12 */ ++ "BLE_LED", /* GPIOA_13 */ ++ "", /* GPIOA_14 */ ++ "", /* GPIOA_15 */ ++ /* GPIOX */ ++ "", /* GPIOX_0 */ ++ "", /* GPIOX_1 */ ++ "", /* GPIOX_2 */ ++ "", /* GPIOX_3 */ ++ "", /* GPIOX_4 */ ++ "", /* GPIOX_5 */ ++ "", /* GPIOX_6 */ ++ "", /* GPIOX_7 */ ++ "", /* GPIOX_8 */ ++ "", /* GPIOX_9 */ ++ "", /* GPIOX_10 */ ++ "", /* GPIOX_11 */ ++ "", /* GPIOX_12 */ ++ "", /* GPIOX_13 */ ++ "", /* GPIOX_14 */ ++ "", /* GPIOX_15 */ ++ "", /* GPIOX_16 */ ++ "", /* GPIOX_17 */ ++ "", /* GPIOX_18 */ ++ ""; /* GPIOX_19 */ ++ ++}; ++ ++&gpio_ao { ++ gpio-line-names = ++ /* GPIOAO */ ++ "", "", "", ++ "PWR_KEY", /* GPIOAO_3 */ ++ "", /* GPIOAO_4 */ ++ "", ++ "FORCE_PWR_ON", /* GPIOAO_6 */ ++ "REQ_PWR_OFF", /* GPIOAO_7 */ ++ "UART_B_TX", /* GPIOAO_8 */ ++ "UART_B_RX", /* GPIOAO_9 */ ++ "", ++ "SYS_LED", /* GPIOAO_11 */ ++ /* GPIOE */ ++ "", "", ""; ++}; ++ ++&sd_emmc_a { ++ max-frequency = <200000000>; ++ vmmc-supply = <&vcc_3v3>; ++ vqmmc-supply = <&vcc_3v3>; ++}; ++ ++&sd_emmc_c { ++ max-frequency = <150000000>; ++}; ++ ++&i2c3 { ++ status = "okay"; ++ pinctrl-0 = <&i2c3_sda_a_pins>, <&i2c3_sck_a_pins>; ++ pinctrl-names = "default"; ++ ++ rtc: rtc@51 { ++ compatible = "nxp,pcf8563"; ++ reg = <0x51>; ++ #wakeup-source; ++ }; ++}; +diff --git a/arch/arm64/boot/dts/amlogic/meson-qihua-s905d3.dtsi b/arch/arm64/boot/dts/amlogic/meson-qihua-s905d3.dtsi +new file mode 100644 +index 000000000000..7599c252e5e4 +--- /dev/null ++++ b/arch/arm64/boot/dts/amlogic/meson-qihua-s905d3.dtsi +@@ -0,0 +1,435 @@ ++// SPDX-License-Identifier: (GPL-2.0+ OR MIT) ++/* ++ * Copyright (c) 2019 BayLibre, SAS ++ * Author: Neil Armstrong ++ * Copyright (c) 2019 Christian Hewitt ++ */ ++ ++#include ++#include ++#include ++ ++/ { ++ memory@0 { ++ device_type = "memory"; ++ reg = <0x0 0x0 0x0 0x80000000>; ++ }; ++ ++ adc-keys { ++ compatible = "adc-keys"; ++ io-channels = <&saradc 2>; ++ io-channel-names = "buttons"; ++ keyup-threshold-microvolt = <1710000>; ++ ++ button-function { ++ label = "Function"; ++ linux,code = ; ++ press-threshold-microvolt = <10000>; ++ }; ++ }; ++ ++ leds { ++ compatible = "gpio-leds"; ++ ++ led-red { ++ label = "x905:red:sys"; ++ gpios = <&gpio_ao GPIOAO_11 GPIO_ACTIVE_HIGH>; ++ linux,default-trigger = "heartbeat"; ++ }; ++ ++ }; ++ ++ emmc_pwrseq: emmc-pwrseq { ++ compatible = "mmc-pwrseq-emmc"; ++ reset-gpios = <&gpio BOOT_12 GPIO_ACTIVE_LOW>; ++ }; ++ ++ gpio-keys-polled { ++ compatible = "gpio-keys-polled"; ++ poll-interval = <100>; ++ ++ power-button { ++ label = "power"; ++ linux,code = ; ++ gpios = <&gpio_ao GPIOAO_3 GPIO_ACTIVE_LOW>; ++ }; ++ }; ++ ++ sdio_pwrseq: sdio-pwrseq { ++ compatible = "mmc-pwrseq-simple"; ++ reset-gpios = <&gpio GPIOX_6 GPIO_ACTIVE_LOW>; ++ clocks = <&wifi32k>; ++ clock-names = "ext_clock"; ++ }; ++ ++ dc_in: regulator-dc_in { ++ compatible = "regulator-fixed"; ++ regulator-name = "DC_IN"; ++ regulator-min-microvolt = <5000000>; ++ regulator-max-microvolt = <5000000>; ++ regulator-always-on; ++ }; ++ ++ vcc_5v: regulator-vcc_5v { ++ compatible = "regulator-fixed"; ++ regulator-name = "VCC_5V"; ++ regulator-min-microvolt = <5000000>; ++ regulator-max-microvolt = <5000000>; ++ vin-supply = <&dc_in>; ++ regulator-always-on; ++ }; ++ ++ vcc_3v3: regulator-vcc_3v3 { ++ compatible = "regulator-fixed"; ++ regulator-name = "VCC_3V3"; ++ regulator-min-microvolt = <3300000>; ++ regulator-max-microvolt = <3300000>; ++ vin-supply = <&dc_in>; ++ regulator-always-on; ++ }; ++ ++ vsys_3v3: regulator-vsys_3v3 { ++ compatible = "regulator-fixed"; ++ regulator-name = "VSYS_3V3"; ++ regulator-min-microvolt = <3300000>; ++ regulator-max-microvolt = <3300000>; ++ vin-supply = <&dc_in>; ++ regulator-always-on; ++ }; ++ ++ vddao_1v8: regulator-vddao_1v8 { ++ compatible = "regulator-fixed"; ++ regulator-name = "VDDIO_AO1V8"; ++ regulator-min-microvolt = <1800000>; ++ regulator-max-microvolt = <1800000>; ++ vin-supply = <&vsys_3v3>; ++ regulator-always-on; ++ }; ++ ++ emmc_1v8: regulator-emmc_1v8 { ++ compatible = "regulator-fixed"; ++ regulator-name = "EMMC_AO1V8"; ++ regulator-min-microvolt = <1800000>; ++ regulator-max-microvolt = <1800000>; ++ vin-supply = <&vsys_3v3>; ++ regulator-always-on; ++ }; ++ ++ hdmi-connector { ++ compatible = "hdmi-connector"; ++ type = "a"; ++ ++ port { ++ hdmi_connector_in: endpoint { ++ remote-endpoint = <&hdmi_tx_tmds_out>; ++ }; ++ }; ++ }; ++ ++ ++ sound { ++ compatible = "amlogic,axg-sound-card"; ++ model = "G12B-KHADAS-VIM3"; ++ audio-aux-devs = <&tdmout_a>; ++ audio-routing = "TDMOUT_A IN 0", "FRDDR_A OUT 0", ++ "TDMOUT_A IN 1", "FRDDR_B OUT 0", ++ "TDMOUT_A IN 2", "FRDDR_C OUT 0", ++ "TDM_A Playback", "TDMOUT_A OUT"; ++ ++ assigned-clocks = <&clkc CLKID_MPLL2>, ++ <&clkc CLKID_MPLL0>, ++ <&clkc CLKID_MPLL1>; ++ assigned-clock-parents = <0>, <0>, <0>; ++ assigned-clock-rates = <294912000>, ++ <270950400>, ++ <393216000>; ++ status = "okay"; ++ ++ dai-link-0 { ++ sound-dai = <&frddr_a>; ++ }; ++ ++ dai-link-1 { ++ sound-dai = <&frddr_b>; ++ }; ++ ++ dai-link-2 { ++ sound-dai = <&frddr_c>; ++ }; ++ ++ /* 8ch hdmi interface */ ++ dai-link-3 { ++ sound-dai = <&tdmif_a>; ++ dai-format = "i2s"; ++ dai-tdm-slot-tx-mask-0 = <1 1>; ++ dai-tdm-slot-tx-mask-1 = <1 1>; ++ dai-tdm-slot-tx-mask-2 = <1 1>; ++ dai-tdm-slot-tx-mask-3 = <1 1>; ++ mclk-fs = <256>; ++ ++ codec { ++ sound-dai = <&tohdmitx TOHDMITX_I2S_IN_A>; ++ }; ++ }; ++ ++ /* hdmi glue */ ++ dai-link-4 { ++ sound-dai = <&tohdmitx TOHDMITX_I2S_OUT>; ++ ++ codec { ++ sound-dai = <&hdmi_tx>; ++ }; ++ }; ++ }; ++ ++ wifi32k: wifi32k { ++ compatible = "pwm-clock"; ++ #clock-cells = <0>; ++ clock-frequency = <32768>; ++ pwms = <&pwm_ef 0 30518 0>; /* PWM_E at 32.768KHz */ ++ }; ++}; ++ ++&arb { ++ status = "okay"; ++}; ++ ++&clkc_audio { ++ status = "okay"; ++}; ++ ++&cec_AO { ++ pinctrl-0 = <&cec_ao_a_h_pins>; ++ pinctrl-names = "default"; ++ status = "disabled"; ++ hdmi-phandle = <&hdmi_tx>; ++}; ++ ++&cecb_AO { ++ pinctrl-0 = <&cec_ao_b_h_pins>; ++ pinctrl-names = "default"; ++ status = "okay"; ++ hdmi-phandle = <&hdmi_tx>; ++}; ++ ++&cpu_thermal { ++ trips { ++ cpu_active: cpu-active { ++ temperature = <80000>; /* millicelsius */ ++ hysteresis = <2000>; /* millicelsius */ ++ type = "active"; ++ }; ++ }; ++ ++}; ++ ++&ext_mdio { ++ external_phy: ethernet-phy@0 { ++ /* Realtek RTL8211F (0x001cc916) */ ++ reg = <0>; ++ max-speed = <1000>; ++ eee-broken-1000t; ++ ++ reset-assert-us = <10000>; ++ reset-deassert-us = <80000>; ++ reset-gpios = <&gpio GPIOZ_15 (GPIO_ACTIVE_LOW | GPIO_OPEN_DRAIN)>; ++ ++ interrupt-parent = <&gpio_intc>; ++ /* MAC_INTR on GPIOZ_14 */ ++ interrupts = <26 IRQ_TYPE_LEVEL_LOW>; ++ }; ++}; ++ ++ðmac { ++ pinctrl-0 = <ð_pins>, <ð_rgmii_pins>; ++ pinctrl-names = "default"; ++ status = "okay"; ++ phy-mode = "rgmii"; ++ phy-handle = <&external_phy>; ++ amlogic,tx-delay-ns = <2>; ++}; ++ ++&frddr_a { ++ status = "okay"; ++}; ++ ++&frddr_b { ++ status = "okay"; ++}; ++ ++&frddr_c { ++ status = "okay"; ++}; ++ ++&hdmi_tx { ++ status = "okay"; ++ pinctrl-0 = <&hdmitx_hpd_pins>, <&hdmitx_ddc_pins>; ++ pinctrl-names = "default"; ++ hdmi-supply = <&vcc_5v>; ++}; ++ ++&hdmi_tx_tmds_port { ++ hdmi_tx_tmds_out: endpoint { ++ remote-endpoint = <&hdmi_connector_in>; ++ }; ++}; ++ ++&i2c3 { ++ /* default i2c clock-frequency is 100Khz */ ++ status = "okay"; ++ ++ /* ++ * : SDA(GPIOA.14->152 Pin) ++ * SCL(GPIOA.15->154 Pin) ++ */ ++ pinctrl-names = "default"; ++ pinctrl-0 = <&i2c3_sck_a_pins>, <&i2c3_sda_a_pins>; ++ ++ /* default 100k */ ++ clock-frequency = <100000>; ++ ++ pcf8563: rtc@51 { ++ status = "okay"; ++ compatible = "nxp,pcf8563"; ++ reg = <0x51>; ++ #clock-cells = <0>; ++ }; ++}; ++ ++&ir { ++ status = "okay"; ++ pinctrl-0 = <&remote_input_ao_pins>; ++ pinctrl-names = "default"; ++ linux,rc-map-name = "rc-khadas"; ++}; ++ ++&pwm_ef { ++ status = "okay"; ++ pinctrl-0 = <&pwm_e_pins>; ++ pinctrl-names = "default"; ++}; ++ ++&saradc { ++ status = "okay"; ++ vref-supply = <&vddao_1v8>; ++}; ++ ++/* SDIO */ ++&sd_emmc_a { ++ status = "okay"; ++ pinctrl-0 = <&sdio_pins>; ++ pinctrl-1 = <&sdio_clk_gate_pins>; ++ pinctrl-names = "default", "clk-gate"; ++ #address-cells = <1>; ++ #size-cells = <0>; ++ ++ bus-width = <4>; ++ cap-sd-highspeed; ++ max-frequency = <200000000>; ++ ++ non-removable; ++ disable-wp; ++ ++ /* WiFi firmware requires power to be kept while in suspend */ ++ keep-power-in-suspend; ++ ++ mmc-pwrseq = <&sdio_pwrseq>; ++ ++ vmmc-supply = <&vcc_3v3>; ++ vqmmc-supply = <&vcc_3v3>; ++ ++ brcmf: wifi@1 { ++ reg = <1>; ++ compatible = "brcm,bcm4329-fmac"; ++ }; ++}; ++ ++/* SD card */ ++&sd_emmc_b { ++ status = "okay"; ++ pinctrl-0 = <&sdcard_c_pins>; ++ pinctrl-1 = <&sdcard_clk_gate_c_pins>; ++ pinctrl-names = "default", "clk-gate"; ++ ++ bus-width = <4>; ++ cap-sd-highspeed; ++ max-frequency = <50000000>; ++ disable-wp; ++ ++ cd-gpios = <&gpio GPIOC_6 GPIO_ACTIVE_LOW>; ++ vmmc-supply = <&vcc_3v3>; ++ vqmmc-supply = <&vcc_3v3>; ++}; ++ ++/* eMMC */ ++&sd_emmc_c { ++ status = "okay"; ++ pinctrl-0 = <&emmc_ctrl_pins>, <&emmc_data_8b_pins>, <&emmc_ds_pins>; ++ pinctrl-1 = <&emmc_clk_gate_pins>; ++ pinctrl-names = "default", "clk-gate"; ++ ++ bus-width = <8>; ++ cap-mmc-highspeed; ++ mmc-ddr-1_8v; ++ mmc-hs200-1_8v; ++ max-frequency = <200000000>; ++ disable-wp; ++ ++ mmc-pwrseq = <&emmc_pwrseq>; ++ vmmc-supply = <&vsys_3v3>; ++ vqmmc-supply = <&emmc_1v8>; ++}; ++ ++/* ++ * EMMC_D4, EMMC_D5, EMMC_D6 and EMMC_D7 pins are shared between SPI NOR CS ++ * and eMMC Data 4 to 7 pins. ++ * Replace emmc_data_8b_pins to emmc_data_4b_pins from sd_emmc_c pinctrl-0, ++ * and change bus-width to 4 then spifc can be enabled. ++ */ ++&spifc { ++ status = "disabled"; ++ pinctrl-0 = <&nor_pins>; ++ pinctrl-names = "default"; ++ ++ w25q128: spi-flash@0 { ++ #address-cells = <1>; ++ #size-cells = <1>; ++ compatible = "winbond,w25q128fw", "jedec,spi-nor"; ++ reg = <0>; ++ spi-max-frequency = <104000000>; ++ }; ++}; ++ ++ ++&tdmif_a { ++ status = "okay"; ++}; ++ ++&tdmout_a { ++ status = "okay"; ++}; ++ ++&tohdmitx { ++ status = "okay"; ++}; ++ ++&uart_A { ++ status = "okay"; ++ pinctrl-0 = <&uart_a_pins>, <&uart_a_cts_rts_pins>; ++ pinctrl-names = "default"; ++ uart-has-rtscts; ++ ++ bluetooth { ++ compatible = "brcm,bcm43438-bt"; ++ shutdown-gpios = <&gpio GPIOX_17 GPIO_ACTIVE_HIGH>; ++ max-speed = <2000000>; ++ clocks = <&wifi32k>; ++ clock-names = "lpo"; ++ }; ++}; ++ ++&uart_AO { ++ status = "okay"; ++ pinctrl-0 = <&uart_ao_a_pins>; ++ pinctrl-names = "default"; ++}; +diff --git a/arch/arm64/boot/dts/amlogic/meson-sm1-qihua-s905d3.dts b/arch/arm64/boot/dts/amlogic/meson-sm1-qihua-s905d3.dts +new file mode 100644 +index 000000000000..70c46a1c9d06 +--- /dev/null ++++ b/arch/arm64/boot/dts/amlogic/meson-sm1-qihua-s905d3.dts +@@ -0,0 +1,102 @@ ++// SPDX-License-Identifier: (GPL-2.0+ OR MIT) ++/* ++ * Copyright (c) 2019 BayLibre, SAS ++ * Author: Neil Armstrong ++ */ ++ ++/dts-v1/; ++ ++#include "meson-sm1.dtsi" ++#include "meson-qihua-s905d3.dtsi" ++#include ++ ++/ { ++ compatible = "qihua,s905d3", "amlogic,sm1"; ++ model = "Qihua S905D3"; ++ ++ aliases { ++ serial0 = &uart_AO; ++ ethernet0 = ðmac; ++ i2c0 = &i2c3; ++ }; ++ ++ chosen { ++ stdout-path = "serial0:115200n8"; ++ }; ++ ++ vddcpu: regulator-vddcpu { ++ /* ++ * Silergy SY8030DEC Regulator. ++ */ ++ compatible = "pwm-regulator"; ++ ++ regulator-name = "VDDCPU"; ++ regulator-min-microvolt = <690000>; ++ regulator-max-microvolt = <1050000>; ++ ++ vin-supply = <&vsys_3v3>; ++ ++ pwms = <&pwm_AO_cd 1 1250 0>; ++ pwm-dutycycle-range = <100 0>; ++ ++ regulator-boot-on; ++ regulator-always-on; ++ }; ++}; ++ ++&cpu0 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&cpu1 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU1_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&cpu2 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU2_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&cpu3 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU3_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&pwm_AO_cd { ++ pinctrl-0 = <&pwm_ao_d_e_pins>; ++ pinctrl-names = "default"; ++ clocks = <&xtal>; ++ clock-names = "clkin1"; ++ status = "okay"; ++}; ++ ++&sd_emmc_a { ++ sd-uhs-sdr50; ++}; ++ ++&usb2_phy0 { ++ phy-supply = <&dc_in>; ++}; ++ ++&usb2_phy1 { ++ phy-supply = <&dc_in>; ++}; ++ ++&usb3_pcie_phy { ++ phy-supply = <&dc_in>; ++}; ++ ++&usb { ++ status = "okay"; ++ dr_mode = "host"; ++}; +diff --git a/arch/arm64/boot/dts/amlogic/meson-sm1-sports-cle-v4.dts b/arch/arm64/boot/dts/amlogic/meson-sm1-sports-cle-v4.dts +new file mode 100644 +index 000000000000..a1a2a7bf1475 +--- /dev/null ++++ b/arch/arm64/boot/dts/amlogic/meson-sm1-sports-cle-v4.dts +@@ -0,0 +1,254 @@ ++// SPDX-License-Identifier: (GPL-2.0+ OR MIT) ++/* ++ * Copyright (c) 2019 BayLibre, SAS ++ * Author: Neil Armstrong ++ */ ++ ++/dts-v1/; ++ ++#include "meson-sm1.dtsi" ++#include "meson-qihua-s905d3.dtsi" ++#include ++ ++/ { ++ compatible = "qihua,s905d3", "amlogic,sm1"; ++ model = "MT Sports CLE V4"; ++ ++ aliases { ++ mmc0 = &sd_emmc_a; ++ mmc1 = &sd_emmc_b; ++ mmc2 = &sd_emmc_c; ++ serial0 = &uart_AO; ++ serial1 = &uart_AO_B; ++ serial2 = &uart_C; ++ ethernet0 = ðmac; ++ i2c0 = &i2c3; ++ }; ++ ++ chosen { ++ stdout-path = "serial0:115200n8"; ++ }; ++ ++ vddcpu: regulator-vddcpu { ++ /* ++ * Silergy SY8030DEC Regulator. ++ */ ++ compatible = "pwm-regulator"; ++ ++ regulator-name = "VDDCPU"; ++ regulator-min-microvolt = <690000>; ++ regulator-max-microvolt = <1050000>; ++ ++ vin-supply = <&vsys_3v3>; ++ ++ pwms = <&pwm_AO_cd 1 1250 0>; ++ pwm-dutycycle-range = <100 0>; ++ ++ regulator-boot-on; ++ regulator-always-on; ++ }; ++ ++ lte_vdd: regulator-tflash_vdd { ++ compatible = "regulator-fixed"; ++ ++ regulator-name = "LTE_VDD"; ++ regulator-min-microvolt = <3300000>; ++ regulator-max-microvolt = <3300000>; ++ ++ gpio = <&gpio GPIOA_11 GPIO_ACTIVE_HIGH>; ++ enable-active-high; ++ vin-supply = <&dc_in>; ++ regulator-always-on; ++ }; ++ ++ nrf_pwr: regulator-nrf_pwr { ++ compatible = "regulator-fixed"; ++ regulator-name = "NRF_PWR"; ++ regulator-min-microvolt = <5000000>; ++ regulator-max-microvolt = <5000000>; ++ vin-supply = <&vcc_5v>; ++ ++ gpio = <&gpio GPIOA_9 GPIO_ACTIVE_HIGH>; ++ enable-active-high; ++ regulator-always-on; ++ }; ++ ++ leds { ++ compatible = "gpio-leds"; ++ ++ led-wan { ++ label = "mt-sports:wan"; ++ gpios = <&gpio GPIOA_12 GPIO_ACTIVE_HIGH>; ++ default-state = "off"; ++ }; ++ ++ led-ble { ++ label = "mt-sports:ble"; ++ gpios = <&gpio GPIOA_13 GPIO_ACTIVE_HIGH>; ++ default-state = "off"; ++ }; ++ }; ++ ++ // gpio-restart { ++ // compatible = "gpio-restart"; ++ // gpios = <&gpio GPIOA_3 GPIO_ACTIVE_HIGH>; ++ // priority = <128>; ++ // active-delay = <450>; ++ // inactive-delay = <100>; ++ // wait-delay = <3000>; ++ // line-name = "lte-reset"; ++ // }; ++}; ++ ++&cpu0 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&cpu1 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU1_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&cpu2 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU2_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&cpu3 { ++ cpu-supply = <&vddcpu>; ++ operating-points-v2 = <&cpu_opp_table>; ++ clocks = <&clkc CLKID_CPU3_CLK>; ++ clock-latency = <50000>; ++}; ++ ++&pwm_AO_cd { ++ pinctrl-0 = <&pwm_ao_d_e_pins>; ++ pinctrl-names = "default"; ++ clocks = <&xtal>; ++ clock-names = "clkin1"; ++ status = "okay"; ++}; ++ ++ðmac { ++ status = "disable"; ++}; ++ ++&uart_AO_B { ++ status = "okay"; ++ pinctrl-0 = <&uart_ao_b_tx_8_pins>, <&uart_ao_b_rx_9_pins>; ++ pinctrl-names = "default"; ++}; ++ ++&uart_C { ++ status = "okay"; ++ pinctrl-0 = <&uart_c_pins>; ++ pinctrl-names = "default"; ++}; ++ ++&usb2_phy0 { ++ phy-supply = <&dc_in>; ++ vbus-supply = <&nrf_pwr>; ++ status = "okay"; ++}; ++ ++&usb2_phy1 { ++ phy-supply = <&dc_in>; ++ status = "okay"; ++}; ++ ++&usb3_pcie_phy { ++ phy-supply = <&dc_in>; ++}; ++ ++&usb { ++ status = "okay"; ++ dr_mode = "host"; ++}; ++ ++&gpio { ++ gpio-line-names = ++ /* GPIOZ */ ++ "", "", "", "", "", "", "", "", ++ "", "", "", "", "", "", "","", ++ /* GPIOH */ ++ "", "", "", "", ++ "ESP_PRG_EN", /* GPIOH_4 */ ++ "ESP_PRG_ID0", /* GPIOH_5 */ ++ "UART_EE_C_RX", /* GPIOH_6 */ ++ "UART_EE_C_TX", /* GPIOH_7 */ ++ "", ++ /* BOOT */ ++ "", "", "", "", "", "", "", "", ++ "", "", "", "", "", "", "", "", ++ /* GPIOC */ ++ "", "", "", "", "", "", "", "", ++ /* GPIOA */ ++ "nFORCE_NRF_3.3V", /* GPIOA_0 */ ++ "", ++ "NCHG_DET", /* GPIOA_2 */ ++ "", "", "", ++ "LTE_RST", /* GPIOA_6 */ ++ "NRF_SWD", /* GPIOA_7 */ ++ "NRF_SWC", /* GPIOA_8 */ ++ "NRF_PWR_EN", /* GPIOA_9 */ ++ "NRF_DFU", /* GPIOA_10 */ ++ "PWR_LTE_ON", /* GPIOA_11 */ ++ "WAN_LED", /* GPIOA_12 */ ++ "BLE_LED", /* GPIOA_13 */ ++ "", /* GPIOA_14 */ ++ "", /* GPIOA_15 */ ++ /* GPIOX */ ++ "", /* GPIOX_0 */ ++ "", /* GPIOX_1 */ ++ "", /* GPIOX_2 */ ++ "", /* GPIOX_3 */ ++ "", /* GPIOX_4 */ ++ "", /* GPIOX_5 */ ++ "", /* GPIOX_6 */ ++ "", /* GPIOX_7 */ ++ "", /* GPIOX_8 */ ++ "", /* GPIOX_9 */ ++ "", /* GPIOX_10 */ ++ "", /* GPIOX_11 */ ++ "", /* GPIOX_12 */ ++ "", /* GPIOX_13 */ ++ "", /* GPIOX_14 */ ++ "", /* GPIOX_15 */ ++ "", /* GPIOX_16 */ ++ "", /* GPIOX_17 */ ++ "", /* GPIOX_18 */ ++ ""; /* GPIOX_19 */ ++ ++}; ++ ++&gpio_ao { ++ gpio-line-names = ++ /* GPIOAO */ ++ "", "", "", ++ "PWR_KEY", /* GPIOAO_3 */ ++ "", /* GPIOAO_4 */ ++ "", ++ "FORCE_PWR_ON", /* GPIOAO_6 */ ++ "REQ_PWR_OFF", /* GPIOAO_7 */ ++ "UART_B_TX", /* GPIOAO_8 */ ++ "UART_B_RX", /* GPIOAO_9 */ ++ "", ++ "SYS_LED", /* GPIOAO_11 */ ++ /* GPIOE */ ++ "", "", ""; ++}; ++ ++&sd_emmc_a { ++ vmmc-supply = <<e_vdd>; ++}; ++ ++&sd_emmc_c { ++ max-frequency = <150000000>; ++}; +-- +2.34.1 + diff --git a/recipes-kernel/linux/linux-yocto_5.10.bb b/recipes-kernel/linux/linux-yocto_5.10.bb index 8bd2183..98d1318 100644 --- a/recipes-kernel/linux/linux-yocto_5.10.bb +++ b/recipes-kernel/linux/linux-yocto_5.10.bb @@ -1,5 +1,5 @@ -#KBRANCH ?= "v5.10/standard/base" -KBRANCH ?= "v5.10/base" +KBRANCH ?= "v5.10/standard/base" +#KBRANCH ?= "v5.10/base" require recipes-kernel/linux/linux-yocto.inc @@ -23,11 +23,11 @@ SRCREV_machine:qemuriscv32 ?= "dafc025b033585311d1693255c80b60b690b0e54" SRCREV_machine:qemux86 ?= "dafc025b033585311d1693255c80b60b690b0e54" SRCREV_machine:qemux86-64 ?= "dafc025b033585311d1693255c80b60b690b0e54" SRCREV_machine:qemumips64 ?= "ee18c4343db52d5846a0f332cd6df26a6f72dd45" -#SRCREV_machine ?= "dafc025b033585311d1693255c80b60b690b0e54" +# SRCREV_machine ?= "dafc025b033585311d1693255c80b60b690b0e54" SRCREV_meta ?= "c1168e10ecf30b123a341ca500966eebf3fe2cc2" -SRCREV_machine ?= "381518b4a9165cd793599c1668c82079fcbcbe1f" - +# SRCREV_machine ?= "381518b4a9165cd793599c1668c82079fcbcbe1f" +SRCREV_machine ?= "cfcf13659ada4eee41e11484404de999ce571196" SRC_URI = "git://git.yoctoproject.org/linux-yocto.git;name=machine;branch=${KBRANCH}; \ git://git.yoctoproject.org/yocto-kernel-cache;type=kmeta;name=meta;branch=yocto-5.10;destsuffix=${KMETA}" diff --git a/recipes-kernel/linux/linux-yocto_5.10.bbappend b/recipes-kernel/linux/linux-yocto_5.10.bbappend index c8ddbaf..09886c6 100644 --- a/recipes-kernel/linux/linux-yocto_5.10.bbappend +++ b/recipes-kernel/linux/linux-yocto_5.10.bbappend @@ -10,7 +10,7 @@ SRC_URI += " \ file://01-10-soc-sunxi-convert-to-devm_platform_ioremap_resource.patch \ file://dts-meson-add-watchdog-to-g12-common-dtsi.patch.txt.patch \ file://0001-g12-add-uart_ao_b-pins.patch \ - file://0001-add-sports-cle-v41-support.patch \ + file://0001-add-sports-cle-v40-v41-dts.patch \ file://0006-fix-8821cs-drv-build.patch \ file://use-rtc1-as-default-rtc.cfg \ file://add-erofs-and-overlayfs.cfg \