Merge "Retire pcmStart and pcmStop" am: afd71a85a1
Original change: https://android-review.googlesource.com/c/device/generic/goldfish/+/2185996
Change-Id: I21949710880e465abf4c67a89f11ff89f8e440bd
Signed-off-by: Automerger Merge Worker <android-build-automerger-merge-worker@system.gserviceaccount.com>
diff --git a/audio/talsa.cpp b/audio/talsa.cpp
index 3844609..41e5cb1 100644
--- a/audio/talsa.cpp
+++ b/audio/talsa.cpp
@@ -183,36 +183,6 @@
}
}
-bool pcmStart(pcm_t *pcm) {
- if (!pcm) {
- return FAILURE(false);
- }
-
- const int r = ::pcm_start(pcm);
- if (r) {
- ALOGE("%s:%d pcm_start failed with %s",
- __func__, __LINE__, ::pcm_get_error(pcm));
- return FAILURE(false);
- } else {
- return true;
- }
-}
-
-bool pcmStop(pcm_t *pcm) {
- if (!pcm) {
- return FAILURE(false);
- }
-
- const int r = ::pcm_stop(pcm);
- if (r) {
- ALOGE("%s:%d pcm_stop failed with %s",
- __func__, __LINE__, ::pcm_get_error(pcm));
- return FAILURE(false);
- } else {
- return true;
- }
-}
-
bool pcmRead(pcm_t *pcm, void *data, unsigned int count) {
if (!pcm) {
return FAILURE(false);
diff --git a/audio/talsa.h b/audio/talsa.h
index 6f2883c..780ca31 100644
--- a/audio/talsa.h
+++ b/audio/talsa.h
@@ -43,8 +43,6 @@
PcmPtr pcmOpen(unsigned int dev, unsigned int card, unsigned int nChannels,
size_t sampleRateHz, size_t frameCount, bool isOut);
bool pcmPrepare(pcm_t *pcm);
-bool pcmStart(pcm_t *pcm);
-bool pcmStop(pcm_t *pcm);
bool pcmRead(pcm_t *pcm, void *data, unsigned int count);
bool pcmWrite(pcm_t *pcm, const void *data, unsigned int count);