diff options
| author | Toomas Soome <tsoome@FreeBSD.org> | 2017-04-18 18:07:54 +0000 |
|---|---|---|
| committer | Toomas Soome <tsoome@FreeBSD.org> | 2017-04-18 18:07:54 +0000 |
| commit | c9296b32275a8b6766447dd78e73653102fb4fa7 (patch) | |
| tree | d3af4c26660dec91519954637d6e0efb8c17b209 /sys/boot/i386 | |
| parent | 31cfa79fab6273c8605129c5e26c8c029c3c6968 (diff) | |
Notes
Diffstat (limited to 'sys/boot/i386')
| -rw-r--r-- | sys/boot/i386/libi386/bioscd.c | 2 | ||||
| -rw-r--r-- | sys/boot/i386/libi386/biosdisk.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/sys/boot/i386/libi386/bioscd.c b/sys/boot/i386/libi386/bioscd.c index ba3be09c877c..2e8fc3b11b49 100644 --- a/sys/boot/i386/libi386/bioscd.c +++ b/sys/boot/i386/libi386/bioscd.c @@ -268,7 +268,7 @@ bc_realstrategy(void *devdata, int rw, daddr_t dblk, size_t size, return (EINVAL); #endif - if (rw != F_READ) + if ((rw & F_MASK) != F_READ) return(EROFS); dev = (struct i386_devdesc *)devdata; unit = dev->d_unit; diff --git a/sys/boot/i386/libi386/biosdisk.c b/sys/boot/i386/libi386/biosdisk.c index 188b8ebb9de8..b3597cccc06e 100644 --- a/sys/boot/i386/libi386/biosdisk.c +++ b/sys/boot/i386/libi386/biosdisk.c @@ -618,7 +618,7 @@ bd_realstrategy(void *devdata, int rw, daddr_t dblk, size_t size, DEBUG("short read %d", blks); } - switch(rw){ + switch (rw & F_MASK) { case F_READ: DEBUG("read %d from %lld to %p", blks, dblk, buf); |
