[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20210721093832.78081-1-desmondcheongzx@gmail.com>
Date: Wed, 21 Jul 2021 17:38:30 +0800
From: Desmond Cheong Zhi Xi <desmondcheongzx@...il.com>
To: marcel@...tmann.org, johan.hedberg@...il.com, luiz.dentz@...il.com,
davem@...emloft.net, kuba@...nel.org, matthieu.baerts@...sares.net,
stefan@...enfreihafen.org
Cc: Desmond Cheong Zhi Xi <desmondcheongzx@...il.com>,
linux-bluetooth@...r.kernel.org, netdev@...r.kernel.org,
linux-kernel@...r.kernel.org, skhan@...uxfoundation.org,
gregkh@...uxfoundation.org,
linux-kernel-mentees@...ts.linuxfoundation.org
Subject: [PATCH v3 0/2] Bluetooth: fix inconsistent lock states
Hi,
This series addresses inconsistent lock states first identified by
Syzbot here:
https://syzkaller.appspot.com/bug?extid=2f6d7c28bb4bf7e82060
v2 -> v3:
- Split SCO and RFCOMM code changes, as suggested by Luiz Augusto von
Dentz.
- Simplify local bh disabling in SCO by using local_bh_disable/enable
inside sco_chan_del. The rationale is inside the commit message, but in
summary I initially wanted to avoid nesting local_bh_disable until I
learned that local_bh_disable/enable pairs are reentrant.
v1 -> v2:
- Instead of pulling out the clean-up code out from sco_chan_del and
using it directly in sco_conn_del, disable local softirqs for relevant
sections.
- Disable local softirqs more thoroughly for instances of
bh_lock_sock/bh_lock_sock_nested in the bluetooth subsystem.
Specifically, the calls in af_bluetooth.c and rfcomm/sock.c are now made
with local softirqs disabled as well.
Best wishes,
Desmond
Desmond Cheong Zhi Xi (2):
Bluetooth: fix inconsistent lock state in SCO
Bluetooth: fix inconsistent lock state in rfcomm_connect_ind
net/bluetooth/rfcomm/sock.c | 2 ++
net/bluetooth/sco.c | 21 +++++++++++++++++++++
2 files changed, 23 insertions(+)
--
2.25.1
Powered by blists - more mailing lists