From: David Woodhouse Date: Sun, 9 Dec 2007 16:08:25 +0000 (-0500) Subject: libertas: stop debugfs code looking at cmdpendingq X-Git-Tag: firefly_0821_release~23655^2~415 X-Git-Url: http://demsky.eecs.uci.edu/git/?a=commitdiff_plain;h=020bb19e2f8cfebb314b8bce4bc48a511c6f5940;p=firefly-linux-kernel-4.4.55.git libertas: stop debugfs code looking at cmdpendingq It doesn't need to wait until no commands are pending anyway -- it only needs to wait until the scan is finished. We can hopefully find it something else to wait on too -- it's the only user of the cmd_pending waitqueue. Signed-off-by: David Woodhouse Signed-off-by: John W. Linville --- diff --git a/drivers/net/wireless/libertas/debugfs.c b/drivers/net/wireless/libertas/debugfs.c index fe422b28a4f8..745191a68962 100644 --- a/drivers/net/wireless/libertas/debugfs.c +++ b/drivers/net/wireless/libertas/debugfs.c @@ -321,8 +321,7 @@ static ssize_t lbs_setuserscan(struct file *file, lbs_scan_networks(priv, scan_cfg, 1); wait_event_interruptible(priv->cmd_pending, - priv->surpriseremoved || - (!priv->cur_cmd && list_empty(&priv->cmdpendingq))); + priv->surpriseremoved || !priv->last_scanned_channel); if (priv->surpriseremoved) goto out_scan_cfg;