aboutsummaryrefslogtreecommitdiff
path: root/sys/i386/boot/disk.c
diff options
context:
space:
mode:
authorsvn2git <svn2git@FreeBSD.org>1994-05-01 08:00:00 +0000
committersvn2git <svn2git@FreeBSD.org>1994-05-01 08:00:00 +0000
commita16f65c7d117419bd266c28a1901ef129a337569 (patch)
tree2626602f66dc3551e7a7c7bc9ad763c3bc7ab40a /sys/i386/boot/disk.c
parent8503f4f13f77abf7adc8f7e329c6f9c1d52b6a20 (diff)
Diffstat (limited to 'sys/i386/boot/disk.c')
-rw-r--r--sys/i386/boot/disk.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/sys/i386/boot/disk.c b/sys/i386/boot/disk.c
index 7e957de72ed3..1c7712f10517 100644
--- a/sys/i386/boot/disk.c
+++ b/sys/i386/boot/disk.c
@@ -24,7 +24,7 @@
* the rights to redistribute these changes.
*
* from: Mach, Revision 2.2 92/04/04 11:35:49 rpd
- * $Id: disk.c,v 1.3 1993/10/16 19:11:34 rgrimes Exp $
+ * $Id: disk.c,v 1.4 1994/02/22 22:59:40 rgrimes Exp $
*/
#include "boot.h"
@@ -166,13 +166,14 @@ devread()
*/
#define RA_SECTORS 18
static char ra_buf[RA_SECTORS * BPS];
+static int ra_dev;
static int ra_end;
static int ra_first;
Bread(dosdev,sector)
int dosdev,sector;
{
- if (sector < ra_first || sector >= ra_end)
+ if (dosdev != ra_dev || sector < ra_first || sector >= ra_end)
{
int cyl, head, sec, nsec;
@@ -192,6 +193,7 @@ Bread(dosdev,sector)
twiddle();
}
}
+ ra_dev = dosdev;
ra_first = sector;
ra_end = sector + nsec;
}