/*
* GRUB -- GRand Unified Bootloader
* Copyright (C) 1999,2000,2001,2002,2003,2005,2006,2007,2008,2009,2011 Free Software Foundation, Inc.
*
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* GRUB is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with GRUB. If not, see <http://www.gnu.org/licenses/>.
*/
/*
* Note: These functions defined in this file may be called from C.
* Be careful of that you must not modify some registers. Quote
* from gcc-2.95.2/gcc/config/i386/i386.h:
1 for registers not available across function calls.
These must include the FIXED_REGISTERS and also any
registers that can be used without being saved.
The latter must include the registers where values are returned
and the register where structure-value addresses are passed.
Aside from that, you can include as many other registers as you like.
ax,dx,cx,bx,si,di,bp,sp,st,st1,st2,st3,st4,st5,st6,st7,arg
{ 1, 1, 1, 0, 0, 0, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1 }
*/
/*
* Note: GRUB is compiled with the options -mrtd and -mregparm=3.
* So the first three arguments are passed in %eax, %edx, and %ecx,
* respectively, and if a function has a fixed number of arguments
* and the number is greater than three, the function must return
* with "ret $N" where N is ((the number of arguments) - 3) * 4.
*/
#include <config.h>
#include <multiboot.h>
.file "startup.S"
.text
/* copy back the decompressed part (except the modules) */
#if 0
/* copy modules before cleaning out the bss */
#endif
/* clean out the bss */
/* compute the bss length */
/* clean out */
/*
* Call the start of main body of C code.
*/
.long 0
.long 0
.endm
.endm
/*
* grub_exit()
*
* Exit the system.
*/
/* Tell the BIOS a boot failure. If this does not work, reboot. */
int $0x18
/* set 0x472 to 0x0000 for cold boot (0x1234 for warm boot) */
/*
* int grub_pxe_call (int func, void* data, grub_uint32_t pxe_rm_entry);
*/
#include "../int.S"
.bss
.long 0