diff options
author | phk <phk@FreeBSD.org> | 2007-12-16 18:03:31 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2007-12-16 18:03:31 +0000 |
commit | e8d782d36d88f5bfd513e485080cea240a6df978 (patch) | |
tree | 37d34ffd3142f02e8bde7f9d7e8720a56633e992 /sys/geom | |
parent | f9bd6ffc2d69fbf7654c64c285fb1ad394e53d25 (diff) | |
download | FreeBSD-src-e8d782d36d88f5bfd513e485080cea240a6df978.zip FreeBSD-src-e8d782d36d88f5bfd513e485080cea240a6df978.tar.gz |
Don't limit BIO_DELETE requests to MAXPHYS, they perform no data
transfers, so they are not subject to the VM system limitation.
Diffstat (limited to 'sys/geom')
-rw-r--r-- | sys/geom/geom_dev.c | 3 | ||||
-rw-r--r-- | sys/geom/geom_io.c | 5 |
2 files changed, 3 insertions, 5 deletions
diff --git a/sys/geom/geom_dev.c b/sys/geom/geom_dev.c index 5c7ac66..2c62b49 100644 --- a/sys/geom/geom_dev.c +++ b/sys/geom/geom_dev.c @@ -302,8 +302,7 @@ g_dev_ioctl(struct cdev *dev, u_long cmd, caddr_t data, int fflag, struct thread offset = ((off_t *)data)[0]; length = ((off_t *)data)[1]; if ((offset % cp->provider->sectorsize) != 0 || - (length % cp->provider->sectorsize) != 0 || - length <= 0 || length > MAXPHYS) { + (length % cp->provider->sectorsize) != 0 || length <= 0) { printf("%s: offset=%jd length=%jd\n", __func__, offset, length); error = EINVAL; diff --git a/sys/geom/geom_io.c b/sys/geom/geom_io.c index 3848f45..5e27f36 100644 --- a/sys/geom/geom_io.c +++ b/sys/geom/geom_io.c @@ -652,9 +652,8 @@ g_delete_data(struct g_consumer *cp, off_t offset, off_t length) struct bio *bp; int error; - KASSERT(length > 0 && length >= cp->provider->sectorsize && - length <= MAXPHYS, ("g_delete_data(): invalid length %jd", - (intmax_t)length)); + KASSERT(length > 0 && length >= cp->provider->sectorsize, + ("g_delete_data(): invalid length %jd", (intmax_t)length)); bp = g_alloc_bio(); bp->bio_cmd = BIO_DELETE; |