diff options
author | Jens Axboe <jens.axboe@oracle.com> | 2009-11-26 09:46:51 +0100 |
---|---|---|
committer | Jens Axboe <jens.axboe@oracle.com> | 2009-11-26 09:46:51 +0100 |
commit | 75e7b634309ef4eabf8a93d36e58863f727fa209 (patch) | |
tree | 6ad097218bd4510fb5b59fa29b654bd7c596bfbb /drivers | |
parent | d9449ce35a1e8fb58dd2d419f9215562a14ecca0 (diff) | |
parent | 35a8a3fdcd4f973a5430e868f2f2a5c363803a5b (diff) | |
download | kernel_samsung_tuna-75e7b634309ef4eabf8a93d36e58863f727fa209.zip kernel_samsung_tuna-75e7b634309ef4eabf8a93d36e58863f727fa209.tar.gz kernel_samsung_tuna-75e7b634309ef4eabf8a93d36e58863f727fa209.tar.bz2 |
Merge branch 'for-jens' of git://git.drbd.org/linux-2.6-drbd into for-2.6.33
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/block/drbd/drbd_nl.c | 2 | ||||
-rw-r--r-- | drivers/block/drbd/drbd_receiver.c | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/drivers/block/drbd/drbd_nl.c b/drivers/block/drbd/drbd_nl.c index e2a5875..436a090 100644 --- a/drivers/block/drbd/drbd_nl.c +++ b/drivers/block/drbd/drbd_nl.c @@ -733,7 +733,7 @@ void drbd_setup_queue_param(struct drbd_conf *mdev, unsigned int max_seg_s) __mu */ static void drbd_reconfig_start(struct drbd_conf *mdev) { - wait_event(mdev->state_wait, test_and_set_bit(CONFIG_PENDING, &mdev->flags)); + wait_event(mdev->state_wait, !test_and_set_bit(CONFIG_PENDING, &mdev->flags)); wait_event(mdev->state_wait, !test_bit(DEVICE_DYING, &mdev->flags)); drbd_thread_start(&mdev->worker); } diff --git a/drivers/block/drbd/drbd_receiver.c b/drivers/block/drbd/drbd_receiver.c index 9bbc509..c548f24 100644 --- a/drivers/block/drbd/drbd_receiver.c +++ b/drivers/block/drbd/drbd_receiver.c @@ -2400,6 +2400,7 @@ static int drbd_uuid_compare(struct drbd_conf *mdev, int *rule_nr) __must_hold(l *rule_nr = 80; + peer = mdev->p_uuid[UI_CURRENT] & ~((u64)1); for (i = UI_HISTORY_START; i <= UI_HISTORY_END; i++) { self = mdev->ldev->md.uuid[i] & ~((u64)1); if (self == peer) @@ -3499,8 +3500,10 @@ static void drbdd(struct drbd_conf *mdev) while (get_t_state(&mdev->receiver) == Running) { drbd_thread_current_set_cpu(mdev); - if (!drbd_recv_header(mdev, header)) + if (!drbd_recv_header(mdev, header)) { + drbd_force_state(mdev, NS(conn, C_PROTOCOL_ERROR)); break; + } if (header->command < P_MAX_CMD) handler = drbd_cmd_handler[header->command]; |