diff --git a/sys/alpha/include/param.h b/sys/alpha/include/param.h index 873ea8504b4f..2bb660ca4cb7 100644 --- a/sys/alpha/include/param.h +++ b/sys/alpha/include/param.h @@ -98,9 +98,16 @@ #define DEV_BSHIFT 9 /* log2(DEV_BSIZE) */ #define DEV_BSIZE (1<<DEV_BSHIFT) -#define BLKDEV_IOSIZE 2048 +#ifndef BLKDEV_IOSIZE +#define BLKDEV_IOSIZE PAGE_SIZE /* default block device I/O size */ +#endif + +#ifndef DFLTPHYS #define DFLTPHYS (64 * 1024) /* default max raw I/O transfer size */ +#endif +#ifndef MAXPHYS #define MAXPHYS (128 * 1024) /* max raw I/O transfer size */ +#endif #define CLSIZE 1 #define CLSIZELOG2 0 diff --git a/sys/conf/NOTES b/sys/conf/NOTES index 08f9f8cbbdc2..f6fe5cf6b9df 100644 --- a/sys/conf/NOTES +++ b/sys/conf/NOTES @@ -56,6 +56,25 @@ maxusers 10 options MAXDSIZ="(256*1024*1024)" options DFLDSIZ="(256*1024*1024)" +# +# BLKDEV_IOSIZE sets the default block size used in user block +# device I/O. Note that this value will be overriden by the label +# when specifying a block device from a label with a non-0 +# partition blocksize +# +# DFLTPHYS is the default maximum physical I/O transaction size +# and is used mostly by the clustering code. It must be a +# multiple of the system page size. +# +# MAXPHYS is the absolute maximum physical I/O transaction size. +# It must be a multiple of the system page size. +# +# In general you should not modify either DFLTPHYS or MAXPHYS. +# +options BLKDEV_IOSIZE=8192 +options DFLTPHYS="(64*1024)" +options MAXPHYS="(128*1024)" + # Options for the VM subsystem #options PQ_NOOPT # No coloring options PQ_LARGECACHE # color for 512k/16k cache diff --git a/sys/conf/options b/sys/conf/options index d29884b0b9b7..3384d3789b53 100644 --- a/sys/conf/options +++ b/sys/conf/options @@ -288,6 +288,9 @@ INVARIANT_SUPPORT opt_global.h INVARIANTS opt_global.h SIMPLELOCK_DEBUG opt_global.h VFS_BIO_DEBUG opt_global.h +BLKDEV_IOSIZE opt_global.h +DFLTPHYS opt_global.h +MAXPHYS opt_global.h # These are VM related options VM_KMEM_SIZE opt_vm.h diff --git a/sys/i386/conf/LINT b/sys/i386/conf/LINT index 08f9f8cbbdc2..f6fe5cf6b9df 100644 --- a/sys/i386/conf/LINT +++ b/sys/i386/conf/LINT @@ -56,6 +56,25 @@ maxusers 10 options MAXDSIZ="(256*1024*1024)" options DFLDSIZ="(256*1024*1024)" +# +# BLKDEV_IOSIZE sets the default block size used in user block +# device I/O. Note that this value will be overriden by the label +# when specifying a block device from a label with a non-0 +# partition blocksize +# +# DFLTPHYS is the default maximum physical I/O transaction size +# and is used mostly by the clustering code. It must be a +# multiple of the system page size. +# +# MAXPHYS is the absolute maximum physical I/O transaction size. +# It must be a multiple of the system page size. +# +# In general you should not modify either DFLTPHYS or MAXPHYS. +# +options BLKDEV_IOSIZE=8192 +options DFLTPHYS="(64*1024)" +options MAXPHYS="(128*1024)" + # Options for the VM subsystem #options PQ_NOOPT # No coloring options PQ_LARGECACHE # color for 512k/16k cache diff --git a/sys/i386/conf/NOTES b/sys/i386/conf/NOTES index 08f9f8cbbdc2..f6fe5cf6b9df 100644 --- a/sys/i386/conf/NOTES +++ b/sys/i386/conf/NOTES @@ -56,6 +56,25 @@ maxusers 10 options MAXDSIZ="(256*1024*1024)" options DFLDSIZ="(256*1024*1024)" +# +# BLKDEV_IOSIZE sets the default block size used in user block +# device I/O. Note that this value will be overriden by the label +# when specifying a block device from a label with a non-0 +# partition blocksize +# +# DFLTPHYS is the default maximum physical I/O transaction size +# and is used mostly by the clustering code. It must be a +# multiple of the system page size. +# +# MAXPHYS is the absolute maximum physical I/O transaction size. +# It must be a multiple of the system page size. +# +# In general you should not modify either DFLTPHYS or MAXPHYS. +# +options BLKDEV_IOSIZE=8192 +options DFLTPHYS="(64*1024)" +options MAXPHYS="(128*1024)" + # Options for the VM subsystem #options PQ_NOOPT # No coloring options PQ_LARGECACHE # color for 512k/16k cache diff --git a/sys/i386/include/param.h b/sys/i386/include/param.h index 1a8b1a724b95..0bd98e4e63b3 100644 --- a/sys/i386/include/param.h +++ b/sys/i386/include/param.h @@ -91,9 +91,15 @@ #define DEV_BSHIFT 9 /* log2(DEV_BSIZE) */ #define DEV_BSIZE (1<<DEV_BSHIFT) -#define BLKDEV_IOSIZE 2048 +#ifndef BLKDEV_IOSIZE +#define BLKDEV_IOSIZE PAGE_SIZE /* default block device I/O size */ +#endif +#ifndef DFLTPHYS #define DFLTPHYS (64 * 1024) /* default max raw I/O transfer size */ +#endif +#ifndef MAXPHYS #define MAXPHYS (128 * 1024) /* max raw I/O transfer size */ +#endif #define IOPAGES 2 /* pages of i/o permission bitmap */ #define UPAGES 2 /* pages of u-area */