Commit 7b01273
dlm: fix sleep in atomic context
This patch changes the orphans mutex to a spinlock since commit
c288745 ("dlm: avoid blocking receive at the end of recovery") is
using a rwlock_t to lock the DLM message receive path and do_purge() can
be called while this lock is held that forbids to sleep.
We need to use spin_lock_bh() because also a user context that calls
dlm_user_purge() can call do_purge() and since commit 92d59ad
("dlm: do message processing in softirq context") the DLM message
receive path is done under softirq context.
Fixes: c288745 ("dlm: avoid blocking receive at the end of recovery")
Reported-by: Dan Carpenter <[email protected]>
Closes: https://lore.kernel.org/gfs2/[email protected]/
Signed-off-by: Alexander Aring <[email protected]>
Signed-off-by: David Teigland <[email protected]>1 parent 15fd7e5 commit 7b01273
3 files changed
+8
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
602 | 602 | | |
603 | 603 | | |
604 | 604 | | |
605 | | - | |
| 605 | + | |
606 | 606 | | |
607 | 607 | | |
608 | 608 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5880 | 5880 | | |
5881 | 5881 | | |
5882 | 5882 | | |
5883 | | - | |
| 5883 | + | |
5884 | 5884 | | |
5885 | 5885 | | |
5886 | 5886 | | |
| |||
5897 | 5897 | | |
5898 | 5898 | | |
5899 | 5899 | | |
5900 | | - | |
| 5900 | + | |
5901 | 5901 | | |
5902 | 5902 | | |
5903 | 5903 | | |
| |||
6089 | 6089 | | |
6090 | 6090 | | |
6091 | 6091 | | |
6092 | | - | |
| 6092 | + | |
6093 | 6093 | | |
6094 | | - | |
| 6094 | + | |
6095 | 6095 | | |
6096 | 6096 | | |
6097 | 6097 | | |
| |||
6241 | 6241 | | |
6242 | 6242 | | |
6243 | 6243 | | |
6244 | | - | |
| 6244 | + | |
6245 | 6245 | | |
6246 | 6246 | | |
6247 | 6247 | | |
6248 | 6248 | | |
6249 | 6249 | | |
6250 | 6250 | | |
6251 | 6251 | | |
6252 | | - | |
| 6252 | + | |
6253 | 6253 | | |
6254 | 6254 | | |
6255 | 6255 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
436 | 436 | | |
437 | 437 | | |
438 | 438 | | |
439 | | - | |
| 439 | + | |
440 | 440 | | |
441 | 441 | | |
442 | 442 | | |
| |||
0 commit comments