mwifiex: rework internal scan for association
mwifiex: rework internal scan for association

There was an issue with internal scan during association wherein
we would complete internal scan on first scan command response.
This would cause association failure if AP is not found in first scan
response e.g. APs from A band.
This patch fixes this issue by completing internal scan only when all
scan commands from scan pending queue and command pending queue are
sent to FW and response to last scan command is received.

Tested-by: Xinmin Hu <8b9c60c177136f4289bffc27dc182e6e6ad5798f@marvell.com>
Signed-off-by: Avinash Patil <50e1049428767d2efb636cdd70a22d5f95f675be@marvell.com>
Signed-off-by: Amitkumar Karwar <7343c7ffb424bf4c3ebd1cd0c94117b3c12118ff@marvell.com>
Signed-off-by: Marc Yang <32e779f38e54433e91e1b8e04b8b1f2f83a13c57@marvell.com>
Signed-off-by: Cathy Luo <a43426796a4084d29fd40628080b00e817af0d23@marvell.com>
Signed-off-by: John W. Linville <2a53bac7a5d324865ef46ec4c38b2c0fba1456b4@tuxdriver.com>

KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs,KristFoundation/Programs