lkml.org 
[lkml]   [2011]   [Dec]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 3/8] ftrace: Add enable/disable ftrace_ops control interface
From
Date
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




\
 
 \ /
  Last update: 2011-12-21 17:59    [from the cache]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and my Meterkast|Read the blog