From: petkan@nucleusys.com
To: "Davide Rizzo" <elpa.rizzo@gmail.com>
Cc: linux-usb@vger.kernel.org, netdev@vger.kernel.org,
petkan@users.sourceforge.net
Subject: Re: Pegasus: Bug / Correction (?)
Date: Fri, 14 Aug 2009 20:24:33 +0300 (EEST) [thread overview]
Message-ID: <e315af7ef85836e3c6dcdf6e1a6f5583.squirrel@nucleusys.com> (raw)
In-Reply-To: <8447d6730908130311vd6984e8t1dd5c1e32efbeb2c@mail.gmail.com>
Not good - the correction will disable set_address for older controllers.
Have you tried this code on a different device?
Petko
> Bug Correction
> ADM8515 fails to read central 2 bytes of MAC address
> This patch solves the problem, but I didn't understand it.
>
> Signed-off-by: Davide Rizzo <elpa.rizzo@gmail.com>
> ---
> diff -urNp linux-2.6.30.4/drivers/net/usb/pegasus.c
> linux-2.6.30.4.elpa/drivers/net/usb/pegasus.c
> --- linux-2.6.30.4/drivers/net/usb/pegasus.c 2009-08-13 07:14:57.000000000
> +0200
> +++ linux-2.6.30.4.elpa/drivers/net/usb/pegasus.c 2009-08-13
> 08:39:01.000000000 +0200
> @@ -425,7 +425,6 @@ fail:
> static inline void enable_eprom_write(pegasus_t * pegasus)
> {
> __u8 tmp;
> - int ret;
>
> get_registers(pegasus, EthCtrl2, 1, &tmp);
> set_register(pegasus, EthCtrl2, tmp | EPROM_WR_ENABLE);
> @@ -434,7 +433,6 @@ static inline void enable_eprom_write(pe
> static inline void disable_eprom_write(pegasus_t * pegasus)
> {
> __u8 tmp;
> - int ret;
>
> get_registers(pegasus, EthCtrl2, 1, &tmp);
> set_register(pegasus, EpromCtrl, 0);
> @@ -486,9 +525,9 @@ static void set_ethernet_addr(pegasus_t
> {
> __u8 node_id[6];
>
> - if (pegasus->features & PEGASUS_II) {
> +/*if (pegasus->features & PEGASUS_II) {
> get_registers(pegasus, 0x10, sizeof(node_id), node_id);
> - } else {
> + } else*/ {
> get_node_id(pegasus, node_id);
> set_registers(pegasus, EthID, sizeof (node_id), node_id);
> }
>
next prev parent reply other threads:[~2009-08-14 17:24 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-08-13 10:11 Pegasus: Bug / Correction (?) Davide Rizzo
2009-08-14 17:24 ` petkan [this message]
[not found] ` <e315af7ef85836e3c6dcdf6e1a6f5583.squirrel-nPnTwAqkgEqakBO8gow8eQ@public.gmane.org>
2009-08-15 5:57 ` Davide Rizzo
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=e315af7ef85836e3c6dcdf6e1a6f5583.squirrel@nucleusys.com \
--to=petkan@nucleusys.com \
--cc=elpa.rizzo@gmail.com \
--cc=linux-usb@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=petkan@users.sourceforge.net \
/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