lkml.org 
[lkml]   [2006]   [Feb]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] block: kill not-so-popular simple flag testing macros
On Thu, Feb 09 2006, Jeff Garzik wrote:
> Tejun Heo wrote:
> >The code he was talking about looks like.
> >
> >if (rq->flags & (REQ_SOFTBARRIER | REQ_HARDBARRIER) {
>
>
> Yes, I certainly agree you don't want to test the same variable multiple
> times, if you are just testing bits in the same variable.

Very few of the flags are usually tested together, so we could just fix
this particular instance. So blk_softbarrier_rq() and
blk_hardbarrier_rq(), combined tested with blk_barrier_rq().

--
Jens Axboe

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2006-02-10 08:25    [W:0.792 / U:0.488 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site