From: Baruch Siach <baruch@tkos.co.il>
To: Roland Stigge <stigge@antcom.de>
Cc: davem@davemloft.net, jeffrey.t.kirsher@intel.com,
alexander.h.duyck@intel.com, eilong@broadcom.com,
ian.campbell@citrix.com, netdev@vger.kernel.org,
w.sang@pengutronix.de, linux-kernel@vger.kernel.org,
kevin.wells@nxp.com, linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v2] ARM: LPC32xx: Ethernet driver
Date: Sun, 26 Feb 2012 03:52:18 +0200 [thread overview]
Message-ID: <20120226015217.GA3257@tarshish> (raw)
In-Reply-To: <1330201304-24037-1-git-send-email-stigge@antcom.de>
Hi Roland,
On Sat, Feb 25, 2012 at 09:21:44PM +0100, Roland Stigge wrote:
> This patch adds an ethernet driver for the LPC32xx ARM SoC.
>
> Signed-off-by: Roland Stigge <stigge@antcom.de>
[snip]
> +static int __init ethaddr(char *s)
> +{
> + int i;
> + unsigned int r[6];
> +
> + sscanf(s, "%x:%x:%x:%x:%x:%x",
> + &r[0], &r[1], &r[2], &r[3], &r[4], &r[5]);
> + for (i = 0; i < 6; i++)
> + mac_address[i] = (u8)r[i];
> +
> + return 1;
> +}
> +__setup("ethaddr=", ethaddr);
Please use a module_param() instead of a top level kernel parameter.
You may also consider using module_param_array() here. See
drivers/net/ethernet/freescale/fec.c for an example. Note, however, that this
changes the format the MAC address representation. Instead of
"01:02:03:04:05:06", use "0x01,0x02,0x03,0x04,0x05,0x06".
baruch
--
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch@tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -
next prev parent reply other threads:[~2012-02-26 1:53 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-02-25 20:21 [PATCH v2] ARM: LPC32xx: Ethernet driver Roland Stigge
2012-02-25 20:41 ` Joe Perches
2012-02-26 1:52 ` Baruch Siach [this message]
2012-02-26 2:28 ` David Miller
-- strict thread matches above, loose matches on Subject: below --
2012-02-28 13:08 Roland Stigge
2012-02-28 13:11 ` David Laight
2012-02-28 13:32 ` Roland Stigge
2012-02-28 13:41 ` Arnd Bergmann
2012-02-28 13:49 ` Roland Stigge
2012-02-28 15:53 ` Ben Hutchings
2012-02-28 19:13 ` David Miller
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=20120226015217.GA3257@tarshish \
--to=baruch@tkos.co.il \
--cc=alexander.h.duyck@intel.com \
--cc=davem@davemloft.net \
--cc=eilong@broadcom.com \
--cc=ian.campbell@citrix.com \
--cc=jeffrey.t.kirsher@intel.com \
--cc=kevin.wells@nxp.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=stigge@antcom.de \
--cc=w.sang@pengutronix.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).