tech-x11 archive

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

xserver support for bebox and prep



Hi! all,


Again.  ;-)

I try to support xserver on bebox and prep.  I edit some Makefile-s and
other files.  Moreover it builded xserver.tgz by './build.sh -x release'.

However startx(8) fails.  I see this error message in /var/log/XFree86.0
.log on bebox and prep.  ('offset' is different)

  Fatal server error:
  R_PPC_REL24 PLT offset 1095c6c8 too large


It explains prep here.
My prep machine has a vga with console.

  vga0 at pci0 dev 14 function 0: S3 86C864-1 ("Vision864") (rev. 0x00)


My XF86Config attached to this mail.

I saw the error as which this was the same though I builded with
'USE_JEMALLOC=no' as seen with macppc.

In addition, I did the following correction, and obtained a more detailed
log.


cvs diff: Diffing xfree/xc/programs/Xserver/hw/xfree86/loader
Index: xfree/xc/programs/Xserver/hw/xfree86/loader/elfloader.c
===================================================================
RCS file: 
/cvsroot/xsrc/xfree/xc/programs/Xserver/hw/xfree86/loader/elfloader.c,v
retrieving revision 1.6
diff -u -r1.6 elfloader.c
--- xfree/xc/programs/Xserver/hw/xfree86/loader/elfloader.c     11 Oct 2007 
19:03:22 -0000      1.6
+++ xfree/xc/programs/Xserver/hw/xfree86/loader/elfloader.c     22 Oct 2008 
03:38:18 -0000
@@ -105,6 +105,7 @@
 #define LOADERDEBUG 0
 #endif
 
+#define LOADERDEBUG 1
 #if LOADERDEBUG
 # define ELFDEBUG ErrorF
 #endif


In addition, I did the following correction, and obtained a more detailed
log (over 30MB). The part is appended.

I do not understand the means to solve this problem at all.
Do you have any ideas?

Thanks,
--
kiyohara
? distrib/sets/lists/xserver/md.bebox
? distrib/sets/lists/xserver/md.prep
Index: libexec/ld.elf_so/rtld.c
===================================================================
RCS file: /cvsroot/src/libexec/ld.elf_so/rtld.c,v
retrieving revision 1.120
diff -u -r1.120 rtld.c
--- libexec/ld.elf_so/rtld.c    24 Jul 2008 04:39:25 -0000      1.120
+++ libexec/ld.elf_so/rtld.c    22 Oct 2008 02:39:38 -0000
@@ -813,6 +813,12 @@
        return(NULL);
 }
 
+static void *
+hackish_return_address(void)
+{
+       return __builtin_return_address(1);
+}
+
 __strong_alias(__dlsym,dlsym)
 void *
 dlsym(void *handle, const char *name)
@@ -832,7 +838,8 @@
        case (intptr_t)RTLD_NEXT:
        case (intptr_t)RTLD_DEFAULT:
        case (intptr_t)RTLD_SELF:
-               retaddr = __builtin_return_address(0); /* __GNUC__ only */
+               /* retaddr = __builtin_return_address(0);*/ /* __GNUC__ only */
+               retaddr = hackish_return_address();
                if ((obj = _rtld_obj_from_addr(retaddr)) == NULL) {
                        _rtld_error("Cannot determine caller's shared object");
                        return NULL;
Index: share/mk/bsd.x11.mk
===================================================================
RCS file: /cvsroot/src/share/mk/bsd.x11.mk,v
retrieving revision 1.67
diff -u -r1.67 bsd.x11.mk
--- share/mk/bsd.x11.mk 15 Sep 2008 18:21:48 -0000      1.67
+++ share/mk/bsd.x11.mk 22 Oct 2008 02:40:05 -0000
@@ -116,11 +116,13 @@
 .endif
 
 .if ${MACHINE} == "amd64"      || \
+    ${MACHINE} == "bebox"      || \
     ${MACHINE} == "cats"       || \
     ${MACHINE} == "i386"       || \
     ${MACHINE} == "macppc"     || \
     ${MACHINE} == "netwinder"  || \
     ${MACHINE} == "ofppc"      || \
+    ${MACHINE} == "prep"       || \
     ${MACHINE} == "sgimips"    || \
     ${MACHINE} == "sparc64"    || \
     ${MACHINE} == "sparc"      || \
Index: sys/arch/bebox/include/param.h
===================================================================
RCS file: /cvsroot/src/sys/arch/bebox/include/param.h,v
retrieving revision 1.10
diff -u -r1.10 param.h
--- sys/arch/bebox/include/param.h      17 Oct 2007 19:54:00 -0000      1.10
+++ sys/arch/bebox/include/param.h      22 Oct 2008 02:40:13 -0000
@@ -49,3 +49,6 @@
 #define        KERNBASE        0x3100
 
 #include <powerpc/param.h>
+
+/* at this offset we mmap() the PCI IO range in display drivers */
+#define PCI_MAGIC_IO_RANGE     0xf2000000
Index: sys/arch/prep/include/param.h
===================================================================
RCS file: /cvsroot/src/sys/arch/prep/include/param.h,v
retrieving revision 1.4
diff -u -r1.4 param.h
--- sys/arch/prep/include/param.h       17 Jun 2001 16:01:29 -0000      1.4
+++ sys/arch/prep/include/param.h       22 Oct 2008 02:40:37 -0000
@@ -47,3 +47,6 @@
 #define        KERNBASE        0x100000
 
 #include <powerpc/param.h>
+
+/* at this offset we mmap() the PCI IO range in display drivers */
+#define PCI_MAGIC_IO_RANGE     0xf2000000
Index: x11/Xserver/Makefile.common
===================================================================
RCS file: /cvsroot/src/x11/Xserver/Makefile.common,v
retrieving revision 1.34
diff -u -r1.34 Makefile.common
--- x11/Xserver/Makefile.common 8 Mar 2008 10:38:59 -0000       1.34
+++ x11/Xserver/Makefile.common 22 Oct 2008 02:41:49 -0000
@@ -49,7 +49,8 @@
     ${MACHINE} == "macppc" || ${MACHINE} == "cats" || \
     ${MACHINE} == "sgimips" || ${MACHINE} == "sparc64" || \
     ${MACHINE} == "sparc" || ${MACHINE} == "ofppc" || \
-    ${MACHINE} == "netwinder" || ${MACHINE} == "shark"
+    ${MACHINE} == "netwinder" || ${MACHINE} == "shark" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 XSERVER_NEEDS_XFONT=   yes
 XSERVER_NEEDS_MIEXT=   yes
 XSERVER_XFREE86=       yes
Index: x11/Xserver/hw/xfree86/drivers/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/drivers/Makefile,v
retrieving revision 1.22
diff -u -r1.22 Makefile
--- x11/Xserver/hw/xfree86/drivers/Makefile     8 Mar 2008 10:38:59 -0000       
1.22
+++ x11/Xserver/hw/xfree86/drivers/Makefile     22 Oct 2008 02:41:50 -0000
@@ -11,7 +11,8 @@
 SUBDIR+=       i740 i810 neomagic via vmware
 .endif
 
-.if ${MACHINE} != "macppc" && ${MACHINE} != "sgimips" && ${MACHINE} != "ofppc"
+.if ${MACHINE} != "macppc" && ${MACHINE} != "sgimips" && \
+    ${MACHINE} != "ofppc" && ${MACHINE} != "bebox" && ${MACHINE} != "prep"
 SUBDIR+=       apm ark cirrus cyrix dummy i128 nsc \
                rendition siliconmotion tga tseng vesa
 .endif
Index: x11/Xserver/hw/xfree86/drivers/ati/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/drivers/ati/Makefile,v
retrieving revision 1.6
diff -u -r1.6 Makefile
--- x11/Xserver/hw/xfree86/drivers/ati/Makefile 8 Mar 2008 10:38:59 -0000       
1.6
+++ x11/Xserver/hw/xfree86/drivers/ati/Makefile 22 Oct 2008 02:41:50 -0000
@@ -57,7 +57,8 @@
 # XXX from the Imakefile
 # -DAVOID_NON_PCI must be defined for those platforms that do not
 # tolerate PCI master aborts.
-.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc"
+.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 CPPFLAGS+=     -DAVOID_NON_PCI
 .endif
 
Index: x11/Xserver/hw/xfree86/drivers/atimisc/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/drivers/atimisc/Makefile,v
retrieving revision 1.5
diff -u -r1.5 Makefile
--- x11/Xserver/hw/xfree86/drivers/atimisc/Makefile     8 Mar 2008 10:38:59 
-0000       1.5
+++ x11/Xserver/hw/xfree86/drivers/atimisc/Makefile     22 Oct 2008 02:41:50 
-0000
@@ -67,7 +67,8 @@
 # XXX from the Imakefile
 # -DAVOID_NON_PCI must be defined for those platforms that do not
 # tolerate PCI master aborts.
-.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc"
+.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 CPPFLAGS+=     -DAVOID_NON_PCI
 .endif
 
Index: x11/Xserver/hw/xfree86/drivers/chips/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/drivers/chips/Makefile,v
retrieving revision 1.5
diff -u -r1.5 Makefile
--- x11/Xserver/hw/xfree86/drivers/chips/Makefile       8 Mar 2008 10:38:59 
-0000       1.5
+++ x11/Xserver/hw/xfree86/drivers/chips/Makefile       22 Oct 2008 02:41:50 
-0000
@@ -42,7 +42,8 @@
 
 CPPFLAGS+=     -DPSZ=8
 
-.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc"
+.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 CPPFLAGS+=     -DNO_VBE
 .endif
 
Index: x11/Xserver/hw/xfree86/drivers/glint/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/drivers/glint/Makefile,v
retrieving revision 1.5
diff -u -r1.5 Makefile
--- x11/Xserver/hw/xfree86/drivers/glint/Makefile       8 Mar 2008 10:39:00 
-0000       1.5
+++ x11/Xserver/hw/xfree86/drivers/glint/Makefile       22 Oct 2008 02:41:52 
-0000
@@ -14,7 +14,8 @@
        TIramdac.c glint_shadow.c sx_accel.c glint_dga.c
 
 .if ${MACHINE_ARCH} == "sparc64" || ${MACHINE_ARCH} == "macppc" || \
-    ${MACHINE} == "ofppc"
+    ${MACHINE} == "ofppc" || ${MACHINE} == "bebox" || \
+    ${MACHINE} == "prep"
 CPPFLAGS+=     -DGLINT_AVOID_INT10
 .endif
 
Index: x11/Xserver/hw/xfree86/drivers/r128/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/drivers/r128/Makefile,v
retrieving revision 1.6
diff -u -r1.6 Makefile
--- x11/Xserver/hw/xfree86/drivers/r128/Makefile        8 Mar 2008 10:39:00 
-0000       1.6
+++ x11/Xserver/hw/xfree86/drivers/r128/Makefile        22 Oct 2008 02:41:52 
-0000
@@ -52,7 +52,8 @@
 .endif
 
 .if ${MACHINE} == "macppc" || ${MACHINE} == "sparc" || \
-    ${MACHINE} == "sparc64" || ${MACHINE} == "ofppc"
+    ${MACHINE} == "sparc64" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 CPPFLAGS+=     -DAVOID_VGAHW
 .endif
        
Index: x11/Xserver/hw/xfree86/xf86/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/xf86/Makefile,v
retrieving revision 1.11
diff -u -r1.11 Makefile
--- x11/Xserver/hw/xfree86/xf86/Makefile        8 Mar 2008 10:39:00 -0000       
1.11
+++ x11/Xserver/hw/xfree86/xf86/Makefile        22 Oct 2008 02:41:55 -0000
@@ -22,7 +22,8 @@
 CPPFLAGS+=-DUSE_MODULAR_KBD
 .endif
 
-.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc"
+.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 CPPFLAGS+=-DUSE_MODULAR_KBD
 .endif
 
Index: x11/Xserver/hw/xfree86/xf86_os/Makefile
===================================================================
RCS file: /cvsroot/src/x11/Xserver/hw/xfree86/xf86_os/Makefile,v
retrieving revision 1.19
diff -u -r1.19 Makefile
--- x11/Xserver/hw/xfree86/xf86_os/Makefile     23 Apr 2008 05:13:43 -0000      
1.19
+++ x11/Xserver/hw/xfree86/xf86_os/Makefile     22 Oct 2008 02:41:55 -0000
@@ -30,7 +30,8 @@
 .endfor
 .endif
 
-.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc"
+.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 SRCS.bsd+=     ppc_video.c bsdResource.c pm_noop.c lnx_agp.c
 .for _FN in ${SRCS.bsd}
 CPPFLAGS.${_FN}=       -DWSCONS_SUPPORT -DUSESTDRES -DHAVE_SYSV_IPC \
@@ -85,11 +86,13 @@
 .if ${MACHINE} == "macppc" || ${MACHINE} == "cats" || \
     ${MACHINE} == "sgimips" || ${MACHINE} == "sparc64" || \
     ${MACHINE} == "sparc" || ${MACHINE} == "netwinder" || \
-    ${MACHINE} == "shark" || ${MACHINE} == "ofppc"
+    ${MACHINE} == "shark" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 SRCS.bus+=     netbsdPci.c
 .endif
 
-.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc"
+.if ${MACHINE} == "macppc" || ${MACHINE} == "ofppc" || \
+    ${MACHINE} == "bebox" || ${MACHINE} == "prep"
 .for _FN in ${SRCS.bus}
 CPPFLAGS.${_FN}=       -DPCI_VIA_TTYE0
 .endfor
@@ -109,7 +112,8 @@
        ${MACHINE} == "cats" || ${MACHINE} == "sgimips" || \
        ${MACHINE} == "sparc64" || ${MACHINE} == "sparc" || \
        ${MACHINE} == "netwinder" || ${MACHINE} == "shark" || \
-       ${MACHINE} == "ofppc"
+       ${MACHINE} == "ofppc" || ${MACHINE} == "bebox" || \
+       ${MACHINE} == "prep"
 SRCS.misc+=    CBUSmemcpy.c CIODelay.c CSlowBcopy.c
 .endif
 
Section "ServerLayout"
        Identifier     "XFree86 Configured"
        Screen      0  "Screen0" 0 0
        InputDevice    "Mouse0" "CorePointer"
        InputDevice    "Keyboard0" "CoreKeyboard"
EndSection

Section "Files"
        RgbPath      "/usr/X11R6/lib/X11/rgb"
        ModulePath   "/usr/X11R6/lib/modules"
        FontPath     "/usr/X11R6/lib/X11/fonts/misc/"
        FontPath     "/usr/X11R6/lib/X11/fonts/Speedo/"
        FontPath     "/usr/X11R6/lib/X11/fonts/Type1/"
        FontPath     "/usr/X11R6/lib/X11/fonts/CID/"
        FontPath     "/usr/X11R6/lib/X11/fonts/75dpi/"
        FontPath     "/usr/X11R6/lib/X11/fonts/100dpi/"
EndSection
Section "Module"
        Load  "dbe"
        Load  "extmod"
        Load  "glx"
        Load  "record"
        Load  "xtrap"
        Load  "speedo"
        Load  "type1"
EndSection
Section "InputDevice"
        Identifier  "Keyboard0"
        Driver      "kbd"
        Option      "Protocol" "wskbd"
        Option      "Device" "/dev/wskbd"
EndSection

Section "InputDevice"
        Identifier  "Mouse0"
        Driver      "mouse"
        Option      "Protocol" "wsmouse"
        Option      "Device" "/dev/wsmouse"
EndSection

Section "Monitor"
        Identifier   "Monitor0"
        VendorName   "Monitor Vendor"
        ModelName    "Monitor Model"
EndSection

Section "Device"
        ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
        ### [arg]: arg optional
        #Option     "ShadowFB"                  # [<bool>]
        #Option     "VGAClocks"                 # [<bool>]
        #Option     "KGAUniversal"              # [<bool>]
        Identifier  "Card0"
        Driver      "vga"
#       Driver      "s3"
        VendorName  "S3 Inc."
        BoardName   "86c864 [Vision 864 DRAM] vers 1"
        BusID       "PCI:0:0:0"
EndSection

Section "Screen"
        Identifier "Screen0"
        Device     "Card0"
        Monitor    "Monitor0"
#       SubSection "Display"
#               Viewport   0 0
#               Depth     1
#       EndSubSection
#       SubSection "Display"
#               Viewport   0 0
#               Depth     4
#       EndSubSection
#       SubSection "Display"
#               Viewport   0 0
#               Depth     8
#       EndSubSection
#       SubSection "Display"
#               Viewport   0 0
#               Depth     15
#       EndSubSection
        SubSection "Display"
                Viewport   0 0
                Depth     16
        EndSubSection
        SubSection "Display"
                Viewport   0 0
                Depth     24
        EndSubSection
EndSection

(II) Module xf1bpp: vendor="The XFree86 Project"
        compiled for 4.5.0, module version = 1.0.0
        ABI class: XFree86 ANSI C Emulation, version 0.3
(II) do I need RAC?  No, I don't.
(II) resource ranges after preInit:
        [0] 0   0       0xff800000 - 0xffffffff (0x800000) MS[B]
        [1] -1  0       0xffffffff - 0xffffffff (0x1) MX[B]
        [2] -1  0       0x00000000 - 0x00000000 (0x1) MX[B]
        [3] -1  0       0x00810000 - 0x0081ffff (0x10000) MX[B](B)
        [4] 0   0       0x000a0000 - 0x000affff (0x10000) MS[B]
        [5] 0   0       0x000b0000 - 0x000b7fff (0x8000) MS[B](OprU)
        [6] 0   0       0x000b8000 - 0x000bffff (0x8000) MS[B](OprU)
        [7] -1  0       0x0000ffff - 0x0000ffff (0x1) IX[B]
        [8] -1  0       0x00000000 - 0x00000000 (0x1) IX[B]
        [9] 0   0       0x000003b0 - 0x000003bb (0xc) IS[B]
        [10] 0  0       0x000003c0 - 0x000003df (0x20) IS[B]
(WW) VGA(0): Cannot read colourmap from VGA.  Will restore with default
(==) VGA(0): DPMS disabled
(==) RandR enabled
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x1788, r_info 0x0x5d0a
1788 93 10
0
ElfGetSymbolNameIndex(5d,b) fbScreenInit 1 0 0
***Unable to resolve symbol fbScreenInit
ElfDelayRelocation 0xef70d760: file 0xef6333a0, sec 1, r_offset 0x1788, r_info 
0x5d0a, r_addend 0x0
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x17a0, r_info 0x0x390a
17a0 57 10
0
ElfGetSymbolNameIndex(39,b) fbPictureInit 1 0 0
***Unable to resolve symbol fbPictureInit
ElfDelayRelocation 0xef70d660: file 0xef6333a0, sec 1, r_offset 0x17a0, r_info 
0x390a, r_addend 0x0
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x17b0, r_info 0x0x5f0a
17b0 95 10
0
ElfGetSymbolNameIndex(5f,b) ShadowFBInit 1 0 0
***Unable to resolve symbol ShadowFBInit
ElfDelayRelocation 0xef70d670: file 0xef6333a0, sec 1, r_offset 0x17b0, r_info 
0x5f0a, r_addend 0x0
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x18d0, r_info 0x0x5d0a
18d0 93 10
0
ElfGetSymbolNameIndex(5d,b) fbScreenInit 1 0 0
***Unable to resolve symbol fbScreenInit
ElfDelayRelocation 0xef70d680: file 0xef6333a0, sec 1, r_offset 0x18d0, r_info 
0x5d0a, r_addend 0x0
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x18e8, r_info 0x0x390a
18e8 57 10
0
ElfGetSymbolNameIndex(39,b) fbPictureInit 1 0 0
***Unable to resolve symbol fbPictureInit
ElfDelayRelocation 0xef70d690: file 0xef6333a0, sec 1, r_offset 0x18e8, r_info 
0x390a, r_addend 0x0
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x18f8, r_info 0x0x5f0a
18f8 95 10
0
ElfGetSymbolNameIndex(5f,b) ShadowFBInit 1 0 0
***Unable to resolve symbol ShadowFBInit
ElfDelayRelocation 0xef70d6a0: file 0xef6333a0, sec 1, r_offset 0x18f8, r_info 
0x5f0a, r_addend 0x0
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x1920, r_info 0x0x5d0a
1920 93 10
0
ElfGetSymbolNameIndex(5d,b) fbScreenInit 1 0 0
***Unable to resolve symbol fbScreenInit
ElfDelayRelocation 0xef70d6b0: file 0xef6333a0, sec 1, r_offset 0x1920, r_info 
0x5d0a, r_addend 0x0
ResolveSymbols: file 0xef6333a0, sec 1, r_offset 0x1938, r_info 0x0x390a
1938 57 10
0
ElfGetSymbolNameIndex(39,b) fbPictureInit 1 0 0
***Unable to resolve symbol fbPictureInit
ElfDelayRelocation 0xef70d6c0: file 0xef6333a0, sec 1, r_offset 0x1938, r_info 
0x390a, r_addend 0x0
1938 57 10
0
ElfGetSymbolNameIndex(39,b) fbPictureInit 1 0 0
R_PPC_REL24 fbPictureInit       secp=ef6a2000   symval=186f120  dest32=ef6a3938 
*dest32=48000001        S+A-P=121cb7e8  R_PPC_REL24 offset 121cb7e8 too large
PLT offset is 1095c6c8

Fatal server error:
R_PPC_REL24 PLT offset 1095c6c8 too large


When reporting a problem related to a server crash, please send
the full server output, not just the last messages.
This can be found in the log file "/var/log/XFree86.0.log".
Please report problems to xfree86%xfree86.org.@localhost



Home | Main Index | Thread Index | Old Index