Commit 35f4b58c7a6e0a9708405cf96d505f1729b30c82
1 parent
9366f418
Prepare for changing audio_pcm_ops dynamically (partially revert r5422)
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@5435 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
11 changed files
with
13 additions
and
13 deletions
audio/alsaaudio.c
| @@ -917,7 +917,7 @@ static struct audio_option alsa_options[] = { | @@ -917,7 +917,7 @@ static struct audio_option alsa_options[] = { | ||
| 917 | {NULL, 0, NULL, NULL, NULL, 0} | 917 | {NULL, 0, NULL, NULL, NULL, 0} |
| 918 | }; | 918 | }; |
| 919 | 919 | ||
| 920 | -static const struct audio_pcm_ops alsa_pcm_ops = { | 920 | +static struct audio_pcm_ops alsa_pcm_ops = { |
| 921 | alsa_init_out, | 921 | alsa_init_out, |
| 922 | alsa_fini_out, | 922 | alsa_fini_out, |
| 923 | alsa_run_out, | 923 | alsa_run_out, |
audio/audio_int.h
| @@ -81,7 +81,7 @@ typedef struct HWVoiceOut { | @@ -81,7 +81,7 @@ typedef struct HWVoiceOut { | ||
| 81 | int samples; | 81 | int samples; |
| 82 | LIST_HEAD (sw_out_listhead, SWVoiceOut) sw_head; | 82 | LIST_HEAD (sw_out_listhead, SWVoiceOut) sw_head; |
| 83 | LIST_HEAD (sw_cap_listhead, SWVoiceCap) cap_head; | 83 | LIST_HEAD (sw_cap_listhead, SWVoiceCap) cap_head; |
| 84 | - const struct audio_pcm_ops *pcm_ops; | 84 | + struct audio_pcm_ops *pcm_ops; |
| 85 | LIST_ENTRY (HWVoiceOut) entries; | 85 | LIST_ENTRY (HWVoiceOut) entries; |
| 86 | } HWVoiceOut; | 86 | } HWVoiceOut; |
| 87 | 87 | ||
| @@ -99,7 +99,7 @@ typedef struct HWVoiceIn { | @@ -99,7 +99,7 @@ typedef struct HWVoiceIn { | ||
| 99 | 99 | ||
| 100 | int samples; | 100 | int samples; |
| 101 | LIST_HEAD (sw_in_listhead, SWVoiceIn) sw_head; | 101 | LIST_HEAD (sw_in_listhead, SWVoiceIn) sw_head; |
| 102 | - const struct audio_pcm_ops *pcm_ops; | 102 | + struct audio_pcm_ops *pcm_ops; |
| 103 | LIST_ENTRY (HWVoiceIn) entries; | 103 | LIST_ENTRY (HWVoiceIn) entries; |
| 104 | } HWVoiceIn; | 104 | } HWVoiceIn; |
| 105 | 105 | ||
| @@ -140,7 +140,7 @@ struct audio_driver { | @@ -140,7 +140,7 @@ struct audio_driver { | ||
| 140 | struct audio_option *options; | 140 | struct audio_option *options; |
| 141 | void *(*init) (void); | 141 | void *(*init) (void); |
| 142 | void (*fini) (void *); | 142 | void (*fini) (void *); |
| 143 | - const struct audio_pcm_ops *pcm_ops; | 143 | + struct audio_pcm_ops *pcm_ops; |
| 144 | int can_be_default; | 144 | int can_be_default; |
| 145 | int max_voices_out; | 145 | int max_voices_out; |
| 146 | int max_voices_in; | 146 | int max_voices_in; |
audio/coreaudio.c
| @@ -520,7 +520,7 @@ static struct audio_option coreaudio_options[] = { | @@ -520,7 +520,7 @@ static struct audio_option coreaudio_options[] = { | ||
| 520 | {NULL, 0, NULL, NULL, NULL, 0} | 520 | {NULL, 0, NULL, NULL, NULL, 0} |
| 521 | }; | 521 | }; |
| 522 | 522 | ||
| 523 | -static const struct audio_pcm_ops coreaudio_pcm_ops = { | 523 | +static struct audio_pcm_ops coreaudio_pcm_ops = { |
| 524 | coreaudio_init_out, | 524 | coreaudio_init_out, |
| 525 | coreaudio_fini_out, | 525 | coreaudio_fini_out, |
| 526 | coreaudio_run_out, | 526 | coreaudio_run_out, |
audio/dsoundaudio.c
| @@ -1057,7 +1057,7 @@ static struct audio_option dsound_options[] = { | @@ -1057,7 +1057,7 @@ static struct audio_option dsound_options[] = { | ||
| 1057 | {NULL, 0, NULL, NULL, NULL, 0} | 1057 | {NULL, 0, NULL, NULL, NULL, 0} |
| 1058 | }; | 1058 | }; |
| 1059 | 1059 | ||
| 1060 | -static const struct audio_pcm_ops dsound_pcm_ops = { | 1060 | +static struct audio_pcm_ops dsound_pcm_ops = { |
| 1061 | dsound_init_out, | 1061 | dsound_init_out, |
| 1062 | dsound_fini_out, | 1062 | dsound_fini_out, |
| 1063 | dsound_run_out, | 1063 | dsound_run_out, |
audio/esdaudio.c
| @@ -566,7 +566,7 @@ struct audio_option qesd_options[] = { | @@ -566,7 +566,7 @@ struct audio_option qesd_options[] = { | ||
| 566 | {NULL, 0, NULL, NULL, NULL, 0} | 566 | {NULL, 0, NULL, NULL, NULL, 0} |
| 567 | }; | 567 | }; |
| 568 | 568 | ||
| 569 | -static const struct audio_pcm_ops qesd_pcm_ops = { | 569 | +static struct audio_pcm_ops qesd_pcm_ops = { |
| 570 | qesd_init_out, | 570 | qesd_init_out, |
| 571 | qesd_fini_out, | 571 | qesd_fini_out, |
| 572 | qesd_run_out, | 572 | qesd_run_out, |
audio/fmodaudio.c
| @@ -657,7 +657,7 @@ static struct audio_option fmod_options[] = { | @@ -657,7 +657,7 @@ static struct audio_option fmod_options[] = { | ||
| 657 | {NULL, 0, NULL, NULL, NULL, 0} | 657 | {NULL, 0, NULL, NULL, NULL, 0} |
| 658 | }; | 658 | }; |
| 659 | 659 | ||
| 660 | -static const struct audio_pcm_ops fmod_pcm_ops = { | 660 | +static struct audio_pcm_ops fmod_pcm_ops = { |
| 661 | fmod_init_out, | 661 | fmod_init_out, |
| 662 | fmod_fini_out, | 662 | fmod_fini_out, |
| 663 | fmod_run_out, | 663 | fmod_run_out, |
audio/noaudio.c
| @@ -145,7 +145,7 @@ static void no_audio_fini (void *opaque) | @@ -145,7 +145,7 @@ static void no_audio_fini (void *opaque) | ||
| 145 | (void) opaque; | 145 | (void) opaque; |
| 146 | } | 146 | } |
| 147 | 147 | ||
| 148 | -static const struct audio_pcm_ops no_pcm_ops = { | 148 | +static struct audio_pcm_ops no_pcm_ops = { |
| 149 | no_init_out, | 149 | no_init_out, |
| 150 | no_fini_out, | 150 | no_fini_out, |
| 151 | no_run_out, | 151 | no_run_out, |
audio/ossaudio.c
| @@ -751,7 +751,7 @@ static struct audio_option oss_options[] = { | @@ -751,7 +751,7 @@ static struct audio_option oss_options[] = { | ||
| 751 | {NULL, 0, NULL, NULL, NULL, 0} | 751 | {NULL, 0, NULL, NULL, NULL, 0} |
| 752 | }; | 752 | }; |
| 753 | 753 | ||
| 754 | -static const struct audio_pcm_ops oss_pcm_ops = { | 754 | +static struct audio_pcm_ops oss_pcm_ops = { |
| 755 | oss_init_out, | 755 | oss_init_out, |
| 756 | oss_fini_out, | 756 | oss_fini_out, |
| 757 | oss_run_out, | 757 | oss_run_out, |
audio/paaudio.c
| @@ -487,7 +487,7 @@ struct audio_option qpa_options[] = { | @@ -487,7 +487,7 @@ struct audio_option qpa_options[] = { | ||
| 487 | {NULL, 0, NULL, NULL, NULL, 0} | 487 | {NULL, 0, NULL, NULL, NULL, 0} |
| 488 | }; | 488 | }; |
| 489 | 489 | ||
| 490 | -static const struct audio_pcm_ops qpa_pcm_ops = { | 490 | +static struct audio_pcm_ops qpa_pcm_ops = { |
| 491 | qpa_init_out, | 491 | qpa_init_out, |
| 492 | qpa_fini_out, | 492 | qpa_fini_out, |
| 493 | qpa_run_out, | 493 | qpa_run_out, |
audio/sdlaudio.c
| @@ -423,7 +423,7 @@ static struct audio_option sdl_options[] = { | @@ -423,7 +423,7 @@ static struct audio_option sdl_options[] = { | ||
| 423 | {NULL, 0, NULL, NULL, NULL, 0} | 423 | {NULL, 0, NULL, NULL, NULL, 0} |
| 424 | }; | 424 | }; |
| 425 | 425 | ||
| 426 | -static const struct audio_pcm_ops sdl_pcm_ops = { | 426 | +static struct audio_pcm_ops sdl_pcm_ops = { |
| 427 | sdl_init_out, | 427 | sdl_init_out, |
| 428 | sdl_fini_out, | 428 | sdl_fini_out, |
| 429 | sdl_run_out, | 429 | sdl_run_out, |
audio/wavaudio.c
| @@ -233,7 +233,7 @@ static struct audio_option wav_options[] = { | @@ -233,7 +233,7 @@ static struct audio_option wav_options[] = { | ||
| 233 | {NULL, 0, NULL, NULL, NULL, 0} | 233 | {NULL, 0, NULL, NULL, NULL, 0} |
| 234 | }; | 234 | }; |
| 235 | 235 | ||
| 236 | -static const struct audio_pcm_ops wav_pcm_ops = { | 236 | +static struct audio_pcm_ops wav_pcm_ops = { |
| 237 | wav_init_out, | 237 | wav_init_out, |
| 238 | wav_fini_out, | 238 | wav_fini_out, |
| 239 | wav_run_out, | 239 | wav_run_out, |