From 63b8874120c970d45718d71531c71b472873923f Mon Sep 17 00:00:00 2001 From: =?utf8?q?=E5=BC=A0=E6=99=B4?= Date: Mon, 17 Mar 2014 10:31:10 +0800 Subject: [PATCH] rk3288:pmic&pwm:set defult voltage --- arch/arm/boot/dts/rk3288-tb.dts | 53 ++++++++++++++++++++++------- arch/arm/configs/rockchip_defconfig | 1 + 2 files changed, 42 insertions(+), 12 deletions(-) diff --git a/arch/arm/boot/dts/rk3288-tb.dts b/arch/arm/boot/dts/rk3288-tb.dts index c449365a153f..4605b94e13eb 100755 --- a/arch/arm/boot/dts/rk3288-tb.dts +++ b/arch/arm/boot/dts/rk3288-tb.dts @@ -16,7 +16,32 @@ backlight { enable-gpios = <&gpio7 GPIO_A2 GPIO_ACTIVE_HIGH>; }; -codec_hdmi_i2s: codec-hdmi-i2s { +pwm_regulator { + compatible = "rockchip_pwm_regulator"; + pwms = <&pwm1 0 25000>; + rockchip,pwm_id= <1>; + rockchip,pwm_voltage_map= <925000 950000 975000 1000000 1025000 1050000 1075000 1100000 1125000 1150000 1175000 1200000 1225000 1250000 1275000 1300000 1325000 1350000 1375000 1400000>; + rockchip,pwm_voltage= <1000000>; + rockchip,pwm_min_voltage= <925000>; + rockchip,pwm_max_voltage= <1400000>; + rockchip,pwm_suspend_voltage= <950000>; + rockchip,pwm_coefficient= <475>; + regulators { + #address-cells = <1>; + #size-cells = <0>; + pwm_reg0: regulator@0{ + regulator-compatible = "pwm_dcdc1"; + regulator-name= "vdd_logic"; + regulator-min-microvolt = <925000>; + regulator-max-microvolt = <1400000>; + regulator-always-on; + regulator-boot-on; + }; + }; + }; + + + codec_hdmi_i2s: codec-hdmi-i2s { compatible = "hdmi-i2s"; }; @@ -35,14 +60,14 @@ codec_hdmi_i2s: codec-hdmi-i2s { bq24296: bq24296@6b { compatible = "ti,bq24296"; reg = <0x6b>; -/* gpios = <&gpio0 GPIO_A7 GPIO_ACTIVE_HIGH>; */ - bq24296,chg_current = <1000 500 2000>; + gpios = <&gpio0 GPIO_A7 GPIO_ACTIVE_HIGH>; + bq24296,chg_current = <1000 500 2000>; status = "disable"; }; bq27320: bq27320@55 { compatible = "ti,bq27320"; reg = <0x55>; -/* gpios = <&gpio0 GPIO_A7 GPIO_ACTIVE_HIGH>; */ + /* gpios = <&gpio0 GPIO_A7 GPIO_ACTIVE_HIGH>; */ status = "disable"; }; }; @@ -220,10 +245,14 @@ codec_hdmi_i2s: codec-hdmi-i2s { }; }; +&pwm1 { + status = "okay"; +}; + /include/ "rk808.dtsi" &rk808 { - gpios =<&gpio0 GPIO_B3 GPIO_ACTIVE_HIGH>,<&gpio0 GPIO_A1 GPIO_ACTIVE_LOW>; + gpios =<&gpio0 GPIO_A4 GPIO_ACTIVE_HIGH>,<&gpio0 GPIO_B3 GPIO_ACTIVE_LOW>; regulators { @@ -234,7 +263,7 @@ codec_hdmi_i2s: codec-hdmi-i2s { }; rk808_dcdc2_reg: regulator@1 { - regulator-name= "vdd_logic"; + regulator-name= "vdd_gpu"; regulator-always-on; regulator-boot-on; }; @@ -289,16 +318,16 @@ codec_hdmi_i2s: codec-hdmi-i2s { rk808_ldo5_reg: regulator@8 { regulator-name= "rk_ldo5"; - regulator-min-microvolt = <2800000>; - regulator-max-microvolt = <2800000>; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; regulator-always-on; regulator-boot-on; }; rk808_ldo6_reg: regulator@9 { regulator-name= "rk_ldo6"; - regulator-min-microvolt = <1200000>; - regulator-max-microvolt = <1200000>; + regulator-min-microvolt = <1000000>; + regulator-max-microvolt = <1000000>; regulator-always-on; regulator-boot-on; }; @@ -313,8 +342,8 @@ codec_hdmi_i2s: codec-hdmi-i2s { rk808_ldo8_reg: regulator@11 { regulator-name= "rk_ldo8"; - regulator-min-microvolt = <1800000>; - regulator-max-microvolt = <1800000>; + regulator-min-microvolt = <3300000>; + regulator-max-microvolt = <3300000>; regulator-always-on; regulator-boot-on; }; diff --git a/arch/arm/configs/rockchip_defconfig b/arch/arm/configs/rockchip_defconfig index 517596d43fe6..d62e7cce96d5 100755 --- a/arch/arm/configs/rockchip_defconfig +++ b/arch/arm/configs/rockchip_defconfig @@ -309,6 +309,7 @@ CONFIG_MFD_RK808=y CONFIG_REGULATOR=y CONFIG_REGULATOR_FIXED_VOLTAGE=y CONFIG_REGULATOR_ACT8846=y +CONFIG_RK30_PWM_REGULATOR=y CONFIG_MEDIA_SUPPORT=y CONFIG_MEDIA_CAMERA_SUPPORT=y CONFIG_MEDIA_RC_SUPPORT=y -- 2.34.1