diff options
author | Poul-Henning Kamp <phk@FreeBSD.org> | 2000-05-05 09:59:14 +0000 |
---|---|---|
committer | Poul-Henning Kamp <phk@FreeBSD.org> | 2000-05-05 09:59:14 +0000 |
commit | 9626b608de4a43ec9984c3ee95b2ce624b3c0924 (patch) | |
tree | b1e53d453112b9bf26ef95be27ea84f2e9bdacf0 | |
parent | 33a0a551d439227028f2280faebe76b81c857cca (diff) |
Notes
182 files changed, 197 insertions, 612 deletions
diff --git a/sys/alpha/alpha/genassym.c b/sys/alpha/alpha/genassym.c index e3c5028e9e691..a67f2d11275c2 100644 --- a/sys/alpha/alpha/genassym.c +++ b/sys/alpha/alpha/genassym.c @@ -43,6 +43,7 @@ #include <sys/systm.h> #include <sys/assym.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/errno.h> #include <sys/proc.h> diff --git a/sys/alpha/alpha/machdep.c b/sys/alpha/alpha/machdep.c index b989c1bb701ef..041ea4e9dd826 100644 --- a/sys/alpha/alpha/machdep.c +++ b/sys/alpha/alpha/machdep.c @@ -103,6 +103,7 @@ #include <sys/lock.h> #include <sys/malloc.h> #include <sys/reboot.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mbuf.h> #include <sys/vmmeter.h> diff --git a/sys/alpha/alpha/vm_machdep.c b/sys/alpha/alpha/vm_machdep.c index 982f127add018..17fe494557022 100644 --- a/sys/alpha/alpha/vm_machdep.c +++ b/sys/alpha/alpha/vm_machdep.c @@ -71,6 +71,7 @@ #include <sys/systm.h> #include <sys/proc.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/vmmeter.h> diff --git a/sys/alpha/osf1/osf1_signal.c b/sys/alpha/osf1/osf1_signal.c index 8766130e64be0..5dd585ff9b7fa 100644 --- a/sys/alpha/osf1/osf1_signal.c +++ b/sys/alpha/osf1/osf1_signal.c @@ -42,6 +42,7 @@ #include <sys/lock.h> #include <sys/malloc.h> #include <sys/reboot.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mbuf.h> #include <sys/vmmeter.h> diff --git a/sys/alpha/tc/esp.c b/sys/alpha/tc/esp.c index 99eb45fb2d86c..e956811005f19 100644 --- a/sys/alpha/tc/esp.c +++ b/sys/alpha/tc/esp.c @@ -49,6 +49,7 @@ #include <sys/errno.h> /*#include <sys/ioctl.h>*/ +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> /*#include <sys/user.h>*/ diff --git a/sys/alpha/tc/tcds_dma.c b/sys/alpha/tc/tcds_dma.c index 00386fddfe577..cab19b4f3e7c9 100644 --- a/sys/alpha/tc/tcds_dma.c +++ b/sys/alpha/tc/tcds_dma.c @@ -38,6 +38,7 @@ #include <sys/errno.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <machine/clock.h> diff --git a/sys/amd64/amd64/genassym.c b/sys/amd64/amd64/genassym.c index 5a2377be0085c..60accd19ba8ee 100644 --- a/sys/amd64/amd64/genassym.c +++ b/sys/amd64/amd64/genassym.c @@ -44,6 +44,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/assym.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/errno.h> diff --git a/sys/amd64/amd64/machdep.c b/sys/amd64/amd64/machdep.c index fc2d564b37fd4..6ee89b0f84948 100644 --- a/sys/amd64/amd64/machdep.c +++ b/sys/amd64/amd64/machdep.c @@ -62,6 +62,7 @@ #include <sys/linker.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/reboot.h> #include <sys/callout.h> diff --git a/sys/amd64/amd64/vm_machdep.c b/sys/amd64/amd64/vm_machdep.c index d58e5a6538fbd..2ef55e4cef2fd 100644 --- a/sys/amd64/amd64/vm_machdep.c +++ b/sys/amd64/amd64/vm_machdep.c @@ -51,6 +51,7 @@ #include <sys/systm.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/vmmeter.h> diff --git a/sys/cam/cam_periph.c b/sys/cam/cam_periph.c index 080912bc5b08f..58ca810c429ca 100644 --- a/sys/cam/cam_periph.c +++ b/sys/cam/cam_periph.c @@ -34,6 +34,7 @@ #include <sys/types.h> #include <sys/malloc.h> #include <sys/linker_set.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/devicestat.h> diff --git a/sys/cam/scsi/scsi_cd.c b/sys/cam/scsi/scsi_cd.c index 0ca386ab686f6..3bd9437806fb3 100644 --- a/sys/cam/scsi/scsi_cd.c +++ b/sys/cam/scsi/scsi_cd.c @@ -51,7 +51,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #include <sys/disk.h> #include <sys/malloc.h> diff --git a/sys/cam/scsi/scsi_da.c b/sys/cam/scsi/scsi_da.c index 53ce964e355fd..94ed4afc4fa7c 100644 --- a/sys/cam/scsi/scsi_da.c +++ b/sys/cam/scsi/scsi_da.c @@ -33,7 +33,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/devicestat.h> #include <sys/conf.h> #include <sys/disk.h> diff --git a/sys/cam/scsi/scsi_pass.c b/sys/cam/scsi/scsi_pass.c index fe9015c37b8e9..46847f34cb400 100644 --- a/sys/cam/scsi/scsi_pass.c +++ b/sys/cam/scsi/scsi_pass.c @@ -31,7 +31,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/types.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/fcntl.h> #include <sys/stat.h> diff --git a/sys/cam/scsi/scsi_pt.c b/sys/cam/scsi/scsi_pt.c index 2f6e4db82250f..8f51ea8709b98 100644 --- a/sys/cam/scsi/scsi_pt.c +++ b/sys/cam/scsi/scsi_pt.c @@ -33,7 +33,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/types.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/devicestat.h> #include <sys/malloc.h> #include <sys/conf.h> diff --git a/sys/cam/scsi/scsi_sa.c b/sys/cam/scsi/scsi_sa.c index 1b9a9d0624429..f5d9f6df3ebc3 100644 --- a/sys/cam/scsi/scsi_sa.c +++ b/sys/cam/scsi/scsi_sa.c @@ -36,7 +36,7 @@ #include <sys/kernel.h> #endif #include <sys/types.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/mtio.h> #include <sys/conf.h> diff --git a/sys/cam/scsi/scsi_targ_bh.c b/sys/cam/scsi/scsi_targ_bh.c index a5a37971f13f5..ba80ac1950ca4 100644 --- a/sys/cam/scsi/scsi_targ_bh.c +++ b/sys/cam/scsi/scsi_targ_bh.c @@ -34,7 +34,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/types.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #include <sys/devicestat.h> #include <sys/malloc.h> diff --git a/sys/cam/scsi/scsi_target.c b/sys/cam/scsi/scsi_target.c index db064443c5e58..db27cacbb26cd 100644 --- a/sys/cam/scsi/scsi_target.c +++ b/sys/cam/scsi/scsi_target.c @@ -34,7 +34,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/types.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #include <sys/devicestat.h> #include <sys/malloc.h> diff --git a/sys/contrib/dev/fla/fla.c b/sys/contrib/dev/fla/fla.c index 59a1bf4ba8a86..e5f86a633bfb1 100644 --- a/sys/contrib/dev/fla/fla.c +++ b/sys/contrib/dev/fla/fla.c @@ -15,7 +15,7 @@ #include <sys/systm.h> #include <sys/sysctl.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/conf.h> #include <sys/disk.h> diff --git a/sys/contrib/softupdates/ffs_softdep.c b/sys/contrib/softupdates/ffs_softdep.c index 4b3807d2a54e3..ce48d430b574a 100644 --- a/sys/contrib/softupdates/ffs_softdep.c +++ b/sys/contrib/softupdates/ffs_softdep.c @@ -69,6 +69,7 @@ #include <sys/param.h> #include <sys/kernel.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/malloc.h> #include <sys/mount.h> diff --git a/sys/dev/amr/amr.c b/sys/dev/amr/amr.c index b81403e5998f5..380ea3693a50b 100644 --- a/sys/dev/amr/amr.c +++ b/sys/dev/amr/amr.c @@ -35,7 +35,7 @@ #include <sys/malloc.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/conf.h> #include <sys/devicestat.h> diff --git a/sys/dev/amr/amr_disk.c b/sys/dev/amr/amr_disk.c index 9d6be1d15c4c4..1e5082ad22c83 100644 --- a/sys/dev/amr/amr_disk.c +++ b/sys/dev/amr/amr_disk.c @@ -35,7 +35,7 @@ #include <sys/systm.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/conf.h> #include <sys/devicestat.h> diff --git a/sys/dev/amr/amr_pci.c b/sys/dev/amr/amr_pci.c index a144fcc960786..fc9f8a9ea2d44 100644 --- a/sys/dev/amr/amr_pci.c +++ b/sys/dev/amr/amr_pci.c @@ -31,7 +31,7 @@ #include <sys/kernel.h> #include <sys/bus.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #include <sys/devicestat.h> #include <sys/disk.h> diff --git a/sys/dev/ata/ata-all.c b/sys/dev/ata/ata-all.c index 17fa2efa36e6a..41e802fa170bd 100644 --- a/sys/dev/ata/ata-all.c +++ b/sys/dev/ata/ata-all.c @@ -44,7 +44,7 @@ #include <sys/disk.h> #include <sys/module.h> #include <sys/bus.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/devicestat.h> #include <sys/sysctl.h> diff --git a/sys/dev/ata/ata-disk.c b/sys/dev/ata/ata-disk.c index 2f0460fbff53d..627366c1d3711 100644 --- a/sys/dev/ata/ata-disk.c +++ b/sys/dev/ata/ata-disk.c @@ -36,7 +36,7 @@ #include <sys/kernel.h> #include <sys/proc.h> #include <sys/malloc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/conf.h> #include <sys/disk.h> diff --git a/sys/dev/ata/ata-dma.c b/sys/dev/ata/ata-dma.c index dc96bde13a114..cd586ca4650dd 100644 --- a/sys/dev/ata/ata-dma.c +++ b/sys/dev/ata/ata-dma.c @@ -31,7 +31,7 @@ #include "pci.h" #include <sys/param.h> #include <sys/systm.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/bus.h> #include <sys/disk.h> diff --git a/sys/dev/ata/atapi-cd.c b/sys/dev/ata/atapi-cd.c index 65b2ae50e0b3a..9cd87d200687a 100644 --- a/sys/dev/ata/atapi-cd.c +++ b/sys/dev/ata/atapi-cd.c @@ -33,7 +33,7 @@ #include <sys/kernel.h> #include <sys/proc.h> #include <sys/malloc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/disklabel.h> #include <sys/devicestat.h> diff --git a/sys/dev/ata/atapi-fd.c b/sys/dev/ata/atapi-fd.c index b1e2051fd3155..abeac0235770c 100644 --- a/sys/dev/ata/atapi-fd.c +++ b/sys/dev/ata/atapi-fd.c @@ -33,7 +33,7 @@ #include <sys/kernel.h> #include <sys/proc.h> #include <sys/malloc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/conf.h> #include <sys/disk.h> diff --git a/sys/dev/ata/atapi-tape.c b/sys/dev/ata/atapi-tape.c index 092891f282b4d..aaa2be70b5964 100644 --- a/sys/dev/ata/atapi-tape.c +++ b/sys/dev/ata/atapi-tape.c @@ -33,7 +33,7 @@ #include <sys/kernel.h> #include <sys/conf.h> #include <sys/malloc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/mtio.h> #include <sys/disklabel.h> diff --git a/sys/dev/ccd/ccd.c b/sys/dev/ccd/ccd.c index ad301ab266e7c..3f62c1ad51388 100644 --- a/sys/dev/ccd/ccd.c +++ b/sys/dev/ccd/ccd.c @@ -94,7 +94,7 @@ #include <sys/kernel.h> #include <sys/module.h> #include <sys/proc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/namei.h> #include <sys/conf.h> diff --git a/sys/dev/dpt/dpt_control.c b/sys/dev/dpt/dpt_control.c index 474eb8838b04d..ef3ddf2650498 100644 --- a/sys/dev/dpt/dpt_control.c +++ b/sys/dev/dpt/dpt_control.c @@ -45,6 +45,7 @@ #include <sys/systm.h> #include <sys/malloc.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/uio.h> #include <sys/conf.h> diff --git a/sys/dev/fdc/fdc.c b/sys/dev/fdc/fdc.c index cd4df134945b6..f3d47b47c29ad 100644 --- a/sys/dev/fdc/fdc.c +++ b/sys/dev/fdc/fdc.c @@ -57,6 +57,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/bus.h> #include <sys/conf.h> diff --git a/sys/dev/ida/ida.c b/sys/dev/ida/ida.c index e76c56a63c52e..d10986c813d07 100644 --- a/sys/dev/ida/ida.c +++ b/sys/dev/ida/ida.c @@ -44,7 +44,7 @@ #include <sys/systm.h> #include <sys/malloc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/devicestat.h> #include <sys/disk.h> diff --git a/sys/dev/ida/ida_disk.c b/sys/dev/ida/ida_disk.c index 72a6f04055a22..47e32a9191e8b 100644 --- a/sys/dev/ida/ida_disk.c +++ b/sys/dev/ida/ida_disk.c @@ -34,7 +34,7 @@ #include <sys/systm.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/conf.h> #include <sys/devicestat.h> diff --git a/sys/dev/ida/ida_eisa.c b/sys/dev/ida/ida_eisa.c index fd3fd29e20155..93b8bdf5e3fb2 100644 --- a/sys/dev/ida/ida_eisa.c +++ b/sys/dev/ida/ida_eisa.c @@ -32,7 +32,7 @@ #include <sys/kernel.h> #include <sys/bus.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/devicestat.h> #include <sys/disk.h> diff --git a/sys/dev/ida/ida_pci.c b/sys/dev/ida/ida_pci.c index 0bb7e9fa80adf..04cf5c7f75f0f 100644 --- a/sys/dev/ida/ida_pci.c +++ b/sys/dev/ida/ida_pci.c @@ -30,7 +30,7 @@ #include <sys/systm.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/devicestat.h> #include <sys/disk.h> diff --git a/sys/dev/mcd/mcd.c b/sys/dev/mcd/mcd.c index 1bdc7263aca62..aeb5e4cb3ee3c 100644 --- a/sys/dev/mcd/mcd.c +++ b/sys/dev/mcd/mcd.c @@ -49,7 +49,7 @@ static const char COPYRIGHT[] = "mcd-driver (C)1993 by H.Veit & B.Moore"; #include <sys/systm.h> #include <sys/conf.h> #include <sys/fcntl.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/cdio.h> #include <sys/disklabel.h> #include <sys/kernel.h> diff --git a/sys/dev/md/md.c b/sys/dev/md/md.c index 44a7cef4b7f05..3543a068bec98 100644 --- a/sys/dev/md/md.c +++ b/sys/dev/md/md.c @@ -15,7 +15,7 @@ #include <sys/param.h> #include <sys/systm.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #include <sys/devicestat.h> #include <sys/disk.h> diff --git a/sys/dev/mlx/mlx.c b/sys/dev/mlx/mlx.c index cc226e8891f84..942bebbe1cb51 100644 --- a/sys/dev/mlx/mlx.c +++ b/sys/dev/mlx/mlx.c @@ -35,7 +35,7 @@ #include <sys/malloc.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/conf.h> #include <sys/devicestat.h> diff --git a/sys/dev/mlx/mlx_disk.c b/sys/dev/mlx/mlx_disk.c index 15af6b7481fe4..190f7a785468e 100644 --- a/sys/dev/mlx/mlx_disk.c +++ b/sys/dev/mlx/mlx_disk.c @@ -35,7 +35,7 @@ #include <sys/systm.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/bus.h> #include <sys/conf.h> #include <sys/devicestat.h> diff --git a/sys/dev/mlx/mlx_pci.c b/sys/dev/mlx/mlx_pci.c index 6fe9a562126a1..9a5a658cc4e72 100644 --- a/sys/dev/mlx/mlx_pci.c +++ b/sys/dev/mlx/mlx_pci.c @@ -31,7 +31,7 @@ #include <sys/kernel.h> #include <sys/bus.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #include <sys/devicestat.h> #include <sys/disk.h> diff --git a/sys/dev/scd/scd.c b/sys/dev/scd/scd.c index d0ae35ed873ab..7c83434090049 100644 --- a/sys/dev/scd/scd.c +++ b/sys/dev/scd/scd.c @@ -51,7 +51,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/conf.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/cdio.h> #include <sys/disklabel.h> #include <sys/kernel.h> diff --git a/sys/dev/sound/pcm/sound.h b/sys/dev/sound/pcm/sound.h index e4565974084ba..9520c29b73978 100644 --- a/sys/dev/sound/pcm/sound.h +++ b/sys/dev/sound/pcm/sound.h @@ -55,6 +55,7 @@ #include <sys/errno.h> #include <sys/malloc.h> #include <sys/bus.h> +#include <sys/bio.h> #include <sys/buf.h> #include <machine/clock.h> /* for DELAY */ #include <machine/resource.h> diff --git a/sys/dev/usb/usb_mem.h b/sys/dev/usb/usb_mem.h index ac19b84240f18..35f08532f3a90 100644 --- a/sys/dev/usb/usb_mem.h +++ b/sys/dev/usb/usb_mem.h @@ -68,6 +68,7 @@ void usb_freemem __P((usbd_bus_handle, usb_dma_t *)); #include <sys/systm.h> #include <sys/queue.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/malloc.h> #include <sys/kernel.h> diff --git a/sys/dev/vinum/vinumhdr.h b/sys/dev/vinum/vinumhdr.h index 9fa4f58cc1b39..2f46ddfe71dd2 100644 --- a/sys/dev/vinum/vinumhdr.h +++ b/sys/dev/vinum/vinumhdr.h @@ -49,6 +49,7 @@ #include <sys/proc.h> #include <sys/errno.h> #include <sys/dkstat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/malloc.h> #include <sys/uio.h> diff --git a/sys/dev/vn/vn.c b/sys/dev/vn/vn.c index f8ba7e9912b41..b59e317a338d6 100644 --- a/sys/dev/vn/vn.c +++ b/sys/dev/vn/vn.c @@ -65,7 +65,7 @@ #include <sys/kernel.h> #include <sys/namei.h> #include <sys/proc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/mount.h> #include <sys/vnode.h> @@ -136,7 +136,6 @@ struct vn_softc { vm_object_t sc_object; /* backing object if not NULL */ struct ucred *sc_cred; /* credentials */ int sc_maxactive; /* max # of active requests */ - struct buf sc_tab; /* transfer queue */ u_long sc_options; /* options */ SLIST_ENTRY(vn_softc) sc_list; }; @@ -300,8 +299,8 @@ vnstrategy(struct bio *bp) IFOPT(vn, VN_LABELS) { if (vn->sc_slices != NULL && dscheck(bp, vn->sc_slices) <= 0) { - /* XXX: Normal B_ERROR processing, instead ? */ - bp->bio_flags |= B_INVAL; + bp->bio_error = EINVAL; + bp->bio_flags |= BIO_ERROR; biodone(bp); return; } @@ -316,7 +315,6 @@ vnstrategy(struct bio *bp) if (bp->bio_bcount % vn->sc_secsize != 0 || bp->bio_blkno % (vn->sc_secsize / DEV_BSIZE) != 0) { bp->bio_error = EINVAL; - /* XXX bp->b_flags |= B_INVAL; */ bp->bio_flags |= BIO_ERROR; biodone(bp); return; diff --git a/sys/fs/cd9660/cd9660_lookup.c b/sys/fs/cd9660/cd9660_lookup.c index b9aabbc7e2b88..1b58f44fd67f4 100644 --- a/sys/fs/cd9660/cd9660_lookup.c +++ b/sys/fs/cd9660/cd9660_lookup.c @@ -44,6 +44,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/namei.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/fs/cd9660/cd9660_node.c b/sys/fs/cd9660/cd9660_node.c index d7093fe3fd7f1..a1dfd391fd02a 100644 --- a/sys/fs/cd9660/cd9660_node.c +++ b/sys/fs/cd9660/cd9660_node.c @@ -43,6 +43,7 @@ #include <sys/systm.h> #include <sys/mount.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/fs/cd9660/cd9660_rrip.c b/sys/fs/cd9660/cd9660_rrip.c index b4f97a98e1123..5f0a262bd901c 100644 --- a/sys/fs/cd9660/cd9660_rrip.c +++ b/sys/fs/cd9660/cd9660_rrip.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/fs/cd9660/cd9660_vfsops.c b/sys/fs/cd9660/cd9660_vfsops.c index 6ec00f605d93c..a828540127022 100644 --- a/sys/fs/cd9660/cd9660_vfsops.c +++ b/sys/fs/cd9660/cd9660_vfsops.c @@ -46,6 +46,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/cdio.h> #include <sys/conf.h> diff --git a/sys/fs/cd9660/cd9660_vnops.c b/sys/fs/cd9660/cd9660_vnops.c index c685aa0369471..e4c6909af7959 100644 --- a/sys/fs/cd9660/cd9660_vnops.c +++ b/sys/fs/cd9660/cd9660_vnops.c @@ -44,6 +44,7 @@ #include <sys/namei.h> #include <sys/kernel.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> #include <sys/vnode.h> diff --git a/sys/fs/hpfs/hpfs_alsubr.c b/sys/fs/hpfs/hpfs_alsubr.c index 52ca645e70786..07d928ec2e15b 100644 --- a/sys/fs/hpfs/hpfs_alsubr.c +++ b/sys/fs/hpfs/hpfs_alsubr.c @@ -37,6 +37,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <fs/hpfs/hpfs.h> diff --git a/sys/fs/hpfs/hpfs_lookup.c b/sys/fs/hpfs/hpfs_lookup.c index 53fde4d200e68..88542cb2160be 100644 --- a/sys/fs/hpfs/hpfs_lookup.c +++ b/sys/fs/hpfs/hpfs_lookup.c @@ -37,6 +37,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <fs/hpfs/hpfs.h> diff --git a/sys/fs/hpfs/hpfs_subr.c b/sys/fs/hpfs/hpfs_subr.c index 4d60f92f72f8c..5fa32a5d9a7a1 100644 --- a/sys/fs/hpfs/hpfs_subr.c +++ b/sys/fs/hpfs/hpfs_subr.c @@ -37,6 +37,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <fs/hpfs/hpfs.h> diff --git a/sys/fs/hpfs/hpfs_vfsops.c b/sys/fs/hpfs/hpfs_vfsops.c index efbd013f2d60b..0bb10dd8b70ab 100644 --- a/sys/fs/hpfs/hpfs_vfsops.c +++ b/sys/fs/hpfs/hpfs_vfsops.c @@ -35,6 +35,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/fcntl.h> #include <sys/malloc.h> diff --git a/sys/fs/hpfs/hpfs_vnops.c b/sys/fs/hpfs/hpfs_vnops.c index 09668b1e860f4..4ab248c57669e 100644 --- a/sys/fs/hpfs/hpfs_vnops.c +++ b/sys/fs/hpfs/hpfs_vnops.c @@ -37,6 +37,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/dirent.h> diff --git a/sys/fs/msdosfs/msdosfs_denode.c b/sys/fs/msdosfs/msdosfs_denode.c index ea825397a4c7d..b7bf2cbbd2f5e 100644 --- a/sys/fs/msdosfs/msdosfs_denode.c +++ b/sys/fs/msdosfs/msdosfs_denode.c @@ -54,6 +54,7 @@ #include <sys/mount.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> diff --git a/sys/fs/msdosfs/msdosfs_fat.c b/sys/fs/msdosfs/msdosfs_fat.c index 1caad93b2a0c0..38abc16c46511 100644 --- a/sys/fs/msdosfs/msdosfs_fat.c +++ b/sys/fs/msdosfs/msdosfs_fat.c @@ -53,6 +53,7 @@ */ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> /* to define statfs structure */ #include <sys/vnode.h> /* to define vattr structure */ diff --git a/sys/fs/msdosfs/msdosfs_lookup.c b/sys/fs/msdosfs/msdosfs_lookup.c index 95e8e898ad305..edb71a69a0fe4 100644 --- a/sys/fs/msdosfs/msdosfs_lookup.c +++ b/sys/fs/msdosfs/msdosfs_lookup.c @@ -51,6 +51,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/namei.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/fs/msdosfs/msdosfs_vfsops.c b/sys/fs/msdosfs/msdosfs_vfsops.c index c090e61cd5889..84d8b7c2762d4 100644 --- a/sys/fs/msdosfs/msdosfs_vfsops.c +++ b/sys/fs/msdosfs/msdosfs_vfsops.c @@ -56,6 +56,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/fcntl.h> #include <sys/malloc.h> diff --git a/sys/fs/msdosfs/msdosfs_vnops.c b/sys/fs/msdosfs/msdosfs_vnops.c index 6209f662ba54d..302da21397b4e 100644 --- a/sys/fs/msdosfs/msdosfs_vnops.c +++ b/sys/fs/msdosfs/msdosfs_vnops.c @@ -54,6 +54,7 @@ #include <sys/resourcevar.h> /* defines plimit structure in proc struct */ #include <sys/kernel.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/fs/ntfs/ntfs_subr.c b/sys/fs/ntfs/ntfs_subr.c index 7a75972a3758b..e8f558800f0fe 100644 --- a/sys/fs/ntfs/ntfs_subr.c +++ b/sys/fs/ntfs/ntfs_subr.c @@ -36,6 +36,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/file.h> #include <sys/malloc.h> diff --git a/sys/fs/ntfs/ntfs_vfsops.c b/sys/fs/ntfs/ntfs_vfsops.c index ea58a6c10d042..77ac0d88e243d 100644 --- a/sys/fs/ntfs/ntfs_vfsops.c +++ b/sys/fs/ntfs/ntfs_vfsops.c @@ -37,6 +37,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/fcntl.h> #include <sys/malloc.h> diff --git a/sys/fs/ntfs/ntfs_vnops.c b/sys/fs/ntfs/ntfs_vnops.c index fdb555f1efb6f..e3db31f8d3abf 100644 --- a/sys/fs/ntfs/ntfs_vnops.c +++ b/sys/fs/ntfs/ntfs_vnops.c @@ -49,6 +49,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/dirent.h> diff --git a/sys/fs/nwfs/nwfs_io.c b/sys/fs/nwfs/nwfs_io.c index 2cf3e49def63f..c6b301ba2ab15 100644 --- a/sys/fs/nwfs/nwfs_io.c +++ b/sys/fs/nwfs/nwfs_io.c @@ -36,6 +36,7 @@ #include <sys/systm.h> #include <sys/resourcevar.h> /* defines plimit structure in proc struct */ #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/fs/nwfs/nwfs_vfsops.c b/sys/fs/nwfs/nwfs_vfsops.c index d9257afd69d3f..7be59e935f43f 100644 --- a/sys/fs/nwfs/nwfs_vfsops.c +++ b/sys/fs/nwfs/nwfs_vfsops.c @@ -45,6 +45,7 @@ #include <sys/mount.h> #include <sys/stat.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <netncp/ncp.h> diff --git a/sys/fs/nwfs/nwfs_vnops.c b/sys/fs/nwfs/nwfs_vnops.c index 0d6a20539cc34..505e561c1254e 100644 --- a/sys/fs/nwfs/nwfs_vnops.c +++ b/sys/fs/nwfs/nwfs_vnops.c @@ -35,6 +35,7 @@ #include <sys/systm.h> #include <sys/namei.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/fcntl.h> diff --git a/sys/fs/specfs/spec_vnops.c b/sys/fs/specfs/spec_vnops.c index 784142d1f49f6..85ffdbd363930 100644 --- a/sys/fs/specfs/spec_vnops.c +++ b/sys/fs/specfs/spec_vnops.c @@ -39,6 +39,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/conf.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> #include <sys/vnode.h> diff --git a/sys/fs/unionfs/union_vnops.c b/sys/fs/unionfs/union_vnops.c index 38c190b84723c..1c5ed5d5ff476 100644 --- a/sys/fs/unionfs/union_vnops.c +++ b/sys/fs/unionfs/union_vnops.c @@ -48,6 +48,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/lock.h> #include <sys/sysctl.h> diff --git a/sys/geom/geom_ccd.c b/sys/geom/geom_ccd.c index ad301ab266e7c..3f62c1ad51388 100644 --- a/sys/geom/geom_ccd.c +++ b/sys/geom/geom_ccd.c @@ -94,7 +94,7 @@ #include <sys/kernel.h> #include <sys/module.h> #include <sys/proc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/malloc.h> #include <sys/namei.h> #include <sys/conf.h> diff --git a/sys/gnu/ext2fs/ext2_balloc.c b/sys/gnu/ext2fs/ext2_balloc.c index 2b485c6467aef..75c17e5ad9700 100644 --- a/sys/gnu/ext2fs/ext2_balloc.c +++ b/sys/gnu/ext2fs/ext2_balloc.c @@ -37,10 +37,12 @@ * SUCH DAMAGE. * * @(#)ffs_balloc.c 8.4 (Berkeley) 9/23/93 + * $FreeBSD$ */ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/lock.h> #include <sys/ucred.h> diff --git a/sys/gnu/ext2fs/ext2_bmap.c b/sys/gnu/ext2fs/ext2_bmap.c index c24f507f36c29..90563401bb918 100644 --- a/sys/gnu/ext2fs/ext2_bmap.c +++ b/sys/gnu/ext2fs/ext2_bmap.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/vnode.h> diff --git a/sys/gnu/ext2fs/ext2_inode.c b/sys/gnu/ext2fs/ext2_inode.c index 967dacf5e8354..95c25afa53619 100644 --- a/sys/gnu/ext2fs/ext2_inode.c +++ b/sys/gnu/ext2fs/ext2_inode.c @@ -46,6 +46,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/gnu/ext2fs/ext2_linux_balloc.c b/sys/gnu/ext2fs/ext2_linux_balloc.c index 3e5b7d18ba25b..2651d88e77423 100644 --- a/sys/gnu/ext2fs/ext2_linux_balloc.c +++ b/sys/gnu/ext2fs/ext2_linux_balloc.c @@ -30,6 +30,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/gnu/ext2fs/ext2_linux_ialloc.c b/sys/gnu/ext2fs/ext2_linux_ialloc.c index 0419ef6f6a7b8..da03c51adaa4a 100644 --- a/sys/gnu/ext2fs/ext2_linux_ialloc.c +++ b/sys/gnu/ext2fs/ext2_linux_ialloc.c @@ -31,6 +31,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/gnu/ext2fs/ext2_lookup.c b/sys/gnu/ext2fs/ext2_lookup.c index a13b5e059097c..e161534df0264 100644 --- a/sys/gnu/ext2fs/ext2_lookup.c +++ b/sys/gnu/ext2fs/ext2_lookup.c @@ -51,6 +51,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/namei.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> #include <sys/vnode.h> diff --git a/sys/gnu/ext2fs/ext2_subr.c b/sys/gnu/ext2fs/ext2_subr.c index 8ceac7444bd9e..3ded73816ffd5 100644 --- a/sys/gnu/ext2fs/ext2_subr.c +++ b/sys/gnu/ext2fs/ext2_subr.c @@ -37,6 +37,7 @@ * SUCH DAMAGE. * * @(#)ext2_subr.c 8.2 (Berkeley) 9/21/93 + * $FreeBSD$ */ #include <sys/param.h> @@ -48,6 +49,7 @@ #include <sys/ucred.h> #include <sys/vnode.h> #include <gnu/ext2fs/ext2_extern.h> +#include <sys/bio.h> #include <sys/buf.h> #include <ufs/ufs/quota.h> #include <ufs/ufs/inode.h> diff --git a/sys/gnu/ext2fs/ext2_vfsops.c b/sys/gnu/ext2fs/ext2_vfsops.c index 3602c51070c6e..b2f07f512ef0e 100644 --- a/sys/gnu/ext2fs/ext2_vfsops.c +++ b/sys/gnu/ext2fs/ext2_vfsops.c @@ -49,6 +49,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/fcntl.h> diff --git a/sys/gnu/ext2fs/ext2_vnops.c b/sys/gnu/ext2fs/ext2_vnops.c index 7b688f3bb88aa..b96e01c64bdde 100644 --- a/sys/gnu/ext2fs/ext2_vnops.c +++ b/sys/gnu/ext2fs/ext2_vnops.c @@ -54,6 +54,7 @@ #include <sys/resourcevar.h> #include <sys/kernel.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/gnu/fs/ext2fs/ext2_balloc.c b/sys/gnu/fs/ext2fs/ext2_balloc.c index 2b485c6467aef..75c17e5ad9700 100644 --- a/sys/gnu/fs/ext2fs/ext2_balloc.c +++ b/sys/gnu/fs/ext2fs/ext2_balloc.c @@ -37,10 +37,12 @@ * SUCH DAMAGE. * * @(#)ffs_balloc.c 8.4 (Berkeley) 9/23/93 + * $FreeBSD$ */ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/lock.h> #include <sys/ucred.h> diff --git a/sys/gnu/fs/ext2fs/ext2_bmap.c b/sys/gnu/fs/ext2fs/ext2_bmap.c index c24f507f36c29..90563401bb918 100644 --- a/sys/gnu/fs/ext2fs/ext2_bmap.c +++ b/sys/gnu/fs/ext2fs/ext2_bmap.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/vnode.h> diff --git a/sys/gnu/fs/ext2fs/ext2_inode.c b/sys/gnu/fs/ext2fs/ext2_inode.c index 967dacf5e8354..95c25afa53619 100644 --- a/sys/gnu/fs/ext2fs/ext2_inode.c +++ b/sys/gnu/fs/ext2fs/ext2_inode.c @@ -46,6 +46,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/gnu/fs/ext2fs/ext2_linux_balloc.c b/sys/gnu/fs/ext2fs/ext2_linux_balloc.c index 3e5b7d18ba25b..2651d88e77423 100644 --- a/sys/gnu/fs/ext2fs/ext2_linux_balloc.c +++ b/sys/gnu/fs/ext2fs/ext2_linux_balloc.c @@ -30,6 +30,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/gnu/fs/ext2fs/ext2_linux_ialloc.c b/sys/gnu/fs/ext2fs/ext2_linux_ialloc.c index 0419ef6f6a7b8..da03c51adaa4a 100644 --- a/sys/gnu/fs/ext2fs/ext2_linux_ialloc.c +++ b/sys/gnu/fs/ext2fs/ext2_linux_ialloc.c @@ -31,6 +31,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/gnu/fs/ext2fs/ext2_lookup.c b/sys/gnu/fs/ext2fs/ext2_lookup.c index a13b5e059097c..e161534df0264 100644 --- a/sys/gnu/fs/ext2fs/ext2_lookup.c +++ b/sys/gnu/fs/ext2fs/ext2_lookup.c @@ -51,6 +51,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/namei.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> #include <sys/vnode.h> diff --git a/sys/gnu/fs/ext2fs/ext2_subr.c b/sys/gnu/fs/ext2fs/ext2_subr.c index 8ceac7444bd9e..3ded73816ffd5 100644 --- a/sys/gnu/fs/ext2fs/ext2_subr.c +++ b/sys/gnu/fs/ext2fs/ext2_subr.c @@ -37,6 +37,7 @@ * SUCH DAMAGE. * * @(#)ext2_subr.c 8.2 (Berkeley) 9/21/93 + * $FreeBSD$ */ #include <sys/param.h> @@ -48,6 +49,7 @@ #include <sys/ucred.h> #include <sys/vnode.h> #include <gnu/ext2fs/ext2_extern.h> +#include <sys/bio.h> #include <sys/buf.h> #include <ufs/ufs/quota.h> #include <ufs/ufs/inode.h> diff --git a/sys/gnu/fs/ext2fs/ext2_vfsops.c b/sys/gnu/fs/ext2fs/ext2_vfsops.c index 3602c51070c6e..b2f07f512ef0e 100644 --- a/sys/gnu/fs/ext2fs/ext2_vfsops.c +++ b/sys/gnu/fs/ext2fs/ext2_vfsops.c @@ -49,6 +49,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/fcntl.h> diff --git a/sys/gnu/fs/ext2fs/ext2_vnops.c b/sys/gnu/fs/ext2fs/ext2_vnops.c index 7b688f3bb88aa..b96e01c64bdde 100644 --- a/sys/gnu/fs/ext2fs/ext2_vnops.c +++ b/sys/gnu/fs/ext2fs/ext2_vnops.c @@ -54,6 +54,7 @@ #include <sys/resourcevar.h> #include <sys/kernel.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/i386/i386/genassym.c b/sys/i386/i386/genassym.c index 5a2377be0085c..60accd19ba8ee 100644 --- a/sys/i386/i386/genassym.c +++ b/sys/i386/i386/genassym.c @@ -44,6 +44,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/assym.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/errno.h> diff --git a/sys/i386/i386/machdep.c b/sys/i386/i386/machdep.c index fc2d564b37fd4..6ee89b0f84948 100644 --- a/sys/i386/i386/machdep.c +++ b/sys/i386/i386/machdep.c @@ -62,6 +62,7 @@ #include <sys/linker.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/reboot.h> #include <sys/callout.h> diff --git a/sys/i386/i386/vm_machdep.c b/sys/i386/i386/vm_machdep.c index d58e5a6538fbd..2ef55e4cef2fd 100644 --- a/sys/i386/i386/vm_machdep.c +++ b/sys/i386/i386/vm_machdep.c @@ -51,6 +51,7 @@ #include <sys/systm.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/vmmeter.h> diff --git a/sys/i386/isa/bs/bsif.h b/sys/i386/isa/bs/bsif.h index 431189432b7de..5a89681bcce0e 100644 --- a/sys/i386/isa/bs/bsif.h +++ b/sys/i386/isa/bs/bsif.h @@ -75,7 +75,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/disklabel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/queue.h> #include <sys/malloc.h> #include <sys/errno.h> diff --git a/sys/i386/isa/labpc.c b/sys/i386/isa/labpc.c index ba59bc840db18..c3c06b770adc9 100644 --- a/sys/i386/isa/labpc.c +++ b/sys/i386/isa/labpc.c @@ -50,7 +50,7 @@ #include <sys/kernel.h> #include <sys/malloc.h> -#include <sys/buf.h> +#include <sys/bio.h> #define b_actf bio_queue.tqe_next #include <sys/dataacq.h> #include <sys/conf.h> diff --git a/sys/i386/isa/matcd/matcd.c b/sys/i386/isa/matcd/matcd.c index 4b48446d09932..b056a848ea61f 100644 --- a/sys/i386/isa/matcd/matcd.c +++ b/sys/i386/isa/matcd/matcd.c @@ -348,7 +348,7 @@ static char MATCDCOPYRIGHT[] = "Matsushita CD-ROM driver, Copr. 1994,1995 Frank #include <sys/param.h> #include <sys/systm.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/cdio.h> #include <sys/disklabel.h> #include <sys/fcntl.h> diff --git a/sys/i386/isa/mcd.c b/sys/i386/isa/mcd.c index 1bdc7263aca62..aeb5e4cb3ee3c 100644 --- a/sys/i386/isa/mcd.c +++ b/sys/i386/isa/mcd.c @@ -49,7 +49,7 @@ static const char COPYRIGHT[] = "mcd-driver (C)1993 by H.Veit & B.Moore"; #include <sys/systm.h> #include <sys/conf.h> #include <sys/fcntl.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/cdio.h> #include <sys/disklabel.h> #include <sys/kernel.h> diff --git a/sys/i386/isa/scd.c b/sys/i386/isa/scd.c index d0ae35ed873ab..7c83434090049 100644 --- a/sys/i386/isa/scd.c +++ b/sys/i386/isa/scd.c @@ -51,7 +51,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/conf.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/cdio.h> #include <sys/disklabel.h> #include <sys/kernel.h> diff --git a/sys/i386/isa/sound/os.h b/sys/i386/isa/sound/os.h index 1abc45b87e6d4..fb9400895bcbd 100644 --- a/sys/i386/isa/sound/os.h +++ b/sys/i386/isa/sound/os.h @@ -1,6 +1,7 @@ /* * os.h -- only included by sound_config.h right after local.h * + * $FreeBSD$ */ #ifndef _OS_H_ @@ -16,6 +17,7 @@ #include <sys/kernel.h> #include <sys/poll.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/signalvar.h> diff --git a/sys/i386/isa/wt.c b/sys/i386/isa/wt.c index f6e65a5e548a5..c6b46e490f37f 100644 --- a/sys/i386/isa/wt.c +++ b/sys/i386/isa/wt.c @@ -62,7 +62,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/fcntl.h> #include <sys/malloc.h> #include <sys/mtio.h> diff --git a/sys/isa/fd.c b/sys/isa/fd.c index cd4df134945b6..f3d47b47c29ad 100644 --- a/sys/isa/fd.c +++ b/sys/isa/fd.c @@ -57,6 +57,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/bus.h> #include <sys/conf.h> diff --git a/sys/isofs/cd9660/cd9660_lookup.c b/sys/isofs/cd9660/cd9660_lookup.c index b9aabbc7e2b88..1b58f44fd67f4 100644 --- a/sys/isofs/cd9660/cd9660_lookup.c +++ b/sys/isofs/cd9660/cd9660_lookup.c @@ -44,6 +44,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/namei.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/isofs/cd9660/cd9660_node.c b/sys/isofs/cd9660/cd9660_node.c index d7093fe3fd7f1..a1dfd391fd02a 100644 --- a/sys/isofs/cd9660/cd9660_node.c +++ b/sys/isofs/cd9660/cd9660_node.c @@ -43,6 +43,7 @@ #include <sys/systm.h> #include <sys/mount.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/isofs/cd9660/cd9660_rrip.c b/sys/isofs/cd9660/cd9660_rrip.c index b4f97a98e1123..5f0a262bd901c 100644 --- a/sys/isofs/cd9660/cd9660_rrip.c +++ b/sys/isofs/cd9660/cd9660_rrip.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/isofs/cd9660/cd9660_vfsops.c b/sys/isofs/cd9660/cd9660_vfsops.c index 6ec00f605d93c..a828540127022 100644 --- a/sys/isofs/cd9660/cd9660_vfsops.c +++ b/sys/isofs/cd9660/cd9660_vfsops.c @@ -46,6 +46,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/cdio.h> #include <sys/conf.h> diff --git a/sys/isofs/cd9660/cd9660_vnops.c b/sys/isofs/cd9660/cd9660_vnops.c index c685aa0369471..e4c6909af7959 100644 --- a/sys/isofs/cd9660/cd9660_vnops.c +++ b/sys/isofs/cd9660/cd9660_vnops.c @@ -44,6 +44,7 @@ #include <sys/namei.h> #include <sys/kernel.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> #include <sys/vnode.h> diff --git a/sys/kern/kern_mib.c b/sys/kern/kern_mib.c index 375b50014ddd6..35c70fb19b17e 100644 --- a/sys/kern/kern_mib.c +++ b/sys/kern/kern_mib.c @@ -247,6 +247,7 @@ SYSCTL_INT(_debug_sizeof, OID_AUTO, proc, CTLFLAG_RD, SYSCTL_INT(_debug_sizeof, OID_AUTO, specinfo, CTLFLAG_RD, 0, sizeof(struct specinfo), "sizeof(struct specinfo)"); +#include <sys/bio.h> #include <sys/buf.h> SYSCTL_INT(_debug_sizeof, OID_AUTO, bio, CTLFLAG_RD, 0, sizeof(struct bio), "sizeof(struct bio)"); diff --git a/sys/kern/kern_physio.c b/sys/kern/kern_physio.c index 62df11cde4829..a83cada3013d7 100644 --- a/sys/kern/kern_physio.c +++ b/sys/kern/kern_physio.c @@ -21,6 +21,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/proc.h> diff --git a/sys/kern/kern_shutdown.c b/sys/kern/kern_shutdown.c index e4a4696ccbeeb..18cd1a4fde7b8 100644 --- a/sys/kern/kern_shutdown.c +++ b/sys/kern/kern_shutdown.c @@ -47,6 +47,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/eventhandler.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/reboot.h> #include <sys/proc.h> diff --git a/sys/kern/subr_devstat.c b/sys/kern/subr_devstat.c index c86d16b966f30..503564110ce36 100644 --- a/sys/kern/subr_devstat.c +++ b/sys/kern/subr_devstat.c @@ -31,6 +31,7 @@ #include <sys/param.h> #include <sys/kernel.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/sysctl.h> diff --git a/sys/kern/subr_disk.c b/sys/kern/subr_disk.c index cf25c1b1ad5f4..c600d384e19c1 100644 --- a/sys/kern/subr_disk.c +++ b/sys/kern/subr_disk.c @@ -14,7 +14,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/sysctl.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #include <sys/disk.h> #include <sys/malloc.h> diff --git a/sys/kern/subr_disklabel.c b/sys/kern/subr_disklabel.c index fc7fb28cec704..ed68f3818b437 100644 --- a/sys/kern/subr_disklabel.c +++ b/sys/kern/subr_disklabel.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/disklabel.h> diff --git a/sys/kern/subr_diskmbr.c b/sys/kern/subr_diskmbr.c index 13e4387036383..842fed1378086 100644 --- a/sys/kern/subr_diskmbr.c +++ b/sys/kern/subr_diskmbr.c @@ -40,6 +40,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #ifdef PC98 diff --git a/sys/kern/subr_diskslice.c b/sys/kern/subr_diskslice.c index 1e7d6c4a54398..68df0db5905d6 100644 --- a/sys/kern/subr_diskslice.c +++ b/sys/kern/subr_diskslice.c @@ -52,7 +52,7 @@ #include <sys/param.h> #include <sys/systm.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/conf.h> #ifdef DEVFS #include <sys/devfsext.h> diff --git a/sys/kern/vfs_aio.c b/sys/kern/vfs_aio.c index 0e91fdf4196fb..16867cd95122f 100644 --- a/sys/kern/vfs_aio.c +++ b/sys/kern/vfs_aio.c @@ -22,6 +22,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/sysproto.h> #include <sys/filedesc.h> diff --git a/sys/kern/vfs_bio.c b/sys/kern/vfs_bio.c index 025d030958845..93e4620f2a935 100644 --- a/sys/kern/vfs_bio.c +++ b/sys/kern/vfs_bio.c @@ -29,6 +29,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/eventhandler.h> #include <sys/lock.h> diff --git a/sys/kern/vfs_cluster.c b/sys/kern/vfs_cluster.c index caf35c436edc2..e1c05b02a5e21 100644 --- a/sys/kern/vfs_cluster.c +++ b/sys/kern/vfs_cluster.c @@ -42,6 +42,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/kern/vfs_default.c b/sys/kern/vfs_default.c index b362ff1d7719b..f478aa2b2d215 100644 --- a/sys/kern/vfs_default.c +++ b/sys/kern/vfs_default.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/kernel.h> #include <sys/lock.h> diff --git a/sys/kern/vfs_export.c b/sys/kern/vfs_export.c index 273829b3b675b..662085265cef2 100644 --- a/sys/kern/vfs_export.c +++ b/sys/kern/vfs_export.c @@ -46,6 +46,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/dirent.h> diff --git a/sys/kern/vfs_extattr.c b/sys/kern/vfs_extattr.c index 99084d332ed62..08e2965b3dbdc 100644 --- a/sys/kern/vfs_extattr.c +++ b/sys/kern/vfs_extattr.c @@ -44,6 +44,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/sysent.h> #include <sys/malloc.h> diff --git a/sys/kern/vfs_subr.c b/sys/kern/vfs_subr.c index 273829b3b675b..662085265cef2 100644 --- a/sys/kern/vfs_subr.c +++ b/sys/kern/vfs_subr.c @@ -46,6 +46,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/dirent.h> diff --git a/sys/kern/vfs_syscalls.c b/sys/kern/vfs_syscalls.c index 99084d332ed62..08e2965b3dbdc 100644 --- a/sys/kern/vfs_syscalls.c +++ b/sys/kern/vfs_syscalls.c @@ -44,6 +44,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/sysent.h> #include <sys/malloc.h> diff --git a/sys/kern/vfs_vnops.c b/sys/kern/vfs_vnops.c index 0df42d9e78e81..e8f2713f84d2e 100644 --- a/sys/kern/vfs_vnops.c +++ b/sys/kern/vfs_vnops.c @@ -48,6 +48,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/vnode.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/filio.h> #include <sys/ttycom.h> diff --git a/sys/miscfs/devfs/devfs_vnops.c b/sys/miscfs/devfs/devfs_vnops.c index 3ec62f88b4d68..e716d0fa3d4cd 100644 --- a/sys/miscfs/devfs/devfs_vnops.c +++ b/sys/miscfs/devfs/devfs_vnops.c @@ -28,6 +28,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/namei.h> #include <sys/kernel.h> diff --git a/sys/miscfs/specfs/spec_vnops.c b/sys/miscfs/specfs/spec_vnops.c index 784142d1f49f6..85ffdbd363930 100644 --- a/sys/miscfs/specfs/spec_vnops.c +++ b/sys/miscfs/specfs/spec_vnops.c @@ -39,6 +39,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/conf.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> #include <sys/vnode.h> diff --git a/sys/miscfs/union/union_vnops.c b/sys/miscfs/union/union_vnops.c index 38c190b84723c..1c5ed5d5ff476 100644 --- a/sys/miscfs/union/union_vnops.c +++ b/sys/miscfs/union/union_vnops.c @@ -48,6 +48,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/lock.h> #include <sys/sysctl.h> diff --git a/sys/msdosfs/msdosfs_denode.c b/sys/msdosfs/msdosfs_denode.c index ea825397a4c7d..b7bf2cbbd2f5e 100644 --- a/sys/msdosfs/msdosfs_denode.c +++ b/sys/msdosfs/msdosfs_denode.c @@ -54,6 +54,7 @@ #include <sys/mount.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> diff --git a/sys/msdosfs/msdosfs_fat.c b/sys/msdosfs/msdosfs_fat.c index 1caad93b2a0c0..38abc16c46511 100644 --- a/sys/msdosfs/msdosfs_fat.c +++ b/sys/msdosfs/msdosfs_fat.c @@ -53,6 +53,7 @@ */ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> /* to define statfs structure */ #include <sys/vnode.h> /* to define vattr structure */ diff --git a/sys/msdosfs/msdosfs_lookup.c b/sys/msdosfs/msdosfs_lookup.c index 95e8e898ad305..edb71a69a0fe4 100644 --- a/sys/msdosfs/msdosfs_lookup.c +++ b/sys/msdosfs/msdosfs_lookup.c @@ -51,6 +51,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/namei.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/msdosfs/msdosfs_vfsops.c b/sys/msdosfs/msdosfs_vfsops.c index c090e61cd5889..84d8b7c2762d4 100644 --- a/sys/msdosfs/msdosfs_vfsops.c +++ b/sys/msdosfs/msdosfs_vfsops.c @@ -56,6 +56,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/fcntl.h> #include <sys/malloc.h> diff --git a/sys/msdosfs/msdosfs_vnops.c b/sys/msdosfs/msdosfs_vnops.c index 6209f662ba54d..302da21397b4e 100644 --- a/sys/msdosfs/msdosfs_vnops.c +++ b/sys/msdosfs/msdosfs_vnops.c @@ -54,6 +54,7 @@ #include <sys/resourcevar.h> /* defines plimit structure in proc struct */ #include <sys/kernel.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/nfs/nfs_bio.c b/sys/nfs/nfs_bio.c index 6923feb9e059e..09585bff6c00b 100644 --- a/sys/nfs/nfs_bio.c +++ b/sys/nfs/nfs_bio.c @@ -43,6 +43,7 @@ #include <sys/resourcevar.h> #include <sys/signalvar.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/nfs/nfs_common.c b/sys/nfs/nfs_common.c index dbbb4dd906332..70e871fc4db0b 100644 --- a/sys/nfs/nfs_common.c +++ b/sys/nfs/nfs_common.c @@ -45,6 +45,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/nfs/nfs_serv.c b/sys/nfs/nfs_serv.c index 6aad427c12ca3..06ce9ed1d34e6 100644 --- a/sys/nfs/nfs_serv.c +++ b/sys/nfs/nfs_serv.c @@ -85,6 +85,7 @@ #include <sys/stat.h> #include <sys/kernel.h> #include <sys/sysctl.h> +#include <sys/bio.h> #include <sys/buf.h> #include <vm/vm.h> diff --git a/sys/nfs/nfs_subs.c b/sys/nfs/nfs_subs.c index dbbb4dd906332..70e871fc4db0b 100644 --- a/sys/nfs/nfs_subs.c +++ b/sys/nfs/nfs_subs.c @@ -45,6 +45,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/nfs/nfs_syscalls.c b/sys/nfs/nfs_syscalls.c index ead5b86032416..1e0162fc8bab2 100644 --- a/sys/nfs/nfs_syscalls.c +++ b/sys/nfs/nfs_syscalls.c @@ -48,6 +48,7 @@ #include <sys/malloc.h> #include <sys/mount.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mbuf.h> #include <sys/socket.h> diff --git a/sys/nfs/nfs_vnops.c b/sys/nfs/nfs_vnops.c index 27fe3c8ac00e3..91f9435bc7753 100644 --- a/sys/nfs/nfs_vnops.c +++ b/sys/nfs/nfs_vnops.c @@ -50,6 +50,7 @@ #include <sys/resourcevar.h> #include <sys/proc.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/malloc.h> #include <sys/mbuf.h> diff --git a/sys/nfsclient/nfs_bio.c b/sys/nfsclient/nfs_bio.c index 6923feb9e059e..09585bff6c00b 100644 --- a/sys/nfsclient/nfs_bio.c +++ b/sys/nfsclient/nfs_bio.c @@ -43,6 +43,7 @@ #include <sys/resourcevar.h> #include <sys/signalvar.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/mount.h> diff --git a/sys/nfsclient/nfs_nfsiod.c b/sys/nfsclient/nfs_nfsiod.c index ead5b86032416..1e0162fc8bab2 100644 --- a/sys/nfsclient/nfs_nfsiod.c +++ b/sys/nfsclient/nfs_nfsiod.c @@ -48,6 +48,7 @@ #include <sys/malloc.h> #include <sys/mount.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mbuf.h> #include <sys/socket.h> diff --git a/sys/nfsclient/nfs_subs.c b/sys/nfsclient/nfs_subs.c index dbbb4dd906332..70e871fc4db0b 100644 --- a/sys/nfsclient/nfs_subs.c +++ b/sys/nfsclient/nfs_subs.c @@ -45,6 +45,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/nfsclient/nfs_vnops.c b/sys/nfsclient/nfs_vnops.c index 27fe3c8ac00e3..91f9435bc7753 100644 --- a/sys/nfsclient/nfs_vnops.c +++ b/sys/nfsclient/nfs_vnops.c @@ -50,6 +50,7 @@ #include <sys/resourcevar.h> #include <sys/proc.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/malloc.h> #include <sys/mbuf.h> diff --git a/sys/nfsserver/nfs_serv.c b/sys/nfsserver/nfs_serv.c index 6aad427c12ca3..06ce9ed1d34e6 100644 --- a/sys/nfsserver/nfs_serv.c +++ b/sys/nfsserver/nfs_serv.c @@ -85,6 +85,7 @@ #include <sys/stat.h> #include <sys/kernel.h> #include <sys/sysctl.h> +#include <sys/bio.h> #include <sys/buf.h> #include <vm/vm.h> diff --git a/sys/nfsserver/nfs_srvsubs.c b/sys/nfsserver/nfs_srvsubs.c index dbbb4dd906332..70e871fc4db0b 100644 --- a/sys/nfsserver/nfs_srvsubs.c +++ b/sys/nfsserver/nfs_srvsubs.c @@ -45,6 +45,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/nfsserver/nfs_syscalls.c b/sys/nfsserver/nfs_syscalls.c index ead5b86032416..1e0162fc8bab2 100644 --- a/sys/nfsserver/nfs_syscalls.c +++ b/sys/nfsserver/nfs_syscalls.c @@ -48,6 +48,7 @@ #include <sys/malloc.h> #include <sys/mount.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mbuf.h> #include <sys/socket.h> diff --git a/sys/ntfs/ntfs_subr.c b/sys/ntfs/ntfs_subr.c index 7a75972a3758b..e8f558800f0fe 100644 --- a/sys/ntfs/ntfs_subr.c +++ b/sys/ntfs/ntfs_subr.c @@ -36,6 +36,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/file.h> #include <sys/malloc.h> diff --git a/sys/ntfs/ntfs_vfsops.c b/sys/ntfs/ntfs_vfsops.c index ea58a6c10d042..77ac0d88e243d 100644 --- a/sys/ntfs/ntfs_vfsops.c +++ b/sys/ntfs/ntfs_vfsops.c @@ -37,6 +37,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/fcntl.h> #include <sys/malloc.h> diff --git a/sys/ntfs/ntfs_vnops.c b/sys/ntfs/ntfs_vnops.c index fdb555f1efb6f..e3db31f8d3abf 100644 --- a/sys/ntfs/ntfs_vnops.c +++ b/sys/ntfs/ntfs_vnops.c @@ -49,6 +49,7 @@ #include <sys/mount.h> #include <sys/namei.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/dirent.h> diff --git a/sys/nwfs/nwfs_io.c b/sys/nwfs/nwfs_io.c index 2cf3e49def63f..c6b301ba2ab15 100644 --- a/sys/nwfs/nwfs_io.c +++ b/sys/nwfs/nwfs_io.c @@ -36,6 +36,7 @@ #include <sys/systm.h> #include <sys/resourcevar.h> /* defines plimit structure in proc struct */ #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/nwfs/nwfs_vfsops.c b/sys/nwfs/nwfs_vfsops.c index d9257afd69d3f..7be59e935f43f 100644 --- a/sys/nwfs/nwfs_vfsops.c +++ b/sys/nwfs/nwfs_vfsops.c @@ -45,6 +45,7 @@ #include <sys/mount.h> #include <sys/stat.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <netncp/ncp.h> diff --git a/sys/nwfs/nwfs_vnops.c b/sys/nwfs/nwfs_vnops.c index 0d6a20539cc34..505e561c1254e 100644 --- a/sys/nwfs/nwfs_vnops.c +++ b/sys/nwfs/nwfs_vnops.c @@ -35,6 +35,7 @@ #include <sys/systm.h> #include <sys/namei.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/fcntl.h> diff --git a/sys/pc98/cbus/fdc.c b/sys/pc98/cbus/fdc.c index daec257cf2e82..76ae8153bc987 100644 --- a/sys/pc98/cbus/fdc.c +++ b/sys/pc98/cbus/fdc.c @@ -57,6 +57,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/bus.h> #include <sys/conf.h> diff --git a/sys/pc98/cbus/olpt.c b/sys/pc98/cbus/olpt.c index 542b7335635b1..defa012d8e8c1 100644 --- a/sys/pc98/cbus/olpt.c +++ b/sys/pc98/cbus/olpt.c @@ -111,6 +111,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/conf.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/kernel.h> #include <sys/uio.h> diff --git a/sys/pc98/i386/machdep.c b/sys/pc98/i386/machdep.c index 2193f46f58e39..5c45f8732107d 100644 --- a/sys/pc98/i386/machdep.c +++ b/sys/pc98/i386/machdep.c @@ -62,6 +62,7 @@ #include <sys/linker.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/reboot.h> #include <sys/callout.h> diff --git a/sys/pc98/pc98/diskslice_machdep.c b/sys/pc98/pc98/diskslice_machdep.c index 5ff899caa1a2b..2f9dec67e18fa 100644 --- a/sys/pc98/pc98/diskslice_machdep.c +++ b/sys/pc98/pc98/diskslice_machdep.c @@ -46,6 +46,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/disklabel.h> diff --git a/sys/pc98/pc98/fd.c b/sys/pc98/pc98/fd.c index daec257cf2e82..76ae8153bc987 100644 --- a/sys/pc98/pc98/fd.c +++ b/sys/pc98/pc98/fd.c @@ -57,6 +57,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/bus.h> #include <sys/conf.h> diff --git a/sys/pc98/pc98/machdep.c b/sys/pc98/pc98/machdep.c index 2193f46f58e39..5c45f8732107d 100644 --- a/sys/pc98/pc98/machdep.c +++ b/sys/pc98/pc98/machdep.c @@ -62,6 +62,7 @@ #include <sys/linker.h> #include <sys/malloc.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/reboot.h> #include <sys/callout.h> diff --git a/sys/pc98/pc98/olpt.c b/sys/pc98/pc98/olpt.c index 542b7335635b1..defa012d8e8c1 100644 --- a/sys/pc98/pc98/olpt.c +++ b/sys/pc98/pc98/olpt.c @@ -111,6 +111,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/conf.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/kernel.h> #include <sys/uio.h> diff --git a/sys/pc98/pc98/spkr.c b/sys/pc98/pc98/spkr.c index 6ac7c2fc4a316..4ec23a330e0ab 100644 --- a/sys/pc98/pc98/spkr.c +++ b/sys/pc98/pc98/spkr.c @@ -14,6 +14,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/kernel.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/uio.h> #include <sys/conf.h> diff --git a/sys/pc98/pc98/wd.c b/sys/pc98/pc98/wd.c index fc8728f781614..8ffd92061cb96 100644 --- a/sys/pc98/pc98/wd.c +++ b/sys/pc98/pc98/wd.c @@ -71,7 +71,7 @@ #include <sys/bus.h> #include <sys/disklabel.h> #include <sys/diskslice.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/devicestat.h> #include <sys/malloc.h> #include <machine/bootinfo.h> diff --git a/sys/pc98/pc98/wd_cd.c b/sys/pc98/pc98/wd_cd.c index 2980ae1402915..722dc507678cf 100644 --- a/sys/pc98/pc98/wd_cd.c +++ b/sys/pc98/pc98/wd_cd.c @@ -33,7 +33,7 @@ #include <sys/kernel.h> #include <sys/proc.h> #include <sys/malloc.h> -#include <sys/buf.h> +#include <sys/bio.h> #include <sys/disklabel.h> #include <sys/devicestat.h> #include <sys/cdio.h> diff --git a/sys/pc98/pc98/wfd.c b/sys/pc98/pc98/wfd.c index 458fffb9053d9..439769f7e6d6e 100644 --- a/sys/pc98/pc98/wfd.c +++ b/sys/pc98/pc98/wfd.c @@ -38,6 +38,7 @@ #include <sys/conf.h> #include <sys/proc.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/devicestat.h> #include <sys/disklabel.h> diff --git a/sys/pc98/pc98/wst.c b/sys/pc98/pc98/wst.c index 412a56b177087..3e34a38cc8d99 100644 --- a/sys/pc98/pc98/wst.c +++ b/sys/pc98/pc98/wst.c @@ -36,6 +36,7 @@ #include <sys/kernel.h> #include <sys/conf.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mtio.h> #include <machine/clock.h> diff --git a/sys/pci/simos.c b/sys/pci/simos.c index e325f12f05011..413f7d777535d 100644 --- a/sys/pci/simos.c +++ b/sys/pci/simos.c @@ -29,6 +29,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> diff --git a/sys/powerpc/aim/vm_machdep.c b/sys/powerpc/aim/vm_machdep.c index 982f127add018..17fe494557022 100644 --- a/sys/powerpc/aim/vm_machdep.c +++ b/sys/powerpc/aim/vm_machdep.c @@ -71,6 +71,7 @@ #include <sys/systm.h> #include <sys/proc.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/vmmeter.h> diff --git a/sys/powerpc/powerpc/genassym.c b/sys/powerpc/powerpc/genassym.c index e3c5028e9e691..a67f2d11275c2 100644 --- a/sys/powerpc/powerpc/genassym.c +++ b/sys/powerpc/powerpc/genassym.c @@ -43,6 +43,7 @@ #include <sys/systm.h> #include <sys/assym.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/errno.h> #include <sys/proc.h> diff --git a/sys/powerpc/powerpc/vm_machdep.c b/sys/powerpc/powerpc/vm_machdep.c index 982f127add018..17fe494557022 100644 --- a/sys/powerpc/powerpc/vm_machdep.c +++ b/sys/powerpc/powerpc/vm_machdep.c @@ -71,6 +71,7 @@ #include <sys/systm.h> #include <sys/proc.h> #include <sys/malloc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/vmmeter.h> diff --git a/sys/sys/bio.h b/sys/sys/bio.h index 60920a6118904..bdd19dffb7689 100644 --- a/sys/sys/bio.h +++ b/sys/sys/bio.h @@ -39,36 +39,13 @@ * $FreeBSD$ */ -#ifndef _SYS_BUF_H_ -#define _SYS_BUF_H_ +#ifndef _SYS_BIO_H_ +#define _SYS_BIO_H_ #include <sys/queue.h> -#include <sys/lock.h> struct bio; struct buf; -struct mount; -struct vnode; - -/* - * To avoid including <ufs/ffs/softdep.h> - */ -LIST_HEAD(workhead, worklist); -/* - * These are currently used only by the soft dependency code, hence - * are stored once in a global variable. If other subsystems wanted - * to use these hooks, a pointer to a set of bio_ops could be added - * to each buffer. - */ -extern struct bio_ops { - void (*io_start) __P((struct buf *)); - void (*io_complete) __P((struct buf *)); - void (*io_deallocate) __P((struct buf *)); - int (*io_fsync) __P((struct vnode *)); - int (*io_sync) __P((struct mount *)); - void (*io_movedeps) __P((struct buf *, struct buf *)); - int (*io_countdeps) __P((struct buf *, int)); -} bioops; struct iodone_chain { long ic_prev_flags; @@ -106,292 +83,26 @@ struct bio { struct iodone_chain *bio_done_chain; }; -static __inline__ void -biodone(struct bio *bp) -{ - bp->bio_done(bp); -} - -/* - * The buffer header describes an I/O operation in the kernel. - * - * NOTES: - * b_bufsize, b_bcount. b_bufsize is the allocation size of the - * buffer, either DEV_BSIZE or PAGE_SIZE aligned. b_bcount is the - * originally requested buffer size and can serve as a bounds check - * against EOF. For most, but not all uses, b_bcount == b_bufsize. - * - * b_dirtyoff, b_dirtyend. Buffers support piecemeal, unaligned - * ranges of dirty data that need to be written to backing store. - * The range is typically clipped at b_bcount ( not b_bufsize ). - * - * b_resid. Number of bytes remaining in I/O. After an I/O operation - * completes, b_resid is usually 0 indicating 100% success. - */ -struct buf { - /* XXX: b_io must be the first element of struct buf for now /phk */ - struct bio b_io; /* "Builtin" I/O request. */ -#define b_bcount b_io.bio_bcount -#define b_blkno b_io.bio_blkno -#define b_caller1 b_io.bio_caller1 -#define b_data b_io.bio_data -#define b_dev b_io.bio_dev -#define b_driver1 b_io.bio_driver1 -#define b_driver2 b_io.bio_driver2 -#define b_error b_io.bio_error -#define b_iocmd b_io.bio_cmd -#define b_ioflags b_io.bio_flags -#define b_pblkno b_io.bio_pblkno -#define b_resid b_io.bio_resid - void (*b_iodone) __P((struct buf *)); - off_t b_offset; /* Offset into file. */ - LIST_ENTRY(buf) b_hash; /* Hash chain. */ - TAILQ_ENTRY(buf) b_vnbufs; /* Buffer's associated vnode. */ - TAILQ_ENTRY(buf) b_freelist; /* Free list position if not active. */ - TAILQ_ENTRY(buf) b_act; /* Device driver queue when active. *new* */ - long b_flags; /* B_* flags. */ - unsigned short b_qindex; /* buffer queue index */ - unsigned char b_xflags; /* extra flags */ - struct lock b_lock; /* Buffer lock */ - long b_bufsize; /* Allocated buffer size. */ - caddr_t b_kvabase; /* base kva for buffer */ - int b_kvasize; /* size of kva for buffer */ - daddr_t b_lblkno; /* Logical block number. */ - struct vnode *b_vp; /* Device vnode. */ - int b_dirtyoff; /* Offset in buffer of dirty region. */ - int b_dirtyend; /* Offset of end of dirty region. */ - struct ucred *b_rcred; /* Read credentials reference. */ - struct ucred *b_wcred; /* Write credentials reference. */ - void *b_saveaddr; /* Original b_addr for physio. */ - union pager_info { - void *pg_spc; - int pg_reqpage; - } b_pager; - union cluster_info { - TAILQ_HEAD(cluster_list_head, buf) cluster_head; - TAILQ_ENTRY(buf) cluster_entry; - } b_cluster; - struct vm_page *b_pages[btoc(MAXPHYS)]; - int b_npages; - struct workhead b_dep; /* List of filesystem dependencies. */ -}; - -#define b_spc b_pager.pg_spc - -/* - * These flags are kept in b_flags. - * - * Notes: - * - * B_ASYNC VOP calls on bp's are usually async whether or not - * B_ASYNC is set, but some subsystems, such as NFS, like - * to know what is best for the caller so they can - * optimize the I/O. - * - * B_PAGING Indicates that bp is being used by the paging system or - * some paging system and that the bp is not linked into - * the b_vp's clean/dirty linked lists or ref counts. - * Buffer vp reassignments are illegal in this case. - * - * B_CACHE This may only be set if the buffer is entirely valid. - * The situation where B_DELWRI is set and B_CACHE is - * clear MUST be committed to disk by getblk() so - * B_DELWRI can also be cleared. See the comments for - * getblk() in kern/vfs_bio.c. If B_CACHE is clear, - * the caller is expected to clear BIO_ERROR and B_INVAL, - * set BIO_READ, and initiate an I/O. - * - * The 'entire buffer' is defined to be the range from - * 0 through b_bcount. - * - * B_MALLOC Request that the buffer be allocated from the malloc - * pool, DEV_BSIZE aligned instead of PAGE_SIZE aligned. - * - * B_CLUSTEROK This flag is typically set for B_DELWRI buffers - * by filesystems that allow clustering when the buffer - * is fully dirty and indicates that it may be clustered - * with other adjacent dirty buffers. Note the clustering - * may not be used with the stage 1 data write under NFS - * but may be used for the commit rpc portion. - * - * B_VMIO Indicates that the buffer is tied into an VM object. - * The buffer's data is always PAGE_SIZE aligned even - * if b_bufsize and b_bcount are not. ( b_bufsize is - * always at least DEV_BSIZE aligned, though ). - * - */ - #define BIO_READ 1 #define BIO_WRITE 2 #define BIO_DELETE 4 #define BIO_FORMAT 8 -#define BIO_ERROR 0x00000001 /* I/O error occurred. */ -#define BIO_ORDERED 0x00000002 /* Must guarantee I/O ordering */ +#define BIO_ERROR 0x00000001 +#define BIO_ORDERED 0x00000002 +#define BIO_DONE 0x00000004 #define BIO_FLAG2 0x40000000 /* Available for local hacks */ #define BIO_FLAG1 0x80000000 /* Available for local hacks */ -#define B_AGE 0x00000001 /* Move to age queue when I/O done. */ -#define B_NEEDCOMMIT 0x00000002 /* Append-write in progress. */ -#define B_ASYNC 0x00000004 /* Start I/O, do not wait. */ -#define B_UNUSED0 0x00000008 /* Old B_BAD */ -#define B_DEFERRED 0x00000010 /* Skipped over for cleaning */ -#define B_CACHE 0x00000020 /* Bread found us in the cache. */ -#define B_UNUSED40 0x00000040 /* Old B_CALL */ -#define B_DELWRI 0x00000080 /* Delay I/O until buffer reused. */ -#define B_DONE 0x00000200 /* I/O completed. */ -#define B_EINTR 0x00000400 /* I/O was interrupted */ -#define B_00000800 0x00000800 /* Available flag. */ -#define B_SCANNED 0x00001000 /* VOP_FSYNC funcs mark written bufs */ -#define B_INVAL 0x00002000 /* Does not contain valid info. */ -#define B_LOCKED 0x00004000 /* Locked in core (not reusable). */ -#define B_NOCACHE 0x00008000 /* Do not cache block after use. */ -#define B_MALLOC 0x00010000 /* malloced b_data */ -#define B_CLUSTEROK 0x00020000 /* Pagein op, so swap() can count it. */ -#define B_PHYS 0x00040000 /* I/O to user memory. */ -#define B_RAW 0x00080000 /* Set by physio for raw transfers. */ -#define B_DIRTY 0x00200000 /* Needs writing later. */ -#define B_RELBUF 0x00400000 /* Release VMIO buffer. */ -#define B_WANT 0x00800000 /* Used by vm_pager.c */ -#define B_WRITEINPROG 0x01000000 /* Write in progress. */ -#define B_XXX 0x02000000 /* Debugging flag. */ -#define B_PAGING 0x04000000 /* volatile paging I/O -- bypass VMIO */ -#define B_08000000 0x08000000 /* Available flag. */ -#define B_RAM 0x10000000 /* Read ahead mark (flag) */ -#define B_VMIO 0x20000000 /* VMIO flag */ -#define B_CLUSTER 0x40000000 /* pagein op, so swap() can count it */ -#define B_80000000 0x80000000 /* Available flag. */ - -#define PRINT_BUF_FLAGS "\20\40autochain\37cluster\36vmio\35ram\34ordered" \ - "\33paging\32xxx\31writeinprog\30want\27relbuf\26dirty" \ - "\25read\24raw\23phys\22clusterok\21malloc\20nocache" \ - "\17locked\16inval\15scanned\14error\13eintr\12done\11freebuf" \ - "\10delwri\7call\6cache\4bad\3async\2needcommit\1age" - -/* - * These flags are kept in b_xflags. - */ -#define BX_VNDIRTY 0x00000001 /* On vnode dirty list */ -#define BX_VNCLEAN 0x00000002 /* On vnode clean list */ -#define BX_BKGRDWRITE 0x00000004 /* Do writes in background */ -#define BX_BKGRDINPROG 0x00000008 /* Background write in progress */ -#define BX_BKGRDWAIT 0x00000010 /* Background write waiting */ - -#define NOOFFSET (-1LL) /* No buffer offset calculated yet */ - #ifdef _KERNEL -/* - * Buffer locking - */ -extern struct simplelock buftimelock; /* Interlock on setting prio and timo */ -extern char *buf_wmesg; /* Default buffer lock message */ -#define BUF_WMESG "bufwait" -#include <sys/proc.h> /* XXX for curproc */ -/* - * Initialize a lock. - */ -#define BUF_LOCKINIT(bp) \ - lockinit(&(bp)->b_lock, PRIBIO + 4, buf_wmesg, 0, 0) -/* - * - * Get a lock sleeping non-interruptably until it becomes available. - */ -static __inline int BUF_LOCK __P((struct buf *, int)); -static __inline int -BUF_LOCK(struct buf *bp, int locktype) -{ - int s, ret; - - s = splbio(); - simple_lock(&buftimelock); - locktype |= LK_INTERLOCK; - bp->b_lock.lk_wmesg = buf_wmesg; - bp->b_lock.lk_prio = PRIBIO + 4; - bp->b_lock.lk_timo = 0; - ret = lockmgr(&(bp)->b_lock, locktype, &buftimelock, curproc); - splx(s); - return ret; -} -/* - * Get a lock sleeping with specified interruptably and timeout. - */ -static __inline int BUF_TIMELOCK __P((struct buf *, int, char *, int, int)); -static __inline int -BUF_TIMELOCK(struct buf *bp, int locktype, char *wmesg, int catch, int timo) -{ - int s, ret; - - s = splbio(); - simple_lock(&buftimelock); - locktype |= LK_INTERLOCK; - bp->b_lock.lk_wmesg = wmesg; - bp->b_lock.lk_prio = (PRIBIO + 4) | catch; - bp->b_lock.lk_timo = timo; - ret = lockmgr(&(bp)->b_lock, (locktype), &buftimelock, curproc); - splx(s); - return ret; -} -/* - * Release a lock. Only the acquiring process may free the lock unless - * it has been handed off to biodone. - */ -static __inline void BUF_UNLOCK __P((struct buf *)); -static __inline void -BUF_UNLOCK(struct buf *bp) -{ - int s; - - s = splbio(); - lockmgr(&(bp)->b_lock, LK_RELEASE, NULL, curproc); - splx(s); -} - -/* - * Free a buffer lock. - */ -#define BUF_LOCKFREE(bp) \ - if (BUF_REFCNT(bp) > 0) \ - panic("free locked buf") -/* - * When initiating asynchronous I/O, change ownership of the lock to the - * kernel. Once done, the lock may legally released by biodone. The - * original owning process can no longer acquire it recursively, but must - * wait until the I/O is completed and the lock has been freed by biodone. - */ -static __inline void BUF_KERNPROC __P((struct buf *)); -static __inline void -BUF_KERNPROC(struct buf *bp) -{ - struct proc *p = curproc; - if (p != NULL && bp->b_lock.lk_lockholder == p->p_pid) - p->p_locks--; - bp->b_lock.lk_lockholder = LK_KERNPROC; -} -/* - * Find out the number of references to a lock. - */ -static __inline int BUF_REFCNT __P((struct buf *)); -static __inline int -BUF_REFCNT(struct buf *bp) +static __inline__ void +biodone(struct bio *bp) { - int s, ret; - - s = splbio(); - ret = lockcount(&(bp)->b_lock); - splx(s); - return ret; + bp->bio_flags |= BIO_DONE; + bp->bio_done(bp); } -#endif /* _KERNEL */ - -struct buf_queue_head { - TAILQ_HEAD(buf_queue, buf) queue; - daddr_t last_pblkno; - struct buf *insert_point; - struct buf *switch_point; -}; - struct bio_queue_head { TAILQ_HEAD(bio_queue, bio) queue; daddr_t last_pblkno; @@ -399,44 +110,14 @@ struct bio_queue_head { struct bio *switch_point; }; -/* - * This structure describes a clustered I/O. It is stored in the b_saveaddr - * field of the buffer on which I/O is done. At I/O completion, cluster - * callback uses the structure to parcel I/O's to individual buffers, and - * then free's this structure. - */ -struct cluster_save { - long bs_bcount; /* Saved b_bcount. */ - long bs_bufsize; /* Saved b_bufsize. */ - void *bs_saveaddr; /* Saved b_addr. */ - int bs_nchildren; /* Number of associated buffers. */ - struct buf **bs_children; /* List of associated buffers. */ -}; - -#ifdef _KERNEL -static __inline void bufq_init __P((struct buf_queue_head *head)); static __inline void bioq_init __P((struct bio_queue_head *head)); -static __inline void bufq_insert_tail __P((struct buf_queue_head *head, - struct buf *bp)); static __inline void bioq_insert_tail __P((struct bio_queue_head *head, struct bio *bp)); -static __inline void bufq_remove __P((struct buf_queue_head *head, - struct buf *bp)); static __inline void bioq_remove __P((struct bio_queue_head *head, struct bio *bp)); -static __inline struct buf *bufq_first __P((struct buf_queue_head *head)); static __inline struct bio *bioq_first __P((struct bio_queue_head *head)); static __inline void -bufq_init(struct buf_queue_head *head) -{ - TAILQ_INIT(&head->queue); - head->last_pblkno = 0; - head->insert_point = NULL; - head->switch_point = NULL; -} - -static __inline void bioq_init(struct bio_queue_head *head) { TAILQ_INIT(&head->queue); @@ -446,16 +127,6 @@ bioq_init(struct bio_queue_head *head) } static __inline void -bufq_insert_tail(struct buf_queue_head *head, struct buf *bp) -{ - if ((bp->b_ioflags & BIO_ORDERED) != 0) { - head->insert_point = bp; - head->switch_point = NULL; - } - TAILQ_INSERT_TAIL(&head->queue, bp, b_act); -} - -static __inline void bioq_insert_tail(struct bio_queue_head *head, struct bio *bp) { if ((bp->bio_flags & BIO_ORDERED) != 0) { @@ -466,22 +137,6 @@ bioq_insert_tail(struct bio_queue_head *head, struct bio *bp) } static __inline void -bufq_remove(struct buf_queue_head *head, struct buf *bp) -{ - if (bp == head->switch_point) - head->switch_point = TAILQ_NEXT(bp, b_act); - if (bp == head->insert_point) { - head->insert_point = TAILQ_PREV(bp, buf_queue, b_act); - if (head->insert_point == NULL) - head->last_pblkno = 0; - } else if (bp == TAILQ_FIRST(&head->queue)) - head->last_pblkno = bp->b_pblkno; - TAILQ_REMOVE(&head->queue, bp, b_act); - if (TAILQ_FIRST(&head->queue) == head->switch_point) - head->switch_point = NULL; -} - -static __inline void bioq_remove(struct bio_queue_head *head, struct bio *bp) { if (bp == head->switch_point) @@ -497,43 +152,12 @@ bioq_remove(struct bio_queue_head *head, struct bio *bp) head->switch_point = NULL; } -static __inline struct buf * -bufq_first(struct buf_queue_head *head) -{ - return (TAILQ_FIRST(&head->queue)); -} - static __inline struct bio * bioq_first(struct bio_queue_head *head) { return (TAILQ_FIRST(&head->queue)); } -#define BUF_WRITE(bp) VOP_BWRITE((bp)->b_vp, (bp)) -#define BUF_STRATEGY(bp) VOP_STRATEGY((bp)->b_vp, (bp)) - -#endif /* _KERNEL */ - -/* - * Definitions for the buffer free lists. - */ -#define BUFFER_QUEUES 6 /* number of free buffer queues */ - -#define QUEUE_NONE 0 /* on no queue */ -#define QUEUE_LOCKED 1 /* locked buffers */ -#define QUEUE_CLEAN 2 /* non-B_DELWRI buffers */ -#define QUEUE_DIRTY 3 /* B_DELWRI buffers */ -#define QUEUE_EMPTYKVA 4 /* empty buffer headers w/KVA assignment */ -#define QUEUE_EMPTY 5 /* empty buffer headers */ - -/* - * Zero out the buffer's data area. - */ -#define clrbuf(bp) { \ - bzero((bp)->b_data, (u_int)(bp)->b_bcount); \ - (bp)->b_resid = 0; \ -} - /* * Zero out the bio's data area. */ @@ -542,75 +166,10 @@ bioq_first(struct bio_queue_head *head) (bp)->bio_resid = 0; \ } -/* Flags to low-level allocation routines. */ -#define B_CLRBUF 0x01 /* Request allocated buffer be cleared. */ -#define B_SYNC 0x02 /* Do all allocations synchronously. */ - -#ifdef _KERNEL -extern int nbuf; /* The number of buffer headers */ -extern int buf_maxio; /* nominal maximum I/O for buffer */ -extern struct buf *buf; /* The buffer headers. */ -extern char *buffers; /* The buffer contents. */ -extern int bufpages; /* Number of memory pages in the buffer pool. */ -extern struct buf *swbuf; /* Swap I/O buffer headers. */ -extern int nswbuf; /* Number of swap I/O buffer headers. */ -extern TAILQ_HEAD(swqueue, buf) bswlist; -extern TAILQ_HEAD(bqueues, buf) bufqueues[BUFFER_QUEUES]; - -struct uio; - -caddr_t bufhashinit __P((caddr_t)); -void bufinit __P((void)); -void bwillwrite __P((void)); -void bremfree __P((struct buf *)); -int bread __P((struct vnode *, daddr_t, int, - struct ucred *, struct buf **)); -int breadn __P((struct vnode *, daddr_t, int, daddr_t *, int *, int, - struct ucred *, struct buf **)); -int bwrite __P((struct buf *)); -void bdwrite __P((struct buf *)); -void bawrite __P((struct buf *)); -void bdirty __P((struct buf *)); -void bundirty __P((struct buf *)); -int bowrite __P((struct buf *)); -void brelse __P((struct buf *)); -void bqrelse __P((struct buf *)); -int vfs_bio_awrite __P((struct buf *)); -struct buf * getpbuf __P((int *)); -struct buf *incore __P((struct vnode *, daddr_t)); -struct buf *gbincore __P((struct vnode *, daddr_t)); -int inmem __P((struct vnode *, daddr_t)); -struct buf *getblk __P((struct vnode *, daddr_t, int, int, int)); -struct buf *geteblk __P((int)); -int bufwait __P((struct buf *)); -void bufdone __P((struct buf *)); -void bufdonebio __P((struct bio *)); - -void cluster_callback __P((struct buf *)); -int cluster_read __P((struct vnode *, u_quad_t, daddr_t, long, - struct ucred *, long, int, struct buf **)); -int cluster_wbuild __P((struct vnode *, long, daddr_t, int)); -void cluster_write __P((struct buf *, u_quad_t, int)); int physio __P((dev_t dev, struct uio *uio, int ioflag)); #define physread physio #define physwrite physio -void vfs_bio_set_validclean __P((struct buf *, int base, int size)); -void vfs_bio_clrbuf __P((struct buf *)); -void vfs_busy_pages __P((struct buf *, int clear_modify)); -void vfs_unbusy_pages __P((struct buf *)); -void vwakeup __P((struct buf *)); -void vmapbuf __P((struct buf *)); -void vunmapbuf __P((struct buf *)); -void relpbuf __P((struct buf *, int *)); -void brelvp __P((struct buf *)); -void bgetvp __P((struct vnode *, struct buf *)); -void pbgetvp __P((struct vnode *, struct buf *)); -void pbrelvp __P((struct buf *)); -int allocbuf __P((struct buf *bp, int size)); -void reassignbuf __P((struct buf *, struct vnode *)); -void pbreassignbuf __P((struct buf *, struct vnode *)); -struct buf *trypbuf __P((int *)); #endif /* _KERNEL */ -#endif /* !_SYS_BUF_H_ */ +#endif /* !_SYS_BIO_H_ */ diff --git a/sys/sys/buf.h b/sys/sys/buf.h index 60920a6118904..39a5c99135a5e 100644 --- a/sys/sys/buf.h +++ b/sys/sys/buf.h @@ -70,48 +70,6 @@ extern struct bio_ops { int (*io_countdeps) __P((struct buf *, int)); } bioops; -struct iodone_chain { - long ic_prev_flags; - void (*ic_prev_iodone) __P((struct bio *)); - void *ic_prev_iodone_chain; - struct { - long ia_long; - void *ia_ptr; - } ic_args[5]; -}; - -/* - * The bio structure describes an I/O operation in the kernel. - */ -struct bio { - u_int bio_cmd; /* I/O operation. */ - dev_t bio_dev; /* Device to do I/O on. */ - daddr_t bio_blkno; /* Underlying physical block number. */ - off_t bio_offset; /* Offset into file. */ - long bio_bcount; /* Valid bytes in buffer. */ - caddr_t bio_data; /* Memory, superblocks, indirect etc. */ - u_int bio_flags; /* BIO_ flags. */ - struct buf *_bio_buf; /* Parent buffer. */ - int bio_error; /* Errno for BIO_ERROR. */ - long bio_resid; /* Remaining I/0 in bytes. */ - void (*bio_done) __P((struct bio *)); - void *bio_driver1; /* Private use by the callee. */ - void *bio_driver2; /* Private use by the callee. */ - void *bio_caller1; /* Private use by the caller. */ - void *bio_caller2; /* Private use by the caller. */ - TAILQ_ENTRY(bio) bio_queue; /* Disksort queue. */ - - /* XXX: these go away when bio chaining is introduced */ - daddr_t bio_pblkno; /* physical block number */ - struct iodone_chain *bio_done_chain; -}; - -static __inline__ void -biodone(struct bio *bp) -{ - bp->bio_done(bp); -} - /* * The buffer header describes an I/O operation in the kernel. * @@ -221,16 +179,6 @@ struct buf { * */ -#define BIO_READ 1 -#define BIO_WRITE 2 -#define BIO_DELETE 4 -#define BIO_FORMAT 8 - -#define BIO_ERROR 0x00000001 /* I/O error occurred. */ -#define BIO_ORDERED 0x00000002 /* Must guarantee I/O ordering */ -#define BIO_FLAG2 0x40000000 /* Available for local hacks */ -#define BIO_FLAG1 0x80000000 /* Available for local hacks */ - #define B_AGE 0x00000001 /* Move to age queue when I/O done. */ #define B_NEEDCOMMIT 0x00000002 /* Append-write in progress. */ #define B_ASYNC 0x00000004 /* Start I/O, do not wait. */ @@ -392,13 +340,6 @@ struct buf_queue_head { struct buf *switch_point; }; -struct bio_queue_head { - TAILQ_HEAD(bio_queue, bio) queue; - daddr_t last_pblkno; - struct bio *insert_point; - struct bio *switch_point; -}; - /* * This structure describes a clustered I/O. It is stored in the b_saveaddr * field of the buffer on which I/O is done. At I/O completion, cluster @@ -415,17 +356,11 @@ struct cluster_save { #ifdef _KERNEL static __inline void bufq_init __P((struct buf_queue_head *head)); -static __inline void bioq_init __P((struct bio_queue_head *head)); static __inline void bufq_insert_tail __P((struct buf_queue_head *head, struct buf *bp)); -static __inline void bioq_insert_tail __P((struct bio_queue_head *head, - struct bio *bp)); static __inline void bufq_remove __P((struct buf_queue_head *head, struct buf *bp)); -static __inline void bioq_remove __P((struct bio_queue_head *head, - struct bio *bp)); static __inline struct buf *bufq_first __P((struct buf_queue_head *head)); -static __inline struct bio *bioq_first __P((struct bio_queue_head *head)); static __inline void bufq_init(struct buf_queue_head *head) @@ -437,15 +372,6 @@ bufq_init(struct buf_queue_head *head) } static __inline void -bioq_init(struct bio_queue_head *head) -{ - TAILQ_INIT(&head->queue); - head->last_pblkno = 0; - head->insert_point = NULL; - head->switch_point = NULL; -} - -static __inline void bufq_insert_tail(struct buf_queue_head *head, struct buf *bp) { if ((bp->b_ioflags & BIO_ORDERED) != 0) { @@ -456,16 +382,6 @@ bufq_insert_tail(struct buf_queue_head *head, struct buf *bp) } static __inline void -bioq_insert_tail(struct bio_queue_head *head, struct bio *bp) -{ - if ((bp->bio_flags & BIO_ORDERED) != 0) { - head->insert_point = bp; - head->switch_point = NULL; - } - TAILQ_INSERT_TAIL(&head->queue, bp, bio_queue); -} - -static __inline void bufq_remove(struct buf_queue_head *head, struct buf *bp) { if (bp == head->switch_point) @@ -481,34 +397,12 @@ bufq_remove(struct buf_queue_head *head, struct buf *bp) head->switch_point = NULL; } -static __inline void -bioq_remove(struct bio_queue_head *head, struct bio *bp) -{ - if (bp == head->switch_point) - head->switch_point = TAILQ_NEXT(bp, bio_queue); - if (bp == head->insert_point) { - head->insert_point = TAILQ_PREV(bp, bio_queue, bio_queue); - if (head->insert_point == NULL) - head->last_pblkno = 0; - } else if (bp == TAILQ_FIRST(&head->queue)) - head->last_pblkno = bp->bio_pblkno; - TAILQ_REMOVE(&head->queue, bp, bio_queue); - if (TAILQ_FIRST(&head->queue) == head->switch_point) - head->switch_point = NULL; -} - static __inline struct buf * bufq_first(struct buf_queue_head *head) { return (TAILQ_FIRST(&head->queue)); } -static __inline struct bio * -bioq_first(struct bio_queue_head *head) -{ - return (TAILQ_FIRST(&head->queue)); -} - #define BUF_WRITE(bp) VOP_BWRITE((bp)->b_vp, (bp)) #define BUF_STRATEGY(bp) VOP_STRATEGY((bp)->b_vp, (bp)) @@ -534,14 +428,6 @@ bioq_first(struct bio_queue_head *head) (bp)->b_resid = 0; \ } -/* - * Zero out the bio's data area. - */ -#define clrbio(bp) { \ - bzero((bp)->bio_data, (u_int)(bp)->bio_bcount); \ - (bp)->bio_resid = 0; \ -} - /* Flags to low-level allocation routines. */ #define B_CLRBUF 0x01 /* Request allocated buffer be cleared. */ #define B_SYNC 0x02 /* Do all allocations synchronously. */ @@ -591,9 +477,6 @@ int cluster_read __P((struct vnode *, u_quad_t, daddr_t, long, struct ucred *, long, int, struct buf **)); int cluster_wbuild __P((struct vnode *, long, daddr_t, int)); void cluster_write __P((struct buf *, u_quad_t, int)); -int physio __P((dev_t dev, struct uio *uio, int ioflag)); -#define physread physio -#define physwrite physio void vfs_bio_set_validclean __P((struct buf *, int base, int size)); void vfs_bio_clrbuf __P((struct buf *)); void vfs_busy_pages __P((struct buf *, int clear_modify)); diff --git a/sys/ufs/ffs/ffs_alloc.c b/sys/ufs/ffs/ffs_alloc.c index 0b06479753b3d..1f24b2bcaeef2 100644 --- a/sys/ufs/ffs/ffs_alloc.c +++ b/sys/ufs/ffs/ffs_alloc.c @@ -38,6 +38,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/proc.h> diff --git a/sys/ufs/ffs/ffs_balloc.c b/sys/ufs/ffs/ffs_balloc.c index 51b249a3127ae..28cc1ed0510d7 100644 --- a/sys/ufs/ffs/ffs_balloc.c +++ b/sys/ufs/ffs/ffs_balloc.c @@ -36,6 +36,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/lock.h> #include <sys/mount.h> diff --git a/sys/ufs/ffs/ffs_inode.c b/sys/ufs/ffs/ffs_inode.c index 188278bed7fea..4725090aeb742 100644 --- a/sys/ufs/ffs/ffs_inode.c +++ b/sys/ufs/ffs/ffs_inode.c @@ -40,6 +40,7 @@ #include <sys/systm.h> #include <sys/mount.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/ufs/ffs/ffs_softdep.c b/sys/ufs/ffs/ffs_softdep.c index 4b3807d2a54e3..ce48d430b574a 100644 --- a/sys/ufs/ffs/ffs_softdep.c +++ b/sys/ufs/ffs/ffs_softdep.c @@ -69,6 +69,7 @@ #include <sys/param.h> #include <sys/kernel.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/malloc.h> #include <sys/mount.h> diff --git a/sys/ufs/ffs/ffs_subr.c b/sys/ufs/ffs/ffs_subr.c index ee3173adba447..5155a42faab0a 100644 --- a/sys/ufs/ffs/ffs_subr.c +++ b/sys/ufs/ffs/ffs_subr.c @@ -45,6 +45,7 @@ #include <sys/systm.h> #include <sys/lock.h> #include <sys/vnode.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/ucred.h> diff --git a/sys/ufs/ffs/ffs_vfsops.c b/sys/ufs/ffs/ffs_vfsops.c index df24e8dd493dc..b9cb91a11b7a4 100644 --- a/sys/ufs/ffs/ffs_vfsops.c +++ b/sys/ufs/ffs/ffs_vfsops.c @@ -44,6 +44,7 @@ #include <sys/kernel.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/fcntl.h> diff --git a/sys/ufs/ffs/ffs_vnops.c b/sys/ufs/ffs/ffs_vnops.c index 1964a7583e1b2..7d3b2c32a7957 100644 --- a/sys/ufs/ffs/ffs_vnops.c +++ b/sys/ufs/ffs/ffs_vnops.c @@ -42,6 +42,7 @@ #include <sys/signalvar.h> #include <sys/kernel.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/ufs/mfs/mfs_vfsops.c b/sys/ufs/mfs/mfs_vfsops.c index 13ddd8efef659..5c5e01070b0e8 100644 --- a/sys/ufs/mfs/mfs_vfsops.c +++ b/sys/ufs/mfs/mfs_vfsops.c @@ -42,6 +42,7 @@ #include <sys/conf.h> #include <sys/kernel.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/mount.h> #include <sys/signalvar.h> diff --git a/sys/ufs/mfs/mfs_vnops.c b/sys/ufs/mfs/mfs_vnops.c index 9cb097ac28f78..9e27dcf23c6a7 100644 --- a/sys/ufs/mfs/mfs_vnops.c +++ b/sys/ufs/mfs/mfs_vnops.c @@ -38,6 +38,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/ufs/ufs/ufs_bmap.c b/sys/ufs/ufs/ufs_bmap.c index c24f507f36c29..90563401bb918 100644 --- a/sys/ufs/ufs/ufs_bmap.c +++ b/sys/ufs/ufs/ufs_bmap.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/vnode.h> diff --git a/sys/ufs/ufs/ufs_disksubr.c b/sys/ufs/ufs/ufs_disksubr.c index fc7fb28cec704..ed68f3818b437 100644 --- a/sys/ufs/ufs/ufs_disksubr.c +++ b/sys/ufs/ufs/ufs_disksubr.c @@ -41,6 +41,7 @@ #include <sys/param.h> #include <sys/systm.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/conf.h> #include <sys/disklabel.h> diff --git a/sys/ufs/ufs/ufs_lookup.c b/sys/ufs/ufs/ufs_lookup.c index fd9d60954a35b..3834a546e5009 100644 --- a/sys/ufs/ufs/ufs_lookup.c +++ b/sys/ufs/ufs/ufs_lookup.c @@ -43,6 +43,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/namei.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/stat.h> diff --git a/sys/ufs/ufs/ufs_vnops.c b/sys/ufs/ufs/ufs_vnops.c index 6d36fb7e905df..e3b6e29adc668 100644 --- a/sys/ufs/ufs/ufs_vnops.c +++ b/sys/ufs/ufs/ufs_vnops.c @@ -48,6 +48,7 @@ #include <sys/kernel.h> #include <sys/fcntl.h> #include <sys/stat.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/mount.h> diff --git a/sys/vm/swap_pager.c b/sys/vm/swap_pager.c index 473be9bdf7197..4e8174bd32c7f 100644 --- a/sys/vm/swap_pager.c +++ b/sys/vm/swap_pager.c @@ -72,6 +72,7 @@ #include <sys/conf.h> #include <sys/kernel.h> #include <sys/proc.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vnode.h> #include <sys/malloc.h> diff --git a/sys/vm/vm_pager.c b/sys/vm/vm_pager.c index 49c459a905e38..7c08a3a131f94 100644 --- a/sys/vm/vm_pager.c +++ b/sys/vm/vm_pager.c @@ -73,6 +73,7 @@ #include <sys/systm.h> #include <sys/kernel.h> #include <sys/vnode.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/ucred.h> #include <sys/malloc.h> diff --git a/sys/vm/vm_swap.c b/sys/vm/vm_swap.c index d3a80decbf472..cf5cf4b1adaaf 100644 --- a/sys/vm/vm_swap.c +++ b/sys/vm/vm_swap.c @@ -39,6 +39,7 @@ #include <sys/param.h> #include <sys/systm.h> #include <sys/sysproto.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/proc.h> #include <sys/namei.h> diff --git a/sys/vm/vnode_pager.c b/sys/vm/vnode_pager.c index 95d1ebce83e60..904ffd215674d 100644 --- a/sys/vm/vnode_pager.c +++ b/sys/vm/vnode_pager.c @@ -56,6 +56,7 @@ #include <sys/proc.h> #include <sys/vnode.h> #include <sys/mount.h> +#include <sys/bio.h> #include <sys/buf.h> #include <sys/vmmeter.h> #include <sys/conf.h> |