Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 4cf4059c authored by Roshan Pius's avatar Roshan Pius
Browse files

wifi: Fetch the gscan bucket idx from request

We can't rely on the ordering of these buckets to populate their
indexes. So, send them explicitly from the caller.

Bug: 35989680
Test: Compiles
Change-Id: Ife09440935eb3526636c27bfdd40c37c69c7ade2
parent 09258a2a
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -354,7 +354,10 @@ bool convertHidlGscanParamsToLegacy(
        hidl_scan_params.buckets[bucket_idx];
    legacy_hal::wifi_scan_bucket_spec& legacy_bucket_spec =
        legacy_scan_params->buckets[bucket_idx];
    legacy_bucket_spec.bucket = bucket_idx;
    if (hidl_bucket_spec.bucketIdx >= MAX_BUCKETS) {
      return false;
    }
    legacy_bucket_spec.bucket = hidl_bucket_spec.bucketIdx;
    legacy_bucket_spec.band =
        convertHidlWifiBandToLegacy(hidl_bucket_spec.band);
    legacy_bucket_spec.period = hidl_bucket_spec.periodInMs;
+5 −0
Original line number Diff line number Diff line
@@ -319,6 +319,11 @@ enum StaScanLimits : uint32_t {
 * scan requests.
 */
struct StaBackgroundScanBucketParameters {
  /**
   * Bucket index. This index is used to report results in
   * |StaScanData.bucketsScanned|.
   */
  uint32_t bucketIdx;
  /**
   * Bands to scan or |BAND_UNSPECIFIED| if frequencies list must be used
   * instead.