INB
np->sv_scntl0 = INB(nc_scntl0) & 0x0a;
np->sv_scntl3 = INB(nc_scntl3) & 0x07;
np->sv_dmode = INB(nc_dmode) & 0xce;
np->sv_dcntl = INB(nc_dcntl) & 0xa8;
np->sv_ctest0 = INB(nc_ctest0) & 0x84;
np->sv_ctest3 = INB(nc_ctest3) & 0x01;
np->sv_ctest4 = INB(nc_ctest4) & 0x80;
np->sv_ctest5 = INB(nc_ctest5) & 0x24;
np->sv_gpcntl = INB(nc_gpcntl);
np->sv_stest2 = INB(nc_stest2) & 0x20;
np->sv_stest4 = INB(nc_stest4);
np->myaddr = INB(nc_scid) & 0x07;
if (INB(nc_gpreg) & 0x08)
term = INB(nc_sstat0);
term |= ((INB(nc_sstat2) & 0x01) << 26) | /* sdp1 */
INB(nc_sbcl); /* req ack bsy sel atn msg cd io */
u_char target = INB (nc_sdid) & 0x0f;
u16 target = INB (nc_sdid) & 0x0f;
if (INB(nc_istat) & (INTF|SIP|DIP)) {
ncr_name (np), (unsigned)INB (nc_sdid)&0x0f, dstat, sist,
(unsigned)INB (nc_socl), (unsigned)INB (nc_sbcl), (unsigned)INB (nc_sbdl),
(unsigned)INB (nc_sxfer),(unsigned)INB (nc_scntl3), script_name, script_ofs,
istat = INB (nc_istat);
istat = INB (nc_istat);
dstat = (istat & DIP) ? INB (nc_dstat) : 0;
(int)INB(nc_scr0),
u_char scsi_mode = INB (nc_stest4) & SMODE;
u_char hsts = INB (HS_PRT);
u_char sstat1 = INB (nc_sstat1);
if (!(INB (nc_scntl1) & ISCON))
sbcl = INB (nc_sbcl);
ctest5 = (np->rv_ctest5 & DFS) ? INB (nc_ctest5) : 0;
delta=(((ctest5 << 8) | (INB (nc_dfifo) & 0xff)) - rest) & 0x3ff;
delta=(INB (nc_dfifo) - rest) & 0x7f;
ss0 = INB (nc_sstat0);
if (INB(nc_scntl3) & EWS) {
ss2 = INB (nc_sstat2);
u_char s_status = INB (SS_PRT);
INB (nc_ctest2); /* Clear SIGP */
u_char num = INB (nc_dsps);
u_char target = INB (nc_sdid) & 0x0f;
if (INB (HS_PRT) == HS_NEGOTIATE) {
if (INB (HS_PRT) == HS_NEGOTIATE) {
if (INB(nc_istat) & (INTF|SIP|DIP))
while (!(INB(nc_stest4) & LCKFRQ) && --i > 0)
unsigned char scntl3 = INB(nc_scntl3);
unsigned char stest1 = INB(nc_stest1);
#define OUTONB(r, m) OUTB(r, INB(r) | (m))
#define OUTOFFB(r, m) OUTB(r, INB(r) & ~(m))
INB(np, nc_mbox1);
if (INB(np, nc_istat) & (INTF|SIP|DIP))
dstat = INB(np, nc_dstat);
sym_name(np), (unsigned)INB(np, nc_sdid)&0x0f, dstat, sist,
(unsigned)INB(np, nc_socl), (unsigned)INB(np, nc_sbcl),
(unsigned)INB(np, nc_sbdl), (unsigned)INB(np, nc_sxfer),
(unsigned)INB(np, nc_scntl3),
(np->features & FE_C10) ? (unsigned)INB(np, nc_scntl4) : 0,
dstat = INB(np, nc_dstat);
INB(np, nc_mbox1);
INB(np, nc_mbox1);
if (!(np->features & FE_ISTAT1) || !(INB(np, nc_istat1) & SCRUN))
istat = INB(np, nc_istat);
if (INB(np, nc_dstat) & ABRT)
INB(np, nc_mbox1);
OUTB(np, nc_stest1, INB(np, nc_stest1) | 0x30);
OUTB(np, nc_gpcntl, INB(np, nc_gpcntl) & ~0x01);
OUTB(np, nc_gpcntl, (INB(np, nc_gpcntl) & ~0x41) | 0x20);
INB(np, nc_mbox1);
np->scsi_mode = INB(np, nc_stest4) & SMODE;
INB(np, nc_mbox1);
assert(target == (INB(np, nc_sdid) & 0x0f));
term = INB(np, nc_sstat0);
term |= ((INB(np, nc_sstat2) & 0x01) << 26) | /* sdp1 */
INB(np, nc_sbcl); /* req ack bsy sel atn msg cd io */
u_char scsi_mode = INB(np, nc_stest4) & SMODE;
u_char hsts = INB(np, HS_PRT);
u_char sbcl = INB(np, nc_sbcl);
if (!(INB(np, nc_scntl1) & ISCON)) {
ss0 = INB(np, nc_sstat0);
ss2 = INB(np, nc_sstat2);
printf ("P%x%x RL=%d D=%d ", cmd&7, INB(np, nc_sbcl)&7,
while (!(INB(np, nc_stest4) & LCKFRQ) && --i > 0)
cmd&7, INB(np, nc_sbcl)&7, (unsigned)olen,
hflags0 = INB(np, HF_PRT);
INB(np, nc_mbox1);
(INB(np, nc_scntl2) & WSR)) {
istat = INB(np, nc_istat);
istat |= INB(np, nc_istat); /* DUMMY READ */
dstat |= INB(np, nc_dstat);
istatc = INB(np, nc_istat);
(int)INB(np, nc_scr0),
target = INB(np, nc_sdid) & 0xf;
target = INB(np, nc_sdid) & 0xf;
hflags = INB(np, HF_PRT);
if (INB(np, HS_PRT) == HS_NEGOTIATE) {
if (INB(np, HS_PRT) == HS_NEGOTIATE) {
if (INB(np, HS_PRT) == HS_NEGOTIATE) {
u_char num = INB(np, nc_dsps);
u_char target = INB(np, nc_sdid) & 0x0f;
if (INB(np, HS_PRT) == HS_NEGOTIATE)
np->sv_scntl0 = INB(np, nc_scntl0) & 0x0a;
np->sv_scntl3 = INB(np, nc_scntl3) & 0x07;
np->sv_dmode = INB(np, nc_dmode) & 0xce;
np->sv_dcntl = INB(np, nc_dcntl) & 0xa8;
np->sv_ctest3 = INB(np, nc_ctest3) & 0x01;
np->sv_ctest4 = INB(np, nc_ctest4) & 0x80;
np->sv_gpcntl = INB(np, nc_gpcntl);
np->sv_stest1 = INB(np, nc_stest1);
np->sv_stest2 = INB(np, nc_stest2) & 0x20;
np->sv_stest4 = INB(np, nc_stest4);
np->sv_scntl4 = INB(np, nc_scntl4);
np->sv_ctest5 = INB(np, nc_ctest5) & 0x04;
np->sv_ctest5 = INB(np, nc_ctest5) & 0x24;
if (!(INB(np, nc_gpreg) & 0x08))
np->myaddr = INB(np, nc_scid) & 0x07;
#define OUTONB(np, r, m) OUTB(np, r, INB(np, r) | (m))
#define OUTOFFB(np, r, m) OUTB(np, r, INB(np, r) & ~(m))
INB(np, nc_mbox1);
*read_bit = INB(np, nc_gpreg);
old_gpreg = INB(np, nc_gpreg);
old_gpcntl = INB(np, nc_gpcntl);
old_gpreg = INB(np, nc_gpreg);
old_gpcntl = INB(np, nc_gpcntl);
INB(np, nc_mbox1);
*read_bit = INB(np, nc_gpreg);
INB(np, nc_mbox1);
INB(np, nc_mbox1);
*read_bit = INB(np, nc_gpreg);
old_gpreg = INB(np, nc_gpreg);
old_gpcntl = INB(np, nc_gpcntl);
unsigned char tmp = INB(0x3da); \
tmp = INB(0x3da); \