audiopolicy: Modify logging in setOutputDevices
Modify logging in setOutputDevices to log ioHandles, mixport
names for better debugging.
Also, modify the method signature to include caller, as
setOutputDevices can be modified from multiple places,
having a caller context is helpful during multiple
device connection scenarios.
Test: Build and check logs while running usecases
Bug: 293535290
Change-Id: I461bf184bfab1c45ebe0170008fc59aa5a6a29a4
diff --git a/services/audiopolicy/managerdefault/AudioPolicyManager.h b/services/audiopolicy/managerdefault/AudioPolicyManager.h
index 863c785..509cc79 100644
--- a/services/audiopolicy/managerdefault/AudioPolicyManager.h
+++ b/services/audiopolicy/managerdefault/AudioPolicyManager.h
@@ -526,6 +526,7 @@
/**
* @brief setOutputDevices change the route of the specified output.
+ * @param caller of the method
* @param outputDesc to be considered
* @param device to be considered to route the output
* @param force if true, force the routing even if no change.
@@ -539,7 +540,8 @@
* @return the number of ms we have slept to allow new routing to take effect in certain
* cases.
*/
- uint32_t setOutputDevices(const sp<SwAudioOutputDescriptor>& outputDesc,
+ uint32_t setOutputDevices(const char *caller,
+ const sp<SwAudioOutputDescriptor>& outputDesc,
const DeviceVector &device,
bool force = false,
int delayMs = 0,