Re: [PATCH 3/8] ftrace: Add enable/disable ftrace_ops controlinterface

From: Steven Rostedt
Date: Wed Dec 21 2011 - 11:55:53 EST


On Wed, 2011-12-21 at 17:43 +0100, Jiri Olsa wrote:

> > more readable. With what you have, I looked at that condition three
> > times to figure out what was different between what was '&'d with the
> > flags and what was being equal too. Usually the ((flags & X) == Y) is
> > done to check if a subset of bits are set within a mask of bits.
>
> Well, thats what I need to do here. Bail out if both bits are set,
> since we dont support both global and control flags set at the same
> time.. I'll add some comment to it.
>

Ah that's right, that's not a single bit. OK, you need to rename
FL_GLOBAL_CONTROL to FL_GLOBAL_CONTROL_BITS or _MASK. _MASK may be
better, as I think it's used more often for this case.

Otherwise it looks like a single bit. Then you wont even need the
comment. But I wont stop you from adding one.

-- Steve


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