mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Joe Perches <joe@perches.com>
To: "aurélien bouin" <a.bouin@gmail.com>
Cc: broonie <broonie@kernel.org>, Fabio Estevam <festevam@gmail.com>,
	linux-spi <linux-spi@vger.kernel.org>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH 2/4] spi: imx: checkpatch cleanup
Date: Thu, 12 Feb 2015 09:44:38 -0800	[thread overview]
Message-ID: <1423763078.15343.32.camel@perches.com> (raw)
In-Reply-To: <CAFeThoBqepd8WO4=zqxc2H3SQ+XgbgKATwCO=n3W3B0dpwR9Rw@mail.gmail.com>

On Thu, 2015-02-12 at 14:03 +0100, aurélien bouin wrote:
> Hello,

Rehi

> It does not change readability ... Often breaks are in functions parameters ...

[please don't top post, more below]

> > > diff --git a/drivers/spi/spi-imx.c b/drivers/spi/spi-imx.c
> > []
> > > @@ -282,7 +282,8 @@ static unsigned int mx51_ecspi_clkdiv(unsigned int fin, unsigned int fspi,
[]
> > > -static void __maybe_unused mx51_ecspi_intctrl(struct spi_imx_data *spi_imx, int enable)
> > > +static void __maybe_unused mx51_ecspi_intctrl(struct spi_imx_data *spi_imx,
> > > +             int enable)
> > Perhaps it'd be better to use this style:
> > __maybe_unused
> > static void foo(...)
> > ie:
> > __maybe_unused
> > static void mx51_ecspi_intctrl(struct spi_imx_data *spi_imx, int enable)

It's not the break in the function parameters that
matters much, it's the more difficult mechanism to
find the function itself.

typical is:

[static] [const] <type> <function>(params...)

inserting <attribute> between <type> and <function>
breaks that pattern and can make it harder for
less comprehensive code parsers to identify the
function names.



  reply	other threads:[~2015-02-12 17:44 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-02-12 12:07 [PATCH 1/4] serial: " Aurelien BOUIN
2015-02-12 12:07 ` [PATCH 2/4] spi: " Aurelien BOUIN
2015-02-12 12:42   ` Joe Perches
2015-02-12 13:03     ` aurélien bouin
2015-02-12 17:44       ` Joe Perches [this message]
2015-02-21 14:34   ` Mark Brown
2015-02-23  8:45     ` aurélien bouin
2015-02-23 13:33       ` Mark Brown
2015-02-12 12:07 ` [PATCH 3/4] spi: imx: Chose DMA bits per word transfered Aurelien BOUIN
2015-02-21 14:35   ` Mark Brown
2015-02-23  8:44     ` aurélien bouin
2015-02-23 14:46       ` Mark Brown
2015-02-23 15:25         ` aurélien bouin
2015-02-24  1:54           ` Mark Brown
2015-02-12 12:07 ` [PATCH 4/4] dt: fsl-imx-cspi.txt: Add fsl,spi-dma-bits-per-word Aurelien BOUIN

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1423763078.15343.32.camel@perches.com \
    --to=joe@perches.com \
    --cc=a.bouin@gmail.com \
    --cc=broonie@kernel.org \
    --cc=festevam@gmail.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-spi@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

Powered by JetHome