diff --git a/drivers/soc/rockchip/pm_domains.c b/drivers/soc/rockchip/pm_domains.c index 4ee8006eb507..f6b19fa5d99e 100644 --- a/drivers/soc/rockchip/pm_domains.c +++ b/drivers/soc/rockchip/pm_domains.c @@ -17,6 +17,7 @@ #include #include #include +#include #include #include #include @@ -882,6 +883,13 @@ static const struct rockchip_domain_info px30_pm_domains[] = { [PX30_PD_GPU] = DOMAIN_PX30(BIT(15), BIT(15), BIT(2), false), }; +static const struct rockchip_domain_info rk1808_pm_domains[] = { + [RK1808_VD_NPU] = DOMAIN_PX30(BIT(15), BIT(15), BIT(2), false), + [RK1808_PD_PCIE] = DOMAIN_PX30(BIT(9), BIT(9), BIT(4), true), + [RK1808_PD_VPU] = DOMAIN_PX30(BIT(13), BIT(13), BIT(7), false), + [RK1808_PD_VIO] = DOMAIN_PX30(BIT(14), BIT(14), BIT(8), false), +}; + static const struct rockchip_domain_info rk3036_pm_domains[] = { [RK3036_PD_MSCH] = DOMAIN_RK3036(BIT(14), BIT(23), BIT(30), true), [RK3036_PD_CORE] = DOMAIN_RK3036(BIT(13), BIT(17), BIT(24), false), @@ -1008,6 +1016,17 @@ static const struct rockchip_pmu_info px30_pmu = { .domain_info = px30_pm_domains, }; +static const struct rockchip_pmu_info rk1808_pmu = { + .pwr_offset = 0x18, + .status_offset = 0x20, + .req_offset = 0x64, + .idle_offset = 0x6c, + .ack_offset = 0x6c, + + .num_domains = ARRAY_SIZE(rk1808_pm_domains), + .domain_info = rk1808_pm_domains, +}; + static const struct rockchip_pmu_info rk3036_pmu = { .req_offset = 0x148, .idle_offset = 0x14c, @@ -1137,6 +1156,10 @@ static const struct of_device_id rockchip_pm_domain_dt_match[] = { .compatible = "rockchip,px30-power-controller", .data = (void *)&px30_pmu, }, + { + .compatible = "rockchip,rk1808-power-controller", + .data = (void *)&rk1808_pmu, + }, { .compatible = "rockchip,rk3036-power-controller", .data = (void *)&rk3036_pmu,