lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1472496420.3425.77.camel@perches.com>
Date:   Mon, 29 Aug 2016 11:47:00 -0700
From:   Joe Perches <joe@...ches.com>
To:     "Luck, Tony" <tony.luck@...el.com>,
        "Levin, Alexander" <alexander.levin@...izon.com>
Cc:     Greg KH <gregkh@...uxfoundation.org>,
        Sasha Levin <levinsasha928@...il.com>,
        "ksummit-discuss@...ts.linuxfoundation.org" 
        <ksummit-discuss@...ts.linuxfoundation.org>,
        LKML <linux-kernel@...r.kernel.org>
Subject: Re: [Ksummit-discuss] checkkpatch (in)sanity ?

On Mon, 2016-08-29 at 11:01 -0700, Joe Perches wrote:
> On Mon, 2016-08-29 at 17:46 +0000, Luck, Tony wrote:
> > [checkpatch] offered the advice
> > to restructure the code with helper functions etc. to avoid deep
> > indentation?
> It suggests that already for 6+ leading tabs,

And here's an inexact little histogram of the code that
expands indent levels in the -next kernel source tree.

$ grep -rP --include=*.[ch] -oh "^[\t]+(do|while|for|if|else|return|goto|continue|switch|default|case|break)\b" * | \
  sed -r 's/^(\t+).*$/\1/' | awk '{print length($0)}' | sort -n | uniq -c
1217165 1
 783085 2
 249655 3
  59775 4
  11653 5
   1993 6
    444 7
    158 8
     50 9
     19 10
     10 11
      4 12
      1 13

Some of that code, as Linus once put it, is eye-gouging.
Luckily, almost all of the 7+ tab indent code is prehistoric.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ