netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jingoo Han <jg1.han@samsung.com>
To: 'Stephen Hemminger' <stephen@networkplumber.org>
Cc: 'Greg Kroah-Hartman' <gregkh@linuxfoundation.org>,
	linux-kernel@vger.kernel.org,
	'David Miller' <davem@davemloft.net>,
	netdev@vger.kernel.org, 'Joe Perches' <joe@perches.com>,
	'Jonas Bonn' <jonas@southpole.se>,
	'Jingoo Han' <jg1.han@samsung.com>
Subject: Re: [PATCH 20/39] net: remove DEFINE_PCI_DEVICE_TABLE macro
Date: Tue, 03 Dec 2013 11:44:16 +0900	[thread overview]
Message-ID: <004601ceefd1$8efd6ea0$acf84be0$%han@samsung.com> (raw)
In-Reply-To: <20131202183646.459564a9@nehalam.linuxnetplumber.net>

On Tuesday, December 03, 2013 11:37 AM, Stephen Hemminger wrote:
> On Tue, 03 Dec 2013 08:19:25 +0900
> Jingoo Han <jg1.han@samsung.com> wrote:
> 
> > Don't use DEFINE_PCI_DEVICE_TABLE macro, because this macro
> > is not preferred.
> >
> > Signed-off-by: Jingoo Han <jg1.han@samsung.com>
> 
> Perhaps a little more explanation why it is not preferred.
> Not everyone tracks LKML or the PCI list.

(+cc Joe Perches, Jonas Bonn)

It is simple.
There is no special reason to use DEFINE_PCI_DEVICE_TABLE macro.

According to the Greg Kroah-Hartman,
"Yeah, and it's a horrid macro that deserves to be removed,
please don't use it in more places."

Currently, there is no other bus that has something like this
macro for their device ids. Thus, DEFINE_PCI_DEVICE_TABLE macro
should be removed.

Jonas Bonn (author of DEFINE_PCI_DEVICE_TABLE macro) also agreed
to remove this macro. According to Jonas Bonn,
"Actually, I think I submitted an even uglier macro called 
DECLARE_PCI_DEVICE_TABLE... might have been the first kernel
Patch I  ever sent?  In any case, it should certainly have been
kindly rejected."

After Joe Perches's patch[1] is merged, I will send these patches
to each subsystem maintainer.

[1][PATCH] pci/checkpatch: Deprecate DEFINE_PCI_DEVICE_TABLE
    (http://lkml.org/lkml/2013/12/2/400)

In this patch, Joe Perches fixed 'Documentation/PCI/pci.txt', and
'scripts/checkpatch.pl', in order to guide to use 'struct pci_device_id'
instead of 'DEFINE_PCI_DEVICE_TABLE' macro.

Thank you.

Best regards,
Jingoo Han

      reply	other threads:[~2013-12-03  2:44 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <001501ceefb1$69c96820$3d5c3860$%han@samsung.com>
2013-12-02 23:19 ` [PATCH 20/39] net: remove DEFINE_PCI_DEVICE_TABLE macro Jingoo Han
2013-12-03  2:36   ` Stephen Hemminger
2013-12-03  2:44     ` Jingoo Han [this message]

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='004601ceefd1$8efd6ea0$acf84be0$%han@samsung.com' \
    --to=jg1.han@samsung.com \
    --cc=davem@davemloft.net \
    --cc=gregkh@linuxfoundation.org \
    --cc=joe@perches.com \
    --cc=jonas@southpole.se \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netdev@vger.kernel.org \
    --cc=stephen@networkplumber.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;
as well as URLs for NNTP newsgroup(s).