From 9df2ac603e8c6bbd0aac389510813811abc4e54f Mon Sep 17 00:00:00 2001 From: Karel Zak Date: Thu, 5 Jan 2012 16:58:56 +0100 Subject: [PATCH] sfdisk: remove PACKED macro Signed-off-by: Karel Zak --- fdisk/sfdisk.c | 20 +++----------------- 1 file changed, 3 insertions(+), 17 deletions(-) diff --git a/fdisk/sfdisk.c b/fdisk/sfdisk.c index cb353402b9..3727253af2 100644 --- a/fdisk/sfdisk.c +++ b/fdisk/sfdisk.c @@ -20,16 +20,11 @@ * * The current program is a rewrite from scratch, and I started a * version numbering at 3.0. - * Andries Brouwer, aeb@cwi.nl, 950813 + * Andries Brouwer, aeb@cwi.nl, 950813 * * Well, a good user interface is still lacking. On the other hand, * many configurations cannot be handled by any other fdisk. * I changed the name to sfdisk to prevent confusion. - aeb, 970501 - * - * Changes: - * 19990319 - Arnaldo Carvalho de Melo - i18n - * 20040428 - Jeroen Dobbelaere - added PACKED - * 20040824 - David A. Wheeler - warnings to stderr */ #define PROGNAME "sfdisk" @@ -115,15 +110,6 @@ error(char *s, ...) { va_end(p); } -/* - * arm needs PACKED - use it everywhere? - */ -#if defined(__GNUC__) && (defined(__arm__) || defined(__alpha__)) -#define PACKED __attribute__ ((packed)) -#else -#define PACKED -#endif - /* * A. About seeking */ @@ -497,7 +483,7 @@ get_cylindersize(char *dev, int fd, int silent) { typedef struct { unsigned char h, s, c; -} PACKED chs; /* has some c bits in s */ +} __attribute__ ((packed)) chs; /* has some c bits in s */ chs zero_chs = { 0, 0, 0 }; typedef struct { @@ -656,7 +642,7 @@ struct partition { chs end_chs; unsigned int start_sect; /* starting sector counting from 0 */ unsigned int nr_sects; /* nr of sectors in partition */ -} PACKED; +} __attribute__ ((packed)); /* Unfortunately, partitions are not aligned, and non-Intel machines are unhappy with non-aligned integers. So, we need a copy by hand. */ -- 2.47.2