From: Takashi Iwai Date: Tue, 29 Jul 2008 10:08:16 +0000 (+0200) Subject: ALSA: hda - use input_free_device() X-Git-Tag: v2.6.28-rc1~720^2~250 X-Git-Url: http://www.pilppa.org/gitweb/gitweb.cgi?a=commitdiff_plain;h=f6154d6d007c69a330acc9021ec77cca5da9dc4c;p=linux-2.6-omap-h63xx.git ALSA: hda - use input_free_device() Use input_free_devce() correctly instead of kfree() at error path. Signed-off-by: Takashi Iwai Signed-off-by: Jaroslav Kysela --- diff --git a/sound/pci/hda/hda_beep.c b/sound/pci/hda/hda_beep.c index 5a764c48139..9b77b3e0fa9 100644 --- a/sound/pci/hda/hda_beep.c +++ b/sound/pci/hda/hda_beep.c @@ -103,7 +103,7 @@ int snd_hda_attach_beep_device(struct hda_codec *codec, int nid) err = input_register_device(input_dev); if (err < 0) { - kfree(input_dev); + input_free_device(input_dev); kfree(beep); return err; }