]> git.ipfire.org Git - thirdparty/kernel/linux.git/commit
firewire: core: fix race condition against transaction list
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>
Tue, 27 Jan 2026 22:34:13 +0000 (07:34 +0900)
committerTakashi Sakamoto <o-takashi@sakamocchi.jp>
Wed, 28 Jan 2026 23:03:55 +0000 (08:03 +0900)
commit20e01bba2ae4898ce65cdcacd1bd6bec5111abd9
treec608015eb42aae63d45db42e5af4e974f3ddcf10
parent63804fed149a6750ffd28610c5c1c98cce6bd377
firewire: core: fix race condition against transaction list

The list of transaction is enumerated without acquiring card lock when
processing AR response event. This causes a race condition bug when
processing AT request completion event concurrently.

This commit fixes the bug by put timer start for split transaction
expiration into the scope of lock. The value of jiffies in card structure
is referred before acquiring the lock.

Cc: stable@vger.kernel.org # v6.18
Fixes: b5725cfa4120 ("firewire: core: use spin lock specific to timer for split transaction")
Reported-by: Andreas Persson <andreasp56@outlook.com>
Closes: https://github.com/alsa-project/snd-firewire-ctl-services/issues/209
Tested-by: Andreas Persson <andreasp56@outlook.com>
Link: https://lore.kernel.org/r/20260127223413.22265-1-o-takashi@sakamocchi.jp
Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
drivers/firewire/core-transaction.c