From f5e2469c02825f018df6336125882812003b8e64 Mon Sep 17 00:00:00 2001 From: Eric Laurent Date: Sun, 27 Jul 2014 16:14:57 -0700 Subject: audio HAL: add parameters to open stream Pass device address (and audio source for inputs) to open_output_stream() and open_input_stream() audio HAL functions. Bug: 14815883. Change-Id: I5535677db3f3027917a31a7ed5c0a4c6bc013639 --- modules/audio/audio_hw.c | 7 +++++-- modules/audio_remote_submix/audio_hw.cpp | 7 +++++-- modules/usbaudio/audio_hw.c | 7 +++++-- 3 files changed, 15 insertions(+), 6 deletions(-) (limited to 'modules') diff --git a/modules/audio/audio_hw.c b/modules/audio/audio_hw.c index ef070c1..18c0e59 100644 --- a/modules/audio/audio_hw.c +++ b/modules/audio/audio_hw.c @@ -218,7 +218,8 @@ static int adev_open_output_stream(struct audio_hw_device *dev, audio_devices_t devices, audio_output_flags_t flags, struct audio_config *config, - struct audio_stream_out **stream_out) + struct audio_stream_out **stream_out, + const char *address __unused) { struct stub_audio_device *ladev = (struct stub_audio_device *)dev; struct stub_stream_out *out; @@ -328,7 +329,9 @@ static int adev_open_input_stream(struct audio_hw_device *dev, audio_devices_t devices, struct audio_config *config, struct audio_stream_in **stream_in, - audio_input_flags_t flags __unused) + audio_input_flags_t flags __unused, + const char *address __unused, + audio_source_t source __unused) { struct stub_audio_device *ladev = (struct stub_audio_device *)dev; struct stub_stream_in *in; diff --git a/modules/audio_remote_submix/audio_hw.cpp b/modules/audio_remote_submix/audio_hw.cpp index 9e824b1..014da8e 100644 --- a/modules/audio_remote_submix/audio_hw.cpp +++ b/modules/audio_remote_submix/audio_hw.cpp @@ -1188,7 +1188,8 @@ static int adev_open_output_stream(struct audio_hw_device *dev, audio_devices_t devices, audio_output_flags_t flags, struct audio_config *config, - struct audio_stream_out **stream_out) + struct audio_stream_out **stream_out, + const char *address __unused) { struct submix_audio_device * const rsxadev = audio_hw_device_get_submix_audio_device(dev); ALOGV("adev_open_output_stream()"); @@ -1374,7 +1375,9 @@ static int adev_open_input_stream(struct audio_hw_device *dev, audio_devices_t devices, struct audio_config *config, struct audio_stream_in **stream_in, - audio_input_flags_t flags __unused) + audio_input_flags_t flags __unused, + const char *address __unused, + audio_source_t source __unused) { struct submix_audio_device *rsxadev = audio_hw_device_get_submix_audio_device(dev); struct submix_stream_in *in; diff --git a/modules/usbaudio/audio_hw.c b/modules/usbaudio/audio_hw.c index 4a946e7..d9bb611 100644 --- a/modules/usbaudio/audio_hw.c +++ b/modules/usbaudio/audio_hw.c @@ -473,7 +473,8 @@ static int adev_open_output_stream(struct audio_hw_device *dev, audio_devices_t devices, audio_output_flags_t flags, struct audio_config *config, - struct audio_stream_out **stream_out) + struct audio_stream_out **stream_out, + const char *address __unused) { ALOGV("usb:audio_hw::out adev_open_output_stream() handle:0x%X, device:0x%X, flags:0x%X", handle, devices, flags); @@ -888,7 +889,9 @@ static int adev_open_input_stream(struct audio_hw_device *dev, audio_devices_t devices, struct audio_config *config, struct audio_stream_in **stream_in, - audio_input_flags_t flags __unused) + audio_input_flags_t flags __unused, + const char *address __unused, + audio_source_t source __unused) { ALOGV("usb: in adev_open_input_stream() rate:%" PRIu32 ", chanMask:0x%" PRIX32 ", fmt:%" PRIu8, config->sample_rate, config->channel_mask, config->format); -- cgit v1.1