Remove the internal use of __packed and put it on the structures

themselves.

Reviewed by:	nate, peter, warner, robert
Approved by:	re (ken)
This commit is contained in:
Matt Jacob 2007-07-11 22:34:34 +00:00
parent 5415f1deb5
commit 06b642b55d
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=171382
2 changed files with 40 additions and 40 deletions

View File

@ -179,44 +179,44 @@ bmp_splash(video_adapter_t *adp, int on)
*/
typedef struct tagBITMAPFILEHEADER { /* bmfh */
u_short bfType __packed;
int bfSize __packed;
u_short bfReserved1 __packed;
u_short bfReserved2 __packed;
int bfOffBits __packed;
} BITMAPFILEHEADER;
u_short bfType;
int bfSize;
u_short bfReserved1;
u_short bfReserved2;
int bfOffBits;
} __packed BITMAPFILEHEADER;
typedef struct tagBITMAPINFOHEADER { /* bmih */
int biSize __packed;
int biWidth __packed;
int biHeight __packed;
short biPlanes __packed;
short biBitCount __packed;
int biCompression __packed;
int biSizeImage __packed;
int biXPelsPerMeter __packed;
int biYPelsPerMeter __packed;
int biClrUsed __packed;
int biClrImportant __packed;
} BITMAPINFOHEADER;
int biSize;
int biWidth;
int biHeight;
short biPlanes;
short biBitCount;
int biCompression;
int biSizeImage;
int biXPelsPerMeter;
int biYPelsPerMeter;
int biClrUsed;
int biClrImportant;
} __packed BITMAPINFOHEADER;
typedef struct tagRGBQUAD { /* rgbq */
u_char rgbBlue __packed;
u_char rgbGreen __packed;
u_char rgbRed __packed;
u_char rgbReserved __packed;
} RGBQUAD;
u_char rgbBlue;
u_char rgbGreen;
u_char rgbRed;
u_char rgbReserved;
} __packed RGBQUAD;
typedef struct tagBITMAPINFO { /* bmi */
BITMAPINFOHEADER bmiHeader __packed;
RGBQUAD bmiColors[256] __packed;
} BITMAPINFO;
BITMAPINFOHEADER bmiHeader;
RGBQUAD bmiColors[256];
} __packed BITMAPINFO;
typedef struct tagBITMAPF
{
BITMAPFILEHEADER bmfh __packed;
BITMAPINFO bmfi __packed;
} BITMAPF;
BITMAPFILEHEADER bmfh;
BITMAPINFO bmfi;
} __packed BITMAPF;
#define BI_RGB 0
#define BI_RLE8 1

View File

@ -32,21 +32,21 @@
struct vesa_info
{
/* mandatory fields */
u_int8_t v_sig[4]; /* VESA */
u_int16_t v_version __packed; /* ver in BCD */
u_int32_t v_oemstr __packed; /* OEM string */
u_int32_t v_flags __packed; /* flags */
u_int8_t v_sig[4]; /* VESA */
u_int16_t v_version; /* ver in BCD */
u_int32_t v_oemstr; /* OEM string */
u_int32_t v_flags; /* flags */
#define V_DAC8 (1<<0)
#define V_NONVGA (1<<1)
#define V_SNOW (1<<2)
u_int32_t v_modetable __packed; /* modes */
u_int16_t v_memsize __packed; /* in 64K */
u_int32_t v_modetable; /* modes */
u_int16_t v_memsize; /* in 64K */
/* 2.0 */
u_int16_t v_revision __packed; /* software rev */
u_int32_t v_venderstr __packed; /* vender */
u_int32_t v_prodstr __packed; /* product name */
u_int32_t v_revstr __packed; /* product rev */
};
u_int16_t v_revision; /* software rev */
u_int32_t v_venderstr; /* vender */
u_int32_t v_prodstr; /* product name */
u_int32_t v_revstr; /* product rev */
} __packed;
struct vesa_mode
{