cvs commit: src/sys/dev/age if_age.c if_agereg.h if_agevar.h

Andrew Thompson thompsa at FreeBSD.org
Fri Jul 18 00:13:35 UTC 2008


On Mon, May 19, 2008 at 01:39:59AM +0000, Pyun YongHyeon wrote:
> yongari     2008-05-19 01:39:59 UTC
> 
>   FreeBSD src repository
> 
>   Added files:
>     sys/dev/age          if_age.c if_agereg.h if_agevar.h 
>   Log:
>   Add age(4), a driver for Attansic/Atheros L1 gigabit ethernet
>   controller.

+static void
+age_phy_reset(struct age_softc *sc)
+{
+
+        /* Reset PHY. */
+        CSR_WRITE_4(sc, AGE_GPHY_CTRL, GPHY_CTRL_RST);
+        pause("agephy", hz / 1000);
+        CSR_WRITE_4(sc, AGE_GPHY_CTRL, GPHY_CTRL_CLR);
+        pause("agephy", hz / 1000);
+}

This will panic if hz < 1000, perhaps a DELAY(1) is better?


Andrew


More information about the freebsd-current mailing list