diff options
author | Kenneth R Westerback <krw@cvs.openbsd.org> | 2021-10-21 13:16:50 +0000 |
---|---|---|
committer | Kenneth R Westerback <krw@cvs.openbsd.org> | 2021-10-21 13:16:50 +0000 |
commit | b6862b7bfeabe653d603e18193e48c805ac341ea (patch) | |
tree | 59a5edb9a3e7d3223218236033240912448af7a0 /sbin/fdisk/cmd.c | |
parent | 00c0d6e9c85a90057c89fb85d302d500cfbba9cd (diff) |
Remove 'disk' editing command. Determining the disk geometry on startup (from
-l, -c/-h/-s or DIOCGPDINFO) should be enough for anyone.
Diffstat (limited to 'sbin/fdisk/cmd.c')
-rw-r--r-- | sbin/fdisk/cmd.c | 31 |
1 files changed, 1 insertions, 30 deletions
diff --git a/sbin/fdisk/cmd.c b/sbin/fdisk/cmd.c index 3ed1209a2bb..82a5290c84f 100644 --- a/sbin/fdisk/cmd.c +++ b/sbin/fdisk/cmd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: cmd.c,v 1.146 2021/09/10 15:26:36 krw Exp $ */ +/* $OpenBSD: cmd.c,v 1.147 2021/10/21 13:16:49 krw Exp $ */ /* * Copyright (c) 1997 Tobias Weingartner @@ -79,35 +79,6 @@ Xreinit(char *args, struct mbr *mbr) } int -Xdisk(char *args, struct mbr *mbr) -{ - int maxcyl = 1024; - int maxhead = 256; - int maxsec = 63; - - DISK_printgeometry(args); - -#if defined (__powerpc__) || defined (__mips__) - maxcyl = 9999999; - maxhead = 9999999; - maxsec = 9999999; -#endif - - if (ask_yn("Change disk geometry?")) { - disk.dk_cylinders = ask_num("BIOS Cylinders", - disk.dk_cylinders, 1, maxcyl); - disk.dk_heads = ask_num("BIOS Heads", - disk.dk_heads, 1, maxhead); - disk.dk_sectors = ask_num("BIOS Sectors", - disk.dk_sectors, 1, maxsec); - - disk.dk_size = disk.dk_cylinders * disk.dk_heads * disk.dk_sectors; - } - - return CMD_CONT; -} - -int Xswap(char *args, struct mbr *mbr) { char *from, *to; |