From e60f6da1d620471f051e0f050e8d8be2149ceff9 Mon Sep 17 00:00:00 2001 From: Marius Strobl Date: Fri, 15 Oct 2010 15:46:58 +0000 Subject: [PATCH] Now that all previous users of mii_phy_probe() have been converted in r213893 and r213894 to use mii_attach() instead remove the former and along with it the "EVIL HACK". MFC after: never --- sys/dev/mii/mii.c | 15 --------------- sys/dev/mii/miivar.h | 1 - sys/modules/mii/Makefile | 1 - 3 files changed, 17 deletions(-) diff --git a/sys/dev/mii/mii.c b/sys/dev/mii/mii.c index 263a18b4de35..79378f5e203b 100644 --- a/sys/dev/mii/mii.c +++ b/sys/dev/mii/mii.c @@ -454,21 +454,6 @@ mii_attach(device_t dev, device_t *miibus, struct ifnet *ifp, return (rv); } -int -mii_phy_probe(device_t dev, device_t *child, ifm_change_cb_t ifmedia_upd, - ifm_stat_cb_t ifmedia_sts) -{ - struct ifnet *ifp; - - /* - * Note that each NIC's softc must start with an ifnet pointer. - * XXX: EVIL HACK! - */ - ifp = *(struct ifnet **)device_get_softc(dev); - return (mii_attach(dev, child, ifp, ifmedia_upd, ifmedia_sts, - BMSR_DEFCAPMASK, MII_PHY_ANY, MII_OFFSET_ANY, 0)); -} - /* * Media changed; notify all PHYs. */ diff --git a/sys/dev/mii/miivar.h b/sys/dev/mii/miivar.h index 9196f8d1ce0f..78d152a248e3 100644 --- a/sys/dev/mii/miivar.h +++ b/sys/dev/mii/miivar.h @@ -232,7 +232,6 @@ void mii_down(struct mii_data *); int mii_mediachg(struct mii_data *); void mii_tick(struct mii_data *); void mii_pollstat(struct mii_data *); -int mii_phy_probe(device_t, device_t *, ifm_change_cb_t, ifm_stat_cb_t); void mii_add_media(struct mii_softc *); void mii_phy_add_media(struct mii_softc *); diff --git a/sys/modules/mii/Makefile b/sys/modules/mii/Makefile index 23ec702d4aea..c1ffae217be7 100644 --- a/sys/modules/mii/Makefile +++ b/sys/modules/mii/Makefile @@ -14,7 +14,6 @@ SRCS+= xmphy.c EXPORT_SYMS= mii_attach \ mii_mediachg \ - mii_phy_probe \ mii_phy_reset \ mii_pollstat \ mii_tick