summaryrefslogtreecommitdiffstats
path: root/hw/audio
diff options
context:
space:
mode:
authorZihan Yang2017-04-26 14:53:08 +0200
committerGerd Hoffmann2017-05-04 08:29:01 +0200
commit5eaa8e1e0f09ff08c9c683676eabb82ad1179647 (patch)
treee386ed21e2e3ed797fb46872b706375783cc3709 /hw/audio
parenthw/audio: replace exit with unrealize in hda_codec_device_class_init (diff)
downloadqemu-5eaa8e1e0f09ff08c9c683676eabb82ad1179647.tar.gz
qemu-5eaa8e1e0f09ff08c9c683676eabb82ad1179647.tar.xz
qemu-5eaa8e1e0f09ff08c9c683676eabb82ad1179647.zip
hw/audio: convert exit callback in HDACodecDeviceClass to void
The exit callback always return 0, convert it to void Signed-off-by: Zihan Yang <tgnyang@gmail.com> Message-id: 1493211188-24086-5-git-send-email-tgnyang@gmail.com Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'hw/audio')
-rw-r--r--hw/audio/hda-codec.c3
-rw-r--r--hw/audio/intel-hda.h2
2 files changed, 2 insertions, 3 deletions
diff --git a/hw/audio/hda-codec.c b/hw/audio/hda-codec.c
index 52d4640e60..5402cd196c 100644
--- a/hw/audio/hda-codec.c
+++ b/hw/audio/hda-codec.c
@@ -520,7 +520,7 @@ static int hda_audio_init(HDACodecDevice *hda, const struct desc_codec *desc)
return 0;
}
-static int hda_audio_exit(HDACodecDevice *hda)
+static void hda_audio_exit(HDACodecDevice *hda)
{
HDAAudioState *a = HDA_AUDIO(hda);
HDAAudioStream *st;
@@ -539,7 +539,6 @@ static int hda_audio_exit(HDACodecDevice *hda)
}
}
AUD_remove_card(&a->card);
- return 0;
}
static int hda_audio_post_load(void *opaque, int version)
diff --git a/hw/audio/intel-hda.h b/hw/audio/intel-hda.h
index d784bcf5fc..53b78da4df 100644
--- a/hw/audio/intel-hda.h
+++ b/hw/audio/intel-hda.h
@@ -38,7 +38,7 @@ typedef struct HDACodecDeviceClass
DeviceClass parent_class;
int (*init)(HDACodecDevice *dev);
- int (*exit)(HDACodecDevice *dev);
+ void (*exit)(HDACodecDevice *dev);
void (*command)(HDACodecDevice *dev, uint32_t nid, uint32_t data);
void (*stream)(HDACodecDevice *dev, uint32_t stnr, bool running, bool output);
} HDACodecDeviceClass;