Deleted Added
full compact
nsphy.c (69925) nsphy.c (72132)
1/* $NetBSD: nsphy.c,v 1.18 1999/07/14 23:57:36 thorpej Exp $ */
2
3/*-
4 * Copyright (c) 1998, 1999 The NetBSD Foundation, Inc.
5 * All rights reserved.
6 *
7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Jason R. Thorpe of the Numerical Aerospace Simulation Facility,

--- 78 unchanged lines hidden (view full) ---

87#include <dev/mii/miidevs.h>
88
89#include <dev/mii/nsphyreg.h>
90
91#include "miibus_if.h"
92
93#if !defined(lint)
94static const char rcsid[] =
1/* $NetBSD: nsphy.c,v 1.18 1999/07/14 23:57:36 thorpej Exp $ */
2
3/*-
4 * Copyright (c) 1998, 1999 The NetBSD Foundation, Inc.
5 * All rights reserved.
6 *
7 * This code is derived from software contributed to The NetBSD Foundation
8 * by Jason R. Thorpe of the Numerical Aerospace Simulation Facility,

--- 78 unchanged lines hidden (view full) ---

87#include <dev/mii/miidevs.h>
88
89#include <dev/mii/nsphyreg.h>
90
91#include "miibus_if.h"
92
93#if !defined(lint)
94static const char rcsid[] =
95 "$FreeBSD: head/sys/dev/mii/nsphy.c 69925 2000-12-12 19:31:14Z wpaul $";
95 "$FreeBSD: head/sys/dev/mii/nsphy.c 72132 2001-02-07 19:57:40Z semenu $";
96#endif
97
98static int nsphy_probe __P((device_t));
99static int nsphy_attach __P((device_t));
100static int nsphy_detach __P((device_t));
101
102static device_method_t nsphy_methods[] = {
103 /* device interface */

--- 22 unchanged lines hidden (view full) ---

126{
127 struct mii_attach_args *ma;
128
129 ma = device_get_ivars(dev);
130
131 if (MII_OUI(ma->mii_id1, ma->mii_id2) == MII_OUI_NATSEMI &&
132 MII_MODEL(ma->mii_id2) == MII_MODEL_NATSEMI_DP83840) {
133 device_set_desc(dev, MII_STR_NATSEMI_DP83840);
96#endif
97
98static int nsphy_probe __P((device_t));
99static int nsphy_attach __P((device_t));
100static int nsphy_detach __P((device_t));
101
102static device_method_t nsphy_methods[] = {
103 /* device interface */

--- 22 unchanged lines hidden (view full) ---

126{
127 struct mii_attach_args *ma;
128
129 ma = device_get_ivars(dev);
130
131 if (MII_OUI(ma->mii_id1, ma->mii_id2) == MII_OUI_NATSEMI &&
132 MII_MODEL(ma->mii_id2) == MII_MODEL_NATSEMI_DP83840) {
133 device_set_desc(dev, MII_STR_NATSEMI_DP83840);
134 } else if (MII_OUI(ma->mii_id1, ma->mii_id2) == MII_OUI_QUALSEMI &&
135 MII_MODEL(ma->mii_id2) == MII_MODEL_QUALSEMI_QS6612) {
136 device_set_desc(dev, MII_STR_QUALSEMI_QS6612);
137 } else if (MII_OUI(ma->mii_id1, ma->mii_id2) == MII_OUI_xxALTIMA &&
138 MII_MODEL(ma->mii_id2) == MII_MODEL_xxALTIMA_AC101) {
139 device_set_desc(dev, MII_STR_xxALTIMA_AC101);
140 } else
141 return (ENXIO);
142
143 return (0);
144}
145
146static int nsphy_attach(dev)
147 device_t dev;

--- 289 unchanged lines hidden ---
134 } else
135 return (ENXIO);
136
137 return (0);
138}
139
140static int nsphy_attach(dev)
141 device_t dev;

--- 289 unchanged lines hidden ---