Fix a data type of the display ID
The valid display ID ranges from 0 to 255 so this changes its data type
from a 8-bit signed integer to 32-bit signed integer.
Bug: 170401743
Test: Successful build
Change-Id: Ic4cb38d2d0446e169652689a3d3c71f1d7240455
diff --git a/automotive/evs/aidl/aidl_api/android.hardware.automotive.evs/current/android/hardware/automotive/evs/IEvsEnumerator.aidl b/automotive/evs/aidl/aidl_api/android.hardware.automotive.evs/current/android/hardware/automotive/evs/IEvsEnumerator.aidl
index a79c68d..225b504 100644
--- a/automotive/evs/aidl/aidl_api/android.hardware.automotive.evs/current/android/hardware/automotive/evs/IEvsEnumerator.aidl
+++ b/automotive/evs/aidl/aidl_api/android.hardware.automotive.evs/current/android/hardware/automotive/evs/IEvsEnumerator.aidl
@@ -44,7 +44,7 @@
android.hardware.automotive.evs.UltrasonicsArrayDesc[] getUltrasonicsArrayList();
boolean isHardware();
android.hardware.automotive.evs.IEvsCamera openCamera(in String cameraId, in android.hardware.automotive.evs.Stream streamCfg);
- android.hardware.automotive.evs.IEvsDisplay openDisplay(in byte id);
+ android.hardware.automotive.evs.IEvsDisplay openDisplay(in int id);
android.hardware.automotive.evs.IEvsUltrasonicsArray openUltrasonicsArray(in String ultrasonicsArrayId);
void registerStatusCallback(in android.hardware.automotive.evs.IEvsEnumeratorStatusCallback callback);
}
diff --git a/automotive/evs/aidl/android/hardware/automotive/evs/IEvsEnumerator.aidl b/automotive/evs/aidl/android/hardware/automotive/evs/IEvsEnumerator.aidl
index 8e380e0..8698700 100644
--- a/automotive/evs/aidl/android/hardware/automotive/evs/IEvsEnumerator.aidl
+++ b/automotive/evs/aidl/android/hardware/automotive/evs/IEvsEnumerator.aidl
@@ -146,7 +146,7 @@
* @return EvsDisplay object to be used.
* @throws EvsResult::INVALID_ARG if no display with a given id exists
*/
- IEvsDisplay openDisplay(in byte id);
+ IEvsDisplay openDisplay(in int id);
/**
* Gets the IEvsUltrasonicsArray associated with a ultrasonicsArrayId from a
diff --git a/automotive/evs/aidl/impl/default/include/DefaultEvsEnumerator.h b/automotive/evs/aidl/impl/default/include/DefaultEvsEnumerator.h
index 8bcd867..03a578d 100644
--- a/automotive/evs/aidl/impl/default/include/DefaultEvsEnumerator.h
+++ b/automotive/evs/aidl/impl/default/include/DefaultEvsEnumerator.h
@@ -37,7 +37,7 @@
const ::aidl::android::hardware::automotive::evs::CameraDesc& desc,
std::vector<::aidl::android::hardware::automotive::evs::Stream>* _aidl_return) override;
::ndk::ScopedAStatus openDisplay(
- int8_t displayId,
+ int32_t displayId,
std::shared_ptr<::aidl::android::hardware::automotive::evs::IEvsDisplay>* obj) override;
::ndk::ScopedAStatus closeDisplay(
const std::shared_ptr<::aidl::android::hardware::automotive::evs::IEvsDisplay>& obj)
diff --git a/automotive/evs/aidl/impl/default/src/DefaultEvsEnumerator.cpp b/automotive/evs/aidl/impl/default/src/DefaultEvsEnumerator.cpp
index 2ff6d59..5a81d05 100644
--- a/automotive/evs/aidl/impl/default/src/DefaultEvsEnumerator.cpp
+++ b/automotive/evs/aidl/impl/default/src/DefaultEvsEnumerator.cpp
@@ -51,7 +51,7 @@
return ScopedAStatus::ok();
}
-ScopedAStatus DefaultEvsEnumerator::openDisplay(int8_t displayId,
+ScopedAStatus DefaultEvsEnumerator::openDisplay(int32_t displayId,
std::shared_ptr<IEvsDisplay>* obj) {
return ScopedAStatus::ok();
}