[alsa-devel] [PATCH] snd_usb_caiaq_input_free() fix
input_free_device()'s comment says: input_free_device() should only be used if input_register_device() was not called yet or if it failed. Once device was registered use input_unregister_device() and memory will be freed once last refrence to the device is dropped.
Signed-off-by: Karsten Wiese fzu@wemgehoertderstaat.de ---
diff -pur rt9/sound/usb/caiaq/caiaq-input.c rt9-kw/sound/usb/caiaq/caiaq-input.c --- rt9/sound/usb/caiaq/caiaq-input.c 2007-07-10 20:56:30.000000000 +0200 +++ rt9-kw/sound/usb/caiaq/caiaq-input.c 2007-07-27 11:45:52.000000000 +0200 @@ -238,7 +238,6 @@ void snd_usb_caiaq_input_free(struct snd return;
input_unregister_device(dev->input_dev); - input_free_device(dev->input_dev); dev->input_dev = NULL; }
At Fri, 27 Jul 2007 12:06:50 +0200, Karsten Wiese wrote:
input_free_device()'s comment says: input_free_device() should only be used if input_register_device() was not called yet or if it failed. Once device was registered use input_unregister_device() and memory will be freed once last refrence to the device is dropped.
Signed-off-by: Karsten Wiese fzu@wemgehoertderstaat.de
Thanks, applied to HG tree now.
Takashi
participants (2)
-
Karsten Wiese
-
Takashi Iwai