david/ipxe
david
/
ipxe
Archived
1
0
Fork 0

Move uninitialised .data16 variables to .bss16; saves around 2000

bytes of useless zeroes in the final image.
This commit is contained in:
Michael Brown 2007-07-16 13:22:12 +01:00
parent 389204713f
commit 6d2e4e719c
6 changed files with 10 additions and 10 deletions

View File

@ -27,4 +27,4 @@
#include <basemem_packet.h> #include <basemem_packet.h>
#undef basemem_packet #undef basemem_packet
char __data16_array ( basemem_packet, [BASEMEM_PACKET_LEN] ); char __bss16_array ( basemem_packet, [BASEMEM_PACKET_LEN] );

View File

@ -36,11 +36,11 @@
*/ */
/** Parameter block for calling UNDI loader */ /** Parameter block for calling UNDI loader */
static struct s_UNDI_LOADER __data16 ( undi_loader ); static struct s_UNDI_LOADER __bss16 ( undi_loader );
#define undi_loader __use_data16 ( undi_loader ) #define undi_loader __use_data16 ( undi_loader )
/** UNDI loader entry point */ /** UNDI loader entry point */
static SEGOFF16_t __data16 ( undi_loader_entry ); static SEGOFF16_t __bss16 ( undi_loader_entry );
#define undi_loader_entry __use_data16 ( undi_loader_entry ) #define undi_loader_entry __use_data16 ( undi_loader_entry )
/** /**

View File

@ -136,7 +136,7 @@ undinet_function_name ( unsigned int function ) {
* Used as the paramter block for all UNDI API calls. Resides in base * Used as the paramter block for all UNDI API calls. Resides in base
* memory. * memory.
*/ */
static union u_PXENV_ANY __data16 ( undinet_params ); static union u_PXENV_ANY __bss16 ( undinet_params );
#define undinet_params __use_data16 ( undinet_params ) #define undinet_params __use_data16 ( undinet_params )
/** UNDI entry point /** UNDI entry point
@ -144,7 +144,7 @@ static union u_PXENV_ANY __data16 ( undinet_params );
* Used as the indirection vector for all UNDI API calls. Resides in * Used as the indirection vector for all UNDI API calls. Resides in
* base memory. * base memory.
*/ */
SEGOFF16_t __data16 ( undinet_entry_point ); SEGOFF16_t __bss16 ( undinet_entry_point );
#define undinet_entry_point __use_data16 ( undinet_entry_point ) #define undinet_entry_point __use_data16 ( undinet_entry_point )
/** /**

View File

@ -49,7 +49,7 @@ struct e820_entry {
#define E820_TYPE_NVS 4 /**< ACPI NVS memory */ #define E820_TYPE_NVS 4 /**< ACPI NVS memory */
/** Buffer for INT 15,e820 calls */ /** Buffer for INT 15,e820 calls */
static struct e820_entry __data16 ( e820buf ); static struct e820_entry __bss16 ( e820buf );
#define e820buf __use_data16 ( e820buf ) #define e820buf __use_data16 ( e820buf )
/** /**

View File

@ -195,7 +195,7 @@ multiboot_build_module_list ( struct image *image,
* along with the other structures belonging to the Multiboot * along with the other structures belonging to the Multiboot
* information table. * information table.
*/ */
static struct multiboot_info __data16 ( mbinfo ); static struct multiboot_info __bss16 ( mbinfo );
#define mbinfo __use_data16 ( mbinfo ) #define mbinfo __use_data16 ( mbinfo )
/** The multiboot bootloader name */ /** The multiboot bootloader name */
@ -204,11 +204,11 @@ static char __data16_array ( mb_bootloader_name, [] ) = "gPXE " VERSION;
/** The multiboot memory map */ /** The multiboot memory map */
static struct multiboot_memory_map static struct multiboot_memory_map
__data16_array ( mbmemmap, [MAX_MEMORY_REGIONS] ); __bss16_array ( mbmemmap, [MAX_MEMORY_REGIONS] );
#define mbmemmap __use_data16 ( mbmemmap ) #define mbmemmap __use_data16 ( mbmemmap )
/** The multiboot module list */ /** The multiboot module list */
static struct multiboot_module __data16_array ( mbmodules, [MAX_MODULES] ); static struct multiboot_module __bss16_array ( mbmodules, [MAX_MODULES] );
#define mbmodules __use_data16 ( mbmodules ) #define mbmodules __use_data16 ( mbmodules )
/** /**

View File

@ -7,7 +7,7 @@
#define BASEMEM_PACKET_LEN 1514 #define BASEMEM_PACKET_LEN 1514
/** Base memory packet buffer */ /** Base memory packet buffer */
extern char __data16_array ( basemem_packet, [BASEMEM_PACKET_LEN] ); extern char __bss16_array ( basemem_packet, [BASEMEM_PACKET_LEN] );
#define basemem_packet __use_data16 ( basemem_packet ) #define basemem_packet __use_data16 ( basemem_packet )
#endif /* BASEMEM_PACKET_H */ #endif /* BASEMEM_PACKET_H */