From 383b9eba186577b9ab7eac2020a677e49cb44afe Mon Sep 17 00:00:00 2001 From: Lef Date: Fri, 6 Nov 2026 06:50:26 +0200 Subject: [PATCH 1/5] dt-bindings: clock: google,zuma-clock: add CMU_PERIC0 and PERIC1 USI0 Add the clock IDs for PERIC1's USI0 (the haptics driver's I2C bus on the Pixel 8 Pro), the PERIC0 NoC and peripheral paths in CMU_TOP, and the new CMU_PERIC0 with USI14 (the rear flash LED's I2C bus), and the google,zuma-cmu-peric0 compatible. Signed-off-by: Lef --- .../bindings/clock/google,zuma-clock.yaml | 17 ++++++++++++++ include/dt-bindings/clock/google,zuma.h | 23 +++++++++++++++++++ 2 files changed, 40 insertions(+) diff --git a/Documentation/devicetree/bindings/clock/google,zuma-clock.yaml b/Documentation/devicetree/bindings/clock/google,zuma-clock.yaml index 11d78ddd41..b4f1245065 100644 --- a/Documentation/devicetree/bindings/clock/google,zuma-clock.yaml +++ b/Documentation/devicetree/bindings/clock/google,zuma-clock.yaml @@ -27,6 +27,7 @@ properties: - google,zuma-cmu-top - google,zuma-cmu-apm - google,zuma-cmu-hsi0 + - google,zuma-cmu-peric0 - google,zuma-cmu-peric1 reg: @@ -83,6 +84,22 @@ allOf: - const: bus - const: peri - const: alt + - if: + properties: + compatible: + const: google,zuma-cmu-peric0 + then: + properties: + clocks: + items: + - description: External oscillator reference clock + - description: PERIC0 NoC clock from CMU_TOP + - description: PERIC0 USI input clock from CMU_TOP + clock-names: + items: + - const: oscclk + - const: bus + - const: ip - if: properties: compatible: diff --git a/include/dt-bindings/clock/google,zuma.h b/include/dt-bindings/clock/google,zuma.h index 0f8b127ff9..a226cae5a7 100644 --- a/include/dt-bindings/clock/google,zuma.h +++ b/include/dt-bindings/clock/google,zuma.h @@ -25,6 +25,14 @@ #define CLK_DOUT_PERIC1_NOC 20 #define CLK_DOUT_PERIC1_IP 21 +/* CMU_TOP: the PERIC0 NoC and peripheral clock paths. */ +#define CLK_MOUT_PERIC0_NOC 22 +#define CLK_MOUT_PERIC0_IP 23 +#define CLK_GOUT_PERIC0_NOC 24 +#define CLK_GOUT_PERIC0_IP 25 +#define CLK_DOUT_PERIC0_NOC 26 +#define CLK_DOUT_PERIC0_IP 27 + /* CMU_HSI0: USI2, the touchscreen's SPI. */ #define CLK_GOUT_HSI0_ALT 1 #define CLK_MOUT_HSI0_NOC_USER 2 @@ -54,6 +62,11 @@ #define CLK_GOUT_PERIC1_USI9_IPCLK 11 #define CLK_GOUT_PERIC1_USI9_PCLK 12 #define CLK_GOUT_PERIC1_USI9_RSTNSYNC 13 +#define CLK_MOUT_PERIC1_USI0_USER 14 +#define CLK_DOUT_PERIC1_USI0 15 +#define CLK_GOUT_PERIC1_USI0_IPCLK 16 +#define CLK_GOUT_PERIC1_USI0_PCLK 17 +#define CLK_GOUT_PERIC1_USI0_RSTNSYNC 18 /* CMU_APM: the APM mailbox, its SRAM, the always-on GPIO banks, the USI1 UART and the SYSREG. */ #define CLK_APM_PLL_ALV_DIV2 1 @@ -76,4 +89,14 @@ #define CLK_GOUT_APM_USI1_UART_RSTNSYNC 18 #define CLK_GOUT_APM_SYSREG 19 +/* CMU_PERIC0: USI14, the I2C bus of the rear flash LED. */ +#define CLK_MOUT_PERIC0_NOC_USER 1 +#define CLK_GOUT_GPIO_PERIC0 2 +#define CLK_GOUT_PERIC0_SYSREG 3 +#define CLK_MOUT_PERIC0_USI14_USER 4 +#define CLK_DOUT_PERIC0_USI14 5 +#define CLK_GOUT_PERIC0_USI14_IPCLK 6 +#define CLK_GOUT_PERIC0_USI14_PCLK 7 +#define CLK_GOUT_PERIC0_USI14_RSTNSYNC 8 + #endif /* _DT_BINDINGS_CLOCK_GOOGLE_ZUMA_H */ From a9dfb12777102b32207f95bb21e40f08883ad628 Mon Sep 17 00:00:00 2001 From: Lef Date: Fri, 6 Nov 2026 06:50:26 +0200 Subject: [PATCH 2/5] dt-bindings: soc: samsung: exynos-sysreg: add google,zuma-peric0-sysreg The sysreg of the Tensor G3's PERIC0 block, which holds the USI mode selectors; the Pixel 8 Pro's rear flash LED bus (USI14) needs it. Signed-off-by: Lef --- .../devicetree/bindings/soc/samsung/samsung,exynos-sysreg.yaml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Documentation/devicetree/bindings/soc/samsung/samsung,exynos-sysreg.yaml b/Documentation/devicetree/bindings/soc/samsung/samsung,exynos-sysreg.yaml index b5a944604e..6b5892fe9d 100644 --- a/Documentation/devicetree/bindings/soc/samsung/samsung,exynos-sysreg.yaml +++ b/Documentation/devicetree/bindings/soc/samsung/samsung,exynos-sysreg.yaml @@ -30,6 +30,7 @@ properties: - google,gs201-vgpio2ap-sysreg - google,zuma-apm-sysreg - google,zuma-hsi0-sysreg + - google,zuma-peric0-sysreg - google,zuma-peric1-sysreg - google,zuma-ufs-sysreg - google,zumapro-apm-sysreg @@ -120,6 +121,7 @@ allOf: - google,gs201-peric0-sysreg - google,gs201-peric1-sysreg - google,zuma-apm-sysreg + - google,zuma-peric0-sysreg - google,zuma-peric1-sysreg - google,zumapro-apm-sysreg - google,zumapro-hsi0-sysreg From a66323aaff1e25a604225868a55e9bc73929764d Mon Sep 17 00:00:00 2001 From: Lef Date: Wed, 4 Nov 2026 22:55:42 +0200 Subject: [PATCH 3/5] clk: samsung: clk-zuma: add PERIC1 USI0, the PERIC0 paths and CMU_PERIC0 PERIC1's USI0: user mux 0x620, divider 0x1808, gates 0x2038, 0x203c and 0x208c. CMU_TOP's PERIC0 paths: muxes 0x10f0 and 0x10ec, gates 0x2114 and 0x2110, dividers 0x18e8 and 0x18e4. CMU_PERIC0 at 0x10800000: NoC user mux 0x600, USI14 user mux 0x640, USI14 divider 0x180c, USI14 gates 0x2068, 0x206c and 0x20cc, and the read-only GPIO and sysreg gates 0x20b8 and 0x20f0. All offsets are from Google's GPL zuma cal-if (cmucal-sfr.c) and match the PERIC1 ones that are already here. Tested on a Pixel 8 Pro: haptics (USI0) and the torch (USI14) both probe on these clocks. Signed-off-by: Lef --- drivers/clk/samsung/clk-zuma.c | 80 +++++++++++++++++++++++++++++++++- 1 file changed, 78 insertions(+), 2 deletions(-) diff --git a/drivers/clk/samsung/clk-zuma.c b/drivers/clk/samsung/clk-zuma.c index 4a831d69b4..833d676e8b 100644 --- a/drivers/clk/samsung/clk-zuma.c +++ b/drivers/clk/samsung/clk-zuma.c @@ -67,6 +67,10 @@ static const struct samsung_mux_clock top_muxes[] __initconst = { 0x10f8, 0, 2, 0, CLK_MUX_READ_ONLY), MUX_F(CLK_MOUT_PERIC1_IP, "zuma_mout_peric1_ip", mout_peric1_parents, 0x10f4, 0, 2, 0, CLK_MUX_READ_ONLY), + MUX_F(CLK_MOUT_PERIC0_NOC, "zuma_mout_peric0_noc", mout_peric1_parents, + 0x10f0, 0, 2, 0, CLK_MUX_READ_ONLY), + MUX_F(CLK_MOUT_PERIC0_IP, "zuma_mout_peric0_ip", mout_peric1_parents, + 0x10ec, 0, 2, 0, CLK_MUX_READ_ONLY), }; /* The hardware order is mux -> gate -> divider. HSI0 and PERIC1 are firmware-owned. */ @@ -79,6 +83,10 @@ static const struct samsung_gate_clock top_ro_gates[] __initconst = { 0x211c, 21, CLK_IGNORE_UNUSED, 0), GATE(CLK_GOUT_PERIC1_IP, "zuma_gout_peric1_ip", "zuma_mout_peric1_ip", 0x2118, 21, CLK_IGNORE_UNUSED, 0), + GATE(CLK_GOUT_PERIC0_NOC, "zuma_gout_peric0_noc", "zuma_mout_peric0_noc", + 0x2114, 21, CLK_IGNORE_UNUSED, 0), + GATE(CLK_GOUT_PERIC0_IP, "zuma_gout_peric0_ip", "zuma_mout_peric0_ip", + 0x2110, 21, CLK_IGNORE_UNUSED, 0), }; static const struct samsung_div_clock top_dividers[] __initconst = { @@ -90,6 +98,10 @@ static const struct samsung_div_clock top_dividers[] __initconst = { 0x18f0, 0, 4, 0, CLK_DIVIDER_READ_ONLY), DIV_F(CLK_DOUT_PERIC1_IP, "zuma_dout_peric1_ip", "zuma_gout_peric1_ip", 0x18ec, 0, 4, 0, CLK_DIVIDER_READ_ONLY), + DIV_F(CLK_DOUT_PERIC0_NOC, "zuma_dout_peric0_noc", "zuma_gout_peric0_noc", + 0x18e8, 0, 4, 0, CLK_DIVIDER_READ_ONLY), + DIV_F(CLK_DOUT_PERIC0_IP, "zuma_dout_peric0_ip", "zuma_gout_peric0_ip", + 0x18e4, 0, 4, 0, CLK_DIVIDER_READ_ONLY), }; static const struct samsung_cmu_info top_cmu __initconst = { @@ -103,7 +115,7 @@ static const struct samsung_cmu_info top_cmu __initconst = { .nr_ro_gate_clks = ARRAY_SIZE(top_ro_gates), .div_clks = top_dividers, .nr_div_clks = ARRAY_SIZE(top_dividers), - .nr_clk_ids = CLK_DOUT_PERIC1_IP + 1, + .nr_clk_ids = CLK_DOUT_PERIC0_IP + 1, }; static void __init zuma_top_init(struct device_node *np) @@ -262,6 +274,7 @@ static const struct samsung_cmu_info hsi0_cmu __initconst = { PNAME(mout_peric1_noc_user_parents) = { "oscclk", "zuma_dout_peric1_noc" }; PNAME(mout_peric1_usi11_user_parents) = { "oscclk", "zuma_dout_peric1_ip" }; PNAME(mout_peric1_usi9_user_parents) = { "oscclk", "zuma_dout_peric1_ip" }; +PNAME(mout_peric1_usi0_user_parents) = { "oscclk", "zuma_dout_peric1_ip" }; static const struct samsung_mux_clock peric1_muxes[] __initconst = { MUX_F(CLK_MOUT_PERIC1_NOC_USER, "zuma_mout_peric1_noc_user", @@ -270,6 +283,8 @@ static const struct samsung_mux_clock peric1_muxes[] __initconst = { mout_peric1_usi11_user_parents, 0x640, 4, 1, 0, CLK_MUX_READ_ONLY), MUX_F(CLK_MOUT_PERIC1_USI9_USER, "zuma_mout_peric1_usi9_user", mout_peric1_usi9_user_parents, 0x690, 4, 1, 0, CLK_MUX_READ_ONLY), + MUX_F(CLK_MOUT_PERIC1_USI0_USER, "zuma_mout_peric1_usi0_user", + mout_peric1_usi0_user_parents, 0x620, 4, 1, 0, CLK_MUX_READ_ONLY), }; static const struct samsung_div_clock peric1_dividers[] __initconst = { @@ -279,6 +294,9 @@ static const struct samsung_div_clock peric1_dividers[] __initconst = { DIV_F(CLK_DOUT_PERIC1_USI9, "zuma_dout_peric1_usi9", "zuma_mout_peric1_usi9_user", 0x1824, 0, 4, 0, CLK_DIVIDER_READ_ONLY), + DIV_F(CLK_DOUT_PERIC1_USI0, "zuma_dout_peric1_usi0", + "zuma_mout_peric1_usi0_user", 0x1808, 0, 4, 0, + CLK_DIVIDER_READ_ONLY), }; static const struct samsung_gate_clock peric1_ro_gates[] __initconst = { @@ -301,6 +319,12 @@ static const struct samsung_gate_clock peric1_gates[] __initconst = { "zuma_mout_peric1_noc_user", 0x2074, 21, 0, 0), GATE(CLK_GOUT_PERIC1_USI9_RSTNSYNC, "zuma_gout_peric1_usi9_rstnsync", "zuma_dout_peric1_usi9", 0x20a0, 21, 0, 0), + GATE(CLK_GOUT_PERIC1_USI0_IPCLK, "zuma_gout_peric1_usi0_ipclk", + "zuma_dout_peric1_usi0", 0x2038, 21, 0, 0), + GATE(CLK_GOUT_PERIC1_USI0_PCLK, "zuma_gout_peric1_usi0_pclk", + "zuma_mout_peric1_noc_user", 0x203c, 21, 0, 0), + GATE(CLK_GOUT_PERIC1_USI0_RSTNSYNC, "zuma_gout_peric1_usi0_rstnsync", + "zuma_dout_peric1_usi0", 0x208c, 21, 0, 0), }; static const struct samsung_cmu_info peric1_cmu __initconst = { @@ -312,7 +336,58 @@ static const struct samsung_cmu_info peric1_cmu __initconst = { .nr_ro_gate_clks = ARRAY_SIZE(peric1_ro_gates), .gate_clks = peric1_gates, .nr_gate_clks = ARRAY_SIZE(peric1_gates), - .nr_clk_ids = CLK_GOUT_PERIC1_USI9_RSTNSYNC + 1, + .nr_clk_ids = CLK_GOUT_PERIC1_USI0_RSTNSYNC + 1, + .clk_name = "bus", +}; + +/* + * CMU_PERIC0, 0x10800000. Firmware sets it up, as CMU_PERIC1: USI14 is the + * I2C bus of the rear flash LED. The user muxes and the divider are + * read-only, the GPIO and sysreg gates are read-only gates. + */ +PNAME(mout_peric0_noc_user_parents) = { "oscclk", "zuma_dout_peric0_noc" }; +PNAME(mout_peric0_usi14_user_parents) = { "oscclk", "zuma_dout_peric0_ip" }; + +static const struct samsung_mux_clock peric0_muxes[] __initconst = { + MUX_F(CLK_MOUT_PERIC0_NOC_USER, "zuma_mout_peric0_noc_user", + mout_peric0_noc_user_parents, 0x600, 4, 1, 0, CLK_MUX_READ_ONLY), + MUX_F(CLK_MOUT_PERIC0_USI14_USER, "zuma_mout_peric0_usi14_user", + mout_peric0_usi14_user_parents, 0x640, 4, 1, 0, + CLK_MUX_READ_ONLY), +}; + +static const struct samsung_div_clock peric0_dividers[] __initconst = { + DIV_F(CLK_DOUT_PERIC0_USI14, "zuma_dout_peric0_usi14", + "zuma_mout_peric0_usi14_user", 0x180c, 0, 4, 0, + CLK_DIVIDER_READ_ONLY), +}; + +static const struct samsung_gate_clock peric0_ro_gates[] __initconst = { + GATE(CLK_GOUT_GPIO_PERIC0, "zuma_gout_gpio_peric0", + "zuma_mout_peric0_noc_user", 0x20b8, 21, CLK_IGNORE_UNUSED, 0), + GATE(CLK_GOUT_PERIC0_SYSREG, "zuma_gout_peric0_sysreg", + "zuma_mout_peric0_noc_user", 0x20f0, 21, CLK_IGNORE_UNUSED, 0), +}; + +static const struct samsung_gate_clock peric0_gates[] __initconst = { + GATE(CLK_GOUT_PERIC0_USI14_IPCLK, "zuma_gout_peric0_usi14_ipclk", + "zuma_dout_peric0_usi14", 0x2068, 21, 0, 0), + GATE(CLK_GOUT_PERIC0_USI14_PCLK, "zuma_gout_peric0_usi14_pclk", + "zuma_mout_peric0_noc_user", 0x206c, 21, 0, 0), + GATE(CLK_GOUT_PERIC0_USI14_RSTNSYNC, "zuma_gout_peric0_usi14_rstnsync", + "zuma_dout_peric0_usi14", 0x20cc, 21, 0, 0), +}; + +static const struct samsung_cmu_info peric0_cmu __initconst = { + .mux_clks = peric0_muxes, + .nr_mux_clks = ARRAY_SIZE(peric0_muxes), + .div_clks = peric0_dividers, + .nr_div_clks = ARRAY_SIZE(peric0_dividers), + .ro_gate_clks = peric0_ro_gates, + .nr_ro_gate_clks = ARRAY_SIZE(peric0_ro_gates), + .gate_clks = peric0_gates, + .nr_gate_clks = ARRAY_SIZE(peric0_gates), + .nr_clk_ids = CLK_GOUT_PERIC0_USI14_RSTNSYNC + 1, .clk_name = "bus", }; @@ -327,6 +402,7 @@ static int __init zuma_cmu_probe(struct platform_device *pdev) static const struct of_device_id zuma_cmu_match[] = { { .compatible = "google,zuma-cmu-apm", .data = &apm_cmu }, { .compatible = "google,zuma-cmu-hsi0", .data = &hsi0_cmu }, + { .compatible = "google,zuma-cmu-peric0", .data = &peric0_cmu }, { .compatible = "google,zuma-cmu-peric1", .data = &peric1_cmu }, { } }; From 559c14f26c97ba21f9279b30ba9e68ff15fa33eb Mon Sep 17 00:00:00 2001 From: Lef Date: Wed, 4 Nov 2026 22:55:42 +0200 Subject: [PATCH 4/5] arm64: dts: exynos: google: zuma-husky: add the CS40L26A haptics on USI0 Add usi0 and hsi2c_0 (0x10c80000, IRQ 656) and the HSI1 pin controller (pinctrl_hsi1 at 0x12040000, IRQ 413, gph0 to gph2, alias pinctrl8) to zuma.dtsi; the pin controller is disabled there and the board enables it, as HSI1 is the PCIe block and every zuma board would otherwise probe it. The board file gets the CS40L26A at 0x43 with the stock boost, actuator and brownout values from Google's zuma-shusky-haptics.dtsi (2.5 A, 11 V, 145 Hz, 13 ohm, 3.008 V), INTb on gpa6-3 and RESET on gph2-3. USI0 sits on CMU_PERIC1 and SYSREG_PERIC1, which the board file enables since the hsi2c_11 change. Tested on a Pixel 8 Pro with 7.3.0-rc6: the chip answers (ID 0x40a260, revision 0xa1), firmware 7.2.91 runs from cs40l26.wmfw and cs40l26.bin (taken from the owner's own image, not in the repo), and a force-feedback rumble effect vibrates the phone. Signed-off-by: Lef --- .../boot/dts/exynos/google/zuma-husky.dts | 39 ++++++++ .../boot/dts/exynos/google/zuma-pinctrl.dtsi | 48 ++++++++++ arch/arm64/boot/dts/exynos/google/zuma.dtsi | 89 +++++++++++++++++++ 3 files changed, 176 insertions(+) diff --git a/arch/arm64/boot/dts/exynos/google/zuma-husky.dts b/arch/arm64/boot/dts/exynos/google/zuma-husky.dts index 9cf4a9f5a1..a7fcee3e14 100644 --- a/arch/arm64/boot/dts/exynos/google/zuma-husky.dts +++ b/arch/arm64/boot/dts/exynos/google/zuma-husky.dts @@ -382,3 +382,42 @@ interrupt-names = "host-wakeup"; }; }; + +/* + * Haptics: Cirrus Logic CS40L26A at 0x43 on PERIC1 USI0 (Google's I2C bus 0, + * 1 MHz in stock, 400 kHz here), INTb on gpa6-3, RESET on gph2-3 (the + * trigger line gph2-0 is claimed but unused). Boost and actuator values are + * the stock ones from Google's zuma-shusky-haptics.dtsi, as on the 7 Pro. + */ +/* + * The HSI1 pin controller is off in zuma.dtsi (HSI1 is the PCIe block, and + * reading a pin controller Linux does not own has aborted the SoC on gs101), + * so this board enables it for the haptics' reset and trigger lines. The + * interrupt, gpa6-3, is on an alive bank. + */ +&pinctrl_hsi1 { + status = "okay"; +}; + +&usi0 { + status = "okay"; +}; + +&hsi2c_0 { + clock-frequency = <400000>; + status = "okay"; + + haptics: haptic-driver@43 { + compatible = "cirrus,cs40l26a"; + reg = <0x43>; + interrupts-extended = <&gpa6 3 IRQ_TYPE_LEVEL_LOW>; + reset-gpios = <&gph2 3 GPIO_ACTIVE_LOW>; + pinctrl-0 = <&hapt_amp1_irq &hapt_amp1_rst &hapt_amp_trig>; + pinctrl-names = "default"; + cirrus,boost-peak-microamp = <2500000>; + cirrus,boost-ctl-microvolt = <11000000>; + cirrus,lra-f0-hz = <145>; + cirrus,lra-redc-micro-ohms = <13000000>; + cirrus,vpbr-threshold-microvolt = <3008000>; + }; +}; diff --git a/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi b/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi index 69c1a19993..ada6e943f3 100644 --- a/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi +++ b/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi @@ -191,6 +191,14 @@ samsung,pin-pud = ; samsung,pin-drv = ; }; + + /* Haptics INTb: gpa6-3 (XEINT_11), as stock. */ + hapt_amp1_irq: hapt-amp1-irq-pins { + samsung,pins = "gpa6-3"; + samsung,pin-function = ; + samsung,pin-pud = ; + samsung,pin-drv = ; + }; }; &pinctrl_custom_alive { @@ -439,7 +447,47 @@ }; }; +&pinctrl_hsi1 { + gph0: gph0-gpio-bank { + gpio-controller; + #gpio-cells = <2>; + }; + + gph1: gph1-gpio-bank { + gpio-controller; + #gpio-cells = <2>; + }; + + gph2: gph2-gpio-bank { + gpio-controller; + #gpio-cells = <2>; + }; + + /* Haptics (CS40L26A): RESET gph2-3, TRIG gph2-0, from Google's zuma-shusky-haptics.dtsi. */ + hapt_amp1_rst: hapt-amp1-rst-pins { + samsung,pins = "gph2-3"; + samsung,pin-function = ; + samsung,pin-pud = ; + samsung,pin-drv = ; + }; + + hapt_amp_trig: hapt-amp-trig-pins { + samsung,pins = "gph2-0"; + samsung,pin-function = ; + samsung,pin-pud = ; + samsung,pin-drv = ; + }; +}; + &pinctrl_peric1 { + /* USI0, the haptics driver's bus: gpp19-0/1 in function 3, as stock. */ + hsi2c0_bus: hsi2c0-bus-pins { + samsung,pins = "gpp19-0", "gpp19-1"; + samsung,pin-function = ; + samsung,pin-pud = ; + samsung,pin-drv = ; + }; + gpp19: gpp19-gpio-bank { gpio-controller; #gpio-cells = <2>; diff --git a/arch/arm64/boot/dts/exynos/google/zuma.dtsi b/arch/arm64/boot/dts/exynos/google/zuma.dtsi index bd28448a3a..b4416d2b8c 100644 --- a/arch/arm64/boot/dts/exynos/google/zuma.dtsi +++ b/arch/arm64/boot/dts/exynos/google/zuma.dtsi @@ -26,6 +26,7 @@ aliases { pinctrl0 = &pinctrl_gpio_alive; pinctrl1 = &pinctrl_custom_alive; + pinctrl8 = &pinctrl_hsi1; pinctrl10 = &pinctrl_hsi2ufs; pinctrl11 = &pinctrl_peric0; pinctrl12 = &pinctrl_peric1; @@ -347,6 +348,15 @@ interrupts = ; }; + pinctrl_hsi1: pinctrl@12040000 { + compatible = "google,zuma-pinctrl"; + reg = <0x12040000 0x1000>; + clocks = <&clk_gpio_stub>; + clock-names = "pclk"; + interrupts = ; + status = "disabled"; + }; + pinctrl_peric1: pinctrl@10c40000 { compatible = "google,zuma-pinctrl"; reg = <0x10c40000 0x1000>; @@ -360,6 +370,54 @@ * charger and Type-C controller. Firmware leaves them running; * board files enable them. */ + /* CMU_PERIC0 and USI14, the I2C bus of the rear flash LED. */ + cmu_peric0: clock-controller@10800000 { + compatible = "google,zuma-cmu-peric0"; + reg = <0x10800000 0x8000>; + #clock-cells = <1>; + clocks = <&oscclk>, <&cmu_top CLK_DOUT_PERIC0_NOC>, + <&cmu_top CLK_DOUT_PERIC0_IP>; + clock-names = "oscclk", "bus", "ip"; + status = "disabled"; + }; + + sysreg_peric0: syscon@10821000 { + compatible = "google,zuma-peric0-sysreg", "syscon"; + reg = <0x10821000 0x1000>; + clocks = <&cmu_peric0 CLK_GOUT_PERIC0_SYSREG>; + status = "disabled"; + }; + + usi14: usi@109800c0 { + compatible = "google,zuma-usi", "samsung,exynos850-usi"; + reg = <0x109800c0 0x20>; + clocks = <&cmu_peric0 CLK_GOUT_PERIC0_USI14_PCLK>, + <&cmu_peric0 CLK_GOUT_PERIC0_USI14_IPCLK>; + clock-names = "pclk", "ipclk"; + samsung,sysreg = <&sysreg_peric0 0x28>; + samsung,mode = ; + #address-cells = <1>; + #size-cells = <1>; + ranges; + status = "disabled"; + + hsi2c_14: i2c@10980000 { + compatible = "google,zuma-hsi2c", + "samsung,exynosautov9-hsi2c"; + /* USI control starts at 0xc0; do not claim it twice. */ + reg = <0x10980000 0xc0>; + interrupts = ; + clocks = <&cmu_peric0 CLK_GOUT_PERIC0_USI14_IPCLK>, + <&cmu_peric0 CLK_GOUT_PERIC0_USI14_PCLK>; + clock-names = "hsi2c", "hsi2c_pclk"; + pinctrl-0 = <&hsi2c14_bus>; + pinctrl-names = "default"; + #address-cells = <1>; + #size-cells = <0>; + status = "disabled"; + }; + }; + cmu_peric1: clock-controller@10c00000 { compatible = "google,zuma-cmu-peric1"; reg = <0x10c00000 0x8000>; @@ -407,6 +465,37 @@ }; }; + /* USI0 on PERIC1: the haptics driver's I2C bus on the 8 Pro. */ + usi0: usi@10c800c0 { + compatible = "google,zuma-usi", "samsung,exynos850-usi"; + reg = <0x10c800c0 0x20>; + clocks = <&cmu_peric1 CLK_GOUT_PERIC1_USI0_PCLK>, + <&cmu_peric1 CLK_GOUT_PERIC1_USI0_IPCLK>; + clock-names = "pclk", "ipclk"; + samsung,sysreg = <&sysreg_peric1 0x0>; + samsung,mode = ; + #address-cells = <1>; + #size-cells = <1>; + ranges; + status = "disabled"; + + hsi2c_0: i2c@10c80000 { + compatible = "google,zuma-hsi2c", + "samsung,exynosautov9-hsi2c"; + /* USI control starts at 0xc0; do not claim it twice. */ + reg = <0x10c80000 0xc0>; + interrupts = ; + clocks = <&cmu_peric1 CLK_GOUT_PERIC1_USI0_IPCLK>, + <&cmu_peric1 CLK_GOUT_PERIC1_USI0_PCLK>; + clock-names = "hsi2c", "hsi2c_pclk"; + pinctrl-0 = <&hsi2c0_bus>; + pinctrl-names = "default"; + #address-cells = <1>; + #size-cells = <0>; + status = "disabled"; + }; + }; + usi11: usi@10cb00c0 { compatible = "google,zuma-usi", "samsung,exynos850-usi"; reg = <0x10cb00c0 0x20>; From 25079bba8f9171ba0e126c053e6ea550a164f1ef Mon Sep 17 00:00:00 2001 From: Lef Date: Wed, 4 Nov 2026 22:55:42 +0200 Subject: [PATCH 5/5] arm64: dts: exynos: google: zuma-husky: add the rear flash LED (LM3644) Add cmu_peric0, sysreg_peric0, usi14 and hsi2c_14 (0x10980000, IRQ 648) to zuma.dtsi, and the pins hsi2c14_bus (gpp16-0 and gpp16-1, function 2) and flash_en (gpp8-2). The board file gets the LM3644 at 0x63 with HWEN on gpp8-2 and the 7 Pro's bring-up cap of 50 mA per LED (not a stock value), and enables cmu_peric0 and sysreg_peric0, which stay off in zuma.dtsi like PERIC1. Tested on a Pixel 8 Pro with 7.3.0-rc6: the chip is found (LM3644TT, ID 0x04), the LED class white:torch has 17 steps from 2550 to 49110 uA and lights the rear LED. Signed-off-by: Lef --- .../boot/dts/exynos/google/zuma-husky.dts | 42 +++++++++++++++++++ .../boot/dts/exynos/google/zuma-pinctrl.dtsi | 16 +++++++ arch/arm64/boot/dts/exynos/google/zuma.dtsi | 10 ++--- 3 files changed, 63 insertions(+), 5 deletions(-) diff --git a/arch/arm64/boot/dts/exynos/google/zuma-husky.dts b/arch/arm64/boot/dts/exynos/google/zuma-husky.dts index a7fcee3e14..6ed1514cba 100644 --- a/arch/arm64/boot/dts/exynos/google/zuma-husky.dts +++ b/arch/arm64/boot/dts/exynos/google/zuma-husky.dts @@ -7,6 +7,7 @@ #include #include +#include #include #include #include "zuma.dtsi" @@ -421,3 +422,44 @@ cirrus,vpbr-threshold-microvolt = <3008000>; }; }; + +/* + * Rear flash LED: TI LM3644 at 0x63 on PERIC0 USI14 (Google's I2C bus 14, + * 390 kHz in stock, 400 kHz here), HWEN on gpp8-2. Stock drives it from the + * camera HAL through LWIS. Torch only; the cap is the 7 Pro's bring-up limit + * (50 mA per LED), not a stock value. CMU_PERIC0 and its sysreg are enabled + * here, as CMU_PERIC1 is for the haptics: the torch's I2C bus (USI14) sits + * on them. + */ +&cmu_peric0 { + status = "okay"; +}; + +&sysreg_peric0 { + status = "okay"; +}; + +&usi14 { + status = "okay"; +}; + +&hsi2c_14 { + clock-frequency = <400000>; + /* The bus pins and HWEN's mux, as in Google's zuma-husky-camera.dtsi. */ + pinctrl-0 = <&hsi2c14_bus &flash_en>; + pinctrl-names = "default"; + status = "okay"; + + led-controller@63 { + compatible = "ti,lm3644"; + reg = <0x63>; + enable-gpios = <&gpp8 2 GPIO_ACTIVE_HIGH>; + + led { + function = LED_FUNCTION_TORCH; + color = ; + led-sources = <1 2>; + led-max-microamp = <50000>; + }; + }; +}; diff --git a/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi b/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi index ada6e943f3..74b6905631 100644 --- a/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi +++ b/arch/arm64/boot/dts/exynos/google/zuma-pinctrl.dtsi @@ -445,6 +445,22 @@ interrupt-controller; #interrupt-cells = <2>; }; + + /* USI14, the rear flash LED's bus: gpp16-0/1 in function 2, as stock. */ + hsi2c14_bus: hsi2c14-bus-pins { + samsung,pins = "gpp16-0", "gpp16-1"; + samsung,pin-function = ; + samsung,pin-pud = ; + samsung,pin-drv = ; + }; + + /* The LM3644's HWEN (flashlight enable), gpp8-2; the LED driver takes it as a GPIO. */ + flash_en: flash-en-pins { + samsung,pins = "gpp8-2"; + samsung,pin-function = ; + samsung,pin-pud = ; + samsung,pin-drv = ; + }; }; &pinctrl_hsi1 { diff --git a/arch/arm64/boot/dts/exynos/google/zuma.dtsi b/arch/arm64/boot/dts/exynos/google/zuma.dtsi index b4416d2b8c..21c184ae87 100644 --- a/arch/arm64/boot/dts/exynos/google/zuma.dtsi +++ b/arch/arm64/boot/dts/exynos/google/zuma.dtsi @@ -365,11 +365,6 @@ interrupts = ; }; - /* - * CMU_PERIC1 and USI11, the I2C bus of the MAX77759 gauge, - * charger and Type-C controller. Firmware leaves them running; - * board files enable them. - */ /* CMU_PERIC0 and USI14, the I2C bus of the rear flash LED. */ cmu_peric0: clock-controller@10800000 { compatible = "google,zuma-cmu-peric0"; @@ -418,6 +413,11 @@ }; }; + /* + * CMU_PERIC1 and USI11, the I2C bus of the MAX77759 gauge, + * charger and Type-C controller. Firmware leaves them running; + * board files enable them. + */ cmu_peric1: clock-controller@10c00000 { compatible = "google,zuma-cmu-peric1"; reg = <0x10c00000 0x8000>;