On Sat, May 20, 2006 at 09:28:15PM -0500, Will L G wrote: >On startup I immediatedly received the error: The attached patch should fix the following problem: >Fatal server error: >R_ALPHA_GPRELHIGH symval-got is too large for trans:fffffffffe011f6e Let me know how it works for you. David -- David Dawes X-Oz Technologies www.XFree86.org/~dawes www.x-oz.com
Index: elfloader.c =================================================================== RCS file: /home/x-cvs/xc/programs/Xserver/hw/xfree86/loader/elfloader.c,v retrieving revision 1.72 diff -u -r1.72 elfloader.c --- elfloader.c 6 Jun 2006 01:20:43 -0000 1.72 +++ elfloader.c 27 Jun 2006 18:31:26 -0000 @@ -1959,11 +1959,12 @@ case R_ALPHA_GPRELHIGH: { + int nonfatal = 0; dest64 = (unsigned long *)(secp + rel->r_offset); dest16 = (unsigned short *)dest64; #if LOADERDEBUG - LoaderDebugMsg(LOADER_DEBUG_LOWLEVEL, "R_ALPHA_GPRELLOW %s\t", + LoaderDebugMsg(LOADER_DEBUG_LOWLEVEL, "R_ALPHA_GPRELHIGH %s\t", ElfGetSymbolName(elffile, ELF_R_SYM(rel->r_info))); LoaderDebugMsg(LOADER_DEBUG_LOWLEVEL, "secp=%p\t", secp); LoaderDebugMsg(LOADER_DEBUG_LOWLEVEL, "symval=%lx\t", symval); @@ -1976,6 +1977,11 @@ #if LOADERDEBUG LoaderDebugMsg(LOADER_DEBUG_LOWLEVEL, "symval=%lx\t", symval); #endif + /* + * R_ALPHA_GPRELHIGH relocations to LoaderDefaultFunc should be + * temporary, so ignore out of range problems with them. + */ + nonfatal = (symval == (Elf_Addr) &LoaderDefaultFunc); symval = ((unsigned char *)symval) - ((unsigned char *)elffile->got); #if LOADERDEBUG @@ -1983,10 +1989,22 @@ #endif symval = ((long)symval >> 16) + ((symval >> 15) & 1); if ((long)symval > 0x7fff || (long)symval < -(long)0x8000) { - FatalError - ("R_ALPHA_GPRELHIGH symval-got is too large for %s:%lx (%ld)\n", - ElfGetSymbolName(elffile, ELF_R_SYM(rel->r_info)), - symval, symval); + if (nonfatal) { +#if LOADERDEBUG + LoaderDebugMsg(LOADER_DEBUG_LOWLEVEL, + "R_ALPHA_GPRELHIGH symval-got is too large " + "for %s:%lx (%ld)\n", + ElfGetSymbolName(elffile, + ELF_R_SYM(rel->r_info)), + symval, symval); +#endif + } else { + FatalError("R_ALPHA_GPRELHIGH symval-got is too large " + "for %s:%lx (%ld)\n", + ElfGetSymbolName(elffile, + ELF_R_SYM(rel->r_info)), + symval, symval); + } } #if LOADERDEBUG