From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753736AbcFOXKV (ORCPT ); Wed, 15 Jun 2016 19:10:21 -0400 Received: from smtprelay0057.hostedemail.com ([216.40.44.57]:47138 "EHLO smtprelay.hostedemail.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1753203AbcFOXKR (ORCPT ); Wed, 15 Jun 2016 19:10:17 -0400 X-Session-Marker: 6A6F6540706572636865732E636F6D X-Spam-Summary: 2,0,0,,d41d8cd98f00b204,joe@perches.com,:::::::::::::::::::::::::::::::::::::::,RULES_HIT:41:355:379:541:599:800:960:973:988:989:1260:1277:1311:1313:1314:1345:1359:1373:1437:1515:1516:1518:1534:1541:1593:1594:1711:1730:1747:1777:1792:2393:2553:2559:2562:2692:2828:3138:3139:3140:3141:3142:3353:3622:3865:3866:3867:3868:3870:3871:3872:3873:3874:4321:5007:6120:6742:7514:7901:7903:8531:8957:10004:10400:10848:10967:11026:11232:11658:11783:11889:11914:12043:12296:12438:12517:12519:12663:12740:13069:13311:13357:13439:13894:14181:14659:14721:21080:21220,0,RBL:none,CacheIP:none,Bayesian:0.5,0.5,0.5,Netcheck:none,DomainCache:0,MSF:not bulk,SPF:fn,MSBL:0,DNSBL:none,Custom_rules:0:0:0,LFtime:2,LUA_SUMMARY:none X-HE-Tag: linen63_1e90ded8ae209 X-Filterd-Recvd-Size: 3363 Message-ID: <1466032209.19647.20.camel@perches.com> Subject: Re: [PATCH v3 0/4] Introduce the latent_entropy gcc plugin From: Joe Perches To: Kees Cook , Emese Revfy , Greg KH Cc: "kernel-hardening@lists.openwall.com" , PaX Team , Brad Spengler , Michal Marek , LKML , Masahiro Yamada , linux-kbuild , "Theodore Ts'o" , Andrew Morton , Linux-MM , Jens Axboe , Al Viro , Paul McKenney , Ingo Molnar , Thomas Gleixner , bart.vanassche@sandisk.com, "David S. Miller" Date: Wed, 15 Jun 2016 16:10:09 -0700 In-Reply-To: References: <20160615001754.f9e986cf961d1466f5e086dc@gmail.com> <20160615223952.f3a4ece452b15c62babf4629@gmail.com> Content-Type: text/plain; charset="ISO-8859-1" X-Mailer: Evolution 3.18.5.2-0ubuntu3 Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 2016-06-15 at 16:01 -0700, Kees Cook wrote: > On Wed, Jun 15, 2016 at 1:39 PM, Emese Revfy wrote: > > On Wed, 15 Jun 2016 11:55:44 -0700 Kees Cook wrote: > > >  The limit on the length of lines is 80 columns and this is a strongly > > >  preferred limit. > > I think the code looks worse when it is truncated to 80 columns but > > I'll do it and resend the patches. > Yup, I understand your concerns, but since we're optimizing for > readability by a larger audience that has agreed to the guidelines in > CodingStyle, this is what we get. :) > > One area I'm unclear on with kernel coding style, though, is if > splitting all the stuff prior to function name onto a separate line is > "acceptable", since that solves most of the long lines where > __latent_entropy has been added. For example, I don't know which is > better: > > All on one line (gmail may split this, but my intention is all one line): > > static __latent_entropy void rcu_process_callbacks(struct > softirq_action *unused) > > Types and attributes on a separate line: > > static __latent_entropy void > rcu_process_callbacks(struct softirq_action *unused) > > All arguments on the next line: > > static __latent_entropy void rcu_process_callbacks( >                                                           struct > softirq_action *unused) > > > Greg, do you have a better sense of how to split (or not split) these > kinds of long lines? Another option is to add __latent_entropy the same way most __printf uses are done - on a separate line before the function __latent_entropy static void foo(...)