Update raw-io functions as suggested by Charles.

This commit is contained in:
leo 1995-07-12 21:41:03 +00:00
parent d2551bdcaf
commit 8e01fc80af
1 changed files with 17 additions and 19 deletions

View File

@ -1,4 +1,4 @@
/* $NetBSD: ramd.c,v 1.2 1995/04/16 14:59:03 leo Exp $ */
/* $NetBSD: ramd.c,v 1.3 1995/07/12 21:41:03 leo Exp $ */
/*
* Copyright (c) 1995 Leo Weppelman.
@ -228,24 +228,6 @@ dev_t dev;
return(-1);
}
int
rdread(dev, uio)
dev_t dev;
struct uio *uio;
{
return (physio(cdevsw[major(dev)].d_strategy, (struct buf *)NULL,
dev, B_READ, rdminphys, uio));
}
int
rdwrite(dev, uio)
dev_t dev;
struct uio *uio;
{
return(physio(cdevsw[major(dev)].d_strategy, (struct buf *)NULL,
dev, B_WRITE, rdminphys, uio));
}
/* XXX: Limit to 64k. */
static void
rdminphys(bp)
@ -293,6 +275,22 @@ done:
biodone(bp);
}
int
rdread(dev, uio)
dev_t dev;
struct uio *uio;
{
return (physio(rdstrategy, (struct buf *)NULL, dev, B_READ, rdminphys, uio));
}
int
rdwrite(dev, uio)
dev_t dev;
struct uio *uio;
{
return(physio(rdstrategy, (struct buf *)NULL, dev, B_WRITE, rdminphys, uio));
}
static int
loaddisk(ri, proc)
struct ramd_info *ri;