Initial unified commit for Android 14, with "light" GSI target
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
From d817f1b8271e51853040685214aebc378dafd1aa Mon Sep 17 00:00:00 2001
|
||||
From: Pierre-Hugues Husson <phh@phh.me>
|
||||
Date: Fri, 25 Mar 2022 05:37:56 -0400
|
||||
Subject: [PATCH] MIUI13 devices hide their vibrator HAL behind non-default
|
||||
name: "vibratorfeature"
|
||||
|
||||
---
|
||||
services/vibratorservice/VibratorHalController.cpp | 6 ++++++
|
||||
1 file changed, 6 insertions(+)
|
||||
|
||||
diff --git a/services/vibratorservice/VibratorHalController.cpp b/services/vibratorservice/VibratorHalController.cpp
|
||||
index c1795f5c32..345016efd6 100644
|
||||
--- a/services/vibratorservice/VibratorHalController.cpp
|
||||
+++ b/services/vibratorservice/VibratorHalController.cpp
|
||||
@@ -59,6 +59,12 @@ std::shared_ptr<HalWrapper> connectHal(std::shared_ptr<CallbackScheduler> schedu
|
||||
return std::make_shared<AidlHalWrapper>(std::move(scheduler), aidlHal);
|
||||
}
|
||||
|
||||
+ aidlHal = waitForVintfService<Aidl::IVibrator>(String16("vibratorfeature"));
|
||||
+ if (aidlHal) {
|
||||
+ ALOGV("Successfully connected to Xiaomi Vibrator HAL AIDL service.");
|
||||
+ return std::make_shared<AidlHalWrapper>(std::move(scheduler), aidlHal);
|
||||
+ }
|
||||
+
|
||||
sp<V1_0::IVibrator> halV1_0 = V1_0::IVibrator::getService();
|
||||
if (halV1_0 == nullptr) {
|
||||
ALOGV("Vibrator HAL service not available.");
|
||||
--
|
||||
2.34.1
|
||||
|
||||
Reference in New Issue
Block a user