* include/grub/symbol.h (EXT_C) [!ASM_FILE]: Redefine with strings.
* grub-core/lib/i386/backtrace.c (grub_backtrace): Use EXT_C.
This commit is contained in:
parent
70115b995d
commit
5982495738
3 changed files with 12 additions and 2 deletions
|
@ -1,3 +1,8 @@
|
||||||
|
2012-02-29 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
|
* include/grub/symbol.h (EXT_C) [!ASM_FILE]: Redefine with strings.
|
||||||
|
* grub-core/lib/i386/backtrace.c (grub_backtrace): Use EXT_C.
|
||||||
|
|
||||||
2012-02-29 Vladimir Serbinenko <phcoder@gmail.com>
|
2012-02-29 Vladimir Serbinenko <phcoder@gmail.com>
|
||||||
|
|
||||||
* grub-core/gdb/i386/machdep.S: Use VARIABLE and EXT_C instead of
|
* grub-core/gdb/i386/machdep.S: Use VARIABLE and EXT_C instead of
|
||||||
|
|
|
@ -57,10 +57,10 @@ grub_backtrace (void)
|
||||||
{
|
{
|
||||||
#ifdef __x86_64__
|
#ifdef __x86_64__
|
||||||
asm volatile ("movq %rbp, %rdi\n"
|
asm volatile ("movq %rbp, %rdi\n"
|
||||||
"call grub_backtrace_pointer");
|
"call " EXT_C("grub_backtrace_pointer"));
|
||||||
#else
|
#else
|
||||||
asm volatile ("movl %ebp, %eax\n"
|
asm volatile ("movl %ebp, %eax\n"
|
||||||
"call grub_backtrace_pointer");
|
"call " EXT_C("grub_backtrace_pointer"));
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -26,9 +26,14 @@
|
||||||
|
|
||||||
/* Add an underscore to a C symbol in assembler code if needed. */
|
/* Add an underscore to a C symbol in assembler code if needed. */
|
||||||
#ifndef GRUB_UTIL
|
#ifndef GRUB_UTIL
|
||||||
|
|
||||||
#if HAVE_ASM_USCORE
|
#if HAVE_ASM_USCORE
|
||||||
|
#ifdef ASM_FILE
|
||||||
# define EXT_C(sym) _ ## sym
|
# define EXT_C(sym) _ ## sym
|
||||||
#else
|
#else
|
||||||
|
# define EXT_C(sym) "_" sym
|
||||||
|
#endif
|
||||||
|
#else
|
||||||
# define EXT_C(sym) sym
|
# define EXT_C(sym) sym
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue