From: Stephen Hemminger <shemminger@osdl.org>
To: Jeff Garzik <jeff@garzik.org>
Cc: Arnd Bergmann <arnd@arndb.de>, Chris Snook <csnook@redhat.com>,
Jay Cliburn <jacliburn@bellsouth.net>,
romieu@fr.zoreil.com, netdev@vger.kernel.org,
linux-kernel@vger.kernel.org
Subject: Re: [PATCH 3/4] atl1: Main C file for Attansic L1 driver
Date: Mon, 20 Nov 2006 13:59:59 -0800 [thread overview]
Message-ID: <20061120135959.66debead@freekitty> (raw)
In-Reply-To: <45621FEB.204@garzik.org>
On Mon, 20 Nov 2006 16:36:43 -0500
Jeff Garzik <jeff@garzik.org> wrote:
> Stephen Hemminger wrote:
> > On Mon, 20 Nov 2006 14:35:10 -0500
> > Jeff Garzik <jeff@garzik.org> wrote:
> >
> >> Stephen Hemminger wrote:
> >>> Using common MII code is good, but one problem with the existing MII code is that
> >>> it doesn't work when device is down. This makes it impossible to set speed/duplex
> >>> before device comes up.
> >>
> >> That's not true at all. drivers/net/mii.c uses caller-provided locking
> >> in all cases, and there is nothing that prevents the common code from
> >> being called when the interface is down.
> >>
> >> You are probably thinking about all the netif_running() checks found in
> >> the drivers, particularly in the ->begin() hook.
> >>
> >> Jeff
> >>
> >>
> >
> > Yeah it is a driver specific thing. All users of mii seem to block changes so
> > I thought it was in base code.
>
> Yeah. As a bit of history, a lot of drivers would power down the phy
> when the interface was down, and so MII would need to be inaccessible.
> But that's really a driver policy thing. If the driver provides a
> "don't power down phy, when interface is downed" knob, maybe it would
> want to support MII operations when !netif_running().
>
> Jeff
What I would like is for the mii core to maintain the bits (like advertising)
in the mii structure and if not running, it should just change the offline
copy, then when link is brought up use the changes that were requested while
link was down. Understand?
That's why in the skge/sky2, I keep state bits and don't apply them until
link is started. If mii (and phylib) did this, I could use them; but as it
is they require PHY to be powered all the time.
--
Stephen Hemminger <shemminger@osdl.org>
next prev parent reply other threads:[~2006-11-20 22:01 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-11-19 20:30 [PATCH 3/4] atl1: Main C file for Attansic L1 driver Jay Cliburn
2006-11-19 21:46 ` Jan Engelhardt
2006-11-19 23:57 ` Arnd Bergmann
2006-11-20 6:12 ` Chris Snook
2006-11-20 12:21 ` Arnd Bergmann
2006-11-20 18:02 ` Stephen Hemminger
2006-11-20 19:35 ` Jeff Garzik
2006-11-20 20:15 ` Stephen Hemminger
2006-11-20 21:36 ` Jeff Garzik
2006-11-20 21:59 ` Stephen Hemminger [this message]
2006-11-20 22:04 ` Jeff Garzik
2006-11-20 23:17 ` Stephen Hemminger
2006-11-20 12:39 ` Chris Snook
-- strict thread matches above, loose matches on Subject: below --
2007-01-11 0:42 Jay Cliburn
2007-01-11 9:33 ` Christoph Hellwig
2007-01-21 21:06 Jay Cliburn
2007-01-22 8:22 ` Arjan van de Ven
2007-01-22 16:48 ` Jay Cliburn
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=20061120135959.66debead@freekitty \
--to=shemminger@osdl.org \
--cc=arnd@arndb.de \
--cc=csnook@redhat.com \
--cc=jacliburn@bellsouth.net \
--cc=jeff@garzik.org \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=romieu@fr.zoreil.com \
/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).