1: #include <sys/param.h>
   2: #include <sys/inode.h>
   3: #include "saio.h"
   4: 
   5: devread(io)
   6: register struct iob *io;
   7: {
   8: 
   9:     return( (*devsw[io->i_ino.i_dev].dv_strategy)(io,READ) );
  10: }
  11: 
  12: devwrite(io)
  13: register struct iob *io;
  14: {
  15:     return( (*devsw[io->i_ino.i_dev].dv_strategy)(io, WRITE) );
  16: }
  17: 
  18: devopen(io)
  19: register struct iob *io;
  20: {
  21:     (*devsw[io->i_ino.i_dev].dv_open)(io);
  22: }
  23: 
  24: devclose(io)
  25: register struct iob *io;
  26: {
  27:     (*devsw[io->i_ino.i_dev].dv_close)(io);
  28: }
  29: 
  30: nullsys()
  31: { ; }
  32: 
  33: int rpstrategy();
  34: int rkstrategy();
  35: int nullsys();
  36: int tmstrategy(), tmrew(), tmopen();
  37: int htstrategy(), htopen(),htclose();
  38: int hpstrategy();
  39: struct devsw devsw[] {
  40:     "rp",   rpstrategy, nullsys,    nullsys,
  41:     "hp",   hpstrategy, nullsys,    nullsys,
  42:     "rk",   rkstrategy, nullsys,    nullsys,
  43:     "tm",   tmstrategy, tmopen,     tmrew,
  44:     "ht",   htstrategy, htopen,     htclose,
  45:     0,0,0,0
  46: };

Defined functions

devclose defined in line 24; used 1 times
devopen defined in line 18; used 1 times
devread defined in line 5; used 5 times
devwrite defined in line 12; used 1 times
nullsys defined in line 30; used 7 times

Defined variables

devsw defined in line 39; used 4 times
Last modified: 1979-01-10
Generated: 2016-12-26
Generated by src2html V0.67
page hit count: 637
Valid CSS Valid XHTML 1.0 Strict