diff options
author | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2012-10-22 23:09:00 (GMT) |
---|---|---|
committer | Rafael J. Wysocki <rafael.j.wysocki@intel.com> | 2012-10-22 23:09:00 (GMT) |
commit | 021c870ba4ab4bc9a23d5db4e324f50f26d8ab24 (patch) | |
tree | b6e928a4d20ffab16297e0d44de59ee20aaf9c6d /drivers/base/power/qos.c | |
parent | 5efbe4279f959a3f5ed26adf5f05cb78dd1ffa7e (diff) | |
download | linux-fsl-qoriq-021c870ba4ab4bc9a23d5db4e324f50f26d8ab24.tar.xz |
PM / QoS: Prepare struct dev_pm_qos_request for more request types
The subsequent patches will use struct dev_pm_qos_request for
representing both latency requests and flags requests. To make that
easier, put the node member of struct dev_pm_qos_request (under the
name "pnode") into a union called "data" that will represent the
request's value and list node depending on its type.
Signed-off-by: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
Reviewed-by: Jean Pihet <j-pihet@ti.com>
Reviewed-by: mark gross <markgross@thegnar.org>
Diffstat (limited to 'drivers/base/power/qos.c')
-rw-r--r-- | drivers/base/power/qos.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/base/power/qos.c b/drivers/base/power/qos.c index 40ff1b0..96d27b8 100644 --- a/drivers/base/power/qos.c +++ b/drivers/base/power/qos.c @@ -90,7 +90,7 @@ static int apply_constraint(struct dev_pm_qos_request *req, int ret, curr_value; ret = pm_qos_update_target(&req->dev->power.qos->latency, - &req->node, action, value); + &req->data.pnode, action, value); if (ret) { /* Call the global callbacks if needed */ @@ -183,7 +183,7 @@ void dev_pm_qos_constraints_destroy(struct device *dev) c = &qos->latency; /* Flush the constraints list for the device */ - plist_for_each_entry_safe(req, tmp, &c->list, node) { + plist_for_each_entry_safe(req, tmp, &c->list, data.pnode) { /* * Update constraints list and call the notification * callbacks if needed @@ -293,7 +293,7 @@ int dev_pm_qos_update_request(struct dev_pm_qos_request *req, mutex_lock(&dev_pm_qos_mtx); if (req->dev->power.qos) { - if (new_value != req->node.prio) + if (new_value != req->data.pnode.prio) ret = apply_constraint(req, PM_QOS_UPDATE_REQ, new_value); } else { |