mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Jiri Pirko <jpirko@redhat.com>
To: Michal Schmidt <mschmidt@redhat.com>
Cc: linux-kernel@vger.kernel.org, ivecera@redhat.com,
	jgarzik@pobox.com, davem@davemloft.net, netdev@vger.kernel.org
Subject: Re: [PATCH] 8139cp: allow to set mac address on running device
Date: Thu, 12 Mar 2009 18:46:42 +0100	[thread overview]
Message-ID: <20090312174641.GC20153@psychotron.englab.brq.redhat.com> (raw)
In-Reply-To: <20090312181121.79e297a2@brian.englab.brq.redhat.com>

Thu, Mar 12, 2009 at 06:11:21PM CET, mschmidt@redhat.com wrote:
>On Thu, 12 Mar 2009 17:27:31 +0100
>Jiri Pirko <jpirko@redhat.com> wrote:
>
>> +	cpw32_f(MAC0 + 0, le32_to_cpu (*(__le32 *) (dev->dev_addr +
>> 0)));
>> +	cpw32_f(MAC0 + 4, le32_to_cpu (*(__le32 *) (dev->dev_addr +
>> 4)));
>
>You're writing to the card, so using *_to_cpu looks suspicious.
Well, I'm using the same approach as it is already done in function
cp_init_hw(). Quote:

 /* Restore our idea of the MAC address. */
 cpw32_f (MAC0 + 0, le32_to_cpu (*(__le32 *) (dev->dev_addr + 0)));
 cpw32_f (MAC0 + 4, le32_to_cpu (*(__le32 *) (dev->dev_addr + 4)));

Jirka
>
>Michal

  reply	other threads:[~2009-03-12 17:47 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-03-12 16:27 Jiri Pirko
2009-03-12 17:11 ` Michal Schmidt
2009-03-12 17:46   ` Jiri Pirko [this message]
2009-03-13  9:01     ` Ivan Vecera
2009-03-13 11:16       ` Jiri Pirko
2009-03-13 13:11         ` Ivan Vecera
2009-03-13 13:36           ` Jeff Garzik
2009-03-13 13:39             ` Ivan Vecera
2009-03-13 18:47 ` 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=20090312174641.GC20153@psychotron.englab.brq.redhat.com \
    --to=jpirko@redhat.com \
    --cc=davem@davemloft.net \
    --cc=ivecera@redhat.com \
    --cc=jgarzik@pobox.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mschmidt@redhat.com \
    --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

all inboxes | Powered by JetHome®