mirror of
https://github.com/openharmony/third_party_tinyalsa.git
synced 2026-07-19 15:24:22 -04:00
tinyalsa: add pcm_get_subdevice()
The users of tinyalsa had no way of knowing on which subdevice a stream had been created. A new API, "unsigned int pcm_get_subdevice(struct *pcm)" returns it. This information is filled during the pcm_open() Change-Id: Ie866e10e06ce6691ede09e2ca46a24441723ea8b Signed-off-by: David Wagner <david.wagner@intel.com> Signed-off-by: Vinod Koul <vinod.koul@intel.com>
This commit is contained in:
@@ -179,6 +179,9 @@ unsigned int pcm_bytes_to_frames(struct pcm *pcm, unsigned int bytes);
|
||||
int pcm_get_htimestamp(struct pcm *pcm, unsigned int *avail,
|
||||
struct timespec *tstamp);
|
||||
|
||||
/* Returns the subdevice on which the pcm has been opened */
|
||||
unsigned int pcm_get_subdevice(struct pcm *pcm);
|
||||
|
||||
/* Write data to the fifo.
|
||||
* Will start playback on the first write or on a write that
|
||||
* occurs after a fifo underrun.
|
||||
|
||||
Reference in New Issue
Block a user