Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed rockchio6.10 tinker-edge-r bug #7112

Open
wants to merge 12 commits into
base: main
Choose a base branch
from
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
From b95c594a0969e469ef627c3e1724566dc5aa3016 Mon Sep 17 00:00:00 2001
From: ARC-MX <wmx129674@126.com>
Date: Thu, 25 Jul 2024 17:44:54 +0800
Subject: [PATCH] drivers:regulator:fan53555:add new device chip id

drivers:regulator:fan53555

When I use fan53555, I see an error:

FAN53555-regulator 0-0060: Chip ID 0 with rev 12 not supported!

So I fixed this bug

Signed-off-by: ARC-MX <wmx129674@126.com>
---
drivers/regulator/fan53555.c | 5 +++++
1 file changed, 5 insertions(+)

diff --git a/drivers/regulator/fan53555.c b/drivers/regulator/fan53555.c
index 17c9bf204..c8a2e9405 100644
--- a/drivers/regulator/fan53555.c
+++ b/drivers/regulator/fan53555.c
@@ -113,6 +113,7 @@ enum {
enum {
FAN53555_CHIP_REV_00 = 0x3,
FAN53555_CHIP_REV_13 = 0xf,
+ FAN53555_CHIP_REV_23 = 0xc,
};

enum {
@@ -301,6 +302,10 @@ static int fan53555_voltages_setup_fairchild(struct fan53555_device_info *di)
di->vsel_min = 800000;
di->vsel_step = 10000;
break;
+ case FAN53555_CHIP_REV_23:
+ di->vsel_min = 600000;
+ di->vsel_step = 12500;
+ break;
default:
dev_err(di->dev,
"Chip ID %d with rev %d not supported!\n",
--
2.25.1
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You may want to update your Git version or your OS release, this version is 4 years old.


Original file line number Diff line number Diff line change
Expand Up @@ -33,13 +33,13 @@

pwr-led {
gpios = <&gpio0 RK_PA5 GPIO_ACTIVE_HIGH>;
linux,default-trigger = "default-on";
linux,default-trigger = "heartbeat";
retain-state-suspended = <1>;
};

act-led {
gpios = <&gpio0 RK_PA3 GPIO_ACTIVE_HIGH>;
linux,default-trigger="mmc0";
linux,default-trigger="cpu";
};

rsv-led {
Expand Down Expand Up @@ -83,6 +83,14 @@
status = "okay";
};

vcc1v8_s0: vcc1v8-s0 {
compatible = "regulator-fixed";
regulator-name = "vcc1v8_s0";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-always-on;
};

vdd_3v3_reg: fixedregulator_3v3 {
compatible = "regulator-fixed";
regulator-name = "3v3";
Expand Down Expand Up @@ -114,6 +122,23 @@
regulator-name = "vbus_typec";
};

vcca0v9_s3: vcca0v9-s3 {
compatible = "regulator-fixed";
regulator-min-microvolt = <900000>;
regulator-max-microvolt = <900000>;
regulator-name = "vcca0v9_s3";
vin-supply = <&vcc1v8_s0>;
};

/* As above, actually supplied by vcc3v3_sys */
vcca1v8_s3: vcca1v8-s3 {
compatible = "regulator-fixed";
regulator-min-microvolt = <1800000>;
regulator-max-microvolt = <1800000>;
regulator-name = "vcca1v8_s3";
vin-supply = <&vcc1v8_s0>;
};

backlight: backlight {
status = "disabled";
compatible = "pwm-backlight";
Expand Down Expand Up @@ -199,7 +224,7 @@
compatible = "linux,spdif-dit";
#sound-dai-cells = <0>;
};

hdmi_dp_sound: hdmi-dp-sound {
status = "okay";
compatible = "rockchip,rk3399-hdmi-dp";
Expand Down Expand Up @@ -280,11 +305,23 @@
<000000000 0x0000 0x0000 0x0000>;
};

&hdmi_in_vopb {
status = "okay";
};

&hdmi_in_vopl {
status = "disabled";
};

&vopb {
&dp_in_vopl {
status = "disable";
};

&dp_in_vopb {
status = "okay";
};

&vopb {
status = "okay";
// assigned-clocks = <&cru DCLK_VOP0_DIV>;
// assigned-clock-parents = <&cru PLL_VPLL>;
Expand Down Expand Up @@ -732,6 +769,12 @@
};

&pcie0 {
pinctrl-0 = <&pcie_clkreqnb_cpm>;
bus-scan-delay-ms = <0>;
pinctrl-names = "default";
vpcie0v9-supply = <&vcca0v9_s3>; /* VCC_0V9_S0 */
vpcie1v8-supply = <&vcc1v8_s0>; /* VCC_1V8_S0 */
vpcie3v3-supply = <&vccio_3v3>;
status = "okay";
};

Expand Down Expand Up @@ -993,7 +1036,7 @@
};
vsel2_gpio: vsel2-gpio {
rockchip,pins =
<1 RK_PB6 0 &pcfg_pull_down>;
<1 RK_PB6 RK_FUNC_GPIO &pcfg_pull_down>;
};

soc_slppin_gpio: soc-slppin-gpio {
Expand Down Expand Up @@ -1077,4 +1120,3 @@
// };
// };
};