1/* 2 * Copyright (c) 1982, 1990 The Regents of the University of California. 3 * All rights reserved. 4 * 5 * %sccs.include.redist.c% 6 *
| 1/* 2 * Copyright (c) 1982, 1990 The Regents of the University of California. 3 * All rights reserved. 4 * 5 * %sccs.include.redist.c% 6 *
|
7 * @(#)hpib.c 7.4 (Berkeley) 05/05/91
| 7 * @(#)hpib.c 7.5 (Berkeley) 05/07/91
|
8 */ 9 10/* 11 * HPIB driver 12 */ 13#include <sys/param.h> 14#include <sys/reboot.h> 15#include "../dev/device.h" 16#include "hpibvar.h" 17 18#include "saio.h" 19#include "samachdep.h" 20
| 8 */ 9 10/* 11 * HPIB driver 12 */ 13#include <sys/param.h> 14#include <sys/reboot.h> 15#include "../dev/device.h" 16#include "hpibvar.h" 17 18#include "saio.h" 19#include "samachdep.h" 20
|
21int internalhpib = 0x478000;
| 21int internalhpib = IIOV(0x478000);
|
22int fhpibppoll(), nhpibppoll(); 23 24struct hpib_softc hpib_softc[NHPIB]; 25 26#define hpibunit(x) ((x) >> 3) 27#define hpibslave(x) ((x) & 7) 28 29hpibinit() 30{ 31 extern struct hp_hw sc_table[]; 32 register struct hp_hw *hw; 33 register struct hpib_softc *hs; 34 register int i, addr; 35 static int first = 1; 36 37 i = 0;
| 22int fhpibppoll(), nhpibppoll(); 23 24struct hpib_softc hpib_softc[NHPIB]; 25 26#define hpibunit(x) ((x) >> 3) 27#define hpibslave(x) ((x) & 7) 28 29hpibinit() 30{ 31 extern struct hp_hw sc_table[]; 32 register struct hp_hw *hw; 33 register struct hpib_softc *hs; 34 register int i, addr; 35 static int first = 1; 36 37 i = 0;
|
38 for (hw = sc_table; i < NHPIB && hw < &sc_table[MAX_CTLR]; hw++) { 39 if (hw->hw_type != HPIB)
| 38 for (hw = sc_table; i < NHPIB && hw < &sc_table[MAXCTLRS]; hw++) { 39 if (!HW_ISHPIB(hw))
|
40 continue; 41 hs = &hpib_softc[i];
| 40 continue; 41 hs = &hpib_softc[i];
|
42 hs->sc_addr = hw->hw_addr;
| 42 hs->sc_addr = hw->hw_kva;
|
43 if (nhpibinit(i) == 0) 44 if (fhpibinit(i) == 0) 45 continue; 46 if (howto & RB_ASKNAME) 47 printf("hpib%d at sc%d\n", i, hw->hw_sc); 48 /* 49 * Adjust devtype on first call. This routine assumes that 50 * adaptor is in the high byte of devtype.
--- 106 unchanged lines hidden --- | 43 if (nhpibinit(i) == 0) 44 if (fhpibinit(i) == 0) 45 continue; 46 if (howto & RB_ASKNAME) 47 printf("hpib%d at sc%d\n", i, hw->hw_sc); 48 /* 49 * Adjust devtype on first call. This routine assumes that 50 * adaptor is in the high byte of devtype.
--- 106 unchanged lines hidden --- |