*/
static int nbi_boot16 ( struct image *image, struct imgheader *imgheader ) {
int discard_D, discard_S, discard_b;
- int rc;
+ int32_t rc;
DBGC ( image, "NBI %p executing 16-bit image at %04x:%04x\n", image,
imgheader->execaddr.segoff.segment,
0
};
int discard_D, discard_S, discard_b;
- int rc;
+ int32_t rc;
DBGC ( image, "NBI %p executing 32-bit image at %lx\n",
image, imgheader->execaddr.linear );
struct memory_region *prev_region = NULL;
uint32_t next = 0;
uint32_t smap;
- size_t size;
+ uint32_t size;
unsigned int flags;
unsigned int discard_D;
}
if ( size < E820_MIN_SIZE ) {
- DBG ( "INT 15,e820 returned only %zd bytes\n", size );
+ DBG ( "INT 15,e820 returned only %d bytes\n", size );
return -EINVAL;
}
*/
int pcibios_read ( struct pci_device *pci, uint32_t command, uint32_t *value ){
int discard_b, discard_D;
- int status;
+ uint16_t status;
__asm__ __volatile__ ( REAL_CODE ( "stc\n\t"
"int $0x1a\n\t"
"b" ( pci->busdevfn )
: "edx" );
- return ( ( status >> 8 ) & 0xff );
+ return ( status >> 8 );
}
/**
*/
int pcibios_write ( struct pci_device *pci, uint32_t command, uint32_t value ){
int discard_b, discard_c, discard_D;
- int status;
+ uint16_t status;
__asm__ __volatile__ ( REAL_CODE ( "stc\n\t"
"int $0x1a\n\t"
"b" ( pci->busdevfn ), "c" ( value )
: "edx" );
- return ( ( status >> 8 ) & 0xff );
+ return ( status >> 8 );
}
PROVIDE_PCIAPI ( pcbios, pci_num_bus, pcibios_num_bus );
/* Disable interrupts */
"cli\n\t"
)
- : "=a" ( after ), "=d" ( before ), "=q" ( temp )
+ : "=a" ( after ), "=d" ( before ), "=Q" ( temp )
: "2" ( 0 ) );
return ( after - before );
void *params, size_t params_len ) {
struct pxeparent_profiler *profiler = pxeparent_profiler ( function );
PXENV_EXIT_t exit;
- unsigned long started;
- unsigned long stopped;
+ uint32_t before;
+ uint32_t started;
+ uint32_t stopped;
+ uint32_t after;
int discard_D;
int rc;
"D" ( __from_data16 ( &pxeparent_params ) )
: "ecx", "esi" );
profile_stop ( &profiler->total );
- profile_start_at ( &profiler->p2r, profile_started ( &profiler->total));
+ before = profile_started ( &profiler->total );
+ after = profile_stopped ( &profiler->total );
+ profile_start_at ( &profiler->p2r, before );
profile_stop_at ( &profiler->p2r, started );
profile_start_at ( &profiler->ext, started );
profile_stop_at ( &profiler->ext, stopped );
profile_start_at ( &profiler->r2p, stopped );
- profile_stop_at ( &profiler->r2p, profile_stopped ( &profiler->total ));
+ profile_stop_at ( &profiler->r2p, after );
/* Determine return status code based on PXENV_EXIT and
* PXENV_STATUS