qcacld-3.0: Return the safe channel from ACS ch list

Currently in case of LTE-coex event, the driver restarts
the SAP to a new channel if the current SAP operating
channel is unsafe.
In the current logic the driver gets the PCL apply the
logic to remove unsafe channels, NOL channels etc.
and then chose a final channel for the SAP.
Now for the case of standlaone SAP the PCL would contain
only 5ghz channels, and it may be the case that ACS
channel list contains only 2.4ghz channels because
the SAP was initially started on 2.4ghz band.
Now with the intersection of 2.4ghz and 5ghz, the driver
would not get anything left to restart the SAP and the SAP
restart would eventually fail.

Fix is to directly check the number of connections as 1,
that would mean only SAP is present, and if it is the
case, just restart the SAP on any other channel from the
ACS channel list rather than intersection with PCL.

Change-Id: If3a77ca877b2bf5e83ca64930e716936f680940f
CRs-Fixed: 2556054
1 file changed