From: Michael Buesch <mb@bu3sch.de>
To: Stephen Hemminger <shemminger@osdl.org>
Cc: Ayaz Abdulla <aabdulla@nvidia.com>,
Manfred Spraul <manfred@colorfullife.com>,
Jeff Garzik <jgarzik@pobox.com>, Andrew Morton <akpm@osdl.org>,
netdev@vger.kernel.org, Joe Perches <joe@perches.com>
Subject: Re: [PATCH 1/2] forcedeth: coding style cleanups (rev2)
Date: Thu, 27 Jul 2006 21:29:53 +0200 [thread overview]
Message-ID: <200607272129.53773.mb@bu3sch.de> (raw)
In-Reply-To: <20060727122429.27fcd513@localhost.localdomain>
On Thursday 27 July 2006 21:24, Stephen Hemminger wrote:
> On Thu, 27 Jul 2006 21:21:14 +0200
> Michael Buesch <mb@bu3sch.de> wrote:
>
> > On Thursday 27 July 2006 19:48, Stephen Hemminger wrote:
> > > --- sky2.orig/drivers/net/forcedeth.c 2006-07-13 12:53:48.000000000 -0700
> > > +++ sky2/drivers/net/forcedeth.c 2006-07-27 10:45:49.000000000 -0700
> > > @@ -381,21 +381,21 @@
> > >
> > > /* Big endian: should work, but is untested */
> > > struct ring_desc {
> > > - u32 PacketBuffer;
> > > - u32 FlagLen;
> > > + u32 buf;
> > > + u32 flaglen;
> > > };
> > >
> > > struct ring_desc_ex {
> > > - u32 PacketBufferHigh;
> > > - u32 PacketBufferLow;
> > > - u32 TxVlan;
> > > - u32 FlagLen;
> > > + u32 bufhigh;
> > > + u32 buflow;
> > > + u32 txvlan;
> > > + u32 flaglen;
> > > };
> >
> > Shouldn't these two structs be __attribute__((packed)) ?
> >
>
> Not really necessary since the elements are all the same size.
Yes, sure. But I always ask myself if we really want to depend on this.
(There are other drivers also depending on this...)
I would say, if the device depends on the fields being
there without padding, we should tell the compiler.
> Plus, this was a style cleanup patch...
Sure. Was more a generic comment from me. ;)
--
Greetings Michael.
next prev parent reply other threads:[~2006-07-27 19:30 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-07-27 16:19 [PATCH 0/2] forcedeth patches Stephen Hemminger
2006-07-27 16:19 ` [PATCH 1/2] forcedeth: coding style cleanups Stephen Hemminger
2006-07-27 17:48 ` [PATCH 1/2] forcedeth: coding style cleanups (rev2) Stephen Hemminger
2006-07-27 19:21 ` Michael Buesch
2006-07-27 19:24 ` Stephen Hemminger
2006-07-27 19:29 ` Michael Buesch [this message]
2006-07-27 16:19 ` [PATCH 2/2] forcdeth: NAPI support Stephen Hemminger
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=200607272129.53773.mb@bu3sch.de \
--to=mb@bu3sch.de \
--cc=aabdulla@nvidia.com \
--cc=akpm@osdl.org \
--cc=jgarzik@pobox.com \
--cc=joe@perches.com \
--cc=manfred@colorfullife.com \
--cc=netdev@vger.kernel.org \
--cc=shemminger@osdl.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).