linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: linux@arm.linux.org.uk (Russell King - ARM Linux)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: versatile: fix build failure in pci.c
Date: Wed, 4 Apr 2012 15:26:16 +0100	[thread overview]
Message-ID: <20120404142616.GZ24211@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <4F7C5244.4040700@windriver.com>

On Wed, Apr 04, 2012 at 09:53:08AM -0400, Paul Gortmaker wrote:
> On 12-04-04 05:07 AM, Russell King - ARM Linux wrote:
> > On Tue, Apr 03, 2012 at 09:47:13AM -0400, Paul Gortmaker wrote:
> >> As a side note, the fact that struct pci_sys_data is ARM specific
> >> does make one think it would be nice if the name somehow did
> >> reflect that...  wonder if it is worth changing.  Anyway, that is
> >> a separate topic.
> > 
> > And what's wrong with the existing name when it's limited to only
> > ARM specific files?
> 
> Just in the context of Arnd's original comment, he thought I
> screwed up by feeding an ARM specific struct into generic
> PCI code, because I wasn't aware it was ARM specific.
> 
> That wasn't the case, but he's right that something like that
> could happen  A minor nit, sure, but if it was something like
> pci_arm_data, the name itself would convey it was arm specific,
> even in reduced context scenarios (like grep output etc).

If the struct ends up being fed into non-ARM code, then non-ARM code
isn't going to be able to dereference it because there isn't a definition
for it outside of arch/arm/.

The risk which exists is that generic code invents its own pci_sys_data.
At that point, we end up with two definitions for the struct, and the
compiler will error out.

We really don't need the churn of changing this.  It ain't broken, so
don't try to fix it.  Moreover, you'll only end up with conflicts to
deal with if the ixp2xxx stuff is removed (and other people will have
similar problems if they're dealing with code in this area too.)

  reply	other threads:[~2012-04-04 14:26 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-02 23:48 [PATCH] ARM: versatile: fix build failure in pci.c Paul Gortmaker
2012-04-03  0:03 ` Fabio Estevam
2012-04-03  1:01   ` Paul Gortmaker
2012-04-03  1:57     ` Fabio Estevam
2012-04-03  8:19       ` Arnd Bergmann
2012-04-03 13:47         ` Paul Gortmaker
2012-04-03 14:26           ` Arnd Bergmann
2012-04-03 16:44             ` Bjorn Helgaas
2012-04-03 19:09               ` Paul Gortmaker
2012-04-03 19:40                 ` Arnd Bergmann
2012-04-04  9:08             ` Russell King - ARM Linux
2012-04-04  9:07           ` Russell King - ARM Linux
2012-04-04 13:53             ` Paul Gortmaker
2012-04-04 14:26               ` Russell King - ARM Linux [this message]
2012-04-03  4:58 ` Olof Johansson

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=20120404142616.GZ24211@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=linux-arm-kernel@lists.infradead.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).