Commit 829f0e97 authored by Bhaktipriya Shridhar's avatar Bhaktipriya Shridhar Committed by Sebastian Reichel

power: ipaq_micro_battery: Remove deprecated create_singlethread_workqueue

The workqueue "wq" is used for handling battery related tasks.

It has a single work item viz &mb->update and hence it doesn't require
execution ordering. Hence, alloc_workqueue has been used to replace the
deprecated create_singlethread_workqueue instance.

The WQ_MEM_RECLAIM flag has been set to ensure forward progress under
memory pressure.

Since there is a single work item, explicit concurrency
limit is unnecessary here.
Signed-off-by: default avatarBhaktipriya Shridhar <bhaktipriya96@gmail.com>
Signed-off-by: default avatarSebastian Reichel <sre@kernel.org>
parent 9df82628
...@@ -235,7 +235,7 @@ static int micro_batt_probe(struct platform_device *pdev) ...@@ -235,7 +235,7 @@ static int micro_batt_probe(struct platform_device *pdev)
return -ENOMEM; return -ENOMEM;
mb->micro = dev_get_drvdata(pdev->dev.parent); mb->micro = dev_get_drvdata(pdev->dev.parent);
mb->wq = create_singlethread_workqueue("ipaq-battery-wq"); mb->wq = alloc_workqueue("ipaq-battery-wq", WQ_MEM_RECLAIM, 0);
if (!mb->wq) if (!mb->wq)
return -ENOMEM; return -ENOMEM;
......
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