From: Johannes Berg <johannes@sipsolutions.net>
To: David Laight <David.Laight@ACULAB.COM>
Cc: netdev@vger.kernel.org, ben@decadent.org.uk
Subject: Re: [PATCH 5/6] alx: fix MAC address alignment problem
Date: Fri, 21 Jun 2013 10:43:32 +0200 [thread overview]
Message-ID: <1371804212.10400.1.camel@jlt4.sipsolutions.net> (raw)
In-Reply-To: <AE90C24D6B3A694183C094C60CF0A2F6026B729E@saturn3.aculab.com>
On Fri, 2013-06-21 at 09:38 +0100, David Laight wrote:
> > In two places, parts of MAC addresses are used as u32/u16
> > values. This can cause alignment problems, use put_unaligned
> > and get_unaligned to fix this.
>
> I suspect they are always 16bit aligned, so 16bit accesses
> would be ok - rather than using byte accesses.
> However I wouldn't know how to request this with the available
> definitions....
For at least one of them, there's no such guarantee.
johannes
next prev parent reply other threads:[~2013-06-21 8:43 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-20 22:14 [PATCH 0/6] alx: small fixes and cleanups Johannes Berg
2013-06-20 22:14 ` [PATCH 1/6] alx: treat flow control correctly in alx_set_pauseparam() Johannes Berg
2013-06-20 22:14 ` [PATCH 2/6] alx: fix 100mbit/full duplex speed translation Johannes Berg
2013-06-20 22:14 ` [PATCH 3/6] alx: make sizes unsigned Johannes Berg
2013-06-20 22:14 ` [PATCH 4/6] alx: separate link speed/duplex fields Johannes Berg
2013-06-21 12:37 ` Ben Hutchings
2013-06-21 20:43 ` Johannes Berg
2013-06-20 22:14 ` [PATCH 5/6] alx: fix MAC address alignment problem Johannes Berg
2013-06-21 8:38 ` David Laight
2013-06-21 8:43 ` Johannes Berg [this message]
2013-06-20 22:14 ` [PATCH 6/6] alx: fix ethtool support code Johannes Berg
2013-06-21 12:39 ` Ben Hutchings
2013-06-21 20:46 ` Johannes Berg
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=1371804212.10400.1.camel@jlt4.sipsolutions.net \
--to=johannes@sipsolutions.net \
--cc=David.Laight@ACULAB.COM \
--cc=ben@decadent.org.uk \
--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).