qcacmn: Add and modify extract APIs for TBTT offset and SWBA events

Recently, FW changes were implemented to support WMI resource config for
multi-radio. As part of this, the TBTT offset and SWBA events were modified
to support increase in the number of vdevs per SOC.

Brief description of the changes with respect to TBTT offset
------------------------------------------------------------

Converged FW will send extended TBTT offset event when the number of vdevs
configured is greater than 32 and will continue to send normal TBTT offset
event when the number of vdevs configured is less than 32. Legacy FW will
continue to send vdev map and tbttoffset list array as part of the TBTT
event.

Extraction API is added to extract the number of vdevs configured for both
legacy and converged FW. Number of vdevs is sent directly by the FW for
extended TBTT offset event but sent as vdev map for the normal TBTT offset
event. In order to handle normal TBTT offset event, extraction API for
normal TBTT event adds logic to convert vdev map into the number of vdevs
configured.

Extraction APIs are added to extract vdev id and tbttoffset information per
vdev that are configured. The vdev id information is sent as vdev map and
tbttoffset list as an array for normal TBTT event and as an array of
structures containing vdev id and tbttoffset in the case of extended TBTT
event. In order to support normal TBTT event based on num vdevs, extraction
API for normal TBTT eventadds logic to determine the vdev id from vdev map
based on the index(running through 1 to total number of vdevs) passed from
the driver.

Brief description of the changes with respect to SWBA
-----------------------------------------------------

Converged FW will send additional information num vdevs and vdev id
embedded in tim info and p2p noa TLVs for SWBA event. Legacy FW will
continue to send vdev map and array of tim info and p2p noa desciptors.

Extraction APIs is added to extract the number of vdevs configured for both
legacy and converged FW. Number of vdevs is sent directly by the FW for
SWBA event in the case of converged FW and as a vdev map in the legacy FW.
In order to handle legacy FW, extraction API for non-TLV adds logic
to convert vdev map into number of vdevs configured.

Extraction APIs are modified to extract newly embedded vdev id information
in tim info and p2p noa descriptors. The vdev id information is sent as
vdev map for legacy. In order to handle legacy FW, extraction API for
non-TLV adds logic to determing the vdev id from vdev map based on the
index (running through 1 to total number of vdevs) passed from the driver.

Change-Id: Ibf84adbb1c526321ec031d5539aff66dcbd1315b
CRs-Fixed: 2053628
6 files changed