[DRBD-cvs] svn commit by phil - r2550 - branches/drbd-0.7/drbd - That patch is vital for drbd-8 but lethal for drbd-7 ; )

drbd-cvs at lists.linbit.com drbd-cvs at lists.linbit.com
Thu Oct 19 16:42:19 CEST 2006


Author: phil
Date: 2006-10-19 16:42:18 +0200 (Thu, 19 Oct 2006)
New Revision: 2550

Modified:
   branches/drbd-0.7/drbd/drbd_receiver.c
Log:
That patch is vital for drbd-8 but lethal for drbd-7 ;)


Modified: branches/drbd-0.7/drbd/drbd_receiver.c
===================================================================
--- branches/drbd-0.7/drbd/drbd_receiver.c	2006-10-19 13:27:16 UTC (rev 2549)
+++ branches/drbd-0.7/drbd/drbd_receiver.c	2006-10-19 14:42:18 UTC (rev 2550)
@@ -2339,19 +2339,17 @@
 				mdev->conf.timeout*HZ/20;
 		}
 
-		while(1) {
-			if (!drbd_process_ee(mdev,0)) {
-				ERR("process_done_ee() = NOT_OK\n");
-				goto err;
-			}
-			set_bit(SIGNAL_ASENDER, &mdev->flags);
-			spin_lock_irq(&mdev->req_lock);
-			empty = list_empty(&mdev->done_ee);
-			spin_unlock_irq(&mdev->req_lock);
-			if(empty) break;
-			clear_bit(SIGNAL_ASENDER, &mdev->flags);
-			flush_signals(current);
-		}
+		/* FIXME this *should* be below drbd_process_ee,
+		 * but that leads to some distributed deadlock :-(
+		 * this needs to be fixed properly, I'd vote for a separate
+		 * msock sender thread, but others will frown upon yet an other
+		 * kernel thread...
+		 *      -- lge
+		 */
+		set_bit(SIGNAL_ASENDER, &mdev->flags);
+		
+		if (!drbd_process_ee(mdev,0)) goto err;
+		
 		rv = drbd_recv_short(mdev,buf,expect-received);
 		clear_bit(SIGNAL_ASENDER, &mdev->flags);
 



More information about the drbd-cvs mailing list