Deleted Added
full compact
if_vx_eisa.c (46743) if_vx_eisa.c (49360)
1/*
2 * Copyright (C) 1996 Naoki Hamada <nao@tom-yam.or.jp>
3 * 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

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

101
102 port = eisa_get_slot(dev) * EISA_SLOT_SIZE;
103 iobase = port + VX_EISA_SLOT_OFFSET;
104
105 eisa_add_iospace(dev, iobase, VX_EISA_IOSIZE, RESVADDR_NONE);
106 eisa_add_iospace(dev, port, VX_IOSIZE, RESVADDR_NONE);
107
108 /* Set irq */
1/*
2 * Copyright (C) 1996 Naoki Hamada <nao@tom-yam.or.jp>
3 * 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

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

101
102 port = eisa_get_slot(dev) * EISA_SLOT_SIZE;
103 iobase = port + VX_EISA_SLOT_OFFSET;
104
105 eisa_add_iospace(dev, iobase, VX_EISA_IOSIZE, RESVADDR_NONE);
106 eisa_add_iospace(dev, port, VX_IOSIZE, RESVADDR_NONE);
107
108 /* Set irq */
109 eisa_add_intr(dev, inw(iobase + VX_RESOURCE_CONFIG) >> 12);
109 eisa_add_intr(dev, inw(iobase + VX_RESOURCE_CONFIG) >> 12,
110 EISA_TRIGGER_EDGE);
110
111 return (0);
112}
113
114static int
115vx_eisa_attach(device_t dev)
116{
117 struct vx_softc *sc;
118 int unit = device_get_unit(dev);
119 struct resource *io = 0;
120 struct resource *eisa_io = 0;
121 struct resource *irq = 0;
111
112 return (0);
113}
114
115static int
116vx_eisa_attach(device_t dev)
117{
118 struct vx_softc *sc;
119 int unit = device_get_unit(dev);
120 struct resource *io = 0;
121 struct resource *eisa_io = 0;
122 struct resource *irq = 0;
122 u_char level_intr;
123 int rid;
124 void *ih;
125
126 /*
127 * The addresses are sorted in increasing order
128 * so we know the port to pass to the core ep
129 * driver comes first.
130 */

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

144 goto bad;
145 }
146
147 if ((sc = vxalloc(unit)) == NULL)
148 goto bad;
149
150 sc->vx_io_addr = rman_get_start(io);
151
123 int rid;
124 void *ih;
125
126 /*
127 * The addresses are sorted in increasing order
128 * so we know the port to pass to the core ep
129 * driver comes first.
130 */

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

144 goto bad;
145 }
146
147 if ((sc = vxalloc(unit)) == NULL)
148 goto bad;
149
150 sc->vx_io_addr = rman_get_start(io);
151
152 level_intr = FALSE;
153
154 rid = 0;
155 irq = bus_alloc_resource(dev, SYS_RES_IRQ, &rid,
156 0, ~0, 1, RF_ACTIVE);
157 if (!irq) {
158 device_printf(dev, "No irq?!\n");
159 vxfree(sc);
160 goto bad;
161 }

--- 42 unchanged lines hidden ---
152 rid = 0;
153 irq = bus_alloc_resource(dev, SYS_RES_IRQ, &rid,
154 0, ~0, 1, RF_ACTIVE);
155 if (!irq) {
156 device_printf(dev, "No irq?!\n");
157 vxfree(sc);
158 goto bad;
159 }

--- 42 unchanged lines hidden ---