From: Jeff Garzik <jeff@garzik•org>
To: jeffrey.t.kirsher@intel•com
Cc: davem@davemloft•net, Bruce Allan <bruce.w.allan@intel•com>,
netdev@vger•kernel.org, gospo@redhat•com, bphilips@novell•com
Subject: Re: [net-next-2.6 04/15] e1000e: checkpatch error - open braces
Date: Sat, 25 Dec 2010 05:29:16 -0500 [thread overview]
Message-ID: <4D15C77C.9030306@garzik.org> (raw)
In-Reply-To: <1293257174-15498-5-git-send-email-jeffrey.t.kirsher@intel.com>
On 12/25/2010 01:06 AM, jeffrey.t.kirsher@intel•com wrote:
> From: Bruce Allan<bruce.w.allan@intel•com>
>
> ERROR: that open brace { should be on the previous line
>
> Signed-off-by: Bruce Allan<bruce.w.allan@intel•com>
> Tested-by: Emil Tantilov<emil.s.tantilov@intel•com>
> Signed-off-by: Jeff Kirsher<jeffrey.t.kirsher@intel•com>
> ---
> drivers/net/e1000e/es2lan.c | 4 ++--
> drivers/net/e1000e/ethtool.c | 4 ++--
> drivers/net/e1000e/phy.c | 22 +++++++++++-----------
> 3 files changed, 15 insertions(+), 15 deletions(-)
>
> diff --git a/drivers/net/e1000e/es2lan.c b/drivers/net/e1000e/es2lan.c
> index 79da646..b18c644 100644
> --- a/drivers/net/e1000e/es2lan.c
> +++ b/drivers/net/e1000e/es2lan.c
> @@ -100,8 +100,8 @@
> * with a lower bound at "index" and the upper bound at
> * "index + 5".
> */
> -static const u16 e1000_gg82563_cable_length_table[] =
> - { 0, 60, 115, 150, 150, 60, 115, 150, 180, 180, 0xFF };
> +static const u16 e1000_gg82563_cable_length_table[] = {
> + 0, 60, 115, 150, 150, 60, 115, 150, 180, 180, 0xFF };
> #define GG82563_CABLE_LENGTH_TABLE_SIZE \
> ARRAY_SIZE(e1000_gg82563_cable_length_table)
>
> diff --git a/drivers/net/e1000e/ethtool.c b/drivers/net/e1000e/ethtool.c
> index 15c6330..affcacf 100644
> --- a/drivers/net/e1000e/ethtool.c
> +++ b/drivers/net/e1000e/ethtool.c
> @@ -753,8 +753,8 @@ static bool reg_pattern_test(struct e1000_adapter *adapter, u64 *data,
> int reg, int offset, u32 mask, u32 write)
> {
> u32 pat, val;
> - static const u32 test[] =
> - {0x5A5A5A5A, 0xA5A5A5A5, 0x00000000, 0xFFFFFFFF};
> + static const u32 test[] = {
> + 0x5A5A5A5A, 0xA5A5A5A5, 0x00000000, 0xFFFFFFFF};
> for (pat = 0; pat< ARRAY_SIZE(test); pat++) {
> E1000_WRITE_REG_ARRAY(&adapter->hw, reg, offset,
> (test[pat]& write));
Gah, that looks worse than the unpatched code.
I think this was an over-literal checkpatch interpretation. If you look
at e.g. drivers/net/tg3.c, you see that longer tables have the trailing
braces on a separate line, where they should be.
IMO, the single-line cases should just be left as they are now in the
source code.
Jeff
next prev parent reply other threads:[~2010-12-25 10:29 UTC|newest]
Thread overview: 21+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-12-25 6:05 [net-next-2.6 00/15][pull-request] Intel Wired LAN Driver Update jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 01/15] Documentation/networking: Update Intel Wired LAN docs jeffrey.t.kirsher
2010-12-25 12:30 ` Ben Hutchings
2010-12-25 6:06 ` [net-next-2.6 02/15] e1000e: checkpatch error - macro panethesis jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 03/15] e1000e: checkpatch error - trailing statements jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 04/15] e1000e: checkpatch error - open braces jeffrey.t.kirsher
2010-12-25 10:29 ` Jeff Garzik [this message]
2010-12-25 13:10 ` Krzysztof Halasa
2010-12-25 6:06 ` [net-next-2.6 05/15] e1000e: checkpatch warnings - braces jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 06/15] igb: Fix overwrite of the VF's flags jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 07/15] igb: Warn on attempt to override administratively set MAC/VLAN jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 08/15] igb: Some fine tuning jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 09/15] igb: Add Anti-spoofing feature support jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 10/15] igbvf: force link checking when mailbox timeout has occurred jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 11/15] igbvf: add support for i350 VF device jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 12/15] ixgbe: Warn on VF attempt to override Administratively set MAC/VLAN jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 13/15] ixgbe: Add SR-IOV feature support to X540 jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 14/15] ixgbe: Add anti-spoofing feature support jeffrey.t.kirsher
2010-12-25 6:06 ` [net-next-2.6 15/15] ixgbevf: Add X540 VF device support to the ixgbevf driver jeffrey.t.kirsher
2010-12-25 6:35 ` [net-next-2.6 00/15][pull-request] Intel Wired LAN Driver Update Jeff Kirsher
2010-12-26 3:26 ` David Miller
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=4D15C77C.9030306@garzik.org \
--to=jeff@garzik$(echo .)org \
--cc=bphilips@novell$(echo .)com \
--cc=bruce.w.allan@intel$(echo .)com \
--cc=davem@davemloft$(echo .)net \
--cc=gospo@redhat$(echo .)com \
--cc=jeffrey.t.kirsher@intel$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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