blob: e1cca2e044d9ce335d1aa6fd370a50d3da0803e6 [file] [log] [blame]
Dima Zavin8cc353a2011-04-20 16:38:05 -07001/*
2 * Copyright (C) 2011 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17#define LOG_TAG "audio_hw_default"
18//#define LOG_NDEBUG 0
19
20#include <errno.h>
Elliott Hughes07c08552015-01-29 21:19:10 -080021#include <malloc.h>
Dima Zavin8cc353a2011-04-20 16:38:05 -070022#include <pthread.h>
23#include <stdint.h>
24#include <sys/time.h>
25
26#include <cutils/log.h>
27
28#include <hardware/hardware.h>
Dima Zavinaa211722011-05-11 14:15:53 -070029#include <system/audio.h>
Dima Zavin3bc15862011-06-13 17:59:54 -070030#include <hardware/audio.h>
Dima Zavin8cc353a2011-04-20 16:38:05 -070031
32struct stub_audio_device {
33 struct audio_hw_device device;
34};
35
36struct stub_stream_out {
37 struct audio_stream_out stream;
38};
39
40struct stub_stream_in {
41 struct audio_stream_in stream;
42};
43
44static uint32_t out_get_sample_rate(const struct audio_stream *stream)
45{
46 return 44100;
47}
48
49static int out_set_sample_rate(struct audio_stream *stream, uint32_t rate)
50{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080051 ALOGV("out_set_sample_rate: %d", 0);
52 return -ENOSYS;
Dima Zavin8cc353a2011-04-20 16:38:05 -070053}
54
55static size_t out_get_buffer_size(const struct audio_stream *stream)
56{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080057 ALOGV("out_get_buffer_size: %d", 4096);
Dima Zavin8cc353a2011-04-20 16:38:05 -070058 return 4096;
59}
60
Glenn Kastena6354492012-06-19 12:16:04 -070061static audio_channel_mask_t out_get_channels(const struct audio_stream *stream)
Dima Zavin8cc353a2011-04-20 16:38:05 -070062{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080063 ALOGV("out_get_channels");
Dima Zavin8cc353a2011-04-20 16:38:05 -070064 return AUDIO_CHANNEL_OUT_STEREO;
65}
66
Glenn Kastenfe79eb32012-01-12 14:55:57 -080067static audio_format_t out_get_format(const struct audio_stream *stream)
Dima Zavin8cc353a2011-04-20 16:38:05 -070068{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080069 ALOGV("out_get_format");
Dima Zavin8cc353a2011-04-20 16:38:05 -070070 return AUDIO_FORMAT_PCM_16_BIT;
71}
72
Glenn Kastenfe79eb32012-01-12 14:55:57 -080073static int out_set_format(struct audio_stream *stream, audio_format_t format)
Dima Zavin8cc353a2011-04-20 16:38:05 -070074{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080075 ALOGV("out_set_format: %d",format);
76 return -ENOSYS;
Dima Zavin8cc353a2011-04-20 16:38:05 -070077}
78
79static int out_standby(struct audio_stream *stream)
80{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080081 ALOGV("out_standby");
82
Dima Zavin8cc353a2011-04-20 16:38:05 -070083 return 0;
84}
85
86static int out_dump(const struct audio_stream *stream, int fd)
87{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080088 ALOGV("out_dump");
Dima Zavin8cc353a2011-04-20 16:38:05 -070089 return 0;
90}
91
92static int out_set_parameters(struct audio_stream *stream, const char *kvpairs)
93{
Ricardo Garcia37cd7722015-02-23 15:42:26 -080094 ALOGV("out_set_parameters");
Dima Zavin8cc353a2011-04-20 16:38:05 -070095 return 0;
96}
97
98static char * out_get_parameters(const struct audio_stream *stream, const char *keys)
99{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800100 ALOGV("out_get_parameters");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700101 return strdup("");
102}
103
104static uint32_t out_get_latency(const struct audio_stream_out *stream)
105{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800106 ALOGV("out_get_latency");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700107 return 0;
108}
109
110static int out_set_volume(struct audio_stream_out *stream, float left,
111 float right)
112{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800113 ALOGV("out_set_volume: Left:%f Right:%f", left, right);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700114 return 0;
115}
116
117static ssize_t out_write(struct audio_stream_out *stream, const void* buffer,
118 size_t bytes)
119{
Dmitry Shmidta898f932016-10-26 13:54:25 -0700120 ALOGV("out_write: bytes: %zu", bytes);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700121 /* XXX: fake timing for audio output */
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800122 usleep((int64_t)bytes * 1000000 / audio_stream_out_frame_size(stream) /
Dima Zavin8cc353a2011-04-20 16:38:05 -0700123 out_get_sample_rate(&stream->common));
124 return bytes;
125}
126
127static int out_get_render_position(const struct audio_stream_out *stream,
128 uint32_t *dsp_frames)
129{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800130 *dsp_frames = 0;
Glenn Kastene03bfa42015-03-23 10:52:31 -0700131 ALOGV("out_get_render_position: dsp_frames: %p", dsp_frames);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700132 return -EINVAL;
133}
134
Eric Laurentf3008aa2011-06-17 16:53:12 -0700135static int out_add_audio_effect(const struct audio_stream *stream, effect_handle_t effect)
136{
Glenn Kastene03bfa42015-03-23 10:52:31 -0700137 ALOGV("out_add_audio_effect: %p", effect);
Eric Laurentf3008aa2011-06-17 16:53:12 -0700138 return 0;
139}
140
141static int out_remove_audio_effect(const struct audio_stream *stream, effect_handle_t effect)
142{
Glenn Kastene03bfa42015-03-23 10:52:31 -0700143 ALOGV("out_remove_audio_effect: %p", effect);
Eric Laurentf3008aa2011-06-17 16:53:12 -0700144 return 0;
145}
146
Mike J. Chen5ad38a92011-08-15 12:05:00 -0700147static int out_get_next_write_timestamp(const struct audio_stream_out *stream,
148 int64_t *timestamp)
149{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800150 *timestamp = 0;
151 ALOGV("out_get_next_write_timestamp: %ld", (long int)(*timestamp));
Mike J. Chen5ad38a92011-08-15 12:05:00 -0700152 return -EINVAL;
153}
154
Dima Zavin8cc353a2011-04-20 16:38:05 -0700155/** audio_stream_in implementation **/
156static uint32_t in_get_sample_rate(const struct audio_stream *stream)
157{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800158 ALOGV("in_get_sample_rate");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700159 return 8000;
160}
161
162static int in_set_sample_rate(struct audio_stream *stream, uint32_t rate)
163{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800164 ALOGV("in_set_sample_rate: %d", rate);
165 return -ENOSYS;
Dima Zavin8cc353a2011-04-20 16:38:05 -0700166}
167
168static size_t in_get_buffer_size(const struct audio_stream *stream)
169{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800170 ALOGV("in_get_buffer_size: %d", 320);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700171 return 320;
172}
173
Glenn Kastena6354492012-06-19 12:16:04 -0700174static audio_channel_mask_t in_get_channels(const struct audio_stream *stream)
Dima Zavin8cc353a2011-04-20 16:38:05 -0700175{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800176 ALOGV("in_get_channels: %d", AUDIO_CHANNEL_IN_MONO);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700177 return AUDIO_CHANNEL_IN_MONO;
178}
179
Glenn Kastenfe79eb32012-01-12 14:55:57 -0800180static audio_format_t in_get_format(const struct audio_stream *stream)
Dima Zavin8cc353a2011-04-20 16:38:05 -0700181{
182 return AUDIO_FORMAT_PCM_16_BIT;
183}
184
Glenn Kastenfe79eb32012-01-12 14:55:57 -0800185static int in_set_format(struct audio_stream *stream, audio_format_t format)
Dima Zavin8cc353a2011-04-20 16:38:05 -0700186{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800187 return -ENOSYS;
Dima Zavin8cc353a2011-04-20 16:38:05 -0700188}
189
190static int in_standby(struct audio_stream *stream)
191{
192 return 0;
193}
194
195static int in_dump(const struct audio_stream *stream, int fd)
196{
197 return 0;
198}
199
200static int in_set_parameters(struct audio_stream *stream, const char *kvpairs)
201{
202 return 0;
203}
204
205static char * in_get_parameters(const struct audio_stream *stream,
206 const char *keys)
207{
208 return strdup("");
209}
210
211static int in_set_gain(struct audio_stream_in *stream, float gain)
212{
213 return 0;
214}
215
216static ssize_t in_read(struct audio_stream_in *stream, void* buffer,
217 size_t bytes)
218{
Dmitry Shmidta898f932016-10-26 13:54:25 -0700219 ALOGV("in_read: bytes %zu", bytes);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700220 /* XXX: fake timing for audio input */
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800221 usleep((int64_t)bytes * 1000000 / audio_stream_in_frame_size(stream) /
Dima Zavin8cc353a2011-04-20 16:38:05 -0700222 in_get_sample_rate(&stream->common));
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800223 memset(buffer, 0, bytes);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700224 return bytes;
225}
226
227static uint32_t in_get_input_frames_lost(struct audio_stream_in *stream)
228{
229 return 0;
230}
231
Eric Laurentf3008aa2011-06-17 16:53:12 -0700232static int in_add_audio_effect(const struct audio_stream *stream, effect_handle_t effect)
233{
234 return 0;
235}
236
237static int in_remove_audio_effect(const struct audio_stream *stream, effect_handle_t effect)
238{
239 return 0;
240}
Dima Zavin8cc353a2011-04-20 16:38:05 -0700241
242static int adev_open_output_stream(struct audio_hw_device *dev,
Eric Laurent55786bc2012-04-10 16:56:32 -0700243 audio_io_handle_t handle,
244 audio_devices_t devices,
245 audio_output_flags_t flags,
246 struct audio_config *config,
Eric Laurentf5e24692014-07-27 16:14:57 -0700247 struct audio_stream_out **stream_out,
248 const char *address __unused)
Dima Zavin8cc353a2011-04-20 16:38:05 -0700249{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800250 ALOGV("adev_open_output_stream...");
251
Dima Zavin8cc353a2011-04-20 16:38:05 -0700252 struct stub_audio_device *ladev = (struct stub_audio_device *)dev;
253 struct stub_stream_out *out;
254 int ret;
255
256 out = (struct stub_stream_out *)calloc(1, sizeof(struct stub_stream_out));
257 if (!out)
258 return -ENOMEM;
259
260 out->stream.common.get_sample_rate = out_get_sample_rate;
261 out->stream.common.set_sample_rate = out_set_sample_rate;
262 out->stream.common.get_buffer_size = out_get_buffer_size;
263 out->stream.common.get_channels = out_get_channels;
264 out->stream.common.get_format = out_get_format;
265 out->stream.common.set_format = out_set_format;
266 out->stream.common.standby = out_standby;
267 out->stream.common.dump = out_dump;
268 out->stream.common.set_parameters = out_set_parameters;
269 out->stream.common.get_parameters = out_get_parameters;
Eric Laurentf3008aa2011-06-17 16:53:12 -0700270 out->stream.common.add_audio_effect = out_add_audio_effect;
271 out->stream.common.remove_audio_effect = out_remove_audio_effect;
Dima Zavin8cc353a2011-04-20 16:38:05 -0700272 out->stream.get_latency = out_get_latency;
273 out->stream.set_volume = out_set_volume;
274 out->stream.write = out_write;
275 out->stream.get_render_position = out_get_render_position;
Mike J. Chen5ad38a92011-08-15 12:05:00 -0700276 out->stream.get_next_write_timestamp = out_get_next_write_timestamp;
Dima Zavin8cc353a2011-04-20 16:38:05 -0700277
278 *stream_out = &out->stream;
279 return 0;
280
281err_open:
282 free(out);
283 *stream_out = NULL;
284 return ret;
285}
286
287static void adev_close_output_stream(struct audio_hw_device *dev,
288 struct audio_stream_out *stream)
289{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800290 ALOGV("adev_close_output_stream...");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700291 free(stream);
292}
293
294static int adev_set_parameters(struct audio_hw_device *dev, const char *kvpairs)
295{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800296 ALOGV("adev_set_parameters");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700297 return -ENOSYS;
298}
299
300static char * adev_get_parameters(const struct audio_hw_device *dev,
301 const char *keys)
302{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800303 ALOGV("adev_get_parameters");
304 return strdup("");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700305}
306
307static int adev_init_check(const struct audio_hw_device *dev)
308{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800309 ALOGV("adev_init_check");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700310 return 0;
311}
312
313static int adev_set_voice_volume(struct audio_hw_device *dev, float volume)
314{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800315 ALOGV("adev_set_voice_volume: %f", volume);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700316 return -ENOSYS;
317}
318
319static int adev_set_master_volume(struct audio_hw_device *dev, float volume)
320{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800321 ALOGV("adev_set_master_volume: %f", volume);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700322 return -ENOSYS;
323}
324
John Grossman47bf3d72012-07-17 11:54:04 -0700325static int adev_get_master_volume(struct audio_hw_device *dev, float *volume)
326{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800327 ALOGV("adev_get_master_volume: %f", *volume);
John Grossman47bf3d72012-07-17 11:54:04 -0700328 return -ENOSYS;
329}
330
331static int adev_set_master_mute(struct audio_hw_device *dev, bool muted)
332{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800333 ALOGV("adev_set_master_mute: %d", muted);
John Grossman47bf3d72012-07-17 11:54:04 -0700334 return -ENOSYS;
335}
336
337static int adev_get_master_mute(struct audio_hw_device *dev, bool *muted)
Mike J. Chen5ad38a92011-08-15 12:05:00 -0700338{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800339 ALOGV("adev_get_master_mute: %d", *muted);
Mike J. Chen5ad38a92011-08-15 12:05:00 -0700340 return -ENOSYS;
341}
342
Glenn Kasten6df641e2012-01-09 10:41:30 -0800343static int adev_set_mode(struct audio_hw_device *dev, audio_mode_t mode)
Dima Zavin8cc353a2011-04-20 16:38:05 -0700344{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800345 ALOGV("adev_set_mode: %d", mode);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700346 return 0;
347}
348
349static int adev_set_mic_mute(struct audio_hw_device *dev, bool state)
350{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800351 ALOGV("adev_set_mic_mute: %d",state);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700352 return -ENOSYS;
353}
354
355static int adev_get_mic_mute(const struct audio_hw_device *dev, bool *state)
356{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800357 ALOGV("adev_get_mic_mute");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700358 return -ENOSYS;
359}
360
361static size_t adev_get_input_buffer_size(const struct audio_hw_device *dev,
Eric Laurent55786bc2012-04-10 16:56:32 -0700362 const struct audio_config *config)
Dima Zavin8cc353a2011-04-20 16:38:05 -0700363{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800364 ALOGV("adev_get_input_buffer_size: %d", 320);
Dima Zavin8cc353a2011-04-20 16:38:05 -0700365 return 320;
366}
367
Eric Laurent55786bc2012-04-10 16:56:32 -0700368static int adev_open_input_stream(struct audio_hw_device *dev,
369 audio_io_handle_t handle,
370 audio_devices_t devices,
371 struct audio_config *config,
Glenn Kasten7d973ad2014-07-15 11:10:38 -0700372 struct audio_stream_in **stream_in,
Eric Laurentf5e24692014-07-27 16:14:57 -0700373 audio_input_flags_t flags __unused,
374 const char *address __unused,
375 audio_source_t source __unused)
Dima Zavin8cc353a2011-04-20 16:38:05 -0700376{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800377 ALOGV("adev_open_input_stream...");
378
Dima Zavin8cc353a2011-04-20 16:38:05 -0700379 struct stub_audio_device *ladev = (struct stub_audio_device *)dev;
380 struct stub_stream_in *in;
381 int ret;
382
383 in = (struct stub_stream_in *)calloc(1, sizeof(struct stub_stream_in));
384 if (!in)
385 return -ENOMEM;
386
387 in->stream.common.get_sample_rate = in_get_sample_rate;
388 in->stream.common.set_sample_rate = in_set_sample_rate;
389 in->stream.common.get_buffer_size = in_get_buffer_size;
390 in->stream.common.get_channels = in_get_channels;
391 in->stream.common.get_format = in_get_format;
392 in->stream.common.set_format = in_set_format;
393 in->stream.common.standby = in_standby;
394 in->stream.common.dump = in_dump;
395 in->stream.common.set_parameters = in_set_parameters;
396 in->stream.common.get_parameters = in_get_parameters;
Eric Laurentf3008aa2011-06-17 16:53:12 -0700397 in->stream.common.add_audio_effect = in_add_audio_effect;
398 in->stream.common.remove_audio_effect = in_remove_audio_effect;
Dima Zavin8cc353a2011-04-20 16:38:05 -0700399 in->stream.set_gain = in_set_gain;
400 in->stream.read = in_read;
401 in->stream.get_input_frames_lost = in_get_input_frames_lost;
402
403 *stream_in = &in->stream;
404 return 0;
405
406err_open:
407 free(in);
408 *stream_in = NULL;
409 return ret;
410}
411
412static void adev_close_input_stream(struct audio_hw_device *dev,
413 struct audio_stream_in *in)
414{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800415 ALOGV("adev_close_input_stream...");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700416 return;
417}
418
419static int adev_dump(const audio_hw_device_t *device, int fd)
420{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800421 ALOGV("adev_dump");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700422 return 0;
423}
424
425static int adev_close(hw_device_t *device)
426{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800427 ALOGV("adev_close");
Dima Zavin8cc353a2011-04-20 16:38:05 -0700428 free(device);
429 return 0;
430}
431
Dima Zavin8cc353a2011-04-20 16:38:05 -0700432static int adev_open(const hw_module_t* module, const char* name,
433 hw_device_t** device)
434{
Ricardo Garcia37cd7722015-02-23 15:42:26 -0800435 ALOGV("adev_open: %s", name);
436
Dima Zavin8cc353a2011-04-20 16:38:05 -0700437 struct stub_audio_device *adev;
438 int ret;
439
440 if (strcmp(name, AUDIO_HARDWARE_INTERFACE) != 0)
441 return -EINVAL;
442
443 adev = calloc(1, sizeof(struct stub_audio_device));
444 if (!adev)
445 return -ENOMEM;
446
447 adev->device.common.tag = HARDWARE_DEVICE_TAG;
Eric Laurent85e08e22012-08-28 14:30:35 -0700448 adev->device.common.version = AUDIO_DEVICE_API_VERSION_2_0;
Dima Zavin8cc353a2011-04-20 16:38:05 -0700449 adev->device.common.module = (struct hw_module_t *) module;
450 adev->device.common.close = adev_close;
451
Dima Zavin8cc353a2011-04-20 16:38:05 -0700452 adev->device.init_check = adev_init_check;
453 adev->device.set_voice_volume = adev_set_voice_volume;
454 adev->device.set_master_volume = adev_set_master_volume;
Mike J. Chen5ad38a92011-08-15 12:05:00 -0700455 adev->device.get_master_volume = adev_get_master_volume;
John Grossman47bf3d72012-07-17 11:54:04 -0700456 adev->device.set_master_mute = adev_set_master_mute;
457 adev->device.get_master_mute = adev_get_master_mute;
Dima Zavin8cc353a2011-04-20 16:38:05 -0700458 adev->device.set_mode = adev_set_mode;
459 adev->device.set_mic_mute = adev_set_mic_mute;
460 adev->device.get_mic_mute = adev_get_mic_mute;
461 adev->device.set_parameters = adev_set_parameters;
462 adev->device.get_parameters = adev_get_parameters;
463 adev->device.get_input_buffer_size = adev_get_input_buffer_size;
464 adev->device.open_output_stream = adev_open_output_stream;
465 adev->device.close_output_stream = adev_close_output_stream;
466 adev->device.open_input_stream = adev_open_input_stream;
467 adev->device.close_input_stream = adev_close_input_stream;
468 adev->device.dump = adev_dump;
469
470 *device = &adev->device.common;
471
472 return 0;
473}
474
475static struct hw_module_methods_t hal_module_methods = {
476 .open = adev_open,
477};
478
479struct audio_module HAL_MODULE_INFO_SYM = {
480 .common = {
481 .tag = HARDWARE_MODULE_TAG,
Eric Laurent55786bc2012-04-10 16:56:32 -0700482 .module_api_version = AUDIO_MODULE_API_VERSION_0_1,
483 .hal_api_version = HARDWARE_HAL_API_VERSION,
Dima Zavin8cc353a2011-04-20 16:38:05 -0700484 .id = AUDIO_HARDWARE_MODULE_ID,
485 .name = "Default audio HW HAL",
486 .author = "The Android Open Source Project",
487 .methods = &hal_module_methods,
488 },
489};