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: <20180216123139.84c4efe02dc40ed333d886e7@linux-foundation.org>
Date:   Fri, 16 Feb 2018 12:31:39 -0800
From:   Andrew Morton <akpm@...ux-foundation.org>
To:     Joe Perches <joe@...ches.com>
Cc:     Dan Carpenter <dan.carpenter@...cle.com>,
        Yash Omer <yashomer0007@...il.com>, gregkh@...uxfoundation.org,
        devel@...verdev.osuosl.org, driverdev-devel@...uxdriverproject.org,
        linux-kernel@...r.kernel.org, Larry.Finger@...inger.net
Subject: Re: [RFC patch] checkpatch: test identifier lengths

On Fri, 16 Feb 2018 09:13:27 -0800 Joe Perches <joe@...ches.com> wrote:

> On Fri, 2018-02-16 at 15:55 +0300, Dan Carpenter wrote:
> > On Fri, Feb 16, 2018 at 05:06:34PM +0530, Yash Omer wrote:
> > > This patch fix line should not end with open parenthesis found by checkpatch.plscript.
> > > 
> > > Signed-off-by: Yash Omer <yashomer0007@...il.com>
> > > ---
> > >  drivers/staging/nvec/nvec.c | 4 ++--
> > >  1 file changed, 2 insertions(+), 2 deletions(-)
> > > 
> > > diff --git a/drivers/staging/nvec/nvec.c b/drivers/staging/nvec/nvec.c
> > > index 52054a528723..39fb737543b5 100644
> > > --- a/drivers/staging/nvec/nvec.c
> > > +++ b/drivers/staging/nvec/nvec.c
> > > @@ -383,8 +383,8 @@ static void nvec_request_master(struct work_struct *work)
> > >  		msg = list_first_entry(&nvec->tx_data, struct nvec_msg, node);
> > >  		spin_unlock_irqrestore(&nvec->tx_lock, flags);
> > >  		nvec_gpio_set_value(nvec, 0);
> > > -		err = wait_for_completion_interruptible_timeout(
> > > -				&nvec->ec_transfer, msecs_to_jiffies(5000));
> > > +		err = wait_for_completion_interruptible_timeout
> > > +			(&nvec->ec_transfer, msecs_to_jiffies(5000));
> > 
> > The original code is basically fine...  It's OK to ignore checkpatch in
> > this situation.
> 
> Right.

Yes, I'd say that checkpatch is simply wrong here.  I'd prefer that a
function call always have the opening paren hard up against the
function name.  Because I often search for "foo(" to find the callsites
of foo() and I expect that some code-parsing tools do the same thing. 
The "(" is the application of an operator to an identifier.

So I'd vote for simply nuking that checkpatch warning altogether. 
Maybe there are other situations in which it is useful, dunno.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ