summaryrefslogtreecommitdiff
path: root/tizen-audio-pcm.c
diff options
context:
space:
mode:
authorJungsup Lee <jungsup4.lee@samsung.com>2018-06-26 14:38:32 +0900
committerSangchul Lee <sc11.lee@samsung.com>2018-07-20 15:26:29 +0900
commit8dab939f22e28efa0524c4115f386723be1560dd (patch)
treec2e1d7a3d77f4794b31934e732b6c1dd35507ada /tizen-audio-pcm.c
parent7776d3b124e9a858937059fd4de70f21662d2f2f (diff)
downloadaudio-hal-sc7727-8dab939f22e28efa0524c4115f386723be1560dd.tar.gz
audio-hal-sc7727-8dab939f22e28efa0524c4115f386723be1560dd.tar.bz2
audio-hal-sc7727-8dab939f22e28efa0524c4115f386723be1560dd.zip
Card and device arguments are added to pcm open APIsubmit/tizen/20180724.034640accepted/tizen/unified/20180726.064845
[Version] 0.1.24 [Issue Type] API Change-Id: Ia1ba2a63b3aa3212e756debf548611046ebb9495 Signed-off-by: Sangchul Lee <sc11.lee@samsung.com>
Diffstat (limited to 'tizen-audio-pcm.c')
-rw-r--r--tizen-audio-pcm.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/tizen-audio-pcm.c b/tizen-audio-pcm.c
index de97595..e11f8cc 100644
--- a/tizen-audio-pcm.c
+++ b/tizen-audio-pcm.c
@@ -50,7 +50,8 @@ audio_return_t _audio_pcm_deinit(audio_hal_t *ah)
return AUDIO_RET_OK;
}
-audio_return_t audio_pcm_open(void *audio_handle, void **pcm_handle, uint32_t direction, void *sample_spec, uint32_t period_size, uint32_t periods)
+audio_return_t audio_pcm_open(void *audio_handle, const char *card, const char *device, uint32_t direction, void *sample_spec,
+ uint32_t period_size, uint32_t periods, void **pcm_handle)
{
audio_return_t audio_ret = AUDIO_RET_OK;
audio_hal_t *ah = NULL;
@@ -61,12 +62,12 @@ audio_return_t audio_pcm_open(void *audio_handle, void **pcm_handle, uint32_t di
AUDIO_RETURN_VAL_IF_FAIL((period_size > 0), AUDIO_ERR_PARAMETER);
AUDIO_RETURN_VAL_IF_FAIL((periods > 0), AUDIO_ERR_PARAMETER);
- if ((audio_ret = _pcm_open(pcm_handle, direction, sample_spec, period_size, periods)))
+ if ((audio_ret = _pcm_open(card, device, direction, sample_spec, period_size, periods, pcm_handle)))
return audio_ret;
ah = (audio_hal_t*)audio_handle;
ah->device.pcm_count++;
- AUDIO_LOG_INFO("Opening PCM handle 0x%x", *pcm_handle);
+ AUDIO_LOG_INFO("Opening PCM handle 0x%x", (unsigned int)*pcm_handle);
return AUDIO_RET_OK;
}
@@ -205,4 +206,4 @@ audio_return_t audio_pcm_set_params(void *audio_handle, void *pcm_handle, uint32
audio_ret = _pcm_set_params(pcm_handle, direction, sample_spec, period_size, periods);
return audio_ret;
-} \ No newline at end of file
+}