[librm] Provide an abstraction wrapper for prot_call
Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
@@ -18,6 +18,8 @@
|
||||
|
||||
FILE_LICENCE ( GPL2_ONLY )
|
||||
|
||||
#include <librm.h>
|
||||
|
||||
.equ BOOTSEG, 0x07C0 /* original address of boot-sector */
|
||||
|
||||
.equ SYSSEG, 0x1000 /* system loaded at SYSSEG<<4 */
|
||||
@@ -370,8 +372,8 @@ start_runtime:
|
||||
lret
|
||||
.section ".text16", "awx", @progbits
|
||||
1:
|
||||
pushl $main
|
||||
call prot_call
|
||||
/* Run iPXE */
|
||||
virtcall main
|
||||
|
||||
/* Uninstall iPXE */
|
||||
call uninstall
|
||||
|
||||
@@ -24,6 +24,8 @@
|
||||
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
|
||||
#include <librm.h>
|
||||
|
||||
/* Initial temporary stack size */
|
||||
#define EXE_STACK_SIZE 0x400
|
||||
|
||||
@@ -148,8 +150,7 @@ _exe_start:
|
||||
movl %esi, cmdline_phys
|
||||
|
||||
/* Run iPXE */
|
||||
pushl $main
|
||||
call prot_call
|
||||
virtcall main
|
||||
|
||||
/* Uninstall iPXE */
|
||||
call uninstall
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
|
||||
#include <librm.h>
|
||||
|
||||
.text
|
||||
.arch i386
|
||||
.section ".prefix", "awx", @progbits
|
||||
@@ -99,8 +101,8 @@ start_image:
|
||||
lret
|
||||
.section ".text16", "awx", @progbits
|
||||
1:
|
||||
pushl $main
|
||||
call prot_call
|
||||
/* Run iPXE */
|
||||
virtcall main
|
||||
|
||||
/* Uninstall iPXE */
|
||||
call uninstall
|
||||
|
||||
@@ -24,6 +24,8 @@
|
||||
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
|
||||
#include <librm.h>
|
||||
|
||||
.arch i386
|
||||
|
||||
/* Image compression enabled */
|
||||
@@ -887,8 +889,7 @@ payload_death_message:
|
||||
* ready for the copy to the new location.
|
||||
*/
|
||||
progress " relocate\n"
|
||||
pushl $relocate
|
||||
call prot_call
|
||||
virtcall relocate
|
||||
|
||||
/* Jump back to .prefix segment */
|
||||
pushw $1f
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
|
||||
#include <librm.h>
|
||||
|
||||
#define BZI_LOAD_HIGH_ADDR 0x100000
|
||||
|
||||
.text
|
||||
@@ -197,8 +199,7 @@ no_cmd_line:
|
||||
movl %ecx, initrd_len
|
||||
|
||||
/* Run iPXE */
|
||||
pushl $main
|
||||
call prot_call
|
||||
virtcall main
|
||||
|
||||
/* Uninstall iPXE */
|
||||
call uninstall
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
|
||||
#include <librm.h>
|
||||
|
||||
.text
|
||||
.arch i386
|
||||
.code16
|
||||
@@ -66,8 +68,8 @@ _nbi_start:
|
||||
lret
|
||||
.section ".text16", "awx", @progbits
|
||||
1:
|
||||
pushl $main
|
||||
call prot_call
|
||||
/* Run iPXE */
|
||||
virtcall main
|
||||
|
||||
/* Uninstall iPXE */
|
||||
call uninstall
|
||||
|
||||
@@ -16,6 +16,7 @@ FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
.org 0
|
||||
.code16
|
||||
|
||||
#include <librm.h>
|
||||
#include <undi.h>
|
||||
|
||||
#define STACK_MAGIC ( 'L' + ( 'R' << 8 ) + ( 'E' << 16 ) + ( 'T' << 24 ) )
|
||||
@@ -820,8 +821,7 @@ run_ipxe:
|
||||
movl %ecx, cached_dhcpack_phys
|
||||
|
||||
/* Run main program */
|
||||
pushl $main
|
||||
call prot_call
|
||||
virtcall main
|
||||
|
||||
/* Uninstall iPXE */
|
||||
call uninstall
|
||||
|
||||
@@ -8,6 +8,7 @@
|
||||
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
|
||||
#include <librm.h>
|
||||
#include <config/general.h>
|
||||
#include <config/branding.h>
|
||||
|
||||
@@ -806,9 +807,8 @@ exec: /* Set %ds = %cs */
|
||||
#endif /* AUTOBOOT_ROM_FILTER */
|
||||
.endif
|
||||
|
||||
/* Call main() */
|
||||
pushl $main
|
||||
call prot_call
|
||||
/* Run iPXE */
|
||||
virtcall main
|
||||
|
||||
/* Set up flat real mode for return to BIOS */
|
||||
call flatten_real_mode
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
FILE_LICENCE ( GPL2_OR_LATER_OR_UBDL )
|
||||
|
||||
#include <librm.h>
|
||||
|
||||
.text
|
||||
.code16
|
||||
.arch i386
|
||||
@@ -45,8 +47,7 @@ undiloader:
|
||||
.section ".text16", "ax", @progbits
|
||||
1:
|
||||
/* Call UNDI loader C code */
|
||||
pushl $pxe_loader_call
|
||||
call prot_call
|
||||
virtcall pxe_loader_call
|
||||
|
||||
1: /* Restore registers and return */
|
||||
popw %bx
|
||||
|
||||
Reference in New Issue
Block a user