diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1995-12-14 04:25:01 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1995-12-14 04:25:01 +0000 |
commit | dd79441110b3311ff76301f49a0a640d84ead876 (patch) | |
tree | 63bd38bc00cfce361a1655aec7ed55e3e980d7bd /sys | |
parent | f4f54818989ab02ff8189a68093b1ed7fb626374 (diff) |
from netbsd:
"goto start" after sleeping for locked iso_node in cd9660_lock, like
in ufs_lock.
NBPG may not be computable by the preprocessor. Make "do clustered io"
a run-time decision. Note: the compiler can optimize it away.
Diffstat (limited to 'sys')
-rw-r--r-- | sys/isofs/cd9660/cd9660_vnops.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sys/isofs/cd9660/cd9660_vnops.c b/sys/isofs/cd9660/cd9660_vnops.c index ab530dafacb..73297218f70 100644 --- a/sys/isofs/cd9660/cd9660_vnops.c +++ b/sys/isofs/cd9660/cd9660_vnops.c @@ -1,4 +1,4 @@ -/* $NetBSD: cd9660_vnops.c,v 1.24 1995/07/24 21:19:27 cgd Exp $ */ +/* $NetBSD: cd9660_vnops.c,v 1.26 1995/12/01 00:47:33 pk Exp $ */ /*- * Copyright (c) 1994 @@ -233,16 +233,15 @@ cd9660_getattr(ap) return (0); } -#if ISO_DEFAULT_BLOCK_SIZE >= NBPG #ifdef DEBUG extern int doclusterread; #else #define doclusterread 1 #endif -#else + /* XXX until cluster routines can handle block sizes less than one page */ -#define doclusterread 0 -#endif +#define cd9660_doclusterread \ + (doclusterread && (ISO_DEFAULT_BLOCK_SIZE >= NBPG)) /* * Vnode op for reading. @@ -284,7 +283,7 @@ cd9660_read(ap) n = diff; size = blksize(imp, ip, lbn); rablock = lbn + 1; - if (doclusterread) { + if (cd9660_doclusterread) { if (lblktosize(imp, rablock) <= ip->i_size) error = cluster_read(vp, (off_t)ip->i_size, lbn, size, NOCRED, &bp); @@ -792,6 +791,7 @@ start: ip->i_lockwaiter = -1; #endif (void) sleep((caddr_t)ip, PINOD); + goto start; } #ifdef DIAGNOSTIC ip->i_lockwaiter = 0; |