Loading msm/sde_power_handle.c +0 −52 Original line number Diff line number Diff line Loading @@ -517,12 +517,6 @@ int sde_power_resource_init(struct platform_device *pdev, } } if (of_find_property(pdev->dev.of_node, "qcom,dss-cx-ipeak", NULL)) phandle->dss_cx_ipeak = cx_ipeak_register(pdev->dev.of_node, "qcom,dss-cx-ipeak"); else pr_debug("cx ipeak client parse failed\n"); INIT_LIST_HEAD(&phandle->event_list); phandle->rsc_client = NULL; Loading Loading @@ -576,9 +570,6 @@ void sde_power_resource_deinit(struct platform_device *pdev, } mutex_unlock(&phandle->phandle_lock); if (phandle->dss_cx_ipeak) cx_ipeak_unregister(phandle->dss_cx_ipeak); for (i = 0; i < SDE_POWER_HANDLE_DBUS_ID_MAX; i++) sde_power_data_bus_unregister(&phandle->data_bus_handle[i]); Loading Loading @@ -757,47 +748,11 @@ int sde_power_resource_enable(struct sde_power_handle *phandle, bool enable) return rc; } int sde_cx_ipeak_vote(struct sde_power_handle *phandle, struct dss_clk *clock, u64 requested_clk_rate, u64 prev_clk_rate, bool enable_vote) { int ret = 0; u64 curr_core_clk_rate, max_core_clk_rate, prev_core_clk_rate; if (!phandle->dss_cx_ipeak) { pr_debug("%pS->%s: Invalid input\n", __builtin_return_address(0), __func__); return -EOPNOTSUPP; } if (strcmp("core_clk", clock->clk_name)) { pr_debug("Not a core clk , cx_ipeak vote not needed\n"); return -EOPNOTSUPP; } curr_core_clk_rate = clock->rate; max_core_clk_rate = clock->max_rate; prev_core_clk_rate = prev_clk_rate; if (enable_vote && requested_clk_rate == max_core_clk_rate && curr_core_clk_rate != requested_clk_rate) ret = cx_ipeak_update(phandle->dss_cx_ipeak, true); else if (!enable_vote && requested_clk_rate != max_core_clk_rate && prev_core_clk_rate == max_core_clk_rate) ret = cx_ipeak_update(phandle->dss_cx_ipeak, false); if (ret) SDE_EVT32(ret, enable_vote, requested_clk_rate, curr_core_clk_rate, prev_core_clk_rate); return ret; } int sde_power_clk_set_rate(struct sde_power_handle *phandle, char *clock_name, u64 rate) { int i, rc = -EINVAL; struct dss_module_power *mp; u64 prev_clk_rate, requested_clk_rate; if (!phandle) { pr_err("invalid input power handle\n"); Loading @@ -811,15 +766,8 @@ int sde_power_clk_set_rate(struct sde_power_handle *phandle, char *clock_name, (rate > mp->clk_config[i].max_rate)) rate = mp->clk_config[i].max_rate; prev_clk_rate = mp->clk_config[i].rate; requested_clk_rate = rate; sde_cx_ipeak_vote(phandle, &mp->clk_config[i], requested_clk_rate, prev_clk_rate, true); mp->clk_config[i].rate = rate; rc = msm_dss_single_clk_set_rate(&mp->clk_config[i]); if (!rc) sde_cx_ipeak_vote(phandle, &mp->clk_config[i], requested_clk_rate, prev_clk_rate, false); break; } } Loading msm/sde_power_handle.h +0 −3 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ #include <linux/sde_io_util.h> #include <linux/interconnect.h> #include <soc/qcom/cx_ipeak.h> /* event will be triggered before power handler disable */ #define SDE_POWER_EVENT_PRE_DISABLE 0x1 Loading Loading @@ -144,7 +143,6 @@ struct sde_power_event { * @event_list: current power handle event list * @rsc_client: sde rsc client pointer * @rsc_client_init: boolean to control rsc client create * @dss_cx_ipeak: client pointer for cx ipeak driver */ struct sde_power_handle { struct dss_module_power mp; Loading @@ -158,7 +156,6 @@ struct sde_power_handle { struct list_head event_list; struct sde_rsc_client *rsc_client; bool rsc_client_init; struct cx_ipeak_client *dss_cx_ipeak; }; /** Loading Loading
msm/sde_power_handle.c +0 −52 Original line number Diff line number Diff line Loading @@ -517,12 +517,6 @@ int sde_power_resource_init(struct platform_device *pdev, } } if (of_find_property(pdev->dev.of_node, "qcom,dss-cx-ipeak", NULL)) phandle->dss_cx_ipeak = cx_ipeak_register(pdev->dev.of_node, "qcom,dss-cx-ipeak"); else pr_debug("cx ipeak client parse failed\n"); INIT_LIST_HEAD(&phandle->event_list); phandle->rsc_client = NULL; Loading Loading @@ -576,9 +570,6 @@ void sde_power_resource_deinit(struct platform_device *pdev, } mutex_unlock(&phandle->phandle_lock); if (phandle->dss_cx_ipeak) cx_ipeak_unregister(phandle->dss_cx_ipeak); for (i = 0; i < SDE_POWER_HANDLE_DBUS_ID_MAX; i++) sde_power_data_bus_unregister(&phandle->data_bus_handle[i]); Loading Loading @@ -757,47 +748,11 @@ int sde_power_resource_enable(struct sde_power_handle *phandle, bool enable) return rc; } int sde_cx_ipeak_vote(struct sde_power_handle *phandle, struct dss_clk *clock, u64 requested_clk_rate, u64 prev_clk_rate, bool enable_vote) { int ret = 0; u64 curr_core_clk_rate, max_core_clk_rate, prev_core_clk_rate; if (!phandle->dss_cx_ipeak) { pr_debug("%pS->%s: Invalid input\n", __builtin_return_address(0), __func__); return -EOPNOTSUPP; } if (strcmp("core_clk", clock->clk_name)) { pr_debug("Not a core clk , cx_ipeak vote not needed\n"); return -EOPNOTSUPP; } curr_core_clk_rate = clock->rate; max_core_clk_rate = clock->max_rate; prev_core_clk_rate = prev_clk_rate; if (enable_vote && requested_clk_rate == max_core_clk_rate && curr_core_clk_rate != requested_clk_rate) ret = cx_ipeak_update(phandle->dss_cx_ipeak, true); else if (!enable_vote && requested_clk_rate != max_core_clk_rate && prev_core_clk_rate == max_core_clk_rate) ret = cx_ipeak_update(phandle->dss_cx_ipeak, false); if (ret) SDE_EVT32(ret, enable_vote, requested_clk_rate, curr_core_clk_rate, prev_core_clk_rate); return ret; } int sde_power_clk_set_rate(struct sde_power_handle *phandle, char *clock_name, u64 rate) { int i, rc = -EINVAL; struct dss_module_power *mp; u64 prev_clk_rate, requested_clk_rate; if (!phandle) { pr_err("invalid input power handle\n"); Loading @@ -811,15 +766,8 @@ int sde_power_clk_set_rate(struct sde_power_handle *phandle, char *clock_name, (rate > mp->clk_config[i].max_rate)) rate = mp->clk_config[i].max_rate; prev_clk_rate = mp->clk_config[i].rate; requested_clk_rate = rate; sde_cx_ipeak_vote(phandle, &mp->clk_config[i], requested_clk_rate, prev_clk_rate, true); mp->clk_config[i].rate = rate; rc = msm_dss_single_clk_set_rate(&mp->clk_config[i]); if (!rc) sde_cx_ipeak_vote(phandle, &mp->clk_config[i], requested_clk_rate, prev_clk_rate, false); break; } } Loading
msm/sde_power_handle.h +0 −3 Original line number Diff line number Diff line Loading @@ -19,7 +19,6 @@ #include <linux/sde_io_util.h> #include <linux/interconnect.h> #include <soc/qcom/cx_ipeak.h> /* event will be triggered before power handler disable */ #define SDE_POWER_EVENT_PRE_DISABLE 0x1 Loading Loading @@ -144,7 +143,6 @@ struct sde_power_event { * @event_list: current power handle event list * @rsc_client: sde rsc client pointer * @rsc_client_init: boolean to control rsc client create * @dss_cx_ipeak: client pointer for cx ipeak driver */ struct sde_power_handle { struct dss_module_power mp; Loading @@ -158,7 +156,6 @@ struct sde_power_handle { struct list_head event_list; struct sde_rsc_client *rsc_client; bool rsc_client_init; struct cx_ipeak_client *dss_cx_ipeak; }; /** Loading