diff options
Diffstat (limited to 'include/sound/pcm-indirect.h')
-rw-r--r-- | include/sound/pcm-indirect.h | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/include/sound/pcm-indirect.h b/include/sound/pcm-indirect.h index 31fa7a54508a..7003d7702e26 100644 --- a/include/sound/pcm-indirect.h +++ b/include/sound/pcm-indirect.h | |||
@@ -24,7 +24,7 @@ | |||
24 | 24 | ||
25 | #include <sound/pcm.h> | 25 | #include <sound/pcm.h> |
26 | 26 | ||
27 | typedef struct sndrv_pcm_indirect { | 27 | struct snd_pcm_indirect { |
28 | unsigned int hw_buffer_size; /* Byte size of hardware buffer */ | 28 | unsigned int hw_buffer_size; /* Byte size of hardware buffer */ |
29 | unsigned int hw_queue_size; /* Max queue size of hw buffer (0 = buffer size) */ | 29 | unsigned int hw_queue_size; /* Max queue size of hw buffer (0 = buffer size) */ |
30 | unsigned int hw_data; /* Offset to next dst (or src) in hw ring buffer */ | 30 | unsigned int hw_data; /* Offset to next dst (or src) in hw ring buffer */ |
@@ -35,20 +35,20 @@ typedef struct sndrv_pcm_indirect { | |||
35 | unsigned int sw_io; /* Current software pointer in bytes */ | 35 | unsigned int sw_io; /* Current software pointer in bytes */ |
36 | int sw_ready; /* Bytes ready to be transferred to/from hw */ | 36 | int sw_ready; /* Bytes ready to be transferred to/from hw */ |
37 | snd_pcm_uframes_t appl_ptr; /* Last seen appl_ptr */ | 37 | snd_pcm_uframes_t appl_ptr; /* Last seen appl_ptr */ |
38 | } snd_pcm_indirect_t; | 38 | }; |
39 | 39 | ||
40 | typedef void (*snd_pcm_indirect_copy_t)(snd_pcm_substream_t *substream, | 40 | typedef void (*snd_pcm_indirect_copy_t)(struct snd_pcm_substream *substream, |
41 | snd_pcm_indirect_t *rec, size_t bytes); | 41 | struct snd_pcm_indirect *rec, size_t bytes); |
42 | 42 | ||
43 | /* | 43 | /* |
44 | * helper function for playback ack callback | 44 | * helper function for playback ack callback |
45 | */ | 45 | */ |
46 | static inline void | 46 | static inline void |
47 | snd_pcm_indirect_playback_transfer(snd_pcm_substream_t *substream, | 47 | snd_pcm_indirect_playback_transfer(struct snd_pcm_substream *substream, |
48 | snd_pcm_indirect_t *rec, | 48 | struct snd_pcm_indirect *rec, |
49 | snd_pcm_indirect_copy_t copy) | 49 | snd_pcm_indirect_copy_t copy) |
50 | { | 50 | { |
51 | snd_pcm_runtime_t *runtime = substream->runtime; | 51 | struct snd_pcm_runtime *runtime = substream->runtime; |
52 | snd_pcm_uframes_t appl_ptr = runtime->control->appl_ptr; | 52 | snd_pcm_uframes_t appl_ptr = runtime->control->appl_ptr; |
53 | snd_pcm_sframes_t diff = appl_ptr - rec->appl_ptr; | 53 | snd_pcm_sframes_t diff = appl_ptr - rec->appl_ptr; |
54 | int qsize; | 54 | int qsize; |
@@ -89,8 +89,8 @@ snd_pcm_indirect_playback_transfer(snd_pcm_substream_t *substream, | |||
89 | * ptr = current byte pointer | 89 | * ptr = current byte pointer |
90 | */ | 90 | */ |
91 | static inline snd_pcm_uframes_t | 91 | static inline snd_pcm_uframes_t |
92 | snd_pcm_indirect_playback_pointer(snd_pcm_substream_t *substream, | 92 | snd_pcm_indirect_playback_pointer(struct snd_pcm_substream *substream, |
93 | snd_pcm_indirect_t *rec, unsigned int ptr) | 93 | struct snd_pcm_indirect *rec, unsigned int ptr) |
94 | { | 94 | { |
95 | int bytes = ptr - rec->hw_io; | 95 | int bytes = ptr - rec->hw_io; |
96 | if (bytes < 0) | 96 | if (bytes < 0) |
@@ -110,11 +110,11 @@ snd_pcm_indirect_playback_pointer(snd_pcm_substream_t *substream, | |||
110 | * helper function for capture ack callback | 110 | * helper function for capture ack callback |
111 | */ | 111 | */ |
112 | static inline void | 112 | static inline void |
113 | snd_pcm_indirect_capture_transfer(snd_pcm_substream_t *substream, | 113 | snd_pcm_indirect_capture_transfer(struct snd_pcm_substream *substream, |
114 | snd_pcm_indirect_t *rec, | 114 | struct snd_pcm_indirect *rec, |
115 | snd_pcm_indirect_copy_t copy) | 115 | snd_pcm_indirect_copy_t copy) |
116 | { | 116 | { |
117 | snd_pcm_runtime_t *runtime = substream->runtime; | 117 | struct snd_pcm_runtime *runtime = substream->runtime; |
118 | snd_pcm_uframes_t appl_ptr = runtime->control->appl_ptr; | 118 | snd_pcm_uframes_t appl_ptr = runtime->control->appl_ptr; |
119 | snd_pcm_sframes_t diff = appl_ptr - rec->appl_ptr; | 119 | snd_pcm_sframes_t diff = appl_ptr - rec->appl_ptr; |
120 | 120 | ||
@@ -154,8 +154,8 @@ snd_pcm_indirect_capture_transfer(snd_pcm_substream_t *substream, | |||
154 | * ptr = current byte pointer | 154 | * ptr = current byte pointer |
155 | */ | 155 | */ |
156 | static inline snd_pcm_uframes_t | 156 | static inline snd_pcm_uframes_t |
157 | snd_pcm_indirect_capture_pointer(snd_pcm_substream_t *substream, | 157 | snd_pcm_indirect_capture_pointer(struct snd_pcm_substream *substream, |
158 | snd_pcm_indirect_t *rec, unsigned int ptr) | 158 | struct snd_pcm_indirect *rec, unsigned int ptr) |
159 | { | 159 | { |
160 | int qsize; | 160 | int qsize; |
161 | int bytes = ptr - rec->hw_io; | 161 | int bytes = ptr - rec->hw_io; |