[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <DM6PR02MB436155458BFAB5575207B2C4C74A0@DM6PR02MB4361.namprd02.prod.outlook.com>
Date: Mon, 25 Jun 2018 13:47:52 +0000
From: Radhey Shyam Pandey <radheys@...inx.com>
To: Joe Perches <joe@...ches.com>,
Andy Shevchenko <andy.shevchenko@...il.com>
CC: "David S. Miller" <davem@...emloft.net>,
Andrew Lunn <andrew@...n.ch>,
Michal Simek <michals@...inx.com>,
netdev <netdev@...r.kernel.org>,
linux-arm Mailing List <linux-arm-kernel@...ts.infradead.org>,
Linux Kernel Mailing List <linux-kernel@...r.kernel.org>
Subject: RE: [PATCH 1/5] net: emaclite: Use __func__ instead of hardcoded name
> -----Original Message-----
> From: Joe Perches [mailto:joe@...ches.com]
> Sent: Wednesday, June 20, 2018 4:08 AM
> To: Andy Shevchenko <andy.shevchenko@...il.com>; Radhey Shyam
> Pandey <radheys@...inx.com>
> Cc: David S. Miller <davem@...emloft.net>; Andrew Lunn
> <andrew@...n.ch>; Michal Simek <michals@...inx.com>; netdev
> <netdev@...r.kernel.org>; linux-arm Mailing List <linux-arm-
> kernel@...ts.infradead.org>; Linux Kernel Mailing List <linux-
> kernel@...r.kernel.org>
> Subject: Re: [PATCH 1/5] net: emaclite: Use __func__ instead of hardcoded
> name
>
> On Wed, 2018-06-20 at 00:36 +0300, Andy Shevchenko wrote:
> > On Mon, Jun 18, 2018 at 2:08 PM, Radhey Shyam Pandey
> > <radhey.shyam.pandey@...inx.com> wrote:
> > > Switch hardcoded function name with a reference to __func__ making
> > > the code more maintainable. Address below checkpatch warning:
> > >
> > > WARNING: Prefer using '"%s...", __func__' to using
> 'xemaclite_mdio_read',
> > > this function's name, in a string
> > > + "xemaclite_mdio_read(phy_id=%i, reg=%x) == %x\n",
> > >
> > > WARNING: Prefer using '"%s...", __func__' to using
> 'xemaclite_mdio_write',
> > > this function's name, in a string
> > > + "xemaclite_mdio_write(phy_id=%i, reg=%x, val=%x)\n",
> > >
> >
> > For dev_dbg() the __func__ should be completely dropped away.
>
> Not really the same.
>
> dev_dbg without CONFIG_DYNAMIC_DEBUG does not have
> the ability to prefix __func__.
Yes. If it's acceptable, prefer to use __func__ to support all
configurations
>
Powered by blists - more mailing lists