Deleted Added
full compact
vfs_cluster.c (68885) vfs_cluster.c (70374)
1/*-
2 * Copyright (c) 1993
3 * The Regents of the University of California. All rights reserved.
4 * Modifications/enhancements:
5 * Copyright (c) 1995 John S. Dyson. All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 19 unchanged lines hidden (view full) ---

28 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
29 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
30 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
32 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 * SUCH DAMAGE.
34 *
35 * @(#)vfs_cluster.c 8.7 (Berkeley) 2/13/94
1/*-
2 * Copyright (c) 1993
3 * The Regents of the University of California. All rights reserved.
4 * Modifications/enhancements:
5 * Copyright (c) 1995 John S. Dyson. All rights reserved.
6 *
7 * Redistribution and use in source and binary forms, with or without
8 * modification, are permitted provided that the following conditions

--- 19 unchanged lines hidden (view full) ---

28 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
29 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
30 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
31 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
32 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
33 * SUCH DAMAGE.
34 *
35 * @(#)vfs_cluster.c 8.7 (Berkeley) 2/13/94
36 * $FreeBSD: head/sys/kern/vfs_cluster.c 68885 2000-11-18 23:06:26Z dillon $
36 * $FreeBSD: head/sys/kern/vfs_cluster.c 70374 2000-12-26 19:41:38Z dillon $
37 */
38
39#include "opt_debug_cluster.h"
40
41#include <sys/param.h>
42#include <sys/systm.h>
43#include <sys/kernel.h>
44#include <sys/proc.h>

--- 197 unchanged lines hidden (view full) ---

242 * handle the synchronous read
243 */
244 if (bp) {
245#if defined(CLUSTERDEBUG)
246 if (rcluster)
247 printf("S(%ld,%ld,%d) ",
248 (long)bp->b_lblkno, bp->b_bcount, seqcount);
249#endif
37 */
38
39#include "opt_debug_cluster.h"
40
41#include <sys/param.h>
42#include <sys/systm.h>
43#include <sys/kernel.h>
44#include <sys/proc.h>

--- 197 unchanged lines hidden (view full) ---

242 * handle the synchronous read
243 */
244 if (bp) {
245#if defined(CLUSTERDEBUG)
246 if (rcluster)
247 printf("S(%ld,%ld,%d) ",
248 (long)bp->b_lblkno, bp->b_bcount, seqcount);
249#endif
250 if ((bp->b_flags & B_CLUSTER) == 0)
250 if ((bp->b_flags & B_CLUSTER) == 0) {
251 vfs_busy_pages(bp, 0);
251 vfs_busy_pages(bp, 0);
252 } else {
253 bp->b_runningbufspace = bp->b_bufsize;
254 runningbufspace += bp->b_runningbufspace;
255 }
252 bp->b_flags &= ~B_INVAL;
253 bp->b_ioflags &= ~BIO_ERROR;
254 if ((bp->b_flags & B_ASYNC) || bp->b_iodone != NULL)
255 BUF_KERNPROC(bp);
256 error = VOP_STRATEGY(vp, bp);
257 curproc->p_stats->p_ru.ru_inblock++;
258 }
259

--- 18 unchanged lines hidden (view full) ---

278 else
279 printf("A(%ld,%ld,%ld,%d) ",
280 (long)rbp->b_lblkno, rbp->b_bcount,
281 (long)(rbp->b_lblkno - origblkno),
282 seqcount);
283 }
284#endif
285
256 bp->b_flags &= ~B_INVAL;
257 bp->b_ioflags &= ~BIO_ERROR;
258 if ((bp->b_flags & B_ASYNC) || bp->b_iodone != NULL)
259 BUF_KERNPROC(bp);
260 error = VOP_STRATEGY(vp, bp);
261 curproc->p_stats->p_ru.ru_inblock++;
262 }
263

--- 18 unchanged lines hidden (view full) ---

282 else
283 printf("A(%ld,%ld,%ld,%d) ",
284 (long)rbp->b_lblkno, rbp->b_bcount,
285 (long)(rbp->b_lblkno - origblkno),
286 seqcount);
287 }
288#endif
289
286 if ((rbp->b_flags & B_CLUSTER) == 0)
290 if ((rbp->b_flags & B_CLUSTER) == 0) {
287 vfs_busy_pages(rbp, 0);
291 vfs_busy_pages(rbp, 0);
292 } else {
293 rbp->b_runningbufspace = rbp->b_bufsize;
294 runningbufspace += rbp->b_runningbufspace;
295 }
288 rbp->b_flags &= ~B_INVAL;
289 rbp->b_ioflags &= ~BIO_ERROR;
290 if ((rbp->b_flags & B_ASYNC) || rbp->b_iodone != NULL)
291 BUF_KERNPROC(rbp);
292 (void) VOP_STRATEGY(vp, rbp);
293 curproc->p_stats->p_ru.ru_inblock++;
294 }
295 }

--- 616 unchanged lines hidden ---
296 rbp->b_flags &= ~B_INVAL;
297 rbp->b_ioflags &= ~BIO_ERROR;
298 if ((rbp->b_flags & B_ASYNC) || rbp->b_iodone != NULL)
299 BUF_KERNPROC(rbp);
300 (void) VOP_STRATEGY(vp, rbp);
301 curproc->p_stats->p_ru.ru_inblock++;
302 }
303 }

--- 616 unchanged lines hidden ---