smcphy.c (179592) | smcphy.c (213229) |
---|---|
1/*- 2 * Copyright (c) 2006 Benno Rice. All rights reserved. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 1. Redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer. --- 9 unchanged lines hidden (view full) --- 18 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 19 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 20 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 22 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 */ 24 25#include <sys/cdefs.h> | 1/*- 2 * Copyright (c) 2006 Benno Rice. All rights reserved. 3 * 4 * Redistribution and use in source and binary forms, with or without 5 * modification, are permitted provided that the following conditions 6 * are met: 7 * 1. Redistributions of source code must retain the above copyright 8 * notice, this list of conditions and the following disclaimer. --- 9 unchanged lines hidden (view full) --- 18 * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, 19 * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY 20 * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT 21 * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF 22 * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 23 */ 24 25#include <sys/cdefs.h> |
26__FBSDID("$FreeBSD: head/sys/dev/mii/smcphy.c 179592 2008-06-06 05:00:49Z benno $"); | 26__FBSDID("$FreeBSD: head/sys/dev/mii/smcphy.c 213229 2010-09-27 20:31:03Z marius $"); |
27 28/* 29 * Driver for the internal PHY on the SMSC LAN91C111. 30 */ 31 32#include <sys/param.h> 33#include <sys/systm.h> 34#include <sys/kernel.h> --- 62 unchanged lines hidden (view full) --- 97{ 98 struct mii_softc *sc; 99 struct mii_attach_args *ma; 100 struct mii_data *mii; 101 102 sc = device_get_softc(dev); 103 ma = device_get_ivars(dev); 104 sc->mii_dev = device_get_parent(dev); | 27 28/* 29 * Driver for the internal PHY on the SMSC LAN91C111. 30 */ 31 32#include <sys/param.h> 33#include <sys/systm.h> 34#include <sys/kernel.h> --- 62 unchanged lines hidden (view full) --- 97{ 98 struct mii_softc *sc; 99 struct mii_attach_args *ma; 100 struct mii_data *mii; 101 102 sc = device_get_softc(dev); 103 ma = device_get_ivars(dev); 104 sc->mii_dev = device_get_parent(dev); |
105 mii = device_get_softc(sc->mii_dev); | 105 mii = ma->mii_data; |
106 LIST_INSERT_HEAD(&mii->mii_phys, sc, mii_list); 107 108 sc->mii_inst = mii->mii_instance; 109 sc->mii_phy = ma->mii_phyno; 110 sc->mii_service = smcphy_service; 111 sc->mii_pdata = mii; 112 113 mii->mii_instance++; --- 152 unchanged lines hidden --- | 106 LIST_INSERT_HEAD(&mii->mii_phys, sc, mii_list); 107 108 sc->mii_inst = mii->mii_instance; 109 sc->mii_phy = ma->mii_phyno; 110 sc->mii_service = smcphy_service; 111 sc->mii_pdata = mii; 112 113 mii->mii_instance++; --- 152 unchanged lines hidden --- |