Deleted Added
full compact
if_wb.c (51455) if_wb.c (51473)
1/*
2 * Copyright (c) 1997, 1998
3 * Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

24 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
30 * THE POSSIBILITY OF SUCH DAMAGE.
31 *
1/*
2 * Copyright (c) 1997, 1998
3 * Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

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

24 * BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
25 * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
26 * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
27 * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
28 * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
29 * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF
30 * THE POSSIBILITY OF SUCH DAMAGE.
31 *
32 * $FreeBSD: head/sys/pci/if_wb.c 51455 1999-09-20 08:47:11Z wpaul $
32 * $FreeBSD: head/sys/pci/if_wb.c 51473 1999-09-20 19:06:45Z wpaul $
33 */
34
35/*
36 * Winbond fast ethernet PCI NIC driver
37 *
38 * Supports various cheap network adapters based on the Winbond W89C840F
39 * fast ethernet controller chip. This includes adapters manufactured by
40 * Winbond itself and some made by Linksys.

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

129#include "miibus_if.h"
130
131#define WB_USEIOSPACE
132
133#include <pci/if_wbreg.h>
134
135#ifndef lint
136static const char rcsid[] =
33 */
34
35/*
36 * Winbond fast ethernet PCI NIC driver
37 *
38 * Supports various cheap network adapters based on the Winbond W89C840F
39 * fast ethernet controller chip. This includes adapters manufactured by
40 * Winbond itself and some made by Linksys.

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

129#include "miibus_if.h"
130
131#define WB_USEIOSPACE
132
133#include <pci/if_wbreg.h>
134
135#ifndef lint
136static const char rcsid[] =
137 "$FreeBSD: head/sys/pci/if_wb.c 51455 1999-09-20 08:47:11Z wpaul $";
137 "$FreeBSD: head/sys/pci/if_wb.c 51473 1999-09-20 19:06:45Z wpaul $";
138#endif
139
140/*
141 * Various supported device vendors/types and their names.
142 */
143static struct wb_type wb_devs[] = {
144 { WB_VENDORID, WB_DEVICEID_840F,
145 "Winbond W89C840F 10/100BaseTX" },

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

224static driver_t wb_driver = {
225 "wb",
226 wb_methods,
227 sizeof(struct wb_softc)
228};
229
230static devclass_t wb_devclass;
231
138#endif
139
140/*
141 * Various supported device vendors/types and their names.
142 */
143static struct wb_type wb_devs[] = {
144 { WB_VENDORID, WB_DEVICEID_840F,
145 "Winbond W89C840F 10/100BaseTX" },

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

224static driver_t wb_driver = {
225 "wb",
226 wb_methods,
227 sizeof(struct wb_softc)
228};
229
230static devclass_t wb_devclass;
231
232DRIVER_MODULE(if_wb, pci, wb_driver, wb_devclass, 0, 0);
233DRIVER_MODULE(miibus, if_wb, miibus_driver, miibus_devclass, 0, 0);
232DRIVER_MODULE(wb, pci, wb_driver, wb_devclass, 0, 0);
233DRIVER_MODULE(miibus, wb, miibus_driver, miibus_devclass, 0, 0);
234
235#define WB_SETBIT(sc, reg, x) \
236 CSR_WRITE_4(sc, reg, \
237 CSR_READ_4(sc, reg) | x)
238
239#define WB_CLRBIT(sc, reg, x) \
240 CSR_WRITE_4(sc, reg, \
241 CSR_READ_4(sc, reg) & ~x)

--- 1691 unchanged lines hidden ---
234
235#define WB_SETBIT(sc, reg, x) \
236 CSR_WRITE_4(sc, reg, \
237 CSR_READ_4(sc, reg) | x)
238
239#define WB_CLRBIT(sc, reg, x) \
240 CSR_WRITE_4(sc, reg, \
241 CSR_READ_4(sc, reg) & ~x)

--- 1691 unchanged lines hidden ---