From: "Maciej W. Rozycki" <macro@linux-mips.org>
To: Joe Perches <joe@perches.com>
Cc: netdev@vger.kernel.org
Subject: Re: [PATCH] declance: Fix 64-bit compilation warnings
Date: Sun, 29 Jun 2014 02:30:56 +0100 (BST) [thread overview]
Message-ID: <alpine.LFD.2.11.1406290226380.15455@eddie.linux-mips.org> (raw)
In-Reply-To: <1403996818.9064.48.camel@joe-AO725>
On Sat, 28 Jun 2014, Joe Perches wrote:
> > @@ -499,8 +499,9 @@ static void lance_init_ring(struct net_d
> > /* The ones required by tmd2 */
> > *lib_ptr(ib, btx_ring[i].misc, lp->type) = 0;
> > if (i < 3 && ZERO)
> > - printk("%d: 0x%8.8x(0x%8.8x)\n",
> > - i, leptr, (uint)lp->tx_buf_ptr_cpu[i]);
> > + printk("%d: 0x%8.8x(%#0*lx)\n",
> > + i, leptr, (int)sizeof(long),
> > + (long)lp->tx_buf_ptr_cpu[i]);
>
> You need to adjust the "*" and sizeof(long) with +2 for the
> 0x prefix in the output length here.
Good catch, thanks! MIPS kernel addresses always have their MSB set so
this is hard to notice in testing. But also the width has to be doubled
first, to take two digits per byte into account too. Sending an updated
change right away, as soon as it builds and boots.
Maciej
next prev parent reply other threads:[~2014-06-29 1:30 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-06-28 22:57 [PATCH] declance: Fix 64-bit compilation warnings Maciej W. Rozycki
2014-06-28 23:06 ` Joe Perches
2014-06-29 1:30 ` Maciej W. Rozycki [this message]
2014-06-30 9:44 ` David Laight
2014-06-30 9:58 ` Maciej W. Rozycki
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=alpine.LFD.2.11.1406290226380.15455@eddie.linux-mips.org \
--to=macro@linux-mips.org \
--cc=joe@perches.com \
--cc=netdev@vger.kernel.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).