29 Oct, 2009

7 commits

  • Signed-off-by: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Whitcroft
     
  • Ingo reported that the following lines triggered a false warning,

    static struct lock_class_key rcu_lock_key;
    struct lockdep_map rcu_lock_map =
    STATIC_LOCKDEP_MAP_INIT("rcu_read_lock", &rcu_lock_key);
    EXPORT_SYMBOL_GPL(rcu_lock_map);

    from kernel/rcutree.c , and the false warning looked like this,

    WARNING: EXPORT_SYMBOL(foo); should immediately follow its
    function/variable
    +EXPORT_SYMBOL_GPL(rcu_lock_map);

    We actually should be checking the statement before the EXPORT_* for a
    mention of the exported object, and complain where it is not there.

    [akpm@linux-foundation.org: coding-style fixes]
    Cc: Ingo Molnar
    Cc: Paul E. McKenney
    Reported-by: Daniel Walker
    Signed-off-by: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Whitcroft
     
  • In the following code,

    union thread_union init_thread_union
    __attribute__((__section__(".data.init_task"))) =
    { INIT_THREAD_INFO(init_task) };

    There is a non-conforming declaration. It should really be like the
    following,

    union thread_union init_thread_union
    __attribute__((__section__(".data.init_task"))) = {
    INIT_THREAD_INFO(init_task)
    };

    However, checkpatch doesn't catch this right now because it doesn't
    correctly evaluate the "__attribute__".

    It is not at all clear that we care what preceeds an assignment style
    attribute when we find the open brace. Relax the test so we do not need
    to check the __attribute__.

    Reported-by: Daniel Walker
    Signed-off-by: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Whitcroft
     
  • The macro concatenation (##) sequence can cause false errors when checking
    macro's. Checkpatch doesn't currently know about the operator.

    For example this line,

    + entry = (struct ftrace_raw_##call *)raw_data; \

    is correct but it produces the following error,

    ERROR: need consistent spacing around '*' (ctx:WxB)
    + entry = (struct ftrace_raw_##call *)raw_data;\
    ^

    The line above doesn't have any spacing problems, and if you remove the
    macro concatenation sequence checkpatch doesn't give any errors.

    Extend identifier handling to include ## concatenation within the
    definition of an identifier.

    Reported-by: Daniel Walker
    Signed-off-by: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Whitcroft
     
  • Signed-off-by: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Whitcroft
     
  • We are allowing context scanning checks to apply against the first line of
    context outside at the end of the hunk. This can lead to false matches to
    patch names leading to various perl warnings. Correctly stop at the
    bottom of the hunk.

    Signed-off-by: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Whitcroft
     
  • Prevent known non types being detected as modifiers. Ensure we do not
    look at any type which starts with a keyword.

    Signed-off-by: Andy Whitcroft
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andy Whitcroft
     

22 Sep, 2009

8 commits


28 Feb, 2009

8 commits


16 Jan, 2009

6 commits


07 Jan, 2009

11 commits