Commit 30523014 authored by Linus Torvalds's avatar Linus Torvalds

Merge tag 'pm-6.7-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm

Pull more power management updates from Rafael Wysocki:
 "These add new hardware support to a cpufreq driver and fix cpupower
  utility documentation:

   - Add support for several Qualcomm SoC versions to the Qualcomm
     cpufreq driver (Robert Marko, Varadarajan Narayanan)

   - Fix a reference to a removed document in the cpupower utility
     documentation (Vegard Nossum)"

* tag 'pm-6.7-rc1-2' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm:
  cpufreq: qcom-nvmem: Introduce cpufreq for ipq95xx
  cpufreq: qcom-nvmem: Enable cpufreq for ipq53xx
  cpufreq: qcom-nvmem: add support for IPQ8074
  cpupower: fix reference to nonexistent document
parents 25b63770 36cbb924
...@@ -180,8 +180,11 @@ static const struct of_device_id blocklist[] __initconst = { ...@@ -180,8 +180,11 @@ static const struct of_device_id blocklist[] __initconst = {
{ .compatible = "ti,am62a7", }, { .compatible = "ti,am62a7", },
{ .compatible = "ti,am62p5", }, { .compatible = "ti,am62p5", },
{ .compatible = "qcom,ipq5332", },
{ .compatible = "qcom,ipq6018", }, { .compatible = "qcom,ipq6018", },
{ .compatible = "qcom,ipq8064", }, { .compatible = "qcom,ipq8064", },
{ .compatible = "qcom,ipq8074", },
{ .compatible = "qcom,ipq9574", },
{ .compatible = "qcom,apq8064", }, { .compatible = "qcom,apq8064", },
{ .compatible = "qcom,msm8974", }, { .compatible = "qcom,msm8974", },
{ .compatible = "qcom,msm8960", }, { .compatible = "qcom,msm8960", },
......
...@@ -38,6 +38,11 @@ enum ipq806x_versions { ...@@ -38,6 +38,11 @@ enum ipq806x_versions {
#define IPQ6000_VERSION BIT(2) #define IPQ6000_VERSION BIT(2)
enum ipq8074_versions {
IPQ8074_HAWKEYE_VERSION = 0,
IPQ8074_ACORN_VERSION,
};
struct qcom_cpufreq_drv; struct qcom_cpufreq_drv;
struct qcom_cpufreq_match_data { struct qcom_cpufreq_match_data {
...@@ -178,6 +183,16 @@ static int qcom_cpufreq_kryo_name_version(struct device *cpu_dev, ...@@ -178,6 +183,16 @@ static int qcom_cpufreq_kryo_name_version(struct device *cpu_dev,
switch (msm_id) { switch (msm_id) {
case QCOM_ID_MSM8996: case QCOM_ID_MSM8996:
case QCOM_ID_APQ8096: case QCOM_ID_APQ8096:
case QCOM_ID_IPQ5332:
case QCOM_ID_IPQ5322:
case QCOM_ID_IPQ5312:
case QCOM_ID_IPQ5302:
case QCOM_ID_IPQ5300:
case QCOM_ID_IPQ9514:
case QCOM_ID_IPQ9550:
case QCOM_ID_IPQ9554:
case QCOM_ID_IPQ9570:
case QCOM_ID_IPQ9574:
drv->versions = 1 << (unsigned int)(*speedbin); drv->versions = 1 << (unsigned int)(*speedbin);
break; break;
case QCOM_ID_MSM8996SG: case QCOM_ID_MSM8996SG:
...@@ -338,6 +353,44 @@ static int qcom_cpufreq_ipq6018_name_version(struct device *cpu_dev, ...@@ -338,6 +353,44 @@ static int qcom_cpufreq_ipq6018_name_version(struct device *cpu_dev,
return 0; return 0;
} }
static int qcom_cpufreq_ipq8074_name_version(struct device *cpu_dev,
struct nvmem_cell *speedbin_nvmem,
char **pvs_name,
struct qcom_cpufreq_drv *drv)
{
u32 msm_id;
int ret;
*pvs_name = NULL;
ret = qcom_smem_get_soc_id(&msm_id);
if (ret)
return ret;
switch (msm_id) {
case QCOM_ID_IPQ8070A:
case QCOM_ID_IPQ8071A:
case QCOM_ID_IPQ8172:
case QCOM_ID_IPQ8173:
case QCOM_ID_IPQ8174:
drv->versions = BIT(IPQ8074_ACORN_VERSION);
break;
case QCOM_ID_IPQ8072A:
case QCOM_ID_IPQ8074A:
case QCOM_ID_IPQ8076A:
case QCOM_ID_IPQ8078A:
drv->versions = BIT(IPQ8074_HAWKEYE_VERSION);
break;
default:
dev_err(cpu_dev,
"SoC ID %u is not part of IPQ8074 family, limiting to 1.4GHz!\n",
msm_id);
drv->versions = BIT(IPQ8074_ACORN_VERSION);
break;
}
return 0;
}
static const char *generic_genpd_names[] = { "perf", NULL }; static const char *generic_genpd_names[] = { "perf", NULL };
static const struct qcom_cpufreq_match_data match_data_kryo = { static const struct qcom_cpufreq_match_data match_data_kryo = {
...@@ -367,6 +420,10 @@ static const struct qcom_cpufreq_match_data match_data_ipq8064 = { ...@@ -367,6 +420,10 @@ static const struct qcom_cpufreq_match_data match_data_ipq8064 = {
.get_version = qcom_cpufreq_ipq8064_name_version, .get_version = qcom_cpufreq_ipq8064_name_version,
}; };
static const struct qcom_cpufreq_match_data match_data_ipq8074 = {
.get_version = qcom_cpufreq_ipq8074_name_version,
};
static int qcom_cpufreq_probe(struct platform_device *pdev) static int qcom_cpufreq_probe(struct platform_device *pdev)
{ {
struct qcom_cpufreq_drv *drv; struct qcom_cpufreq_drv *drv;
...@@ -494,9 +551,12 @@ static const struct of_device_id qcom_cpufreq_match_list[] __initconst = { ...@@ -494,9 +551,12 @@ static const struct of_device_id qcom_cpufreq_match_list[] __initconst = {
{ .compatible = "qcom,msm8909", .data = &match_data_msm8909 }, { .compatible = "qcom,msm8909", .data = &match_data_msm8909 },
{ .compatible = "qcom,msm8996", .data = &match_data_kryo }, { .compatible = "qcom,msm8996", .data = &match_data_kryo },
{ .compatible = "qcom,qcs404", .data = &match_data_qcs404 }, { .compatible = "qcom,qcs404", .data = &match_data_qcs404 },
{ .compatible = "qcom,ipq5332", .data = &match_data_kryo },
{ .compatible = "qcom,ipq6018", .data = &match_data_ipq6018 }, { .compatible = "qcom,ipq6018", .data = &match_data_ipq6018 },
{ .compatible = "qcom,ipq8064", .data = &match_data_ipq8064 }, { .compatible = "qcom,ipq8064", .data = &match_data_ipq8064 },
{ .compatible = "qcom,ipq8074", .data = &match_data_ipq8074 },
{ .compatible = "qcom,apq8064", .data = &match_data_krait }, { .compatible = "qcom,apq8064", .data = &match_data_krait },
{ .compatible = "qcom,ipq9574", .data = &match_data_kryo },
{ .compatible = "qcom,msm8974", .data = &match_data_krait }, { .compatible = "qcom,msm8974", .data = &match_data_krait },
{ .compatible = "qcom,msm8960", .data = &match_data_krait }, { .compatible = "qcom,msm8960", .data = &match_data_krait },
{}, {},
......
...@@ -17,7 +17,7 @@ settings of all cores, see cpupower(1) how to choose specific cores. ...@@ -17,7 +17,7 @@ settings of all cores, see cpupower(1) how to choose specific cores.
.SH "DOCUMENTATION" .SH "DOCUMENTATION"
kernel sources: kernel sources:
Documentation/power/powercap/powercap.txt Documentation/power/powercap/powercap.rst
.SH "SEE ALSO" .SH "SEE ALSO"
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment