lkml.org 
[lkml]   [2012]   [Jun]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [RFC 1/4] ARM: topology: Add arch_scale_freq_power function
    On Wed, Jun 13, 2012 at 02:52:49PM +0200, Peter Zijlstra wrote:
    > On Tue, 2012-06-12 at 14:02 +0200, Vincent Guittot wrote:
    > > }
    > > smp_wmb();
    > > }
    >
    > You know what.. we should make checkpatch report an error for memory
    > barriers that don't have a comment.
    >
    > I know this isn't added by this patch, but every time I see something
    > like it I cry a little.

    Actually if it was a new line, it would have been reported, at least in
    theory:

    # check for memory barriers without a comment.
    if ($line =~
    /\b(mb|rmb|wmb|read_barrier_depends|smp_mb|smp_rmb|smp_wmb|smp_read_barrier_depends)\(/)
    {
    if (!ctx_has_comment($first_line, $linenr)) {
    CHK("MEMORY_BARRIER",
    "memory barrier without comment\n" . $herecurr);
    }
    }

    -apw


    \
     
     \ /
      Last update: 2012-06-13 22:01    [W:4.712 / U:0.028 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site