* [PATCH: 2.6.12-rc1] mii: GigE support bug fixes
@ 2005-03-22 23:15 Dale Farnsworth
2005-03-22 23:26 ` Jeff Garzik
0 siblings, 1 reply; 2+ messages in thread
From: Dale Farnsworth @ 2005-03-22 23:15 UTC (permalink / raw)
To: Netdev, Jeff Garzik; +Cc: James Chapman
This patch fixes a couple bugs in mii.c GigE support.
Signed-off-by: Dale Farnsworth <dale@farnsworth.org>
Acked-by: James Chapman <jchapman@katalix.com>
Index: linux-2.5-enet/drivers/net/mii.c
===================================================================
--- linux-2.5-enet.orig/drivers/net/mii.c
+++ linux-2.5-enet/drivers/net/mii.c
@@ -43,6 +43,9 @@
(SUPPORTED_10baseT_Half | SUPPORTED_10baseT_Full |
SUPPORTED_100baseT_Half | SUPPORTED_100baseT_Full |
SUPPORTED_Autoneg | SUPPORTED_TP | SUPPORTED_MII);
+ if (mii->supports_gmii)
+ ecmd->supported |= SUPPORTED_1000baseT_Half |
+ SUPPORTED_1000baseT_Full;
/* only supports twisted-pair */
ecmd->port = PORT_MII;
@@ -100,7 +103,7 @@
} else {
ecmd->autoneg = AUTONEG_DISABLE;
- ecmd->speed = ((bmcr2 & BMCR_SPEED1000 &&
+ ecmd->speed = ((bmcr & BMCR_SPEED1000 &&
(bmcr & BMCR_SPEED100) == 0) ? SPEED_1000 :
(bmcr & BMCR_SPEED100) ? SPEED_100 : SPEED_10);
ecmd->duplex = (bmcr & BMCR_FULLDPLX) ? DUPLEX_FULL : DUPLEX_HALF;
@@ -163,9 +166,9 @@
tmp |= ADVERTISE_100FULL;
if (mii->supports_gmii) {
if (ecmd->advertising & ADVERTISED_1000baseT_Half)
- advert2 |= ADVERTISE_1000HALF;
+ tmp2 |= ADVERTISE_1000HALF;
if (ecmd->advertising & ADVERTISED_1000baseT_Full)
- advert2 |= ADVERTISE_1000FULL;
+ tmp2 |= ADVERTISE_1000FULL;
}
if (advert != tmp) {
mii->mdio_write(dev, mii->phy_id, MII_ADVERTISE, tmp);
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH: 2.6.12-rc1] mii: GigE support bug fixes
2005-03-22 23:15 [PATCH: 2.6.12-rc1] mii: GigE support bug fixes Dale Farnsworth
@ 2005-03-22 23:26 ` Jeff Garzik
0 siblings, 0 replies; 2+ messages in thread
From: Jeff Garzik @ 2005-03-22 23:26 UTC (permalink / raw)
To: Dale Farnsworth; +Cc: Netdev, James Chapman
Dale Farnsworth wrote:
> This patch fixes a couple bugs in mii.c GigE support.
>
> Signed-off-by: Dale Farnsworth <dale@farnsworth.org>
> Acked-by: James Chapman <jchapman@katalix.com>
Applied, but a small nit: Don't bother including a patch description in
the body of the email, if it simply re-states the Subject and nothing more.
Jeff
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2005-03-22 23:26 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-22 23:15 [PATCH: 2.6.12-rc1] mii: GigE support bug fixes Dale Farnsworth
2005-03-22 23:26 ` Jeff Garzik
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).