qcacld-3.0: Relocate hdd_set_ldpc() mac_handle test

hdd_set_ldpc() is called from both the STA and SAP ioctl handlers. In
the STA case the caller checks the mac_handle, but in the SAP case the
mac_handle is not checked. This could result in a bad mac_handle being
used in the SAP case. In order to cover both cases relocate the
mac_handle test to hdd_set_ldpc().

Note that this has the added benefit of reducing the cyclomatic
complexity of __iw_setint_getnone(), one of the HDD functions with the
highest complexity.

Change-Id: I97827ee257c9e15e24468ed9800080375f082ff1
CRs-Fixed: 2339226
2 files changed