* Copyright (c) 1982, 1986, 1988 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
* @(#)mba.c 7.6 (Berkeley) 7/9/88
#include "../machine/pte.h"
#include "../vaxmba/mbareg.h"
#include "../vaxmba/hpreg.h"
struct mba_regs
*mba
= mbamba(io
->i_adapt
);
struct mba_drv
*drv
= mbadrv(io
->i_adapt
, unit
);
register struct pte
*pte
= mba
->mba_map
;
o
= (int)io
->i_ma
& PGOFSET
;
npf
= btoc(io
->i_cc
+ o
);
*(int *)pte
++ = v
++ | PG_V
;
mba
->mba_bcr
= -io
->i_cc
;
drv
->mbd_of
|= HPOF_SSEI
;
switch (io
->i_flgs
& F_TYPEMASK
) {
case F_RDDATA
: /* standard read */
drv
->mbd_cs1
= MB_RCOM
|MB_GO
;
case F_WRDATA
: /* standard write */
drv
->mbd_cs1
= MB_WCOM
|MB_GO
;
/* the following commands apply to disks only */
drv
->mbd_cs1
= HP_RHDR
|HP_GO
;
drv
->mbd_cs1
= HP_WHDR
|HP_GO
;
drv
->mbd_cs1
= HP_WCDATA
|HP_GO
;
drv
->mbd_cs1
= HP_WCHDR
|HP_GO
;
if ((drv
->mbd_dt
& MBDT_TAP
) == 0)
io
->i_flgs
&= ~F_TYPEMASK
;
struct mba_regs
*mba
= mbamba(io
->i_adapt
);
struct mba_drv
*drv
= mbadrv(io
->i_adapt
, unit
);
while (mba
->mba_sr
& MBSR_DTBUSY
)
register struct mba_regs
*mba
;
if (badaddr((char *)mba
, sizeof(long)))
if ((mbaact
& (1<<mbanum
)) == 0) {