#include <linux/cpu.h>
#include <linux/err.h>
#include <linux/init.h>
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/nvmem-consumer.h>
#include <linux/of.h>
#include <linux/platform_device.h>
#include <linux/pm.h>
#include <linux/pm_domain.h>
#include <linux/pm_opp.h>
#include <linux/pm_runtime.h>
#include <linux/slab.h>
#include <linux/soc/qcom/smem.h>
#include <dt-bindings/arm/qcom,ids.h>
enum ipq806x_versions { … };
#define IPQ6000_VERSION …
enum ipq8074_versions { … };
struct qcom_cpufreq_drv;
struct qcom_cpufreq_match_data { … };
struct qcom_cpufreq_drv_cpu { … };
struct qcom_cpufreq_drv { … };
static struct platform_device *cpufreq_dt_pdev, *cpufreq_pdev;
static int qcom_cpufreq_simple_get_version(struct device *cpu_dev,
struct nvmem_cell *speedbin_nvmem,
char **pvs_name,
struct qcom_cpufreq_drv *drv)
{ … }
static void get_krait_bin_format_a(struct device *cpu_dev,
int *speed, int *pvs,
u8 *buf)
{ … }
static void get_krait_bin_format_b(struct device *cpu_dev,
int *speed, int *pvs, int *pvs_ver,
u8 *buf)
{ … }
static int qcom_cpufreq_kryo_name_version(struct device *cpu_dev,
struct nvmem_cell *speedbin_nvmem,
char **pvs_name,
struct qcom_cpufreq_drv *drv)
{ … }
static int qcom_cpufreq_krait_name_version(struct device *cpu_dev,
struct nvmem_cell *speedbin_nvmem,
char **pvs_name,
struct qcom_cpufreq_drv *drv)
{ … }
static int qcom_cpufreq_ipq8064_name_version(struct device *cpu_dev,
struct nvmem_cell *speedbin_nvmem,
char **pvs_name,
struct qcom_cpufreq_drv *drv)
{ … }
static int qcom_cpufreq_ipq6018_name_version(struct device *cpu_dev,
struct nvmem_cell *speedbin_nvmem,
char **pvs_name,
struct qcom_cpufreq_drv *drv)
{ … }
static int qcom_cpufreq_ipq8074_name_version(struct device *cpu_dev,
struct nvmem_cell *speedbin_nvmem,
char **pvs_name,
struct qcom_cpufreq_drv *drv)
{ … }
static const char *generic_genpd_names[] = …;
static const struct qcom_cpufreq_match_data match_data_kryo = …;
static const struct qcom_cpufreq_match_data match_data_krait = …;
static const struct qcom_cpufreq_match_data match_data_msm8909 = …;
static const char *qcs404_genpd_names[] = …;
static const struct qcom_cpufreq_match_data match_data_qcs404 = …;
static const struct qcom_cpufreq_match_data match_data_ipq6018 = …;
static const struct qcom_cpufreq_match_data match_data_ipq8064 = …;
static const struct qcom_cpufreq_match_data match_data_ipq8074 = …;
static void qcom_cpufreq_suspend_virt_devs(struct qcom_cpufreq_drv *drv, unsigned int cpu)
{ … }
static void qcom_cpufreq_put_virt_devs(struct qcom_cpufreq_drv *drv, unsigned int cpu)
{ … }
static int qcom_cpufreq_probe(struct platform_device *pdev)
{ … }
static void qcom_cpufreq_remove(struct platform_device *pdev)
{ … }
static int qcom_cpufreq_suspend(struct device *dev)
{ … }
static DEFINE_SIMPLE_DEV_PM_OPS(qcom_cpufreq_pm_ops, qcom_cpufreq_suspend, NULL);
static struct platform_driver qcom_cpufreq_driver = …;
static const struct of_device_id qcom_cpufreq_match_list[] __initconst __maybe_unused = …;
MODULE_DEVICE_TABLE(of, qcom_cpufreq_match_list);
static int __init qcom_cpufreq_init(void)
{ … }
module_init(…) …;
static void __exit qcom_cpufreq_exit(void)
{ … }
module_exit(qcom_cpufreq_exit);
MODULE_DESCRIPTION(…) …;
MODULE_LICENSE(…) …;