]> git.baikalelectronics.ru Git - kernel.git/commit
ALSA: fireworks/bebob/dice/oxfw: add reference-counting for FireWire unit
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>
Sat, 21 Feb 2015 14:54:57 +0000 (23:54 +0900)
committerTakashi Iwai <tiwai@suse.de>
Mon, 23 Feb 2015 08:10:38 +0000 (09:10 +0100)
commit05e3faa4d27e8f7ccaf41615524aaee74e39ef04
tree92362d30da81381fd8fe004fc3ba553ceea754ea
parentfe143b4ef10386c989d8cbb5f60f6cf163428f8a
ALSA: fireworks/bebob/dice/oxfw: add reference-counting for FireWire unit

Fireworks and Dice drivers try to touch instances of FireWire unit after
sound card object is released, while references to the unit is decremented
in .remove(). When unplugging during streaming, sound card object is
released after .remove(), thus Fireworks and Dice drivers causes GPF or
Null-pointer-dereferencing to application processes because an instance of
FireWire unit was already released.

This commit adds reference-counting for FireWire unit in drivers to allow
them to touch an instance of FireWire unit after .remove(). In most case,
any operations after .remove() may be failed safely.

Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Cc: <stable@vger.kernel.org> # 3.19+
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/firewire/bebob/bebob.c
sound/firewire/dice/dice.c
sound/firewire/fireworks/fireworks.c
sound/firewire/oxfw/oxfw.c