Commit e55cd521 authored by Ezequiel Garcia's avatar Ezequiel Garcia
Browse files

HACK: This should be fixed in the bootlader


Signed-off-by: Ezequiel Garcia's avatarEzequiel Garcia <ezequiel@collabora.com>
parent a972af67
Pipeline #5061 passed with stage
in 41 minutes and 17 seconds
......@@ -175,4 +175,4 @@ static int __init cpufreq_dt_platdev_init(void)
-1, data,
sizeof(struct cpufreq_dt_platform_data)));
}
device_initcall(cpufreq_dt_platdev_init);
subsys_initcall(cpufreq_dt_platdev_init);
......@@ -385,7 +385,19 @@ static struct platform_driver dt_cpufreq_platdrv = {
.probe = dt_cpufreq_probe,
.remove = dt_cpufreq_remove,
};
module_platform_driver(dt_cpufreq_platdrv);
static int __init dt_cpufreq_init(void)
{
return platform_driver_register(&dt_cpufreq_platdrv);
}
static void __exit dt_cpufreq_exit(void)
{
platform_driver_unregister(&dt_cpufreq_platdrv);
}
subsys_initcall(dt_cpufreq_init);
module_exit(dt_cpufreq_exit)
MODULE_ALIAS("platform:cpufreq-dt");
MODULE_AUTHOR("Viresh Kumar <viresh.kumar@linaro.org>");
......
......@@ -1277,6 +1277,21 @@ static void cpufreq_policy_free(struct cpufreq_policy *policy)
kfree(policy);
}
static void request_cooling_async(struct work_struct *work)
{
struct cpufreq_policy *policy = container_of(to_delayed_work(work),
struct cpufreq_policy, cooling);
if (cpufreq_thermal_control_enabled(cpufreq_driver))
policy->cdev = of_cpufreq_cooling_register(policy);
}
static void request_cooling(struct cpufreq_policy *policy)
{
INIT_DELAYED_WORK(&policy->cooling, request_cooling_async);
schedule_delayed_work(&policy->cooling, msecs_to_jiffies(15000));
}
static int cpufreq_online(unsigned int cpu)
{
struct cpufreq_policy *policy;
......@@ -1468,8 +1483,8 @@ static int cpufreq_online(unsigned int cpu)
if (cpufreq_driver->ready)
cpufreq_driver->ready(policy);
if (cpufreq_thermal_control_enabled(cpufreq_driver))
policy->cdev = of_cpufreq_cooling_register(policy);
// I don't even want to try.
//request_cooling(policy);
pr_debug("initialization complete\n");
......
......@@ -1359,7 +1359,18 @@ static struct platform_driver rk3x_i2c_driver = {
},
};
module_platform_driver(rk3x_i2c_driver);
static int __init rk3x_i2c_init(void)
{
return platform_driver_register(&rk3x_i2c_driver);
}
static void __exit rk3x_i2c_exit(void)
{
platform_driver_unregister(&rk3x_i2c_driver);
}
subsys_initcall(rk3x_i2c_init);
module_exit(rk3x_i2c_exit);
MODULE_DESCRIPTION("Rockchip RK3xxx I2C Bus driver");
MODULE_AUTHOR("Max Schwarz <max.schwarz@online.de>");
......
......@@ -780,7 +780,18 @@ static struct i2c_driver rk808_i2c_driver = {
.remove = rk808_remove,
};
module_i2c_driver(rk808_i2c_driver);
static int __init rk808_i2c_init(void)
{
return i2c_add_driver(&rk808_i2c_driver);
}
static void __exit rk808_i2c_exit(void)
{
i2c_del_driver(&rk808_i2c_driver);
}
subsys_initcall(rk808_i2c_init);
module_exit(rk808_i2c_exit)
MODULE_LICENSE("GPL");
MODULE_AUTHOR("Chris Zhong <zyw@rock-chips.com>");
......
......@@ -566,7 +566,18 @@ static struct i2c_driver fan53555_regulator_driver = {
.id_table = fan53555_id,
};
module_i2c_driver(fan53555_regulator_driver);
static int __init fan53555_init(void)
{
return i2c_add_driver(&fan53555_regulator_driver);
}
static void __exit fan53555_exit(void)
{
i2c_del_driver(&fan53555_regulator_driver);
}
subsys_initcall(fan53555_init);
module_exit(fan53555_exit)
MODULE_AUTHOR("Yunfan Zhang <yfzhang@marvell.com>");
MODULE_DESCRIPTION("FAN53555 regulator driver");
......
......@@ -1385,7 +1385,18 @@ static struct platform_driver rk808_regulator_driver = {
},
};
module_platform_driver(rk808_regulator_driver);
static int __init rk808_reg_init(void)
{
return platform_driver_register(&rk808_regulator_driver);
}
static void __exit rk808_reg_exit(void)
{
platform_driver_unregister(&rk808_regulator_driver);
}
subsys_initcall(rk808_reg_init);
module_exit(rk808_reg_exit)
MODULE_DESCRIPTION("regulator driver for the RK805/RK808/RK818 series PMICs");
MODULE_AUTHOR("Tony xie <tony.xie@rock-chips.com>");
......
......@@ -73,6 +73,7 @@ struct cpufreq_policy {
void *governor_data;
char last_governor[CPUFREQ_NAME_LEN]; /* last governor used */
struct delayed_work cooling;
struct work_struct update; /* if update_policy() needs to be
* called, but you're in IRQ context */
......
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