提交 794760f7 编写于 作者: P Pierre Ossman 提交者: David S. Miller

[PATCH] libertas: properly end commands on hardware failure

Make sure that errors reported by the hardware layer is properly
handled. Otherwise commands tend to get stuck in limbo.
Signed-off-by: NPierre Ossman <drzeus@drzeus.cx>
Signed-off-by: NJohn W. Linville <linville@tuxdriver.com>
上级 b6e99dd6
......@@ -1009,7 +1009,9 @@ static int DownloadcommandToStation(wlan_private * priv,
if (ret != 0) {
lbs_deb_host("DNLD_CMD: hw_host_to_card failed\n");
spin_lock_irqsave(&adapter->driver_lock, flags);
adapter->cur_cmd_retcode = ret;
__libertas_cleanup_and_insert_cmd(priv, adapter->cur_cmd);
adapter->nr_cmd_pending--;
adapter->cur_cmd = NULL;
spin_unlock_irqrestore(&adapter->driver_lock, flags);
goto done;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册