aboutsummaryrefslogtreecommitdiff
path: root/util-linux/fdisk_osf.c
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2007-12-16 17:22:33 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2007-12-16 17:22:33 +0000
commitf77f369ce89549ae3b0b70bfbac4e9c242ec5298 (patch)
treeb7b9979a4dc949a9bd7f8db90c48ba5491eb1844 /util-linux/fdisk_osf.c
parentc794c51a1aa23d2edcff8e1ab4edf96194d3208c (diff)
downloadbusybox-f77f369ce89549ae3b0b70bfbac4e9c242ec5298.tar.gz
fdisk: reduce global data/bss usage. 8k data+bss build is achievable soon ;)
(add/remove: 0/13 grow/shrink: 6/19 up/down: 74/-492) Total: -418 bytes text data bss dec hex filename 778330 860 7408 786598 c00a6 busybox_old 777970 840 7376 786186 bff0a busybox_unstripped
Diffstat (limited to 'util-linux/fdisk_osf.c')
-rw-r--r--util-linux/fdisk_osf.c12
1 files changed, 5 insertions, 7 deletions
diff --git a/util-linux/fdisk_osf.c b/util-linux/fdisk_osf.c
index 726138265..5a7e6323d 100644
--- a/util-linux/fdisk_osf.c
+++ b/util-linux/fdisk_osf.c
@@ -240,8 +240,6 @@ static const char *const xbsd_fstypes[] = {
Also fixed unaligned accesses in alpha_bootblock_checksum()
*/
-static int possibly_osf_label;
-
#define FREEBSD_PARTITION 0xa5
#define NETBSD_PARTITION 0xa9
@@ -876,10 +874,10 @@ xbsd_initlabel(struct partition *p)
d->d_flags = 0;
#endif
d->d_secsize = SECTOR_SIZE; /* bytes/sector */
- d->d_nsectors = sectors; /* sectors/track */
- d->d_ntracks = heads; /* tracks/cylinder (heads) */
- d->d_ncylinders = cylinders;
- d->d_secpercyl = sectors * heads; /* sectors/cylinder */
+ d->d_nsectors = g_sectors; /* sectors/track */
+ d->d_ntracks = g_heads; /* tracks/cylinder (heads) */
+ d->d_ncylinders = g_cylinders;
+ d->d_secpercyl = g_sectors * g_heads;/* sectors/cylinder */
if (d->d_secpercyl == 0)
d->d_secpercyl = 1; /* avoid segfaults */
d->d_secperunit = d->d_secpercyl * d->d_ncylinders;
@@ -1027,7 +1025,7 @@ xbsd_link_part(void)
int k, i;
struct partition *p;
- k = get_partition(1, partitions);
+ k = get_partition(1, g_partitions);
if (!xbsd_check_new_partition(&i))
return;