On Tue, Apr 15, 2008 at 12:30:40AM +0200, Lubomir Kundrak wrote: > diff -rup grub-1.95.orig/kern/main.c grub-1.95/kern/main.c > --- grub-1.95.orig/kern/main.c 2007-01-29 15:31:36.000000000 +0100 > +++ grub-1.95/kern/main.c 2007-01-30 18:29:55.000000000 +0100 > @@ -106,6 +106,14 @@ grub_load_normal_mode (void) > grub_errno = GRUB_ERR_NONE; > } > > +#ifndef GRUB_UTIL > +/* > + * Let GDB find the stack top > + */ > +void > +main (void) __attribute__ ((alias("grub_main"))); > +#endif
grub_main() isn't always the function we want for top of the stack. For example cmain() in kern/ieee1275/cmain.c does quite a bit of things already. I'm not sure what would be an ellegant way to solve this... :-/ -- Robert Millan <GPLv2> I know my rights; I want my phone call! <DRM> What use is a phone call… if you are unable to speak? (as seen on /.) _______________________________________________ Grub-devel mailing list Grub-devel@gnu.org http://lists.gnu.org/mailman/listinfo/grub-devel