fdisk: remove 8k buffer from bss - OSF labels

are not THAT common anyway
This commit is contained in:
Denis Vlasenko
2007-01-03 02:58:54 +00:00
parent 9b1381fd2f
commit d54708399d
3 changed files with 37 additions and 36 deletions

View File

@@ -272,12 +272,9 @@ static struct partition *xbsd_part;
static int xbsd_part_index;
#endif
#if defined(__alpha__)
/* We access this through a uint64_t * when checksumming */
static char disklabelbuffer[BSD_BBSIZE] ATTRIBUTE_ALIGNED(8);
#else
static char disklabelbuffer[BSD_BBSIZE];
#endif
/* hopefully xmalloc gives us required alignment */
static char *disklabelbuffer; /*[BSD_BBSIZE]*/
static struct xbsd_disklabel xbsd_dlabel;
@@ -299,7 +296,7 @@ check_osf_label(void)
}
static int
btrydev(const char * dev)
bsd_trydev(const char * dev)
{
if (xbsd_readlabel(NULL, &xbsd_dlabel) == 0)
return -1;
@@ -309,7 +306,7 @@ btrydev(const char * dev)
}
static void
bmenu(void)
bsd_menu(void)
{
puts(_("Command action"));
puts(_("\td\tdelete a BSD partition"));
@@ -431,7 +428,7 @@ bsd_select(void)
break;
#endif
default:
bmenu();
bsd_menu();
break;
}
}
@@ -921,6 +918,9 @@ xbsd_readlabel(struct partition *p, struct xbsd_disklabel *d)
{
int t, sector;
if (!disklabelbuffer)
disklabelbuffer = xmalloc(BSD_BBSIZE);
/* p is used only to get the starting sector */
#if !defined(__alpha__)
sector = (p ? get_start_sect(p) : 0);