wlcore: Enable runtime PM autosuspend support
With runtime PM tested working for wlcore with no autosuspend, we can now enable autosuspend to cut down on enable/disable for interrupts. Basically we just replace pm_runtime_put() with the autosuspend variants. Let's use autosuspend delay of 50ms that MMC drivers typically use. Signed-off-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Kalle Valo <kvalo@codeaurora.org>
This commit is contained in:
@@ -288,7 +288,8 @@ static ssize_t radar_detection_write(struct file *file,
|
||||
if (ret < 0)
|
||||
count = ret;
|
||||
|
||||
pm_runtime_put(wl->dev);
|
||||
pm_runtime_mark_last_busy(wl->dev);
|
||||
pm_runtime_put_autosuspend(wl->dev);
|
||||
out:
|
||||
mutex_unlock(&wl->mutex);
|
||||
return count;
|
||||
@@ -329,7 +330,8 @@ static ssize_t dynamic_fw_traces_write(struct file *file,
|
||||
if (ret < 0)
|
||||
count = ret;
|
||||
|
||||
pm_runtime_put(wl->dev);
|
||||
pm_runtime_mark_last_busy(wl->dev);
|
||||
pm_runtime_put_autosuspend(wl->dev);
|
||||
out:
|
||||
mutex_unlock(&wl->mutex);
|
||||
return count;
|
||||
@@ -392,7 +394,8 @@ static ssize_t radar_debug_mode_write(struct file *file,
|
||||
wl->radar_debug_mode, 0);
|
||||
}
|
||||
|
||||
pm_runtime_put(wl->dev);
|
||||
pm_runtime_mark_last_busy(wl->dev);
|
||||
pm_runtime_put_autosuspend(wl->dev);
|
||||
out:
|
||||
mutex_unlock(&wl->mutex);
|
||||
return count;
|
||||
|
مرجع در شماره جدید
Block a user