// SPDX-License-Identifier: (GPL-2.0+ OR MIT) /* * Copyright (c) 2022 Rockchip Electronics Co., Ltd. */ /dts-v1/; #include "rv1106.dtsi" #include "rv1106-amp.dtsi" #include #include #include / { model = "Rockchip RV1106G CoolPi NANO Board"; compatible = "rockchip,rv1106"; aliases { serial0 = &uart2; serial1 = &uart1; serial2 = &uart0; serial3 = &uart3; serial4 = &uart4; serial5 = &uart5; }; adc-keys { compatible = "adc-keys"; io-channels = <&saradc 0>; io-channel-names = "buttons"; poll-interval = <100>; keyup-threshold-microvolt = <1800000>; status = "disabled"; key_volumeup-key { label = "key_volumeup"; linux,code = ; press-threshold-microvolt = <0>; }; key_volumedown-key { label = "key_volumedown"; linux,code = ; press-threshold-microvolt = <400781>; }; }; restart-poweroff { compatible = "restart-poweroff"; }; acodec_sound: acodec-sound { compatible = "simple-audio-card"; simple-audio-card,name = "rv-acodec"; simple-audio-card,format = "i2s"; simple-audio-card,mclk-fs = <256>; simple-audio-card,cpu { sound-dai = <&i2s0_8ch>; }; simple-audio-card,codec { sound-dai = <&acodec>; }; }; vcc_1v8: vcc-1v8 { compatible = "regulator-fixed"; regulator-name = "vcc_1v8"; regulator-always-on; regulator-boot-on; regulator-min-microvolt = <1800000>; regulator-max-microvolt = <1800000>; }; vcc_3v3: vcc-3v3 { compatible = "regulator-fixed"; regulator-name = "vcc_3v3"; regulator-always-on; regulator-boot-on; regulator-min-microvolt = <3300000>; regulator-max-microvolt = <3300000>; }; vdd_arm: vdd-arm { compatible = "pwm-regulator"; pwms = <&pwm0 0 5000 1>; regulator-name = "vdd_arm"; regulator-min-microvolt = <724000>; regulator-max-microvolt = <1078000>; regulator-init-microvolt = <950000>; regulator-always-on; regulator-boot-on; regulator-settling-time-up-us = <250>; }; vcc3v3_sd: vcc3v3-sd { compatible = "regulator-fixed"; regulator-name = "vcc3v3_sd"; regulator-always-on; regulator-boot-on; regulator-min-microvolt = <3300000>; regulator-max-microvolt = <3300000>; }; vcc5v0_otg: vcc5v0-otg { compatible = "regulator-fixed"; regulator-name = "vcc5v0_otg"; regulator-boot-on; regulator-always-on; regulator-min-microvolt = <5000000>; regulator-max-microvolt = <5000000>; }; #if 1 io_switch: io-switch { compatible = "regulator-fixed"; regulator-name = "sig_switch"; regulator-boot-on; regulator-always-on; enable-active-high; gpio = <&gpio4 RK_PC1 GPIO_ACTIVE_HIGH>; pinctrl-names = "default"; pinctrl-0 = <&sig_switch>; }; #endif #if 0 hub_rst: hub-rst { compatible = "regulator-fixed"; regulator-name = "hub_rst"; regulator-boot-on; regulator-always-on; enable-active-high; gpio = <&gpio0 RK_PA2 GPIO_ACTIVE_HIGH>; }; #endif #if 1 vcc3v3_mipi: vcc3v3-mipi { compatible = "regulator-fixed"; regulator-name = "vcc3v3_mipi"; regulator-boot-on; regulator-always-on; enable-active-high; gpio = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>; }; #endif leds { compatible = "gpio-leds"; pinctrl-names = "default"; pinctrl-0 = <&gpio_leds>; status = "okay"; led1 { label = "run"; gpios = <&gpio4 RK_PC0 GPIO_ACTIVE_HIGH>; linux,default-trigger = "heartbeat"; }; led2 { label = "act"; gpios = <&gpio3 RK_PC7 GPIO_ACTIVE_HIGH>; linux,default-trigger = "netdev"; default-state = "off"; }; led3 { label = "link"; gpios = <&gpio3 RK_PD0 GPIO_ACTIVE_HIGH>; linux,default-trigger = "netdev"; default-state = "off"; }; }; xin12m: xin12m { compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <12288000>; clock-output-names = "xin12m"; }; reserved-memory { #address-cells = <1>; #size-cells = <1>; ranges; linux,cma { compatible = "shared-dma-pool"; inactive; reusable; size = <0x1000000>; linux,cma-default; }; drm_logo: drm-logo@00000000 { compatible = "rockchip,drm-logo"; reg = <0x0 0x0>; }; }; }; &fiq_debugger { rockchip,irq-mode-enable = <1>; status = "disabled"; }; &gmac { status = "okay"; }; &i2s0_8ch { status = "okay"; }; &mpp_srv { status = "okay"; }; &mpp_vcodec { status = "okay"; }; &npu { status = "okay"; }; &rga2 { status = "okay"; }; &rkdvbm { status = "okay"; }; &rkvenc { status = "okay"; }; &rkvenc_pp { status = "okay"; }; &rng { status = "okay"; }; &rve { status = "okay"; }; &tsadc { status = "okay"; }; &u2phy { status = "okay"; }; &u2phy_otg { vbus-supply = <&vcc5v0_otg>; status = "okay"; }; &usbdrd { status = "okay"; }; &usbdrd_dwc3 { dr_mode = "host"; extcon = <&u2phy>; status = "okay"; }; &acodec { #sound-dai-cells = <0>; pa-ctl-gpios = <&gpio1 RK_PA1 GPIO_ACTIVE_HIGH>; status = "okay"; }; &cpu0 { cpu-supply = <&vdd_arm>; }; &csi2_dphy_hw { status = "okay"; }; &csi2_dphy0 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; csi_dphy_input: endpoint@1 { reg = <1>; remote-endpoint = <&ov5647_out>; data-lanes = <1 2>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; csi_dphy_output: endpoint@0 { reg = <0>; remote-endpoint = <&mipi_csi2_input>; }; }; }; }; &uart0 { pinctrl-names = "default"; pinctrl-0 = <&uart0m0_xfer>; status = "okay"; }; &uart1 { pinctrl-names = "default"; pinctrl-0 = <&uart1m0_xfer>; status = "okay"; }; &uart2 { pinctrl-names = "default"; pinctrl-0 = <&uart2m1_xfer>; status = "okay"; }; &uart4 { pinctrl-names = "default"; pinctrl-0 = <&uart4m0_xfer>; status = "okay"; }; &i2c1 { status = "okay"; clock-frequency = <400000>; rk618@50 { compatible = "rockchip,rk618"; reg = <0x50>; pinctrl-names = "default"; pinctrl-0 = <&rk618_int>; clocks = <&xin12m>; clock-names = "clkin"; reset-gpios = <&gpio0 RK_PA2 GPIO_ACTIVE_LOW>; status = "okay"; clock: cru { compatible = "rockchip,rk618-cru"; clocks = <&xin12m>; clock-names = "clkin"; assigned-clocks = <&clock SCALER_PLLIN_CLK>, <&clock VIF_PLLIN_CLK>, <&clock SCALER_CLK>, <&clock VIF0_PRE_CLK>, <&clock CODEC_CLK>, <&clock DITHER_CLK>; assigned-clock-parents = <&xin12m>, <&clock LCDC0_CLK>, <&clock SCALER_PLL_CLK>, <&clock VIF_PLL_CLK>, <&clock VIF0_CLK>; #clock-cells = <1>; status = "okay"; }; hdmi { compatible = "rockchip,rk618-hdmi"; clocks = <&clock HDMI_CLK>; clock-names = "hdmi"; assigned-clocks = <&clock HDMI_CLK>; assigned-clock-parents = <&clock VIF0_CLK>; interrupt-parent = <&gpio0>; interrupts = <3 IRQ_TYPE_LEVEL_HIGH>; status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; hdmi_in_rgb: endpoint { remote-endpoint = <&rgb_out_hdmi>; }; }; }; }; }; }; &i2c3 { pinctrl-names = "default"; pinctrl-0 = <&i2c3m2_xfer>; status = "okay"; ov5647: ov5647@36 { status = "okay"; compatible = "ovti,ov5647"; reg = <0x36>; clocks = <&cru MCLK_REF_MIPI0>; clock-names = "xvclk"; pinctrl-names = "default"; pinctrl-0 = <&mipi_refclk_out0>; pwdn-gpios = <&gpio0 RK_PA4 GPIO_ACTIVE_HIGH>; rockchip,camera-module-index = <1>; rockchip,camera-module-facing = "front"; rockchip,camera-module-name = "THDS11073LarganCAM0"; rockchip,camera-module-lens-name = "40122a1"; port { ov5647_out: endpoint { remote-endpoint = <&csi_dphy_input>; data-lanes = <1 2>; }; }; }; }; &display_subsystem { logo-memory-region = <&drm_logo>; status = "okay"; }; &rgb { status = "okay"; pinctrl-names = "default"; pinctrl-0 = <&lcd_pins>; ports { port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; rgb_out_hdmi: endpoint@0 { reg = <0>; remote-endpoint = <&hdmi_in_rgb>; }; }; }; }; &rgb_in_vop { status = "okay"; }; &route_rgb { status = "okay"; }; &vop { status = "okay"; }; &mipi0_csi2 { status = "okay"; ports { #address-cells = <1>; #size-cells = <0>; port@0 { reg = <0>; #address-cells = <1>; #size-cells = <0>; mipi_csi2_input: endpoint@1 { reg = <1>; remote-endpoint = <&csi_dphy_output>; }; }; port@1 { reg = <1>; #address-cells = <1>; #size-cells = <0>; mipi_csi2_output: endpoint@0 { reg = <0>; remote-endpoint = <&cif_mipi_in>; }; }; }; }; &pwm0 { status = "okay"; }; &rkcif { status = "okay"; }; &rkcif_mipi_lvds { status = "okay"; pinctrl-names = "default"; pinctrl-0 = <&mipi_pins>; port { /* MIPI CSI-2 endpoint */ cif_mipi_in: endpoint { remote-endpoint = <&mipi_csi2_output>; }; }; }; &rkcif_mipi_lvds_sditf { status = "okay"; port { /* MIPI CSI-2 endpoint */ mipi_lvds_sditf: endpoint { remote-endpoint = <&isp_in>; }; }; }; &rkisp { status = "okay"; }; &rkisp_vir0 { status = "okay"; port@0 { isp_in: endpoint { remote-endpoint = <&mipi_lvds_sditf>; }; }; }; &saradc { status = "disabled"; vref-supply = <&vcc_1v8>; }; &sfc { status = "disabled"; flash@0 { compatible = "jedec,spi-nor"; reg = <0>; spi-max-frequency = <80000000>; spi-rx-bus-width = <4>; spi-tx-bus-width = <1>; }; }; &emmc { bus-width = <4>; pinctrl-names = "default"; pinctrl-0 = <&emmc_clk &emmc_cmd &emmc_bus4>; status = "okay"; }; &sdmmc { max-frequency = <50000000>; no-sdio; no-mmc; bus-width = <4>; cap-mmc-highspeed; cap-sd-highspeed; disable-wp; card-detect-delay = <800>; pinctrl-names = "default"; pinctrl-0 = <&sdmmc0_clk &sdmmc0_cmd &sdmmc0_det &sdmmc0_bus4>; vmmc-supply = <&vcc3v3_sd>; status = "okay"; }; &pinctrl { signal-enable { sig_switch: sig-siwtch { rockchip,pins = <4 RK_PC1 RK_FUNC_GPIO &pcfg_pull_up>; }; }; led { gpio_leds: gpio-leds { rockchip,pins = <4 RK_PC0 RK_FUNC_GPIO &pcfg_pull_down>, <3 RK_PC7 RK_FUNC_GPIO &pcfg_pull_down>, <3 RK_PD0 RK_FUNC_GPIO &pcfg_pull_down>; }; }; rk618 { rk618_reset: rk618-reeset { rockchip,pins = <0 RK_PA2 RK_FUNC_GPIO &pcfg_output_high>; }; rk618_int: rk618-int { rockchip,pins = <0 RK_PA3 RK_FUNC_GPIO &pcfg_pull_none>; }; }; };