grub-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[patch] small PPC cleanups


From: Hollis Blanchard
Subject: [patch] small PPC cleanups
Date: Sun, 8 May 2005 21:38:24 -0500
User-agent: Mutt/1.5.6+20040907i

This patch corrects a couple of small issues I've come across in the PPC
code:
- struct module_info is unused
- we're declaring space for a stack but not using it
- GRUB_IEEE1275_MODULE_BASE is a 7-char address; add the missing 0

I've tested the stack change on briQ and G3. If there are no comments I
will commit this patch in a couple days.

-Hollis

2005-05-08  Hollis Blanchard  <address@hidden>

        * boot/powerpc/ieee1275/cmain.c (module_info): Remove struct.
        * boot/powerpc/ieee1275/crt0.S (_start): Use init_stack.
        * include/grub/powerpc/ieee1275/kernel.h (GRUB_IEEE1275_MODULE_BASE):
        Correct cosmetic typo.

Index: boot/powerpc/ieee1275/cmain.c
===================================================================
RCS file: /cvsroot/grub/grub2/boot/powerpc/ieee1275/cmain.c,v
retrieving revision 1.7
diff -u -p -r1.7 cmain.c
--- boot/powerpc/ieee1275/cmain.c       1 May 2005 03:45:35 -0000       1.7
+++ boot/powerpc/ieee1275/cmain.c       9 May 2005 02:29:56 -0000
@@ -24,12 +24,6 @@
 #include <grub/machine/ieee1275.h>
 #include <grub/kernel.h>
 
-struct module_info
-{
-  uint32_t start;
-  uint32_t end;
-};
-
 /* OpenFirmware entry point passed to us from the real bootloader.  */
 intptr_t (*grub_ieee1275_entry_fn) (void *);
 
Index: boot/powerpc/ieee1275/crt0.S
===================================================================
RCS file: /cvsroot/grub/grub2/boot/powerpc/ieee1275/crt0.S,v
retrieving revision 1.5
diff -u -p -r1.5 crt0.S
--- boot/powerpc/ieee1275/crt0.S        4 Jan 2005 14:01:45 -0000       1.5
+++ boot/powerpc/ieee1275/crt0.S        9 May 2005 02:29:56 -0000
@@ -25,6 +25,8 @@
        .align  2
        .globl  _start
 _start:        
+       lis     2, address@hidden
+       ori     1, 2, address@hidden
        li      2, 0
        li      13, 0
 
Index: include/grub/powerpc/ieee1275/kernel.h
===================================================================
RCS file: /cvsroot/grub/grub2/include/grub/powerpc/ieee1275/kernel.h,v
retrieving revision 1.1
diff -u -p -r1.1 kernel.h
--- include/grub/powerpc/ieee1275/kernel.h      4 Jan 2005 14:01:45 -0000       
1.1
+++ include/grub/powerpc/ieee1275/kernel.h      9 May 2005 02:29:59 -0000
@@ -21,6 +21,6 @@
 #define GRUB_KERNEL_MACHINE_HEADER     1
 
 /* Where grub-mkimage places the core modules in memory.  */
-#define GRUB_IEEE1275_MODULE_BASE 0x0300000
+#define GRUB_IEEE1275_MODULE_BASE 0x00300000
 
 #endif /* ! GRUB_KERNEL_MACHINE_HEADER */




reply via email to

[Prev in Thread] Current Thread [Next in Thread]