diff options
-rw-r--r-- | sbin/dumpon/dumpon.c | 8 | ||||
-rw-r--r-- | sys/dev/null/null.c | 2 | ||||
-rw-r--r-- | sys/kern/subr_disk.c | 2 | ||||
-rw-r--r-- | sys/sys/disk.h | 2 |
4 files changed, 7 insertions, 7 deletions
diff --git a/sbin/dumpon/dumpon.c b/sbin/dumpon/dumpon.c index a0b9114..97976ca 100644 --- a/sbin/dumpon/dumpon.c +++ b/sbin/dumpon/dumpon.c @@ -84,9 +84,9 @@ main(int argc, char *argv[]) if (fd < 0) err(EX_OSFILE, "%s", argv[0]); u = 0; - i = ioctl(fd, DIOCGKERNELDUMP, &u); + i = ioctl(fd, DIOCSKERNELDUMP, &u); u = 1; - i = ioctl(fd, DIOCGKERNELDUMP, &u); + i = ioctl(fd, DIOCSKERNELDUMP, &u); if (i == 0 && verbose) printf("kernel dumps on %s\n", argv[0]); @@ -95,12 +95,12 @@ main(int argc, char *argv[]) if (fd < 0) err(EX_OSFILE, "%s", _PATH_DEVNULL); u = 0; - i = ioctl(fd, DIOCGKERNELDUMP, &u); + i = ioctl(fd, DIOCSKERNELDUMP, &u); if (i == 0 && verbose) printf("kernel dumps disabled\n"); } if (i < 0) - err(EX_OSERR, "ioctl(DIOCGKERNELDUMP)"); + err(EX_OSERR, "ioctl(DIOCSKERNELDUMP)"); exit (0); } diff --git a/sys/dev/null/null.c b/sys/dev/null/null.c index 6fa5e2b..c82c3d0 100644 --- a/sys/dev/null/null.c +++ b/sys/dev/null/null.c @@ -97,7 +97,7 @@ null_ioctl(dev_t dev, u_long cmd, caddr_t data, int fflag, struct thread *td) { int error; - if (cmd != DIOCGKERNELDUMP) + if (cmd != DIOCSKERNELDUMP) return (noioctl(dev, cmd, data, fflag, td)); error = suser(td); if (error) diff --git a/sys/kern/subr_disk.c b/sys/kern/subr_disk.c index 155cfc3..b1f3e6a 100644 --- a/sys/kern/subr_disk.c +++ b/sys/kern/subr_disk.c @@ -390,7 +390,7 @@ diskioctl(dev_t dev, u_long cmd, caddr_t data, int fflag, struct thread *td) dp = pdev->si_disk; if (!dp) return (ENXIO); - if (cmd == DIOCGKERNELDUMP) { + if (cmd == DIOCSKERNELDUMP) { u = *(u_int *)data; return (diskdumpconf(u, dev, dp)); } diff --git a/sys/sys/disk.h b/sys/sys/disk.h index 00eec8d..2239189 100644 --- a/sys/sys/disk.h +++ b/sys/sys/disk.h @@ -51,6 +51,6 @@ void disk_invalidate(struct disk *disk); #define DIOCGMEDIASIZE _IOR('d', 129, off_t) /* Get media size in bytes */ #define DIOCGFWSECTORS _IOR('d', 130, u_int) /* Get firmware sectorcount */ #define DIOCGFWHEADS _IOR('d', 131, u_int) /* Get firmware headcount */ -#define DIOCGKERNELDUMP _IOW('d', 133, u_int) /* Set/Clear kernel dumps */ +#define DIOCSKERNELDUMP _IOW('d', 133, u_int) /* Set/Clear kernel dumps */ #endif /* _SYS_DISK_H_ */ |