Merge "Remove VehiclePermisionMode from VHAL"
diff --git a/vehicle/2.0/Android.mk b/vehicle/2.0/Android.mk
index dc4d25c..e1b3b39 100644
--- a/vehicle/2.0/Android.mk
+++ b/vehicle/2.0/Android.mk
@@ -681,21 +681,6 @@
$(transform-generated-source)
LOCAL_GENERATED_SOURCES += $(GEN)
-#
-# Build types.hal (VehiclePermissionModel)
-#
-GEN := $(intermediates)/android/hardware/vehicle/V2_0/VehiclePermissionModel.java
-$(GEN): $(HIDL)
-$(GEN): PRIVATE_HIDL := $(HIDL)
-$(GEN): PRIVATE_DEPS := $(LOCAL_PATH)/types.hal
-$(GEN): PRIVATE_OUTPUT_DIR := $(intermediates)
-$(GEN): PRIVATE_CUSTOM_TOOL = \
- $(PRIVATE_HIDL) -o $(PRIVATE_OUTPUT_DIR) \
- -Ljava \
- -randroid.hardware:hardware/interfaces \
- -randroid.hidl:system/libhidl/transport \
- android.hardware.vehicle@2.0::types.VehiclePermissionModel
-
$(GEN): $(LOCAL_PATH)/types.hal
$(transform-generated-source)
LOCAL_GENERATED_SOURCES += $(GEN)
@@ -1635,25 +1620,6 @@
LOCAL_GENERATED_SOURCES += $(GEN)
#
-# Build types.hal (VehiclePermissionModel)
-#
-GEN := $(intermediates)/android/hardware/vehicle/V2_0/VehiclePermissionModel.java
-$(GEN): $(HIDL)
-$(GEN): PRIVATE_HIDL := $(HIDL)
-$(GEN): PRIVATE_DEPS := $(LOCAL_PATH)/types.hal
-$(GEN): PRIVATE_OUTPUT_DIR := $(intermediates)
-$(GEN): PRIVATE_CUSTOM_TOOL = \
- $(PRIVATE_HIDL) -o $(PRIVATE_OUTPUT_DIR) \
- -Ljava \
- -randroid.hardware:hardware/interfaces \
- -randroid.hidl:system/libhidl/transport \
- android.hardware.vehicle@2.0::types.VehiclePermissionModel
-
-$(GEN): $(LOCAL_PATH)/types.hal
- $(transform-generated-source)
-LOCAL_GENERATED_SOURCES += $(GEN)
-
-#
# Build types.hal (VehiclePropConfig)
#
GEN := $(intermediates)/android/hardware/vehicle/V2_0/VehiclePropConfig.java
diff --git a/vehicle/2.0/default/impl/DefaultConfig.h b/vehicle/2.0/default/impl/DefaultConfig.h
index e4ca5ca..77c4f98 100644
--- a/vehicle/2.0/default/impl/DefaultConfig.h
+++ b/vehicle/2.0/default/impl/DefaultConfig.h
@@ -32,14 +32,12 @@
.prop = VehicleProperty::INFO_MAKE,
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::STATIC,
- .permissionModel = VehiclePermissionModel::OEM_ONLY,
},
{
.prop = VehicleProperty::HVAC_POWER_ON,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = toInt(VehicleAreaZone::ROW_1)
},
@@ -47,7 +45,6 @@
.prop = VehicleProperty::HVAC_DEFROSTER,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas =
VehicleAreaWindow::FRONT_WINDSHIELD
| VehicleAreaWindow::REAR_WINDSHIELD
@@ -57,7 +54,6 @@
.prop = VehicleProperty::HVAC_RECIRC_ON,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = toInt(VehicleAreaZone::ROW_1)
},
@@ -65,7 +61,6 @@
.prop = VehicleProperty::HVAC_AC_ON,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = toInt(VehicleAreaZone::ROW_1)
},
@@ -73,7 +68,6 @@
.prop = VehicleProperty::HVAC_AUTO_ON,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = toInt(VehicleAreaZone::ROW_1)
},
@@ -81,7 +75,6 @@
.prop = VehicleProperty::HVAC_FAN_SPEED,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = toInt(VehicleAreaZone::ROW_1),
.areaConfigs = {
VehicleAreaConfig {
@@ -96,7 +89,6 @@
.prop = VehicleProperty::HVAC_FAN_DIRECTION,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = toInt(VehicleAreaZone::ROW_1),
},
@@ -104,7 +96,6 @@
.prop = VehicleProperty::HVAC_TEMPERATURE_SET,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas =
VehicleAreaZone::ROW_1_LEFT
| VehicleAreaZone::ROW_1_RIGHT,
@@ -126,28 +117,24 @@
.prop = VehicleProperty::NIGHT_MODE,
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
},
{
.prop = VehicleProperty::DRIVING_STATUS,
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
},
{
.prop = VehicleProperty::GEAR_SELECTION,
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
},
{
.prop = VehicleProperty::INFO_FUEL_CAPACITY,
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::OEM_ONLY,
.areaConfigs = {
VehicleAreaConfig {
.minFloatValue = 0,
@@ -160,7 +147,6 @@
.prop = VehicleProperty::DISPLAY_BRIGHTNESS,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::OEM_ONLY,
.areaConfigs = {
VehicleAreaConfig {
.minInt32Value = 0,
diff --git a/vehicle/2.0/default/tests/VehicleHalTestUtils.h b/vehicle/2.0/default/tests/VehicleHalTestUtils.h
index 586b5ab..77541fc 100644
--- a/vehicle/2.0/default/tests/VehicleHalTestUtils.h
+++ b/vehicle/2.0/default/tests/VehicleHalTestUtils.h
@@ -32,7 +32,6 @@
.prop = VehicleProperty::INFO_MAKE,
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::STATIC,
- .permissionModel = VehiclePermissionModel::OEM_ONLY,
.configString = "Some=config,options=if,you=have_any",
},
@@ -40,7 +39,6 @@
.prop = VehicleProperty::HVAC_FAN_SPEED,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = static_cast<int32_t>(
VehicleAreaZone::ROW_1_LEFT | VehicleAreaZone::ROW_1_RIGHT),
.areaConfigs = {
@@ -61,7 +59,6 @@
.prop = VehicleProperty::HVAC_SEAT_TEMPERATURE,
.access = VehiclePropertyAccess::WRITE,
.changeMode = VehiclePropertyChangeMode::ON_SET,
- .permissionModel = VehiclePermissionModel::NO_RESTRICTION,
.supportedAreas = static_cast<int32_t>(
VehicleAreaZone::ROW_1_LEFT | VehicleAreaZone::ROW_1_RIGHT),
.areaConfigs = {
@@ -81,7 +78,6 @@
.prop = VehicleProperty::INFO_FUEL_CAPACITY,
.access = VehiclePropertyAccess::READ,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::OEM_ONLY,
.areaConfigs = {
VehicleAreaConfig {
.minFloatValue = 0,
@@ -94,7 +90,6 @@
.prop = VehicleProperty::DISPLAY_BRIGHTNESS,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::OEM_ONLY,
.areaConfigs = {
VehicleAreaConfig {
.minInt32Value = 0,
@@ -107,7 +102,6 @@
.prop = VehicleProperty::MIRROR_FOLD,
.access = VehiclePropertyAccess::READ_WRITE,
.changeMode = VehiclePropertyChangeMode::ON_CHANGE,
- .permissionModel = VehiclePermissionModel::OEM_ONLY,
}
};
@@ -238,7 +232,6 @@
<< " prop: " << enumToHexString(config.prop) << ",\n"
<< " supportedAreas: " << hexString(config.supportedAreas) << ",\n"
<< " access: " << enumToHexString(config.access) << ",\n"
- << " permissionModel: " << enumToHexString(config.permissionModel) << ",\n"
<< " changeMode: " << enumToHexString(config.changeMode) << ",\n"
<< " configFlags: " << hexString(config.configFlags) << ",\n"
<< " minSampleRate: " << config.minSampleRate << ",\n"
diff --git a/vehicle/2.0/types.hal b/vehicle/2.0/types.hal
index 72fa554..5ab0c24 100644
--- a/vehicle/2.0/types.hal
+++ b/vehicle/2.0/types.hal
@@ -2144,30 +2144,6 @@
};
/*
- * These permissions define how the OEMs want to distribute their information
- * and security they want to apply. On top of these restrictions, android will
- * have additional 'app-level' permissions that the apps will need to ask the
- * user before the apps have the information.
- * This information must be kept in VehiclePropConfig#permissionModel.
- */
-enum VehiclePermissionModel : int32_t {
- /*
- * No special restriction, but each property can still require specific
- * android app-level permission.
- */
- NO_RESTRICTION = 0,
-
- /* Signature only. Only APKs signed with OEM keys are allowed. */
- OEM_ONLY = 0x1,
-
- /* System only. APKs built-in to system can access the property. */
- SYSTEM_APP_ONLY = 0x2,
-
- /* Equivalent to “system|signature” */
- OEM_OR_SYSTEM_APP = 0x3,
-};
-
-/*
* Car states.
*
* The driving states determine what features of the UI will be accessible.
@@ -2311,11 +2287,6 @@
VehiclePropertyChangeMode changeMode;
/*
- * Defines permission model to access the data.
- */
- VehiclePermissionModel permissionModel;
-
- /*
* Some of the properties may have associated areas (for example, some hvac
* properties are associated with VehicleAreaZone), in these
* cases the config may contain an ORed value for the associated areas.
diff --git a/vehicle/2.0/vts/types.vts b/vehicle/2.0/vts/types.vts
index e044501..99fa6e7 100644
--- a/vehicle/2.0/vts/types.vts
+++ b/vehicle/2.0/vts/types.vts
@@ -1169,31 +1169,6 @@
}
attribute: {
- name: "::android::hardware::vehicle::V2_0::VehiclePermissionModel"
- type: TYPE_ENUM
- enum_value: {
- scalar_type: "int32_t"
-
- enumerator: "NO_RESTRICTION"
- scalar_value: {
- int32_t: 0
- }
- enumerator: "OEM_ONLY"
- scalar_value: {
- int32_t: 1
- }
- enumerator: "SYSTEM_APP_ONLY"
- scalar_value: {
- int32_t: 2
- }
- enumerator: "OEM_OR_SYSTEM_APP"
- scalar_value: {
- int32_t: 3
- }
- }
-}
-
-attribute: {
name: "::android::hardware::vehicle::V2_0::VehicleDrivingStatus"
type: TYPE_ENUM
enum_value: {
@@ -1604,11 +1579,6 @@
predefined_type: "::android::hardware::vehicle::V2_0::VehiclePropertyChangeMode"
}
struct_value: {
- name: "permissionModel"
- type: TYPE_ENUM
- predefined_type: "::android::hardware::vehicle::V2_0::VehiclePermissionModel"
- }
- struct_value: {
name: "supportedAreas"
type: TYPE_SCALAR
scalar_type: "int32_t"