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

Commit 7998e043 authored by Mahesh KKV's avatar Mahesh KKV Committed by Android (Google) Code Review
Browse files

Merge changes from topic "Wi-Fi 7: TID2Link & Link Removal"

* changes:
  wifi: Notify MLO Link status updates
  wifi: Add TID to link mapping support
parents 590a3170 9cb9424e
Loading
Loading
Loading
Loading
+6 −0
Original line number Original line Diff line number Diff line
@@ -64,4 +64,10 @@ interface ISupplicantStaIfaceCallback {
  oneway void onQosPolicyReset();
  oneway void onQosPolicyReset();
  oneway void onQosPolicyRequest(in int qosPolicyRequestId, in android.hardware.wifi.supplicant.QosPolicyData[] qosPolicyData);
  oneway void onQosPolicyRequest(in int qosPolicyRequestId, in android.hardware.wifi.supplicant.QosPolicyData[] qosPolicyData);
  oneway void onStateChangedWithAkm(in android.hardware.wifi.supplicant.StaIfaceCallbackState newState, in byte[] bssid, in int id, in byte[] ssid, in boolean filsHlpSent, in android.hardware.wifi.supplicant.KeyMgmtMask keyMgmtMask);
  oneway void onStateChangedWithAkm(in android.hardware.wifi.supplicant.StaIfaceCallbackState newState, in byte[] bssid, in int id, in byte[] ssid, in boolean filsHlpSent, in android.hardware.wifi.supplicant.KeyMgmtMask keyMgmtMask);
  oneway void onMloLinksInfoChanged(in android.hardware.wifi.supplicant.ISupplicantStaIfaceCallback.MloLinkInfoChangeReason reason);
  @Backing(type="int") @VintfStability
  enum MloLinkInfoChangeReason {
    TID_TO_LINK_MAP = 0,
    MULTI_LINK_RECONFIG_AP_REMOVAL = 1,
  }
}
}
+2 −0
Original line number Original line Diff line number Diff line
@@ -36,4 +36,6 @@ package android.hardware.wifi.supplicant;
parcelable MloLink {
parcelable MloLink {
  byte linkId;
  byte linkId;
  byte[] staLinkMacAddress;
  byte[] staLinkMacAddress;
  byte tidsUplinkMap;
  byte tidsDownlinkMap;
}
}
+38 −0
Original line number Original line Diff line number Diff line
@@ -329,4 +329,42 @@ oneway interface ISupplicantStaIfaceCallback {
     */
     */
    void onStateChangedWithAkm(in StaIfaceCallbackState newState, in byte[] bssid, in int id,
    void onStateChangedWithAkm(in StaIfaceCallbackState newState, in byte[] bssid, in int id,
            in byte[] ssid, in boolean filsHlpSent, in KeyMgmtMask keyMgmtMask);
            in byte[] ssid, in boolean filsHlpSent, in KeyMgmtMask keyMgmtMask);

    /**
     * Reason codes to be used with the callback |ISupplicantStaIfaceCallback.onMloLinksInfoChanged|
     */
    @VintfStability
    @Backing(type="int")
    enum MloLinkInfoChangeReason {
        /**
         * TID-to-link mapping has changed. Updated mappings will be set in
         * |MloLinksInfo.MloLink[].tids_downlink_map| and
         * |MloLinksInfo.MloLink[].tids_uplink_map| for each of the links.
         *
         * STA MLD will operate in default mode if a TID-to-link mapping is not
         * indicated by the callback. In default mode, all TIDs are mapped to
         * all setup links in downlink and uplink directions.
         */
        TID_TO_LINK_MAP = 0,
        /**
         * Multi-link reconfiguration - AP removal as described in
         * IEEE 802.11be spec, section 35.3.6. This is a mandatory feature for
         * station.
         *
         * Removed link will not be present in |ISupplicantStaIface.getConnectionMloLinksInfo|.
         */
        MULTI_LINK_RECONFIG_AP_REMOVAL = 1,
    }

    /**
     * Used to indicate that Multi Link status has changed due to the provided
     * reason. Upadted MLO link status can be fetched using
     * |ISupplicantStaIface.getConnectionMloLinksInfo|
     *
     * |MloLink.linkId| and |MloLink.staLinkMacAddress| are not expected
     * to change.
     *
     * @param reason Reason as given in MloLinkInfoChangeReason.
     */
    void onMloLinksInfoChanged(in MloLinkInfoChangeReason reason);
}
}
+28 −0
Original line number Original line Diff line number Diff line
@@ -30,4 +30,32 @@ parcelable MloLink {
     * STA Link MAC Address
     * STA Link MAC Address
     */
     */
    byte[/* 6 */] staLinkMacAddress;
    byte[/* 6 */] staLinkMacAddress;
    /**
     * Bitset where each bit indicates TID mapped to this link in uplink and
     * downlink direction.
     *
     * Traffic Identifier (TID) is an identifier used to classify a packet. It
     * is represented as a four bit number identifying the QoS traffic within
     * MAC data service. There are 16 possible values for TID, out of only 8 are
     * practically used to identify differentiated services.
     *
     * A TID-to-link mapping indicates links on which frames belonging to each
     * TID can be exchanged. IEEE 802.11be draft 2.0 defines the mapping for TID
     * values between 0 to 7 only. Once associated, an MLO link state is
     * considered as active if at least one TID is mapped to the link. Link
     * state is considered as idle if no TID is mapped to the link.
     *
     * TIDs can be mapped to uplink, downlink or both directions.
     * e.g.
     *  - TID 4 is mapped to this link in uplink direction, if bit 4 in
     *    MloLink#tids_uplink_map is set.
     *  - TID 2 is mapped to both directions for this link, if bit 2 of both
     *    MloLink#tids_uplink_map and MloLink#tids_downlink_map are set.
     *
     * In case of default link mapping, tids_uplink_map and tids_downlink_map
     * is set to 0xFF for all the links.
     *
     */
    byte tidsUplinkMap;
    byte tidsDownlinkMap;
}
}
+5 −0
Original line number Original line Diff line number Diff line
@@ -213,6 +213,11 @@ class SupplicantStaIfaceCallback : public BnSupplicantStaIfaceCallback {
            ::aidl::android::hardware::wifi::supplicant::KeyMgmtMask /* keyMgmtMask*/) override {
            ::aidl::android::hardware::wifi::supplicant::KeyMgmtMask /* keyMgmtMask*/) override {
        return ndk::ScopedAStatus::ok();
        return ndk::ScopedAStatus::ok();
    }
    }
    ::ndk::ScopedAStatus onMloLinksInfoChanged(
            ::aidl::android::hardware::wifi::supplicant::ISupplicantStaIfaceCallback::
                    MloLinkInfoChangeReason /* reason */) override {
        return ndk::ScopedAStatus::ok();
    }
};
};


class SupplicantStaIfaceAidlTest : public testing::TestWithParam<std::string> {
class SupplicantStaIfaceAidlTest : public testing::TestWithParam<std::string> {