From: Ralf Baechle <ralf@linux-mips.org>
To: Stephen Hemminger <shemminger@linux-foundation.org>
Cc: Thiemo Seufer <ths@networkno.de>,
linux-mips@linux-mips.org, netdev@vger.kernel.org
Subject: Re: [PATCH] Fix/Rewrite of the mipsnet driver
Date: Sun, 28 Oct 2007 20:40:10 +0000 [thread overview]
Message-ID: <20071028204010.GA16898@linux-mips.org> (raw)
In-Reply-To: <20071028132204.5ab09c10@freepuppy.rosehill>
On Sun, Oct 28, 2007 at 01:22:04PM -0700, Stephen Hemminger wrote:
> > -#define MIPSNET_INTCTL_TXDONE ((uint32_t)(1 << 0))
> > -#define MIPSNET_INTCTL_RXDONE ((uint32_t)(1 << 1))
> > -#define MIPSNET_INTCTL_TESTBIT ((uint32_t)(1 << 31))
> > -#define MIPSNET_INTCTL_ALLSOURCES (MIPSNET_INTCTL_TXDONE | \
> > - MIPSNET_INTCTL_RXDONE | \
> > - MIPSNET_INTCTL_TESTBIT)
>
> It is standard practice in the kernel to use u32 rather than uint32_t.
uint32_t has widely leaked in and as long as it's not used in headers
exported to userland is perfectly fine. But if we want to achieve
consistence throughout the kernel it'll take a little witch hunt for
uint32_t and co.
> Also cast of shift is unneeded (1u << 0) works fine.
Old sins of mipsnet.h which was just copied into mipsnet.c. Or toothing
pains of a driver on its way to sanity.
Ralf
prev parent reply other threads:[~2007-10-28 20:40 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-10-28 4:38 [PATCH] Fix/Rewrite of the mipsnet driver Thiemo Seufer
2007-10-29 0:25 ` Ralf Baechle
2007-10-28 20:03 ` Thiemo Seufer
2007-10-28 20:22 ` Stephen Hemminger
2007-10-28 20:38 ` Thiemo Seufer
2007-10-28 20:40 ` Ralf Baechle [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=20071028204010.GA16898@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=linux-mips@linux-mips.org \
--cc=netdev@vger.kernel.org \
--cc=shemminger@linux-foundation.org \
--cc=ths@networkno.de \
/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).