From: Chris Mason Date: Fri, 3 Feb 2012 16:07:41 +0000 (-0500) Subject: rds_send_xmit is called uner a spinlock, lets not do a cond_resched() X-Git-Tag: v4.1.12-92~319^2^2~2^2~53 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=4d8fa5b3e970f490ecc7d1a4ef3c5109c8f9a7e3;p=users%2Fjedix%2Flinux-maple.git rds_send_xmit is called uner a spinlock, lets not do a cond_resched() Signed-off-by: Chris Mason Signed-off-by: Bang Nguyen --- diff --git a/net/rds/send.c b/net/rds/send.c index 2d758fea79516..16e26151f3e07 100644 --- a/net/rds/send.c +++ b/net/rds/send.c @@ -193,7 +193,6 @@ restart: same_rm++; if ((same_rm >= 4096) && printk_ratelimit()) { printk(KERN_ERR "RDS: Stuck rm\n"); - cond_resched(); ret = -EAGAIN; break; } @@ -421,18 +420,8 @@ over_batch: smp_mb(); if (!list_empty(&conn->c_send_queue) && send_gen == conn->c_send_gen) { - cond_resched(); - /* - * repeat our check after the resched in case - * someone else was kind enough to empty or process - * the queue - */ - smp_mb(); - if (!list_empty(&conn->c_send_queue) && - send_gen == conn->c_send_gen) { - rds_stats_inc(s_send_lock_queue_raced); - goto restart; - } + rds_stats_inc(s_send_lock_queue_raced); + goto restart; } } out: