Commit | Line | Data |
---|---|---|
e843bebd | 1 | /* conf.c 4.9 81/12/01 */ |
c7ebcc4e BJ |
2 | |
3 | #include "../h/param.h" | |
4 | #include "../h/inode.h" | |
f7acbdcc | 5 | #include "../h/pte.h" |
2d19f71b | 6 | #include "../h/mbareg.h" |
c7ebcc4e BJ |
7 | #include "saio.h" |
8 | ||
9 | devread(io) | |
2d19f71b | 10 | register struct iob *io; |
c7ebcc4e BJ |
11 | { |
12 | ||
2d19f71b | 13 | return( (*devsw[io->i_ino.i_dev].dv_strategy)(io, READ) ); |
c7ebcc4e BJ |
14 | } |
15 | ||
16 | devwrite(io) | |
2d19f71b | 17 | register struct iob *io; |
c7ebcc4e | 18 | { |
2d19f71b | 19 | |
c7ebcc4e BJ |
20 | return( (*devsw[io->i_ino.i_dev].dv_strategy)(io, WRITE) ); |
21 | } | |
22 | ||
23 | devopen(io) | |
2d19f71b | 24 | register struct iob *io; |
c7ebcc4e | 25 | { |
2d19f71b | 26 | |
c7ebcc4e BJ |
27 | (*devsw[io->i_ino.i_dev].dv_open)(io); |
28 | } | |
29 | ||
30 | devclose(io) | |
2d19f71b | 31 | register struct iob *io; |
c7ebcc4e | 32 | { |
2d19f71b | 33 | |
c7ebcc4e BJ |
34 | (*devsw[io->i_ino.i_dev].dv_close)(io); |
35 | } | |
36 | ||
37 | nullsys() | |
2d19f71b BJ |
38 | { |
39 | ||
40 | ; | |
41 | } | |
c7ebcc4e BJ |
42 | |
43 | int nullsys(); | |
44 | int hpstrategy(), hpopen(); | |
45 | int htstrategy(), htopen(), htclose(); | |
46 | int upstrategy(), upopen(); | |
5cb41021 | 47 | int tmstrategy(), tmopen(), tmclose(); |
2d19f71b | 48 | int tsstrategy(), tsopen(), tsclose(); |
3486ee81 BJ |
49 | int mtstrategy(), mtopen(), mtclose(); |
50 | int rkstrategy(), rkopen(); | |
51 | int udstrategy(), udopen(); | |
e843bebd | 52 | int utstrategy(), utopen(), utclose(); |
c7ebcc4e BJ |
53 | |
54 | struct devsw devsw[] = { | |
55 | "hp", hpstrategy, hpopen, nullsys, | |
56 | "ht", htstrategy, htopen, htclose, | |
57 | "up", upstrategy, upopen, nullsys, | |
5cb41021 | 58 | "tm", tmstrategy, tmopen, tmclose, |
2d19f71b | 59 | "hk", rkstrategy, rkopen, nullsys, |
610c6f01 | 60 | "ts", tsstrategy, tsopen, tsclose, |
3486ee81 BJ |
61 | "mt", mtstrategy, mtopen, mtclose, |
62 | "ra", udstrategy, udopen, nullsys, | |
e843bebd | 63 | "ut", utstrategy, utopen, utclose, |
c7ebcc4e BJ |
64 | 0,0,0,0 |
65 | }; |