From: Ingo Molnar <mingo@elte.hu>
To: Randy Dunlap <randy.dunlap@oracle.com>
Cc: linux-kernel@vger.kernel.org, Jeff Garzik <jgarzik@redhat.com>,
netdev@vger.kernel.org
Subject: Re: [patch] fix 3c515.c:(.text+0x57200): undefined reference to `pnp_get_resource'
Date: Fri, 20 Jun 2008 17:51:05 +0200 [thread overview]
Message-ID: <20080620155105.GB6656@elte.hu> (raw)
In-Reply-To: <20080620081352.6cb4f9df.randy.dunlap@oracle.com>
* Randy Dunlap <randy.dunlap@oracle.com> wrote:
> > Signed-off-by: Ingo Molnar <mingo@elte.hu>
>
> Patch is in Jeff's tree.
i see. Hm, as far as i can see the patch was not Cc:-ed to lkml hence i
did not see that it exist and created a patch for it. Please Cc: lkml
for any mainline fix you think other people might trigger.
also, here's some small nitpicking about your patch:
+#ifdef __ISAPNP__
if (idev) {
irq = pnp_irq(idev, 0);
vp->dev = &idev->dev;
} else {
irq = inw(ioaddr + 0x2002) & 15;
}
+#else
+ irq = inw(ioaddr + 0x2002) & 15;
+#endif
as you now unconditonally assume that idev is NULL in the !__ISAPNP__.
Which is true currently but might not be with other changes (which is
unlikely but still). It also duplicates code visually.
So i'd still slightly prefer my patch instead of yours which avoids the
duplication and puts the assumption/constraint straight in there via a
BUG_ON():
> > if (idev) {
> > +#ifdef __ISAPNP__
> > irq = pnp_irq(idev, 0);
> > +#else
> > + /* Can not happen - in the !PNP case we always pass in NULL */
> > + BUG_ON(1);
> > +#endif
> > vp->dev = &idev->dev;
> > } else {
> > irq = inw(ioaddr + 0x2002) & 15;
> > --
no strong feelings though - it's a nitpick and this code is obviously
obsolete.
Ingo
prev parent reply other threads:[~2008-06-20 15:51 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-06-20 9:33 Ingo Molnar
2008-06-20 15:13 ` Randy Dunlap
2008-06-20 15:51 ` Ingo Molnar [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=20080620155105.GB6656@elte.hu \
--to=mingo@elte.hu \
--cc=jgarzik@redhat.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=randy.dunlap@oracle.com \
/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
all inboxes | Powered by JetHome®