2004-07-27 Marco Gerards <metgerards@student.han.nl>

* boot/powerpc/ieee1275/ieee1275.c (grub_ieee1275_release): New
	function.
	* commands/boot.c: Remove the check for `GRUB_UTIL'.
	* conf/powerpc-ieee1275.rmk (grubof_SOURCES): Add
	`loader/powerpc/ieee1275/linux.c',
	`loader/powerpc/ieee1275/linux_normal.c' and `commands/boot.c'.
	* include/grub/powerpc/ieee1275/ieee1275.h
	(grub_ieee1275_release): New prototype.
	* include/grub/powerpc/ieee1275/loader.h: Rewritten.
	* kern/powerpc/ieee1275/init.c (grub_machine_init): Initialize
	normal, boot, linux and linux_normal.
	* loader/powerpc/ieee1275/linux.c: New file.
	* loader/powerpc/ieee1275/linux_normal.c: Likewise.
This commit is contained in:
marco_g 2004-07-27 17:47:37 +00:00
parent 5a9e354626
commit a447c5dfb2
9 changed files with 398 additions and 31 deletions

View file

@ -84,6 +84,7 @@ int EXPORT_FUNC(grub_ieee1275_open) (char *node,
int EXPORT_FUNC(grub_ieee1275_close) (grub_ieee1275_ihandle_t ihandle);
int EXPORT_FUNC(grub_ieee1275_claim) (void *p, grub_size_t size, unsigned int align,
void **result);
int EXPORT_FUNC(grub_ieee1275_release) (void *p, grub_size_t size);
int EXPORT_FUNC(grub_ieee1275_set_property) (grub_ieee1275_phandle_t phandle,
const char *propname, void *buf,
grub_size_t size,

View file

@ -1,7 +1,6 @@
/*
* GRUB -- GRand Unified Bootloader
* Copyright (C) 2002 Yoshinori K. Okuji <okuji@enbug.org>
* Copyright (C) 2003 Jeroen Dekkers <jeroen@dekkers.cx>
* Copyright (C) 2004 Free Software Foundation, Inc.
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
@ -21,31 +20,13 @@
#ifndef GRUB_LOADER_MACHINE_HEADER
#define GRUB_LOADER_MACHINE_HEADER 1
#include <grub/types.h>
#include <grub/symbol.h>
#include <grub/machine/multiboot.h>
/* The symbol shared between the normal mode and rescue mode
loader. */
void grub_load_linux (int argc, char *argv[]);
extern grub_uint32_t EXPORT_VAR(grub_linux_prot_size);
extern char *EXPORT_VAR(grub_linux_tmp_addr);
extern char *EXPORT_VAR(grub_linux_real_addr);
void EXPORT_FUNC(grub_linux_boot_zimage) (void) __attribute__ ((noreturn));
void EXPORT_FUNC(grub_linux_boot_bzimage) (void) __attribute__ ((noreturn));
/* This is an asm part of the chainloader. */
void EXPORT_FUNC(grub_chainloader_real_boot) (int drive, void *part_addr) __attribute__ ((noreturn));
/* The asm part of the multiboot loader. */
void EXPORT_FUNC(grub_multiboot_real_boot) (grub_addr_t entry,
struct grub_multiboot_info *mbi)
__attribute__ ((noreturn));
/* It is necessary to export these functions, because normal mode commands
reuse rescue mode commands. */
void grub_rescue_cmd_chainloader (int argc, char *argv[]);
void grub_rescue_cmd_linux (int argc, char *argv[]);
void grub_rescue_cmd_initrd (int argc, char *argv[]);
void grub_rescue_cmd_multiboot (int argc, char *argv[]);
void grub_rescue_cmd_module (int argc, char *argv[]);
void grub_linux_init (void);
void grub_linux_fini (void);
void grub_linux_normal_init (void);
void grub_linux_normal_fini (void);
#endif /* ! GRUB_LOADER_MACHINE_HEADER */