connector: remove lazy workqueue creation
Commit 1a5645bc
(connector: create connector workqueue only while
needed once) implements lazy workqueue creation for connector
workqueue. With cmwq now in place, lazy workqueue creation doesn't
make much sense while adding a lot of complexity. Remove it and
allocate an ordered workqueue during initialization.
This also removes a call to flush_scheduled_work() which is deprecated
and scheduled to be removed.
Signed-off-by: Tejun Heo <tj@kernel.org>
Cc: Frederic Weisbecker <fweisbec@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
229aebb873
commit
6cebb17bee
@@ -133,7 +133,8 @@ static int cn_call_callback(struct sk_buff *skb)
|
||||
__cbq->data.skb == NULL)) {
|
||||
__cbq->data.skb = skb;
|
||||
|
||||
if (queue_cn_work(__cbq, &__cbq->work))
|
||||
if (queue_work(dev->cbdev->cn_queue,
|
||||
&__cbq->work))
|
||||
err = 0;
|
||||
else
|
||||
err = -EINVAL;
|
||||
@@ -148,13 +149,11 @@ static int cn_call_callback(struct sk_buff *skb)
|
||||
d->callback = __cbq->data.callback;
|
||||
d->free = __new_cbq;
|
||||
|
||||
__new_cbq->pdev = __cbq->pdev;
|
||||
|
||||
INIT_WORK(&__new_cbq->work,
|
||||
&cn_queue_wrapper);
|
||||
|
||||
if (queue_cn_work(__new_cbq,
|
||||
&__new_cbq->work))
|
||||
if (queue_work(dev->cbdev->cn_queue,
|
||||
&__new_cbq->work))
|
||||
err = 0;
|
||||
else {
|
||||
kfree(__new_cbq);
|
||||
|
Reference in New Issue
Block a user