diff options
author | Karel Zak | 2010-06-15 13:13:05 +0200 |
---|---|---|
committer | Karel Zak | 2010-06-15 13:13:05 +0200 |
commit | 0b1f769f281ac2feb21b8a52af3fe999922c8833 (patch) | |
tree | 8696910bae2fa8dc953ba1cb72b30675b1a66066 /fdisk | |
parent | lscpu: fix typo, "faild" to "failed" (diff) | |
download | kernel-qcow2-util-linux-0b1f769f281ac2feb21b8a52af3fe999922c8833.tar.gz kernel-qcow2-util-linux-0b1f769f281ac2feb21b8a52af3fe999922c8833.tar.xz kernel-qcow2-util-linux-0b1f769f281ac2feb21b8a52af3fe999922c8833.zip |
fdisk: disable DOS mode and cylinders by default
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'fdisk')
-rw-r--r-- | fdisk/fdisk.8 | 4 | ||||
-rw-r--r-- | fdisk/fdisk.c | 22 |
2 files changed, 13 insertions, 13 deletions
diff --git a/fdisk/fdisk.8 b/fdisk/fdisk.8 index 30dc9678a..bd94a020d 100644 --- a/fdisk/fdisk.8 +++ b/fdisk/fdisk.8 @@ -190,7 +190,7 @@ between logical and physical sector size. This option changes both sector sizes Print help and then exit. .TP .BI \-c -Switch off DOS-compatible mode. (Recommended) +Switch off DOS-compatible mode. (Default) .TP .BI "\-C " cyls Specify the number of cylinders of the disk. @@ -215,7 +215,7 @@ If no devices are given, those mentioned in .TP .B \-u When listing partition tables, give sizes in sectors instead -of cylinders. +of cylinders. (Default) .TP .BI "\-s " partition The diff --git a/fdisk/fdisk.c b/fdisk/fdisk.c index 26bc19e1a..f1392e7b6 100644 --- a/fdisk/fdisk.c +++ b/fdisk/fdisk.c @@ -204,7 +204,7 @@ int fd, /* the disk */ ext_index, /* the prime extended partition */ listing = 0, /* no aborts for fdisk -l */ nowarn = 0, /* no warnings for fdisk -l/-s */ - dos_compatible_flag = ~0, + dos_compatible_flag = 0, /* disabled by default */ dos_changed = 0, partitions = 4; /* maximum partition + 1 */ @@ -220,7 +220,7 @@ unsigned int heads, sector_factor = 1, user_set_sector_size = 0, units_per_sector = 1, - display_in_cyl_units = 1; + display_in_cyl_units = 0; unsigned long long total_number_of_sectors; /* (!) 512-byte sectors */ unsigned long grain = DEFAULT_SECTOR_SIZE, @@ -259,14 +259,14 @@ void fatal(enum failure why) { " fdisk [options] -l <disk> list partition table(s)\n" " fdisk -s <partition> give partition size(s) in blocks\n" "\nOptions:\n" -" -b <size> sector size (512, 1024, 2048 or 4096)\n" -" -c switch off DOS-compatible mode\n" -" -h print this help text\n" -" -u show sizes in sectors instead of cylinders\n" -" -v print program version\n" -" -C <number> specify the number of cylinders\n" -" -H <number> specify the number of heads\n" -" -S <number> specify the number of sectors per track\n" +" -b <size> sector size (512, 1024, 2048 or 4096)\n" +" -c switch off DOS-compatible mode (default)\n" +" -h print this help text\n" +" -u show sizes in sectors instead of cylinders (default)\n" +" -v print program version\n" +" -C <number> specify the number of cylinders\n" +" -H <number> specify the number of heads\n" +" -S <number> specify the number of sectors per track\n" "\n"); break; case unable_to_open: @@ -764,7 +764,7 @@ void update_units(void) if (display_in_cyl_units && cyl_units) units_per_sector = cyl_units; else - units_per_sector = 1; /* in sectors */ + units_per_sector = 1; /* in sectors */ } static void |