target/rockchip: refresh kernel patches

Signed-off-by: Liangbin Lian <jjm2473@gmail.com>
This commit is contained in:
Liangbin Lian 2026-06-02 21:05:26 +08:00
parent 4b300d13c6
commit e4d597e97f
29 changed files with 83 additions and 140 deletions

View File

@ -160,7 +160,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
case RK3568:
case RK3588:
pull_type = bank->pull_type[pin_num / 8];
@@ -2792,6 +2905,7 @@ static bool rockchip_pinconf_pull_valid(
@@ -2791,6 +2904,7 @@ static bool rockchip_pinconf_pull_valid(
case RK3328:
case RK3368:
case RK3399:
@ -168,7 +168,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
case RK3568:
case RK3588:
return (pull != PIN_CONFIG_BIAS_PULL_PIN_DEFAULT);
@@ -3917,6 +4031,49 @@ static struct rockchip_pin_ctrl rk3399_p
@@ -3916,6 +4030,49 @@ static struct rockchip_pin_ctrl rk3399_p
.drv_calc_reg = rk3399_calc_drv_reg_and_bit,
};
@ -218,7 +218,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
static struct rockchip_pin_bank rk3568_pin_banks[] = {
PIN_BANK_IOMUX_FLAGS(0, 32, "gpio0", IOMUX_SOURCE_PMU | IOMUX_WIDTH_4BIT,
IOMUX_SOURCE_PMU | IOMUX_WIDTH_4BIT,
@@ -4010,6 +4167,8 @@ static const struct of_device_id rockchi
@@ -4009,6 +4166,8 @@ static const struct of_device_id rockchi
.data = &rk3368_pin_ctrl },
{ .compatible = "rockchip,rk3399-pinctrl",
.data = &rk3399_pin_ctrl },

View File

@ -240,7 +240,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
case RK3588:
pull_type = bank->pull_type[pin_num / 8];
ret = -EINVAL;
@@ -2907,6 +3080,7 @@ static bool rockchip_pinconf_pull_valid(
@@ -2906,6 +3079,7 @@ static bool rockchip_pinconf_pull_valid(
case RK3399:
case RK3528:
case RK3568:
@ -248,7 +248,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
case RK3588:
return (pull != PIN_CONFIG_BIAS_PULL_PIN_DEFAULT);
}
@@ -4113,6 +4287,37 @@ static struct rockchip_pin_ctrl rk3568_p
@@ -4112,6 +4286,37 @@ static struct rockchip_pin_ctrl rk3568_p
.schmitt_calc_reg = rk3568_calc_schmitt_reg_and_bit,
};
@ -286,7 +286,7 @@ Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
static struct rockchip_pin_bank rk3588_pin_banks[] = {
RK3588_PIN_BANK_FLAGS(0, 32, "gpio0",
IOMUX_WIDTH_4BIT, PULL_TYPE_IO_1V8_ONLY),
@@ -4171,6 +4376,8 @@ static const struct of_device_id rockchi
@@ -4170,6 +4375,8 @@ static const struct of_device_id rockchi
.data = &rk3528_pin_ctrl },
{ .compatible = "rockchip,rk3568-pinctrl",
.data = &rk3568_pin_ctrl },

View File

@ -17,7 +17,7 @@ Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
--- a/drivers/gpio/gpio-rockchip.c
+++ b/drivers/gpio/gpio-rockchip.c
@@ -26,9 +26,15 @@
@@ -25,9 +25,15 @@
#include "../pinctrl/core.h"
#include "../pinctrl/pinctrl-rockchip.h"

View File

@ -16,7 +16,7 @@ Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
--- a/drivers/gpio/gpio-rockchip.c
+++ b/drivers/gpio/gpio-rockchip.c
@@ -667,8 +667,9 @@ static int rockchip_get_bank_data(struct
@@ -660,8 +660,9 @@ static int rockchip_get_bank_data(struct
clk_prepare_enable(bank->clk);
id = readl(bank->reg_base + gpio_regs_v2.version_id);
@ -28,7 +28,7 @@ Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
bank->gpio_regs = &gpio_regs_v2;
bank->gpio_type = GPIO_TYPE_V2;
bank->db_clk = of_clk_get(bank->of_node, 1);
@@ -677,9 +678,14 @@ static int rockchip_get_bank_data(struct
@@ -670,9 +671,14 @@ static int rockchip_get_bank_data(struct
clk_disable_unprepare(bank->clk);
return -EINVAL;
}

View File

@ -16,7 +16,7 @@ Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
--- a/drivers/gpio/gpio-rockchip.c
+++ b/drivers/gpio/gpio-rockchip.c
@@ -35,6 +35,7 @@
@@ -34,6 +34,7 @@
#define GPIO_TYPE_V1 (0) /* GPIO Version ID reserved */
#define GPIO_TYPE_V2 (0x01000C2B)
#define GPIO_TYPE_V2_1 (0x0101157C)
@ -24,7 +24,7 @@ Signed-off-by: Bartosz Golaszewski <bartosz.golaszewski@linaro.org>
static const struct rockchip_gpio_regs gpio_regs_v1 = {
.port_dr = 0x00,
@@ -670,6 +671,7 @@ static int rockchip_get_bank_data(struct
@@ -663,6 +664,7 @@ static int rockchip_get_bank_data(struct
switch (id) {
case GPIO_TYPE_V2:
case GPIO_TYPE_V2_1:

View File

@ -9,7 +9,7 @@ Subject: [PATCH] PCI: dw-rockchip: supports rk3528 pcie
--- a/drivers/pci/controller/dwc/pcie-dw-rockchip.c
+++ b/drivers/pci/controller/dwc/pcie-dw-rockchip.c
@@ -60,6 +60,10 @@ struct rockchip_pcie {
@@ -62,6 +62,10 @@ struct rockchip_pcie {
struct irq_domain *irq_domain;
};
@ -20,7 +20,7 @@ Subject: [PATCH] PCI: dw-rockchip: supports rk3528 pcie
static int rockchip_pcie_readl_apb(struct rockchip_pcie *rockchip,
u32 reg)
{
@@ -288,9 +292,12 @@ static int rockchip_pcie_probe(struct pl
@@ -296,9 +300,12 @@ static int rockchip_pcie_probe(struct pl
{
struct device *dev = &pdev->dev;
struct rockchip_pcie *rockchip;
@ -33,7 +33,7 @@ Subject: [PATCH] PCI: dw-rockchip: supports rk3528 pcie
rockchip = devm_kzalloc(dev, sizeof(*rockchip), GFP_KERNEL);
if (!rockchip)
return -ENOMEM;
@@ -338,6 +345,11 @@ static int rockchip_pcie_probe(struct pl
@@ -346,6 +353,11 @@ static int rockchip_pcie_probe(struct pl
if (ret)
goto deinit_phy;
@ -45,7 +45,7 @@ Subject: [PATCH] PCI: dw-rockchip: supports rk3528 pcie
ret = dw_pcie_host_init(pp);
if (!ret)
return 0;
@@ -352,7 +364,15 @@ disable_regulator:
@@ -360,7 +372,15 @@ disable_regulator:
return ret;
}

View File

@ -107,7 +107,7 @@ Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
}
static unsigned long
@@ -1295,6 +1320,9 @@ static int rockchip_usb2phy_probe(struct
@@ -1296,6 +1321,9 @@ static int rockchip_usb2phy_probe(struct
if (!dev->parent || !dev->parent->of_node ||
of_property_present(np, "rockchip,usbgrf")) {
@ -117,7 +117,7 @@ Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
rphy->grf = syscon_regmap_lookup_by_phandle(np, "rockchip,usbgrf");
if (IS_ERR(rphy->grf)) {
dev_err(dev, "failed to locate usbgrf\n");
@@ -1304,6 +1332,7 @@ static int rockchip_usb2phy_probe(struct
@@ -1305,6 +1333,7 @@ static int rockchip_usb2phy_probe(struct
else {
rphy->grf = syscon_node_to_regmap(dev->parent->of_node);

View File

@ -28,7 +28,7 @@ Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
--- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
+++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
@@ -1468,6 +1468,28 @@ put_child:
@@ -1465,6 +1465,28 @@ put_child:
return ret;
}
@ -57,7 +57,7 @@ Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
static int rk3588_usb2phy_tuning(struct rockchip_usb2phy *rphy)
{
int ret;
@@ -1763,6 +1785,54 @@ static const struct rockchip_usb2phy_cfg
@@ -1760,6 +1782,54 @@ static const struct rockchip_usb2phy_cfg
{ /* sentinel */ }
};
@ -112,7 +112,7 @@ Signed-off-by: Jonas Karlman <jonas@kwiboo.se>
static const struct rockchip_usb2phy_cfg rk3568_phy_cfgs[] = {
{
.reg = 0xfe8a0000,
@@ -1999,6 +2069,7 @@ static const struct of_device_id rockchi
@@ -1996,6 +2066,7 @@ static const struct of_device_id rockchi
{ .compatible = "rockchip,rk3328-usb2phy", .data = &rk3328_phy_cfgs },
{ .compatible = "rockchip,rk3366-usb2phy", .data = &rk3366_phy_cfgs },
{ .compatible = "rockchip,rk3399-usb2phy", .data = &rk3399_phy_cfgs },

View File

@ -83,7 +83,7 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
init.parent_names = &clk_name;
init.num_parents = 1;
} else {
@@ -1387,11 +1405,13 @@ static int rockchip_usb2phy_probe(struct
@@ -1388,16 +1406,26 @@ static int rockchip_usb2phy_probe(struct
if (IS_ERR(rphy->phy_reset))
return PTR_ERR(rphy->phy_reset);
@ -101,10 +101,8 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
+ rphy->num_clks = ret < 0 ? 0 : ret;
ret = rockchip_usb2phy_clk480m_register(rphy);
if (ret) {
@@ -1399,6 +1419,14 @@ static int rockchip_usb2phy_probe(struct
return ret;
}
if (ret)
return dev_err_probe(dev, ret, "failed to register 480m output clock\n");
+ ret = clk_bulk_prepare_enable(rphy->num_clks, rphy->clks);
+ if (ret)

View File

@ -17,7 +17,7 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
--- a/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
+++ b/drivers/phy/rockchip/phy-rockchip-inno-usb2.c
@@ -1518,6 +1518,30 @@ static int rk3528_usb2phy_tuning(struct
@@ -1515,6 +1515,30 @@ static int rk3528_usb2phy_tuning(struct
return ret;
}
@ -48,7 +48,7 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
static int rk3588_usb2phy_tuning(struct rockchip_usb2phy *rphy)
{
int ret;
@@ -1928,6 +1952,84 @@ static const struct rockchip_usb2phy_cfg
@@ -1925,6 +1949,84 @@ static const struct rockchip_usb2phy_cfg
{ /* sentinel */ }
};
@ -133,7 +133,7 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
static const struct rockchip_usb2phy_cfg rk3588_phy_cfgs[] = {
{
.reg = 0x0000,
@@ -2099,6 +2201,7 @@ static const struct of_device_id rockchi
@@ -2096,6 +2198,7 @@ static const struct of_device_id rockchi
{ .compatible = "rockchip,rk3399-usb2phy", .data = &rk3399_phy_cfgs },
{ .compatible = "rockchip,rk3528-usb2phy", .data = &rk3528_phy_cfgs },
{ .compatible = "rockchip,rk3568-usb2phy", .data = &rk3568_phy_cfgs },

View File

@ -9,7 +9,7 @@ Subject: [PATCH] drivers/rk808-regulator: initcall early
--- a/drivers/regulator/rk808-regulator.c
+++ b/drivers/regulator/rk808-regulator.c
@@ -1747,7 +1747,17 @@ static struct platform_driver rk808_regu
@@ -1746,7 +1746,17 @@ static struct platform_driver rk808_regu
},
};

View File

@ -10,7 +10,7 @@ Subject: [PATCH] rockchip/pm-domains: export APIs
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -18,6 +18,7 @@
@@ -20,6 +20,7 @@
#include <linux/regmap.h>
#include <linux/mfd/syscon.h>
#include <soc/rockchip/pm_domains.h>
@ -18,7 +18,7 @@ Subject: [PATCH] rockchip/pm-domains: export APIs
#include <dt-bindings/power/px30-power.h>
#include <dt-bindings/power/rockchip,rv1126-power.h>
#include <dt-bindings/power/rk3036-power.h>
@@ -98,6 +99,18 @@ struct rockchip_pmu {
@@ -100,6 +101,18 @@ struct rockchip_pmu {
struct generic_pm_domain *domains[];
};
@ -37,7 +37,7 @@ Subject: [PATCH] rockchip/pm-domains: export APIs
#define to_rockchip_pd(gpd) container_of(gpd, struct rockchip_pm_domain, genpd)
#define DOMAIN(_name, pwr, status, req, idle, ack, wakeup) \
@@ -345,6 +358,29 @@ static int rockchip_pmu_set_idle_request
@@ -347,6 +360,29 @@ static int rockchip_pmu_set_idle_request
return 0;
}
@ -67,7 +67,7 @@ Subject: [PATCH] rockchip/pm-domains: export APIs
static int rockchip_pmu_save_qos(struct rockchip_pm_domain *pd)
{
int i;
@@ -394,6 +430,52 @@ static int rockchip_pmu_restore_qos(stru
@@ -396,6 +432,52 @@ static int rockchip_pmu_restore_qos(stru
return 0;
}
@ -120,7 +120,7 @@ Subject: [PATCH] rockchip/pm-domains: export APIs
static bool rockchip_pmu_domain_is_on(struct rockchip_pm_domain *pd)
{
struct rockchip_pmu *pmu = pd->pmu;
@@ -574,6 +656,65 @@ static int rockchip_pd_power_off(struct
@@ -576,6 +658,65 @@ static int rockchip_pd_power_off(struct
return rockchip_pd_power(pd, false);
}

View File

@ -16,7 +16,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -32,6 +32,7 @@
@@ -34,6 +34,7 @@
#include <dt-bindings/power/rk3368-power.h>
#include <dt-bindings/power/rk3399-power.h>
#include <dt-bindings/power/rk3568-power.h>
@ -24,7 +24,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
#include <dt-bindings/power/rk3588-power.h>
struct rockchip_domain_info {
@@ -186,6 +187,9 @@ static void rockchip_pmu_unlock(struct r
@@ -188,6 +189,9 @@ static void rockchip_pmu_unlock(struct r
#define DOMAIN_RK3568(name, pwr, req, wakeup) \
DOMAIN_M(name, pwr, pwr, req, req, req, wakeup)
@ -34,7 +34,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
/*
* Dynamic Memory Controller may need to coordinate with us -- see
* rockchip_pmu_block().
@@ -1252,6 +1256,28 @@ static const struct rockchip_domain_info
@@ -1247,6 +1251,28 @@ static const struct rockchip_domain_info
[RK3568_PD_PIPE] = DOMAIN_RK3568("pipe", BIT(8), BIT(11), false),
};
@ -63,7 +63,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
static const struct rockchip_domain_info rk3588_pm_domains[] = {
[RK3588_PD_GPU] = DOMAIN_RK3588("gpu", 0x0, BIT(0), 0, 0x0, 0, BIT(1), 0x0, BIT(0), BIT(0), false),
[RK3588_PD_NPU] = DOMAIN_RK3588("npu", 0x0, BIT(1), BIT(1), 0x0, 0, 0, 0x0, 0, 0, false),
@@ -1430,6 +1456,21 @@ static const struct rockchip_pmu_info rk
@@ -1425,6 +1451,21 @@ static const struct rockchip_pmu_info rk
.domain_info = rk3568_pm_domains,
};
@ -85,7 +85,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
static const struct rockchip_pmu_info rk3588_pmu = {
.pwr_offset = 0x14c,
.status_offset = 0x180,
@@ -1506,6 +1547,10 @@ static const struct of_device_id rockchi
@@ -1501,6 +1542,10 @@ static const struct of_device_id rockchi
.data = (void *)&rk3568_pmu,
},
{

View File

@ -18,7 +18,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -45,6 +45,7 @@ struct rockchip_domain_info {
@@ -47,6 +47,7 @@ struct rockchip_domain_info {
bool active_wakeup;
int pwr_w_mask;
int req_w_mask;
@ -26,7 +26,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
int mem_status_mask;
int repair_status_mask;
u32 pwr_offset;
@@ -62,6 +63,7 @@ struct rockchip_pmu_info {
@@ -64,6 +65,7 @@ struct rockchip_pmu_info {
u32 chain_status_offset;
u32 mem_status_offset;
u32 repair_status_offset;
@ -34,7 +34,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
u32 core_pwrcnt_offset;
u32 gpu_pwrcnt_offset;
@@ -314,6 +316,26 @@ static unsigned int rockchip_pmu_read_ac
@@ -316,6 +318,26 @@ static unsigned int rockchip_pmu_read_ac
return val;
}
@ -61,7 +61,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
static int rockchip_pmu_set_idle_request(struct rockchip_pm_domain *pd,
bool idle)
{
@@ -623,6 +645,8 @@ static int rockchip_pd_power(struct rock
@@ -625,6 +647,8 @@ static int rockchip_pd_power(struct rock
return ret;
}
@ -70,7 +70,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
if (!power_on) {
rockchip_pmu_save_qos(pd);
@@ -639,6 +663,7 @@ static int rockchip_pd_power(struct rock
@@ -641,6 +665,7 @@ static int rockchip_pd_power(struct rock
rockchip_pmu_restore_qos(pd);
}

View File

@ -17,7 +17,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -158,6 +158,25 @@ static void rockchip_pmu_unlock(struct r
@@ -160,6 +160,25 @@ static void rockchip_pmu_unlock(struct r
.active_wakeup = wakeup, \
}
@ -43,7 +43,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
#define DOMAIN_RK3036(_name, req, ack, idle, wakeup) \
{ \
.name = _name, \
@@ -189,8 +208,8 @@ static void rockchip_pmu_unlock(struct r
@@ -191,8 +210,8 @@ static void rockchip_pmu_unlock(struct r
#define DOMAIN_RK3568(name, pwr, req, wakeup) \
DOMAIN_M(name, pwr, pwr, req, req, req, wakeup)
@ -54,7 +54,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
/*
* Dynamic Memory Controller may need to coordinate with us -- see
@@ -1282,25 +1301,25 @@ static const struct rockchip_domain_info
@@ -1277,25 +1296,25 @@ static const struct rockchip_domain_info
};
static const struct rockchip_domain_info rk3576_pm_domains[] = {
@ -99,7 +99,7 @@ Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
};
static const struct rockchip_domain_info rk3588_pm_domains[] = {
@@ -1491,6 +1510,7 @@ static const struct rockchip_pmu_info rk
@@ -1486,6 +1505,7 @@ static const struct rockchip_pmu_info rk
.idle_offset = 0x128,
.ack_offset = 0x120,
.repair_status_offset = 0x570,

View File

@ -12,7 +12,7 @@ Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -91,6 +91,7 @@ struct rockchip_pm_domain {
@@ -93,6 +93,7 @@ struct rockchip_pm_domain {
u32 *qos_save_regs[MAX_QOS_REGS_NUM];
int num_clks;
struct clk_bulk_data *clks;
@ -20,7 +20,7 @@ Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
};
struct rockchip_pmu {
@@ -668,6 +669,7 @@ static int rockchip_pd_power(struct rock
@@ -670,6 +671,7 @@ static int rockchip_pd_power(struct rock
if (!power_on) {
rockchip_pmu_save_qos(pd);
@ -28,7 +28,7 @@ Signed-off-by: Elaine Zhang <zhangqing@rock-chips.com>
/* if powering down, idle request to NIU first */
rockchip_pmu_set_idle_request(pd, true);
@@ -679,7 +681,8 @@ static int rockchip_pd_power(struct rock
@@ -681,7 +683,8 @@ static int rockchip_pd_power(struct rock
/* if powering up, leave idle mode */
rockchip_pmu_set_idle_request(pd, false);

View File

@ -9,7 +9,7 @@ Subject: [PATCH] pmdomain: rockchip: Add delay support
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -51,6 +51,7 @@ struct rockchip_domain_info {
@@ -53,6 +53,7 @@ struct rockchip_domain_info {
u32 pwr_offset;
u32 mem_offset;
u32 req_offset;
@ -17,7 +17,7 @@ Subject: [PATCH] pmdomain: rockchip: Add delay support
};
struct rockchip_pmu_info {
@@ -681,6 +682,8 @@ static int rockchip_pd_power(struct rock
@@ -683,6 +684,8 @@ static int rockchip_pd_power(struct rock
/* if powering up, leave idle mode */
rockchip_pmu_set_idle_request(pd, false);

View File

@ -90,7 +90,7 @@ mainly for fixing crash on `nputop` power up:
--- a/drivers/pmdomain/rockchip/pm-domains.c
+++ b/drivers/pmdomain/rockchip/pm-domains.c
@@ -160,7 +160,7 @@ static void rockchip_pmu_unlock(struct r
@@ -162,7 +162,7 @@ static void rockchip_pmu_unlock(struct r
.active_wakeup = wakeup, \
}
@ -99,7 +99,7 @@ mainly for fixing crash on `nputop` power up:
{ \
.name = _name, \
.pwr_offset = p_offset, \
@@ -176,6 +176,7 @@ static void rockchip_pmu_unlock(struct r
@@ -178,6 +178,7 @@ static void rockchip_pmu_unlock(struct r
.idle_mask = (idle), \
.clk_ungate_mask = (g_mask), \
.ack_mask = (ack), \
@ -107,7 +107,7 @@ mainly for fixing crash on `nputop` power up:
.active_wakeup = wakeup, \
}
@@ -210,8 +211,8 @@ static void rockchip_pmu_unlock(struct r
@@ -212,8 +213,8 @@ static void rockchip_pmu_unlock(struct r
#define DOMAIN_RK3568(name, pwr, req, wakeup) \
DOMAIN_M(name, pwr, pwr, req, req, req, wakeup)
@ -118,7 +118,7 @@ mainly for fixing crash on `nputop` power up:
/*
* Dynamic Memory Controller may need to coordinate with us -- see
@@ -1307,25 +1308,25 @@ static const struct rockchip_domain_info
@@ -1302,25 +1303,25 @@ static const struct rockchip_domain_info
};
static const struct rockchip_domain_info rk3576_pm_domains[] = {

View File

@ -20,11 +20,9 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 11 +++++++++++
1 file changed, 11 insertions(+)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index c3c8bd23beae..d793454a7512 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -1159,6 +1159,13 @@ static const struct dev_pm_ops rk_hdptx_phy_pm_ops = {
@@ -1159,6 +1159,13 @@ static const struct dev_pm_ops rk_hdptx_
rk_hdptx_phy_runtime_resume, NULL)
};
@ -38,17 +36,14 @@ index c3c8bd23beae..d793454a7512 100644
static const struct rk_hdptx_phy_cfg rk3588_hdptx_phy_cfgs = {
.num_phys = 2,
.phy_ids = {
@@ -1168,6 +1175,10 @@ static const struct rk_hdptx_phy_cfg rk3588_hdptx_phy_cfgs = {
};
@@ -1169,6 +1176,10 @@ static const struct rk_hdptx_phy_cfg rk3
static const struct of_device_id rk_hdptx_phy_of_match[] = {
+ {
{
+ .compatible = "rockchip,rk3576-hdptx-phy",
+ .data = &rk3576_hdptx_phy_cfgs
+ },
{
+ {
.compatible = "rockchip,rk3588-hdptx-phy",
.data = &rk3588_hdptx_phy_cfgs
--
2.51.0
},

View File

@ -20,8 +20,6 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index d793454a7512..2e1c50b2895d 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -192,6 +192,7 @@
@ -32,7 +30,7 @@ index d793454a7512..2e1c50b2895d 100644
#define HDMI20_MAX_RATE 600000000
struct lcpll_config {
@@ -837,7 +838,7 @@ static int rk_hdptx_ropll_tmds_mode_config(struct rk_hdptx_phy *hdptx,
@@ -837,7 +838,7 @@ static int rk_hdptx_ropll_tmds_mode_conf
regmap_write(hdptx->regmap, LNTOP_REG(0200), 0x06);
@ -41,6 +39,3 @@ index d793454a7512..2e1c50b2895d 100644
/* For 1/40 bitrate clk */
rk_hdptx_multi_reg_write(hdptx, rk_hdtpx_tmds_lntop_highbr_seq);
} else {
--
2.51.0

View File

@ -15,11 +15,9 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index 2e1c50b2895d..6a062e509a01 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -771,9 +771,7 @@ static int rk_hdptx_ropll_tmds_cmn_config(struct rk_hdptx_phy *hdptx,
@@ -771,9 +771,7 @@ static int rk_hdptx_ropll_tmds_cmn_confi
{
const struct ropll_config *cfg = NULL;
struct ropll_config rc = {0};
@ -30,7 +28,7 @@ index 2e1c50b2895d..6a062e509a01 100644
for (i = 0; i < ARRAY_SIZE(ropll_tmds_cfg); i++)
if (rate == ropll_tmds_cfg[i].bit_rate) {
@@ -828,7 +826,11 @@ static int rk_hdptx_ropll_tmds_cmn_config(struct rk_hdptx_phy *hdptx,
@@ -828,7 +826,11 @@ static int rk_hdptx_ropll_tmds_cmn_confi
regmap_update_bits(hdptx->regmap, CMN_REG(0086), PLL_PCG_CLK_EN_MASK,
FIELD_PREP(PLL_PCG_CLK_EN_MASK, 0x1));
@ -43,6 +41,3 @@ index 2e1c50b2895d..6a062e509a01 100644
}
static int rk_hdptx_ropll_tmds_mode_config(struct rk_hdptx_phy *hdptx,
--
2.51.0

View File

@ -15,8 +15,6 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
.../phy/rockchip/phy-rockchip-samsung-hdptx.c | 31 -------------------
1 file changed, 31 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index 6a062e509a01..59d7ced84032 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -195,37 +195,6 @@
@ -57,6 +55,3 @@ index 6a062e509a01..59d7ced84032 100644
struct ropll_config {
u32 bit_rate;
u8 pms_mdiv;
--
2.51.0

View File

@ -15,8 +15,6 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index 59d7ced84032..4e082ab31cae 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -250,7 +250,6 @@ struct rk_hdptx_phy {
@ -27,6 +25,3 @@ index 59d7ced84032..4e082ab31cae 100644
struct clk_bulk_data *clks;
int nr_clks;
struct reset_control_bulk_data rsts[RST_MAX];
--
2.51.0

View File

@ -19,8 +19,6 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 12 +++++-------
1 file changed, 5 insertions(+), 7 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index 4e082ab31cae..de333b743810 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -245,10 +245,7 @@ struct rk_hdptx_phy {
@ -34,7 +32,7 @@ index 4e082ab31cae..de333b743810 100644
struct phy *phy;
struct clk_bulk_data *clks;
int nr_clks;
@@ -1036,6 +1033,7 @@ static int rk_hdptx_phy_runtime_resume(struct device *dev)
@@ -1036,6 +1033,7 @@ static int rk_hdptx_phy_runtime_resume(s
static int rk_hdptx_phy_probe(struct platform_device *pdev)
{
@ -42,7 +40,7 @@ index 4e082ab31cae..de333b743810 100644
struct phy_provider *phy_provider;
struct device *dev = &pdev->dev;
struct rk_hdptx_phy *hdptx;
@@ -1054,14 +1052,14 @@ static int rk_hdptx_phy_probe(struct platform_device *pdev)
@@ -1054,14 +1052,14 @@ static int rk_hdptx_phy_probe(struct pla
return dev_err_probe(dev, PTR_ERR(regs),
"Failed to ioremap resource\n");
@ -61,6 +59,3 @@ index 4e082ab31cae..de333b743810 100644
hdptx->phy_id = id;
break;
}
--
2.51.0

View File

@ -22,8 +22,6 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
.../phy/rockchip/phy-rockchip-samsung-hdptx.c | 79 +++++++++----------
1 file changed, 39 insertions(+), 40 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index de333b743810..36b01a2e414b 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -196,7 +196,7 @@
@ -101,7 +99,7 @@ index de333b743810..36b01a2e414b 100644
1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, },
};
@@ -659,10 +659,10 @@ static void rk_hdptx_phy_disable(struct rk_hdptx_phy *hdptx)
@@ -659,10 +659,10 @@ static void rk_hdptx_phy_disable(struct
regmap_write(hdptx->grf, GRF_HDPTX_CON0, val);
}
@ -114,7 +112,7 @@ index de333b743810..36b01a2e414b 100644
unsigned long k = 0, lc, k_sub, lc_sub;
unsigned int fvco, sdc;
u32 mdiv, sdiv, n = 8;
@@ -732,14 +732,14 @@ static bool rk_hdptx_phy_clk_pll_calc(unsigned int data_rate,
@@ -732,14 +732,14 @@ static bool rk_hdptx_phy_clk_pll_calc(un
}
static int rk_hdptx_ropll_tmds_cmn_config(struct rk_hdptx_phy *hdptx,
@ -131,7 +129,7 @@ index de333b743810..36b01a2e414b 100644
cfg = &ropll_tmds_cfg[i];
break;
}
@@ -753,8 +753,8 @@ static int rk_hdptx_ropll_tmds_cmn_config(struct rk_hdptx_phy *hdptx,
@@ -753,8 +753,8 @@ static int rk_hdptx_ropll_tmds_cmn_confi
}
}
@ -142,7 +140,7 @@ index de333b743810..36b01a2e414b 100644
cfg->sdm_num_sign, cfg->sdm_num, cfg->sdm_deno);
rk_hdptx_pre_power_up(hdptx);
@@ -793,19 +793,19 @@ static int rk_hdptx_ropll_tmds_cmn_config(struct rk_hdptx_phy *hdptx,
@@ -793,19 +793,19 @@ static int rk_hdptx_ropll_tmds_cmn_confi
ret = rk_hdptx_post_enable_pll(hdptx);
if (!ret)
@ -165,7 +163,7 @@ index de333b743810..36b01a2e414b 100644
/* For 1/40 bitrate clk */
rk_hdptx_multi_reg_write(hdptx, rk_hdtpx_tmds_lntop_highbr_seq);
} else {
@@ -823,7 +823,7 @@ static int rk_hdptx_ropll_tmds_mode_config(struct rk_hdptx_phy *hdptx,
@@ -823,7 +823,7 @@ static int rk_hdptx_ropll_tmds_mode_conf
}
static int rk_hdptx_phy_consumer_get(struct rk_hdptx_phy *hdptx,
@ -174,7 +172,7 @@ index de333b743810..36b01a2e414b 100644
{
u32 status;
int ret;
@@ -881,7 +881,7 @@ static int rk_hdptx_phy_consumer_put(struct rk_hdptx_phy *hdptx, bool force)
@@ -881,7 +881,7 @@ static int rk_hdptx_phy_consumer_put(str
static int rk_hdptx_phy_power_on(struct phy *phy)
{
struct rk_hdptx_phy *hdptx = phy_get_drvdata(phy);
@ -183,7 +181,7 @@ index de333b743810..36b01a2e414b 100644
int ret;
/*
@@ -889,10 +889,10 @@ static int rk_hdptx_phy_power_on(struct phy *phy)
@@ -889,10 +889,10 @@ static int rk_hdptx_phy_power_on(struct
* from the HDMI bridge driver until phy_configure_opts_hdmi
* becomes available in the PHY API.
*/
@ -197,7 +195,7 @@ index de333b743810..36b01a2e414b 100644
ret = rk_hdptx_phy_consumer_get(hdptx, rate);
if (ret)
@@ -927,7 +927,7 @@ static int rk_hdptx_phy_clk_prepare(struct clk_hw *hw)
@@ -927,7 +927,7 @@ static int rk_hdptx_phy_clk_prepare(stru
{
struct rk_hdptx_phy *hdptx = to_rk_hdptx_phy(hw);
@ -206,7 +204,7 @@ index de333b743810..36b01a2e414b 100644
}
static void rk_hdptx_phy_clk_unprepare(struct clk_hw *hw)
@@ -948,18 +948,17 @@ static unsigned long rk_hdptx_phy_clk_recalc_rate(struct clk_hw *hw,
@@ -948,18 +948,17 @@ static unsigned long rk_hdptx_phy_clk_re
static long rk_hdptx_phy_clk_round_rate(struct clk_hw *hw, unsigned long rate,
unsigned long *parent_rate)
{
@ -227,7 +225,7 @@ index de333b743810..36b01a2e414b 100644
return -EINVAL;
return rate;
@@ -970,7 +969,7 @@ static int rk_hdptx_phy_clk_set_rate(struct clk_hw *hw, unsigned long rate,
@@ -970,7 +969,7 @@ static int rk_hdptx_phy_clk_set_rate(str
{
struct rk_hdptx_phy *hdptx = to_rk_hdptx_phy(hw);
@ -236,6 +234,3 @@ index de333b743810..36b01a2e414b 100644
}
static const struct clk_ops hdptx_phy_clk_ops = {
--
2.51.0

View File

@ -18,8 +18,6 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index 36b01a2e414b..4c713616963a 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -253,7 +253,7 @@ struct rk_hdptx_phy {
@ -31,7 +29,7 @@ index 36b01a2e414b..4c713616963a 100644
atomic_t usage_count;
};
@@ -793,7 +793,7 @@ static int rk_hdptx_ropll_tmds_cmn_config(struct rk_hdptx_phy *hdptx,
@@ -793,7 +793,7 @@ static int rk_hdptx_ropll_tmds_cmn_confi
ret = rk_hdptx_post_enable_pll(hdptx);
if (!ret)
@ -40,7 +38,7 @@ index 36b01a2e414b..4c713616963a 100644
return ret;
}
@@ -927,7 +927,7 @@ static int rk_hdptx_phy_clk_prepare(struct clk_hw *hw)
@@ -927,7 +927,7 @@ static int rk_hdptx_phy_clk_prepare(stru
{
struct rk_hdptx_phy *hdptx = to_rk_hdptx_phy(hw);
@ -49,7 +47,7 @@ index 36b01a2e414b..4c713616963a 100644
}
static void rk_hdptx_phy_clk_unprepare(struct clk_hw *hw)
@@ -942,7 +942,7 @@ static unsigned long rk_hdptx_phy_clk_recalc_rate(struct clk_hw *hw,
@@ -942,7 +942,7 @@ static unsigned long rk_hdptx_phy_clk_re
{
struct rk_hdptx_phy *hdptx = to_rk_hdptx_phy(hw);
@ -58,6 +56,3 @@ index 36b01a2e414b..4c713616963a 100644
}
static long rk_hdptx_phy_clk_round_rate(struct clk_hw *hw, unsigned long rate,
--
2.51.0

View File

@ -23,11 +23,9 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index 4c713616963a..be504439c767 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -291,6 +291,8 @@ static const struct ropll_config ropll_tmds_cfg[] = {
@@ -291,6 +291,8 @@ static const struct ropll_config ropll_t
1, 1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, },
{ 65000000ULL, 162, 162, 1, 1, 11, 1, 1, 1, 1, 1, 1, 1, 54, 0, 16, 4, 1,
1, 1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, },
@ -36,6 +34,3 @@ index 4c713616963a..be504439c767 100644
{ 33750000ULL, 0x70, 0x70, 1, 1, 0xf, 1, 1, 1, 1, 1, 1, 1, 0x2, 0, 0x01, 5,
1, 1, 1, 0, 0x20, 0x0c, 1, 0x0e, 0, 0, },
{ 40000000ULL, 100, 100, 1, 1, 11, 1, 1, 0, 1, 0, 1, 1, 0x9, 0, 0x05, 0,
--
2.51.0

View File

@ -21,11 +21,9 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index be504439c767..bdc52495774d 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -347,9 +347,7 @@ static const struct reg_sequence rk_hdtpx_common_cmn_init_seq[] = {
@@ -347,9 +347,7 @@ static const struct reg_sequence rk_hdtp
REG_SEQ0(CMN_REG(0043), 0x00),
REG_SEQ0(CMN_REG(0044), 0x46),
REG_SEQ0(CMN_REG(0045), 0x24),
@ -35,7 +33,7 @@ index be504439c767..bdc52495774d 100644
REG_SEQ0(CMN_REG(0049), 0xfa),
REG_SEQ0(CMN_REG(004a), 0x08),
REG_SEQ0(CMN_REG(004b), 0x00),
@@ -422,6 +420,8 @@ static const struct reg_sequence rk_hdtpx_tmds_cmn_init_seq[] = {
@@ -422,6 +420,8 @@ static const struct reg_sequence rk_hdtp
REG_SEQ0(CMN_REG(0034), 0x00),
REG_SEQ0(CMN_REG(003d), 0x40),
REG_SEQ0(CMN_REG(0042), 0x78),
@ -44,6 +42,3 @@ index be504439c767..bdc52495774d 100644
REG_SEQ0(CMN_REG(004e), 0x34),
REG_SEQ0(CMN_REG(005c), 0x25),
REG_SEQ0(CMN_REG(005e), 0x4f),
--
2.51.0

View File

@ -19,11 +19,9 @@ Signed-off-by: Vinod Koul <vkoul@kernel.org>
drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
index bdc52495774d..47c2a3811685 100644
--- a/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
+++ b/drivers/phy/rockchip/phy-rockchip-samsung-hdptx.c
@@ -515,13 +515,9 @@ static const struct reg_sequence rk_hdtpx_common_lane_init_seq[] = {
@@ -515,13 +515,9 @@ static const struct reg_sequence rk_hdtp
static const struct reg_sequence rk_hdtpx_tmds_lane_init_seq[] = {
REG_SEQ0(LANE_REG(0312), 0x00),
@ -37,7 +35,7 @@ index bdc52495774d..47c2a3811685 100644
REG_SEQ0(LANE_REG(0303), 0x2f),
REG_SEQ0(LANE_REG(0403), 0x2f),
REG_SEQ0(LANE_REG(0503), 0x2f),
@@ -534,6 +530,11 @@ static const struct reg_sequence rk_hdtpx_tmds_lane_init_seq[] = {
@@ -534,6 +530,11 @@ static const struct reg_sequence rk_hdtp
REG_SEQ0(LANE_REG(0406), 0x1c),
REG_SEQ0(LANE_REG(0506), 0x1c),
REG_SEQ0(LANE_REG(0606), 0x1c),
@ -49,6 +47,3 @@ index bdc52495774d..47c2a3811685 100644
};
static bool rk_hdptx_phy_is_rw_reg(struct device *dev, unsigned int reg)
--
2.51.0