Merge "Revert "Update emulator config to match real vehicle values"" into main
diff --git a/audio/aidl/Android.bp b/audio/aidl/Android.bp
index 0f2fe99..97577d1 100644
--- a/audio/aidl/Android.bp
+++ b/audio/aidl/Android.bp
@@ -60,7 +60,7 @@
         ndk: {
             apex_available: [
                 "//apex_available:platform",
-                "com.android.btservices",
+                "com.android.bt",
             ],
             min_sdk_version: "31",
         },
diff --git a/audio/common/5.0/Android.bp b/audio/common/5.0/Android.bp
index 02f66a3..d9c4f58 100644
--- a/audio/common/5.0/Android.bp
+++ b/audio/common/5.0/Android.bp
@@ -23,6 +23,6 @@
     gen_java_constants: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
     ],
 }
diff --git a/automotive/vehicle/aidl/android/hardware/automotive/vehicle/VehicleAreaConfig.aidl b/automotive/vehicle/aidl/android/hardware/automotive/vehicle/VehicleAreaConfig.aidl
index 1720628..9ca4366 100644
--- a/automotive/vehicle/aidl/android/hardware/automotive/vehicle/VehicleAreaConfig.aidl
+++ b/automotive/vehicle/aidl/android/hardware/automotive/vehicle/VehicleAreaConfig.aidl
@@ -29,142 +29,156 @@
     int areaId;
 
     /**
-     * client should use {@code getMinMaxSupportedValue} instead.
+     * The optional minimum int32 value at boot time.
+     *
+     * Assume unspecified if both {@code minInt32Value} and
+     * {@code maxInt32Value} is 0. If either one is not 0, then we assume min
+     * and max both take effect. If no minimum or maximum value is available at
+     * boot time, both {@code minInt32Value} and {@code maxInt32Value} must be
+     * set to 0.
+     *
+     * Note that this property only represents the minimum value at boot time
+     * and may not represent the current actual minimum value.
      *
      * Only applicable for {@code INT32} type property. Ignored for other types.
      *
-     * The optional minimum value at boot time.
+     * For certain properties, this field must be specified, see
+     * {@code VehicleProperty} documentation.
      *
-     * For backward compatibility,
-     * if {@code HasSupportedValueInfo.hasMinSupportedValue} is {@code true},
-     * and {@code HasSupportedValueInfo.hasMaxSupportedValue} is {@code true},
-     * this must be equal to the min supported value
-     * ({@code MinMaxSupportedValueResult.minSupportedValue}) at boot time.
-     *
-     * If no minimum or maximum value is available at boot time, both
-     * {@code minInt32Value} and {@code maxInt32Value} must be set to 0.
-     *
-     * If either one is not 0, then we assume min and max both take effect.
+     * If {@code HasSupportedValueInfo} is not {@code null} and this field is
+     * specified, {@code HasSupportedValueInfo.hasMinSupportedValue} must be
+     * {@code true}.
      */
     int minInt32Value;
 
     /**
-     * client should use {@code getMinMaxSupportedValue} instead.
+     * The optional maximum int32 value at boot time.
+     *
+     * Assume unspecified if both {@code minInt32Value} and
+     * {@code maxInt32Value} is 0. If either one is not 0, then we assume min
+     * and max both take effect. If no minimum or maximum value is available at
+     * boot time, both {@code minInt32Value} and {@code maxInt32Value} must be
+     * set to 0.
+     *
+     * Note that this property only represents the minimum value at boot time
+     * and may not represent the current actual minimum value.
      *
      * Only applicable for {@code INT32} type property. Ignored for other types.
      *
-     * The optional maximum value at boot time.
+     * For certain properties, this field must be specified, see
+     * {@code VehicleProperty} documentation.
      *
-     * For backward compatibility,
-     * if {@code HasSupportedValueInfo.hasMinSupportedValue} is {@code true},
-     * and {@code HasSupportedValueInfo.hasMaxSupportedValue} is {@code true},
-     * this must be equal to the max supported value
-     * ({@code MinMaxSupportedValueResult.maxSupportedValue}) at boot time.
-     *
-     * If no minimum or maximum value is available at boot time, both
-     * {@code minInt32Value} and {@code maxInt32Value} must be set to 0.
-     *
-     * If either one is not 0, then we assume min and max both take effect.
+     * If {@code HasSupportedValueInfo} is not {@code null} and this field is
+     * specified, {@code HasSupportedValueInfo.hasMaxSupportedValue} must be
+     * {@code true}.
      */
     int maxInt32Value;
 
     /**
-     * client should use {@code getMinMaxSupportedValue} instead.
+     * The optional minimum int64 value at boot time.
+     *
+     * Assume unspecified if both {@code minInt64Value} and
+     * {@code maxInt64Value} is 0. If either one is not 0, then we assume min
+     * and max both take effect. If no minimum or maximum value is available at
+     * boot time, both {@code minInt64Value} and {@code maxInt64Value} must be
+     * set to 0.
+     *
+     * Note that this property only represents the minimum value at boot time
+     * and may not represent the current actual minimum value.
      *
      * Only applicable for {@code INT64} type property. Ignored for other types.
      *
-     * The optional minimum value at boot time.
+     * For certain properties, this field must be specified, see
+     * {@code VehicleProperty} documentation.
      *
-     * For backward compatibility,
-     * if {@code HasSupportedValueInfo.hasMinSupportedValue} is {@code true},
-     * and {@code HasSupportedValueInfo.hasMaxSupportedValue} is {@code true},
-     * this must be equal to the min supported value
-     * ({@code MinMaxSupportedValueResult.minSupportedValue}) at boot time.
-     *
-     * If no minimum or maximum value is available at boot time, both
-     * {@code minInt64Value} and {@code maxInt64Value} must be set to 0.
-     *
-     * If either one is not 0, then we assume min and max both take effect.
+     * If {@code HasSupportedValueInfo} is not {@code null} and this field is
+     * specified, {@code HasSupportedValueInfo.hasMinSupportedValue} must be
+     * {@code true}.
      */
     long minInt64Value;
 
     /**
-     * client should use {@code getMinMaxSupportedValue} instead.
+     * The optional maximum int64 value at boot time.
+     *
+     * Assume unspecified if both {@code minInt64Value} and
+     * {@code maxInt64Value} is 0. If either one is not 0, then we assume min
+     * and max both take effect. If no minimum or maximum value is available at
+     * boot time, both {@code minInt64Value} and {@code maxInt64Value} must be
+     * set to 0.
+     *
+     * Note that this property only represents the minimum value at boot time
+     * and may not represent the current actual minimum value.
      *
      * Only applicable for {@code INT64} type property. Ignored for other types.
      *
-     * The optional maximum value at boot time.
+     * For certain properties, this field must be specified, see
+     * {@code VehicleProperty} documentation.
      *
-     * For backward compatibility,
-     * if {@code HasSupportedValueInfo.hasMinSupportedValue} is {@code true},
-     * and {@code HasSupportedValueInfo.hasMaxSupportedValue} is {@code true},
-     * this must be equal to the max supported value
-     * ({@code MinMaxSupportedValueResult.maxSupportedValue}) at boot time.
-     *
-     * If no minimum or maximum value is available at boot time, both
-     * {@code minInt64Value} and {@code maxInt64Value} must be set to 0.
-     *
-     * If either one is not 0, then we assume min and max both take effect.
+     * If {@code HasSupportedValueInfo} is not {@code null} and this field is
+     * specified, {@code HasSupportedValueInfo.hasMaxSupportedValue} must be
+     * {@code true}.
      */
     long maxInt64Value;
 
     /**
-     * client should use {@code getMinMaxSupportedValue} instead.
+     * The optional minimum float value at boot time.
+     *
+     * Assume unspecified if both {@code minFloatValue} and
+     * {@code maxFloatValue} is 0. If either one is not 0, then we assume min
+     * and max both take effect. If no minimum or maximum value is available at
+     * boot time, both {@code minFloatValue} and {@code maxFloatValue} must be
+     * set to 0.
+     *
+     * Note that this property only represents the minimum value at boot time
+     * and may not represent the current actual minimum value.
      *
      * Only applicable for {@code FLOAT} type property. Ignored for other types.
      *
-     * The optional minimum value at boot time.
+     * For certain properties, this field must be specified, see
+     * {@code VehicleProperty} documentation.
      *
-     * For backward compatibility,
-     * if {@code HasSupportedValueInfo.hasMinSupportedValue} is {@code true},
-     * and {@code HasSupportedValueInfo.hasMaxSupportedValue} is {@code true},
-     * this must be equal to the min supported value
-     * ({@code MinMaxSupportedValueResult.minSupportedValue}) at boot time.
-     *
-     * If no minimum or maximum value is available at boot time, both
-     * {@code minFloatValue} and {@code maxFloatValue} must be set to 0.
-     *
-     * If either one is not 0, then we assume min and max both take effect.
+     * If {@code HasSupportedValueInfo} is not {@code null} and this field is
+     * specified, {@code HasSupportedValueInfo.hasMinSupportedValue} must be
+     * {@code true}.
      */
     float minFloatValue;
 
     /**
-     * client should use {@code getMinMaxSupportedValue} instead.
+     * The optional maximum float value at boot time.
+     *
+     * Assume unspecified if both {@code minFloatValue} and
+     * {@code maxFloatValue} is 0. If either one is not 0, then we assume min
+     * and max both take effect. If no minimum or maximum value is available at
+     * boot time, both {@code minFloatValue} and {@code maxFloatValue} must be
+     * set to 0.
+     *
+     * Note that this property only represents the minimum value at boot time
+     * and may not represent the current actual minimum value.
      *
      * Only applicable for {@code FLOAT} type property. Ignored for other types.
      *
-     * The optional maximum value at boot time.
+     * For certain properties, this field must be specified, see
+     * {@code VehicleProperty} documentation.
      *
-     * For backward compatibility,
-     * if {@code HasSupportedValueInfo.hasMinSupportedValue} is {@code true},
-     * and {@code HasSupportedValueInfo.hasMaxSupportedValue} is {@code true},
-     * this must be equal to the max supported value
-     * ({@code MinMaxSupportedValueResult.maxSupportedValue}) at boot time.
-     *
-     * If no minimum or maximum value is available at boot time, both
-     * {@code minFloatValue} and {@code maxFloatValue} must be set to 0.
-     *
-     * If either one is not 0, then we assume min and max both take effect.
+     * If {@code HasSupportedValueInfo} is not {@code null} and this field is
+     * specified, {@code HasSupportedValueInfo.hasMinSupportedValue} must be
+     * {@code true}.
      */
     float maxFloatValue;
 
     /**
-     * client should use {@code getMinMaxSupportedValue} instead.
+     * Optional supported subset of supported enum values at boot time.
      *
      * Only applicable for property with {@code @data_enum} annotation. Ignored
      * for other properties.
      *
-     * Optional supported subset of supported values at boot time.
-     *
      * If the property has a @data_enum and supportedEnumValues is {@code null},
      * then it is assumed all @data_enum values are supported unless specified
      * through another mechanism.
      *
-     * For backward compatibility, if
-     * {@code HasSupportedValueInfo.hasSupportedValuesList} is {@code true}
-     * and this property has {@code data_enum} annotation,
-     * this must be set to the same as
-     * {@code SupportedValuesListResult.supportedValuesList} at boot time.
+     * If {@code HasSupportedValueInfo} is not {@code null} and this field is
+     * not {@code null}, {@code HasSupportedValueInfo.hasSupportedValuesList}
+     * must be {@code true}.
      */
     @nullable long[] supportedEnumValues;
 
@@ -237,7 +251,19 @@
      * {@code getSupportedValuesLists}, {@code subscribeSupportedValueChange},
      * {@code unsubscribeSupportedValueChange}.
      *
-     * If this is {@code null} for legacy properties, the APIs mentioned before are not supported.
+     * If this is not {@code null}. The VHAL implementation must implement
+     * {@code getMinMaxSupportedValue}, {@code getSupportedValuesLists},
+     * {@code subscribeSupportedValueChange} for the [propId, areaId].
+     *
+     * This should be non-null if the VHAL implementation wants to expose
+     * min/max supported value or supported values list that may change dynamically. For example,
+     * if the max HVAC fan speed may change due to HVAC power settings.
+     *
+     * This should not be non-null if the VHAL implementation wants to expose supported
+     * values list for property ID that is not an enum type (hence do not support
+     * {@code VehicleAreaConfig#supportedEnumValues}).
+     *
+     * If this is {@code null}, the APIs mentioned before are not supported.
      * Client must fallback to use static supported value information in {@code VehicleAreaConfig}.
      *
      * For VHAL implementation < V4, this is always {@code null}.
diff --git a/bluetooth/1.0/Android.bp b/bluetooth/1.0/Android.bp
index bd1ca69..3ffc203 100644
--- a/bluetooth/1.0/Android.bp
+++ b/bluetooth/1.0/Android.bp
@@ -23,6 +23,6 @@
     gen_java: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
     ],
 }
diff --git a/bluetooth/1.1/Android.bp b/bluetooth/1.1/Android.bp
index f8a05f1..9c65b62 100644
--- a/bluetooth/1.1/Android.bp
+++ b/bluetooth/1.1/Android.bp
@@ -23,6 +23,6 @@
     gen_java: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
     ],
 }
diff --git a/bluetooth/aidl/Android.bp b/bluetooth/aidl/Android.bp
index 721be73..0daecf7 100644
--- a/bluetooth/aidl/Android.bp
+++ b/bluetooth/aidl/Android.bp
@@ -32,7 +32,7 @@
         ndk: {
             apex_available: [
                 "//apex_available:platform",
-                "com.android.btservices",
+                "com.android.bt",
             ],
             min_sdk_version: "33",
         },
diff --git a/bluetooth/audio/2.0/Android.bp b/bluetooth/audio/2.0/Android.bp
index 725ec11..61f9a35 100644
--- a/bluetooth/audio/2.0/Android.bp
+++ b/bluetooth/audio/2.0/Android.bp
@@ -26,6 +26,6 @@
     gen_java: false,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
     ],
 }
diff --git a/bluetooth/audio/2.1/Android.bp b/bluetooth/audio/2.1/Android.bp
index 4ca0bef..4d01a00 100644
--- a/bluetooth/audio/2.1/Android.bp
+++ b/bluetooth/audio/2.1/Android.bp
@@ -25,7 +25,7 @@
     ],
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
     ],
     gen_java: false,
 }
diff --git a/bluetooth/audio/aidl/Android.bp b/bluetooth/audio/aidl/Android.bp
index dbff368..6d4edb1 100644
--- a/bluetooth/audio/aidl/Android.bp
+++ b/bluetooth/audio/aidl/Android.bp
@@ -48,7 +48,7 @@
         ndk: {
             apex_available: [
                 "//apex_available:platform",
-                "com.android.btservices",
+                "com.android.bt",
             ],
             min_sdk_version: "31",
         },
diff --git a/bluetooth/ranging/aidl/Android.bp b/bluetooth/ranging/aidl/Android.bp
index 4096669..b5ae205 100644
--- a/bluetooth/ranging/aidl/Android.bp
+++ b/bluetooth/ranging/aidl/Android.bp
@@ -31,7 +31,7 @@
         ndk: {
             apex_available: [
                 "//apex_available:platform",
-                "com.android.btservices",
+                "com.android.bt",
             ],
             min_sdk_version: "33",
         },
diff --git a/bluetooth/socket/aidl/Android.bp b/bluetooth/socket/aidl/Android.bp
index 77679f8..7c03677 100644
--- a/bluetooth/socket/aidl/Android.bp
+++ b/bluetooth/socket/aidl/Android.bp
@@ -37,7 +37,7 @@
         ndk: {
             apex_available: [
                 "//apex_available:platform",
-                "com.android.btservices",
+                "com.android.bt",
             ],
             min_sdk_version: "33",
         },
diff --git a/contexthub/aidl/Android.bp b/contexthub/aidl/Android.bp
index 674f8af..b56537a 100644
--- a/contexthub/aidl/Android.bp
+++ b/contexthub/aidl/Android.bp
@@ -35,7 +35,7 @@
         ndk: {
             apex_available: [
                 "//apex_available:platform",
-                "com.android.btservices",
+                "com.android.bt",
             ],
             min_sdk_version: "33",
             apps_enabled: true,
diff --git a/graphics/bufferqueue/1.0/Android.bp b/graphics/bufferqueue/1.0/Android.bp
index c7c6453..87c3892 100644
--- a/graphics/bufferqueue/1.0/Android.bp
+++ b/graphics/bufferqueue/1.0/Android.bp
@@ -25,7 +25,7 @@
     gen_java: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
         "com.android.media",
         "com.android.media.swcodec",
     ],
diff --git a/graphics/bufferqueue/2.0/Android.bp b/graphics/bufferqueue/2.0/Android.bp
index e9f75c1..54f68c6 100644
--- a/graphics/bufferqueue/2.0/Android.bp
+++ b/graphics/bufferqueue/2.0/Android.bp
@@ -27,7 +27,7 @@
     gen_java: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
         "com.android.media",
         "com.android.media.swcodec",
     ],
diff --git a/graphics/common/1.0/Android.bp b/graphics/common/1.0/Android.bp
index b876bf3..1683c22 100644
--- a/graphics/common/1.0/Android.bp
+++ b/graphics/common/1.0/Android.bp
@@ -20,7 +20,7 @@
     gen_java_constants: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
         "com.android.media.swcodec",
         "test_com.android.media.swcodec",
     ],
diff --git a/graphics/common/1.1/Android.bp b/graphics/common/1.1/Android.bp
index ff6c9b7..81df887 100644
--- a/graphics/common/1.1/Android.bp
+++ b/graphics/common/1.1/Android.bp
@@ -23,7 +23,7 @@
     gen_java_constants: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
         "com.android.media.swcodec",
         "test_com.android.media.swcodec",
     ],
diff --git a/graphics/common/1.2/Android.bp b/graphics/common/1.2/Android.bp
index b4663e5..e1f4fe0 100644
--- a/graphics/common/1.2/Android.bp
+++ b/graphics/common/1.2/Android.bp
@@ -24,7 +24,7 @@
     gen_java_constants: true,
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
         "com.android.media.swcodec",
         "test_com.android.media.swcodec",
     ],
diff --git a/radio/1.0/Android.bp b/radio/1.0/Android.bp
index e49a50d..09cf9aa 100644
--- a/radio/1.0/Android.bp
+++ b/radio/1.0/Android.bp
@@ -25,7 +25,7 @@
     ],
     apex_available: [
         "//apex_available:platform",
-        "com.android.btservices",
+        "com.android.bt",
     ],
     gen_java: true,
 }
diff --git a/radio/aidl/Android.bp b/radio/aidl/Android.bp
index 01c09d8..53ef145 100644
--- a/radio/aidl/Android.bp
+++ b/radio/aidl/Android.bp
@@ -227,7 +227,7 @@
         java: {
             apex_available: [
                 "//apex_available:platform",
-                "com.android.btservices",
+                "com.android.bt",
             ],
             sdk_version: "module_current",
             min_sdk_version: "Tiramisu",