Compare commits

..

No commits in common. "ed1d196854a82a8d92a112bd5d5d8b94d932ce20" and "18c3fbb0b5094a51bdc248c0a493c2034acdf73c" have entirely different histories.

5 changed files with 49 additions and 48 deletions

View file

@ -1,4 +1,4 @@
From 7222eae1b450166edb709164eaa060d50df0284c Mon Sep 17 00:00:00 2001 From 13537c3a17b60050d431d7d5b9dbfc591ee41762 Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me> From: Pierre-Hugues Husson <phh@phh.me>
Date: Sat, 19 Feb 2022 08:20:25 -0500 Date: Sat, 19 Feb 2022 08:20:25 -0500
Subject: [PATCH] Add new mechanism to fake vendor props on a per-process basis Subject: [PATCH] Add new mechanism to fake vendor props on a per-process basis
@ -17,7 +17,7 @@ Squashed: Rework property overriding
1 file changed, 79 insertions(+), 2 deletions(-) 1 file changed, 79 insertions(+), 2 deletions(-)
diff --git a/libc/system_properties/system_properties.cpp b/libc/system_properties/system_properties.cpp diff --git a/libc/system_properties/system_properties.cpp b/libc/system_properties/system_properties.cpp
index e0d38a8..4f54885 100644 index 9dd5e35ce..4524f8410 100644
--- a/libc/system_properties/system_properties.cpp --- a/libc/system_properties/system_properties.cpp
+++ b/libc/system_properties/system_properties.cpp +++ b/libc/system_properties/system_properties.cpp
@@ -36,6 +36,8 @@ @@ -36,6 +36,8 @@
@ -109,7 +109,7 @@ index e0d38a8..4f54885 100644
static bool is_dir(const char* pathname) { static bool is_dir(const char* pathname) {
struct stat info; struct stat info;
if (stat(pathname, &info) == -1) { if (stat(pathname, &info) == -1) {
@@ -160,17 +235,19 @@ uint32_t SystemProperties::AreaSerial() { @@ -156,17 +231,19 @@ uint32_t SystemProperties::AreaSerial() {
} }
const prop_info* SystemProperties::Find(const char* name) { const prop_info* SystemProperties::Find(const char* name) {
@ -132,5 +132,5 @@ index e0d38a8..4f54885 100644
static bool is_appcompat_override(const char* name) { static bool is_appcompat_override(const char* name) {
-- --
2.44.0 2.43.1

View file

@ -1,4 +1,4 @@
From e164e6032a9df3bf8814cdb8d6267b1c5663687f Mon Sep 17 00:00:00 2001 From a4c4caca86ecfe7f0dfce67fc479f9777be26410 Mon Sep 17 00:00:00 2001
From: Peter Cai <peter@typeblog.net> From: Peter Cai <peter@typeblog.net>
Date: Wed, 24 Aug 2022 10:41:29 -0400 Date: Wed, 24 Aug 2022 10:41:29 -0400
Subject: [PATCH 1/2] gd: hci: Ignore unexpected status events Subject: [PATCH 1/2] gd: hci: Ignore unexpected status events
@ -9,30 +9,31 @@ error here (the status event comes from the failure response).
Change-Id: Ifb9a65fd77f21d15a8dc1ced9240194d38218ef6 Change-Id: Ifb9a65fd77f21d15a8dc1ced9240194d38218ef6
--- ---
system/gd/hci/hci_layer.cc | 14 +++++++------- system/gd/hci/hci_layer.cc | 15 +++++++--------
1 file changed, 7 insertions(+), 7 deletions(-) 1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/system/gd/hci/hci_layer.cc b/system/gd/hci/hci_layer.cc diff --git a/system/gd/hci/hci_layer.cc b/system/gd/hci/hci_layer.cc
index fe5fa33..9c411fb 100644 index 5ae661cb75..d91bb1480d 100644
--- a/system/gd/hci/hci_layer.cc --- a/system/gd/hci/hci_layer.cc
+++ b/system/gd/hci/hci_layer.cc +++ b/system/gd/hci/hci_layer.cc
@@ -230,13 +230,13 @@ struct HciLayer::impl { @@ -218,14 +218,13 @@ struct HciLayer::impl {
command_complete_view.IsValid(), "assert failed: command_complete_view.IsValid()"); command_queue_.front().GetCallback<CommandCompleteView>()->Invoke(
(*command_queue_.front().GetCallback<CommandCompleteView>())(command_complete_view); std::move(command_complete_view));
} else { } else {
- log::assert_that( - ASSERT_LOG(
- command_queue_.front().waiting_for_status_ == is_status, - command_queue_.front().waiting_for_status_ == is_status,
- "{} was not expecting {} event", - "0x%02hx (%s) was not expecting %s event",
- OpCodeText(op_code), - op_code,
- logging_id); - OpCodeText(op_code).c_str(),
- logging_id.c_str());
- -
- (*command_queue_.front().GetCallback<TResponse>())(std::move(response_view)); - command_queue_.front().GetCallback<TResponse>()->Invoke(std::move(response_view));
+ if (command_queue_.front().waiting_for_status_ == is_status) { + if (command_queue_.front().waiting_for_status_ == is_status) {
+ (*command_queue_.front().GetCallback<TResponse>())(std::move(response_view)); + command_queue_.front().GetCallback<TResponse>()->Invoke(std::move(response_view));
+ } else { + } else {
+ CommandCompleteView command_complete_view = CommandCompleteView::Create( + CommandCompleteView command_complete_view = CommandCompleteView::Create(
+ EventView::Create(PacketView<kLittleEndian>(std::make_shared<std::vector<uint8_t>>(std::vector<uint8_t>())))); + EventView::Create(PacketView<kLittleEndian>(std::make_shared<std::vector<uint8_t>>(std::vector<uint8_t>()))));
+ (*command_queue_.front().GetCallback<CommandCompleteView>())(std::move(command_complete_view)); + command_queue_.front().GetCallback<CommandCompleteView>()->Invoke(std::move(command_complete_view));
+ } + }
} }

View file

@ -1,4 +1,4 @@
From 63b517cc58a937ba43ff7fe2527990b4b532521d Mon Sep 17 00:00:00 2001 From 16e6571d11f6a2509a496e84e0d08ebae3b39254 Mon Sep 17 00:00:00 2001
From: Peter Cai <peter@typeblog.net> From: Peter Cai <peter@typeblog.net>
Date: Wed, 24 Aug 2022 15:45:18 -0400 Date: Wed, 24 Aug 2022 15:45:18 -0400
Subject: [PATCH 2/2] audio_hal_interface: Optionally use sysbta HAL Subject: [PATCH 2/2] audio_hal_interface: Optionally use sysbta HAL
@ -13,10 +13,10 @@ Change-Id: I59973e6ec84c5923be8a7c67b36b2e237f000860
3 files changed, 20 insertions(+), 6 deletions(-) 3 files changed, 20 insertions(+), 6 deletions(-)
diff --git a/system/audio_hal_interface/aidl/client_interface_aidl.cc b/system/audio_hal_interface/aidl/client_interface_aidl.cc diff --git a/system/audio_hal_interface/aidl/client_interface_aidl.cc b/system/audio_hal_interface/aidl/client_interface_aidl.cc
index f4cfee0..f98032e 100644 index 76e8788d02..a990422993 100644
--- a/system/audio_hal_interface/aidl/client_interface_aidl.cc --- a/system/audio_hal_interface/aidl/client_interface_aidl.cc
+++ b/system/audio_hal_interface/aidl/client_interface_aidl.cc +++ b/system/audio_hal_interface/aidl/client_interface_aidl.cc
@@ -68,7 +68,7 @@ bool BluetoothAudioClientInterface::IsValid() const { @@ -63,7 +63,7 @@ BluetoothAudioClientInterface::BluetoothAudioClientInterface(
bool BluetoothAudioClientInterface::is_aidl_available() { bool BluetoothAudioClientInterface::is_aidl_available() {
return AServiceManager_isDeclared( return AServiceManager_isDeclared(
@ -25,7 +25,7 @@ index f4cfee0..f98032e 100644
} }
std::vector<AudioCapabilities> std::vector<AudioCapabilities>
@@ -84,7 +84,7 @@ BluetoothAudioClientInterface::GetAudioCapabilities(SessionType session_type) { @@ -79,7 +79,7 @@ BluetoothAudioClientInterface::GetAudioCapabilities(SessionType session_type) {
} }
auto provider_factory = IBluetoothAudioProviderFactory::fromBinder( auto provider_factory = IBluetoothAudioProviderFactory::fromBinder(
::ndk::SpAIBinder(AServiceManager_waitForService( ::ndk::SpAIBinder(AServiceManager_waitForService(
@ -33,8 +33,8 @@ index f4cfee0..f98032e 100644
+ audioProviderFactoryInterface().c_str()))); + audioProviderFactoryInterface().c_str())));
if (provider_factory == nullptr) { if (provider_factory == nullptr) {
log::error("can't get capability from unknown factory"); LOG(ERROR) << __func__ << ", can't get capability from unknown factory";
@@ -112,7 +112,7 @@ BluetoothAudioClientInterface::GetProviderInfo( @@ -108,7 +108,7 @@ BluetoothAudioClientInterface::GetProviderInfo(
if (provider_factory == nullptr) { if (provider_factory == nullptr) {
provider_factory = IBluetoothAudioProviderFactory::fromBinder( provider_factory = IBluetoothAudioProviderFactory::fromBinder(
::ndk::SpAIBinder(AServiceManager_waitForService( ::ndk::SpAIBinder(AServiceManager_waitForService(
@ -43,7 +43,7 @@ index f4cfee0..f98032e 100644
} }
if (provider_factory == nullptr) { if (provider_factory == nullptr) {
@@ -193,7 +193,7 @@ void BluetoothAudioClientInterface::FetchAudioProvider() { @@ -192,7 +192,7 @@ void BluetoothAudioClientInterface::FetchAudioProvider() {
} }
auto provider_factory = IBluetoothAudioProviderFactory::fromBinder( auto provider_factory = IBluetoothAudioProviderFactory::fromBinder(
::ndk::SpAIBinder(AServiceManager_waitForService( ::ndk::SpAIBinder(AServiceManager_waitForService(
@ -51,20 +51,20 @@ index f4cfee0..f98032e 100644
+ audioProviderFactoryInterface().c_str()))); + audioProviderFactoryInterface().c_str())));
if (provider_factory == nullptr) { if (provider_factory == nullptr) {
log::error("can't get capability from unknown factory"); LOG(ERROR) << __func__ << ", can't get capability from unknown factory";
diff --git a/system/audio_hal_interface/aidl/client_interface_aidl.h b/system/audio_hal_interface/aidl/client_interface_aidl.h diff --git a/system/audio_hal_interface/aidl/client_interface_aidl.h b/system/audio_hal_interface/aidl/client_interface_aidl.h
index 9b92319..643507e 100644 index c191e4054e..99d5192376 100644
--- a/system/audio_hal_interface/aidl/client_interface_aidl.h --- a/system/audio_hal_interface/aidl/client_interface_aidl.h
+++ b/system/audio_hal_interface/aidl/client_interface_aidl.h +++ b/system/audio_hal_interface/aidl/client_interface_aidl.h
@@ -29,6 +29,7 @@ @@ -27,6 +27,7 @@
#include "bta/le_audio/broadcaster/broadcaster_types.h" #include "audio_ctrl_ack.h"
#include "bta/le_audio/le_audio_types.h" #include "bluetooth_audio_port_impl.h"
#include "transport_instance.h" #include "transport_instance.h"
+#include "osi/include/properties.h" +#include "osi/include/properties.h"
#define BLUETOOTH_AUDIO_HAL_PROP_DISABLED \ #define BLUETOOTH_AUDIO_HAL_PROP_DISABLED \
"persist.bluetooth.bluetooth_audio_hal.disabled" "persist.bluetooth.bluetooth_audio_hal.disabled"
@@ -177,6 +178,12 @@ class BluetoothAudioClientInterface { @@ -175,6 +176,12 @@ class BluetoothAudioClientInterface {
// "android.hardware.bluetooth.audio.IBluetoothAudioProviderFactory/default"; // "android.hardware.bluetooth.audio.IBluetoothAudioProviderFactory/default";
static inline const std::string kDefaultAudioProviderFactoryInterface = static inline const std::string kDefaultAudioProviderFactoryInterface =
std::string() + IBluetoothAudioProviderFactory::descriptor + "/default"; std::string() + IBluetoothAudioProviderFactory::descriptor + "/default";
@ -78,18 +78,18 @@ index 9b92319..643507e 100644
private: private:
IBluetoothTransportInstance* transport_; IBluetoothTransportInstance* transport_;
diff --git a/system/audio_hal_interface/hal_version_manager.cc b/system/audio_hal_interface/hal_version_manager.cc diff --git a/system/audio_hal_interface/hal_version_manager.cc b/system/audio_hal_interface/hal_version_manager.cc
index c4e01bc..55ef87b 100644 index 36672cb32c..d2b75e7891 100644
--- a/system/audio_hal_interface/hal_version_manager.cc --- a/system/audio_hal_interface/hal_version_manager.cc
+++ b/system/audio_hal_interface/hal_version_manager.cc +++ b/system/audio_hal_interface/hal_version_manager.cc
@@ -20,6 +20,7 @@ @@ -26,6 +26,7 @@
#include <android/hidl/manager/1.2/IServiceManager.h> #include "aidl/audio_aidl_interfaces.h"
#include <bluetooth/log.h> #include "include/check.h"
#include <hidl/ServiceManagement.h> #include "os/log.h"
+#include "osi/include/properties.h" +#include "osi/include/properties.h"
#include <memory> namespace bluetooth {
namespace audio {
@@ -34,6 +35,12 @@ using ::aidl::android::hardware::bluetooth::audio:: @@ -35,6 +36,12 @@ using ::aidl::android::hardware::bluetooth::audio::
static const std::string kDefaultAudioProviderFactoryInterface = static const std::string kDefaultAudioProviderFactoryInterface =
std::string() + IBluetoothAudioProviderFactory::descriptor + "/default"; std::string() + IBluetoothAudioProviderFactory::descriptor + "/default";
@ -102,7 +102,7 @@ index c4e01bc..55ef87b 100644
std::string toString(BluetoothAudioHalTransport transport) { std::string toString(BluetoothAudioHalTransport transport) {
switch (transport) { switch (transport) {
@@ -75,7 +82,7 @@ BluetoothAudioHalVersion GetAidlInterfaceVersion() { @@ -76,7 +83,7 @@ BluetoothAudioHalVersion GetAidlInterfaceVersion() {
int version = 0; int version = 0;
auto provider_factory = IBluetoothAudioProviderFactory::fromBinder( auto provider_factory = IBluetoothAudioProviderFactory::fromBinder(
::ndk::SpAIBinder(AServiceManager_waitForService( ::ndk::SpAIBinder(AServiceManager_waitForService(
@ -110,8 +110,8 @@ index c4e01bc..55ef87b 100644
+ audioProviderFactoryInterface().c_str()))); + audioProviderFactoryInterface().c_str())));
if (provider_factory == nullptr) { if (provider_factory == nullptr) {
log::error( LOG_ERROR(
@@ -147,7 +154,7 @@ HalVersionManager::GetProvidersFactory_2_0() { @@ -146,7 +153,7 @@ HalVersionManager::GetProvidersFactory_2_0() {
HalVersionManager::HalVersionManager() { HalVersionManager::HalVersionManager() {
hal_transport_ = BluetoothAudioHalTransport::UNKNOWN; hal_transport_ = BluetoothAudioHalTransport::UNKNOWN;
if (AServiceManager_checkService( if (AServiceManager_checkService(

View file

@ -1,4 +1,4 @@
From 54428255201c9f02f4827961ad077c74ff126860 Mon Sep 17 00:00:00 2001 From 5452f9228873c2e00897aeb74e8b453d939d2e4c Mon Sep 17 00:00:00 2001
From: Isaac Chen <tingyi364@gmail.com> From: Isaac Chen <tingyi364@gmail.com>
Date: Wed, 23 Jun 2021 13:07:30 +0800 Date: Wed, 23 Jun 2021 13:07:30 +0800
Subject: [PATCH 1/2] init: Do not start console service when debuggable Subject: [PATCH 1/2] init: Do not start console service when debuggable
@ -13,10 +13,10 @@ Change-Id: I34cfd6b42d3b9aee4b3e63181480cfb8b1255f29
1 file changed, 3 deletions(-) 1 file changed, 3 deletions(-)
diff --git a/rootdir/init.rc b/rootdir/init.rc diff --git a/rootdir/init.rc b/rootdir/init.rc
index 2443b7c..06cb386 100644 index 8a2ed9fac..960534805 100644
--- a/rootdir/init.rc --- a/rootdir/init.rc
+++ b/rootdir/init.rc +++ b/rootdir/init.rc
@@ -1317,9 +1317,6 @@ on property:ro.debuggable=1 @@ -1306,9 +1306,6 @@ on property:ro.debuggable=1
# Give reads to anyone for the accessibility trace folder on debug builds. # Give reads to anyone for the accessibility trace folder on debug builds.
chmod 0775 /data/misc/a11ytrace chmod 0775 /data/misc/a11ytrace

View file

@ -1,4 +1,4 @@
From 18b70443969bec36e1f8551b6f67a762df5fc210 Mon Sep 17 00:00:00 2001 From ddaa66e3cdc62f065143b1a8eb3f06bec65ff651 Mon Sep 17 00:00:00 2001
From: Pierre-Hugues Husson <phh@phh.me> From: Pierre-Hugues Husson <phh@phh.me>
Date: Wed, 23 Feb 2022 17:37:47 -0500 Date: Wed, 23 Feb 2022 17:37:47 -0500
Subject: [PATCH 2/2] init: Override select system properties Subject: [PATCH 2/2] init: Override select system properties
@ -11,10 +11,10 @@ Change-Id: I94efa3f108ae97711026f099f367b6bea325629f
1 file changed, 11 insertions(+), 4 deletions(-) 1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/init/property_service.cpp b/init/property_service.cpp diff --git a/init/property_service.cpp b/init/property_service.cpp
index 0d6eb15..16e0448 100644 index 157fc709c..7ec3c0b10 100644
--- a/init/property_service.cpp --- a/init/property_service.cpp
+++ b/init/property_service.cpp +++ b/init/property_service.cpp
@@ -801,13 +801,20 @@ static void LoadProperties(char* data, const char* filter, const char* filename, @@ -797,13 +797,20 @@ static void LoadProperties(char* data, const char* filter, const char* filename,
std::string error; std::string error;
if (CheckPermissions(key, value, context, cr, &error) == PROP_SUCCESS) { if (CheckPermissions(key, value, context, cr, &error) == PROP_SUCCESS) {
auto it = properties->find(key); auto it = properties->find(key);