2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-26 22:24:09 +08:00
linux-next/drivers/block/drbd
Lars Ellenberg cde81d99af drbd: fix race between handshake and admin disconnect/down
conn_try_disconnect() could potentialy hit the BUG_ON()
in _conn_set_state() where it iterates over _drbd_set_state()
and "asserts" via BUG_ON() that the latter was successful.

If the STATE_SENT bit was not yet visible to conn_is_valid_transition()
early in _conn_request_state(), but became visible before conn_set_state()
later in that call path, we could hit the BUG_ON() after _drbd_set_state(),
because it returned SS_IN_TRANSIENT_STATE.

To avoid that race, we better protect set_bit(SENT_STATE) with the spinlock.

Signed-off-by: Philipp Reisner <philipp.reisner@linbit.com>
Signed-off-by: Lars Ellenberg <lars.ellenberg@linbit.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
2017-08-29 15:34:46 -06:00
..
drbd_actlog.c block: replace bi_bdev with a gendisk pointer and partitions index 2017-08-23 12:49:55 -06:00
drbd_bitmap.c block: replace bi_bdev with a gendisk pointer and partitions index 2017-08-23 12:49:55 -06:00
drbd_debugfs.c drbd: make intelligent use of blkdev_issue_zeroout 2017-04-08 11:25:38 -06:00
drbd_debugfs.h drbd: debugfs: add basic hierarchy 2014-07-10 18:35:16 +02:00
drbd_int.h drbd: introduce drbd_recv_header_maybe_unplug 2017-08-29 15:34:43 -06:00
drbd_interval.c drbd: use RB_DECLARE_CALLBACKS() to define augment callbacks 2014-09-18 09:00:17 -06:00
drbd_interval.h drbd: code cleanups without semantic changes 2016-06-13 21:43:07 -06:00
drbd_main.c drbd: fix rmmod cleanup, remove _all_ debugfs entries 2017-08-29 15:34:45 -06:00
drbd_nl.c drbd: fix potential deadlock when trying to detach during handshake 2017-08-29 15:34:45 -06:00
drbd_nla.c netlink: pass extended ACK struct to parsing functions 2017-04-13 13:58:22 -04:00
drbd_nla.h drbd: Split off netlink mandatory attribute handling into separate file 2012-11-08 16:57:45 +01:00
drbd_proc.c drbd: A single dot should be put into a sequence. 2017-08-29 15:34:45 -06:00
drbd_protocol.h drbd: introduce WRITE_SAME support 2016-06-13 21:43:07 -06:00
drbd_receiver.c drbd: fix race between handshake and admin disconnect/down 2017-08-29 15:34:46 -06:00
drbd_req.c drbd: add explicit plugging when submitting batches 2017-08-29 15:34:44 -06:00
drbd_req.h drbd: introduce drbd_recv_header_maybe_unplug 2017-08-29 15:34:43 -06:00
drbd_state_change.h drbd: Backport the "events2" command 2015-11-25 09:22:00 -07:00
drbd_state.c drbd: fix potential deadlock when trying to detach during handshake 2017-08-29 15:34:45 -06:00
drbd_state.h drbd: fix potential deadlock when trying to detach during handshake 2017-08-29 15:34:45 -06:00
drbd_strings.c drbd: code cleanups without semantic changes 2016-06-13 21:43:07 -06:00
drbd_strings.h drbd: Move string function prototypes from linux/drbd.h to drbd_string.h 2014-02-17 16:50:37 +01:00
drbd_vli.h Fix common misspellings 2011-03-31 11:26:23 -03:00
drbd_worker.c drbd: fix potential get_ldev/put_ldev refcount imbalance during attach 2017-08-29 15:34:45 -06:00
Kconfig drbd: update Kconfig to match current dependencies 2012-12-06 13:08:29 +01:00
Makefile drbd: debugfs: add basic hierarchy 2014-07-10 18:35:16 +02:00