From: Amitkumar Karwar Date: Sat, 12 Jul 2014 03:53:14 +0000 (-0700) Subject: mwifiex: fix corner case system hang issue X-Git-Tag: omap-for-v3.17/fixes-against-rc2~149^2~73^2~61 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d5343f06902bf6635734d1e72aa2100dd63a6f4b;p=pandora-kernel.git mwifiex: fix corner case system hang issue Sometimes pending internal scan commands are delayed to give preference to Tx traffic. 'scan_processing' flag has been checked at the beginning of delay timer routine to know if in the meantime scan operation has been cancelled. There is a corner case where pending scan commands are emptied after scan_processing flag check is passed. In this case wrong pointer returned by list_first_entry() is passed to list_del() which causes system hang. This patch fixes the issue by adding list_empty() check. Signed-off-by: Amitkumar Karwar Signed-off-by: Bing Zhao Signed-off-by: John W. Linville --- Reading git-diff-tree failed