L4T 28.2.1 - centos 7

hi,
i’m trying to use centos7 aarch64 root file system, but i can’t start x:
[ 39.519]
X.Org X Server 1.19.5
Release Date: 2017-10-12
[ 39.519] X Protocol Version 11, Revision 0
[ 39.519] Build Operating System: 4.11.0-45.4.1.el7a.aarch64
[ 39.519] Current Operating System: Linux jetson-tx2 4.4.38-tegra #1 SMP PREEMPT Thu May 17 00:15:19 PDT 2018 aarch64
[ 39.519] Kernel command line: root=/dev/mmcblk0p1 rw rootwait console=ttyS0,115200n8 console=tty0 OS=l4t fbcon=map:0 net.ifnames=0 memtype=0 video=tegrafb no_console_suspend=1 earlycon=uart8250,mmio32,0x03100000 nvdumper_reserved=0x2772e0000 gpt tegraid=18.1.2.0.0 tegra_keep_boot_clocks maxcpus=6 boot.slot_suffix= boot.ratchetvalues=0.2.1 androidboot.serialno=0321117060020 bl_prof_dataptr=0x10000@0x277040000 sdhci_tegra.en_boot_part_access=1 root=/dev/mmcblk0p1 rw rootwait rootfstype=ext4
[ 39.520] Build Date: 13 April 2018 01:16:34AM
[ 39.520] Build ID: xorg-x11-server 1.19.5-5.el7
[ 39.520] Current version of pixman: 0.34.0
[ 39.520] Before reporting problems, check http://wiki.x.org
to make sure that you have the latest version.
[ 39.520] Markers: (–) probed, () from config file, (==) default setting,
(++) from command line, (!!) notice, (II) informational,
(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[ 39.521] (==) Log file: “/var/log/Xorg.0.log”, Time: Tue Jun 19 18:29:30 2018
[ 39.531] (==) Using config directory: “/etc/X11/xorg.conf.d”
[ 39.531] (==) Using system config directory “/usr/share/X11/xorg.conf.d”
[ 39.535] (==) No Layout section. Using the first Screen section.
[ 39.535] (==) No screen section available. Using defaults.
[ 39.535] (
) |–>Screen “Default Screen Section” (0)
[ 39.535] () | |–>Monitor “”
[ 39.536] (==) No device specified for screen “Default Screen Section”.
Using the first device section listed.
[ 39.536] (
) | |–>Device “Tegra0”
[ 39.536] (==) No monitor specified for screen “Default Screen Section”.
Using a default monitor configuration.
[ 39.536] (==) Automatically adding devices
[ 39.536] (==) Automatically enabling devices
[ 39.537] (==) Automatically adding GPU devices
[ 39.537] (==) Automatically binding GPU devices
[ 39.539] (==) Max clients allowed: 256, resource mask: 0x1fffff
[ 39.539] (==) FontPath set to:
catalogue:/etc/X11/fontpath.d,
built-ins
[ 39.539] (**) ModulePath set to “/usr/lib64/nvidia/xorg,/usr/lib64/xorg/modules”
[ 39.539] (II) The server relies on udev to provide the list of input devices.
If no devices become available, reconfigure udev or disable AutoAddDevices.
[ 39.539] (II) Loader magic: 0x5559615008
[ 39.539] (II) Module ABI versions:
[ 39.539] X.Org ANSI C Emulation: 0.4
[ 39.539] X.Org Video Driver: 23.0
[ 39.539] X.Org XInput driver : 24.1
[ 39.539] X.Org Server Extension : 10.0
[ 39.540] (II) no primary bus or device found
[ 39.540] (WW) “dri” will not be loaded unless you’ve specified it to be loaded elsewhere.
[ 39.540] (II) “glx” will be loaded by default.
[ 39.540] (II) LoadModule: “extmod”
[ 39.541] (II) Module “extmod” already built-in
[ 39.541] (II) LoadModule: “glx”
[ 39.543] (II) Loading /usr/lib64/nvidia/xorg/libglx.so
[ 39.547] (EE) Failed to load /usr/lib64/nvidia/xorg/libglx.so: libnvidia-tls.so.28.2.1: cannot open shared object file: No such file or directory
[ 39.547] (II) UnloadModule: “glx”
[ 39.547] (II) Unloading glx
[ 39.547] (EE) Failed to load module “glx” (loader failed, 7)
[ 39.547] (II) LoadModule: “nvidia”
[ 39.549] (II) Loading /usr/lib64/xorg/modules/drivers/nvidia_drv.so
[ 39.552] (EE) Failed to load /usr/lib64/xorg/modules/drivers/nvidia_drv.so: libnvidia-rmapi-tegra.so.28.2.1: cannot open shared object file: No such file or directory
[ 39.553] (II) UnloadModule: “nvidia”
[ 39.553] (II) Unloading nvidia
[ 39.553] (EE) Failed to load module “nvidia” (loader failed, 7)
[ 39.553] (EE) No drivers available.
[ 39.553] (EE)
#########
cat /usr/share/X11/xorg.conf.d/20-nvidia.conf
Section “Files”
ModulePath “/usr/lib64/nvidia/xorg”
#ModulePath “/usr/lib64/tegra186”
ModulePath “/usr/lib64/xorg/modules”
EndSection

Section “Module”
Disable “dri”
SubSection “extmod”
Option “omit xfree86-dga”
EndSubSection
EndSection

Section “Device”
Identifier “Tegra0”
Option “ModeDebug” “yes”
Driver “nvidia”
# Allow X server to be started even if no display devices are connected.
Option “AllowEmptyInitialConfiguration” “true”
EndSection
#########
xinit

X: symbol lookup error: X: undefined symbol: drmSetServerInfo

#########
ldconfig -v
/usr/lib64/tegra186:
libnvmm.so → libnvmm.so
libnvimp.so → libnvimp.so
libnvcam_imageencoder.so → libnvcam_imageencoder.so
libOpenGL.so.0 → libOpenGL.so.0
libnvapputil.so → libnvapputil.so
libnvid_mapper.so.1.0.0 → libnvid_mapper.so.1.0.0
libnvos.so → libnvos.so
libglx.so → libglx.so
libnvtvmr.so → libnvtvmr.so
libnvmmlite_image.so → libnvmmlite_image.so
libGLX_nvidia.so.0 → libGLX_nvidia.so.0
libnvparser.so → libnvparser.so
libargus_socketclient.so → libargus_socketclient.so
libnvidia-glsi.so.28.2.1 → libnvidia-glsi.so.28.2.1
libnvdc.so → libnvdc.so
libnvidia-rmapi-tegra.so.28.2.1 → libnvidia-rmapi-tegra.so.28.2.1
libnvcolorutil.so → libnvcolorutil.so
libscf.so → libscf.so
libdrm.so.2 → libdrm.so.2
libnvddk_2d_v2.so → libnvddk_2d_v2.so
libnvmmlite.so → libnvmmlite.so
libnvrm.so → libnvrm.so
libnvomxilclient.so → libnvomxilclient.so
libnvmm_parser.so → libnvmm_parser.so
libnvosd.so → libnvosd.so
libtegrav4l2.so → libtegrav4l2.so
libnvfnet.so → libnvfnet.so
libnvodm_imager.so → libnvodm_imager.so
libGLdispatch.so.0 → libGLdispatch.so.0
libnvidia-tls.so.28.2.1 → libnvidia-tls.so.28.2.1
libnvidia-fatbinaryloader.so.28.2.1 → libnvidia-fatbinaryloader.so.28.2.1
libnvmedia.so → libnvmedia.so
libnvmmlite_utils.so → libnvmmlite_utils.so
libnvcamerautils.so → libnvcamerautils.so
libnvidia-eglcore.so.28.2.1 → libnvidia-eglcore.so.28.2.1
libnvjpeg.so → libnvjpeg.so
libnvrm_gpu.so → libnvrm_gpu.so
libnvidia-glcore.so.28.2.1 → libnvidia-glcore.so.28.2.1
libnvbuf_utils.so.1.0.0 → libnvbuf_utils.so.1.0.0
libnveglstream_camconsumer.so → libnveglstream_camconsumer.so
libnvidia-egl-wayland.so.1.0.1 → libnvidia-egl-wayland.so
libnvfnetstorehdfx.so → libnvfnetstorehdfx.so
libnvwinsys.so → libnvwinsys.so
libnvtnr.so → libnvtnr.so
libnvmm_utils.so → libnvmm_utils.so
libGL.so.1 → libGL.so.1
libnvavp.so → libnvavp.so
libcuda.so.1 → libcuda.so.1.1
libnvtx_helper.so → libnvtx_helper.so
libnvfnetstoredefog.so → libnvfnetstoredefog.so
libargus_socketserver.so → libargus_socketserver.so
libnvcameratools.so → libnvcameratools.so
libnvddk_vic.so → libnvddk_vic.so
libnvexif.so → libnvexif.so
libnvmmlite_video.so → libnvmmlite_video.so
libnvmm_contentpipe.so → libnvmm_contentpipe.so
libnvll.so → libnvll.so
libnvtestresults.so → libnvtestresults.so
libnvidia-ptxjitcompiler.so.1 → libnvidia-ptxjitcompiler.so.28.2.1
libnveglstreamproducer.so → libnveglstreamproducer.so
libnvrm_graphics.so → libnvrm_graphics.so
libGLX.so.0 → libGLX.so.0
libargus.so → libargus.so
libnvomx.so → libnvomx.so
libnvcamlog.so → libnvcamlog.so
/usr/lib64/tegra186-egl:
libGLESv2.so.2 → libGLESv2.so.2
libEGL_nvidia.so.0 → libEGL_nvidia.so.0
libGLESv2_nvidia.so.2 → libGLESv2_nvidia.so.2
libEGL.so.1 → libEGL.so.1
libGLESv1_CM.so.1 → libGLESv1_CM.so.1
libGLESv1_CM_nvidia.so.1 → libGLESv1_CM_nvidia.so.1


cat /etc/ld.so.conf.d/nvidia-tegra186.conf
/usr/lib64/tegra186
/usr/lib64/nvidia/xorg
/usr/lib64/tegra186-egl
####################
any suggestions?

The Ubuntu supported under L4T uses this video driver ABI:

[     9.410] (II) Module ABI versions:
[     9.410]    X.Org ANSI C Emulation: 0.4
[     9.410]    <i><u><b>X.Org Video Driver: 20.0</b></u></i>
[     9.411]    X.Org XInput driver : 22.1
[     9.411]    X.Org Server Extension : 9.0

Yours uses:

39.539] X.Org Video Driver: 23.0

If your server had found the NVIDIA driver (not Nouveau), then it would have failed from incompatible ABI. Nouveau might work, but then CUDA and hardware accelerated OpenGL won’t work. This was missing though:

[ 39.541] (II) LoadModule: "glx"
[ 39.543] (II) Loading /usr/lib64/nvidia/xorg/libglx.so
[ 39.547] (EE) Failed to load <b>/usr/lib64/nvidia/xorg/libglx.so</b>: libnvidia-tls.so.28.2.1: cannot open shared object file: No such file or directory
[ 39.547] (II) UnloadModule: "glx"
[ 39.547] (II) Unloading glx
[ 39.547] (EE) Failed to load module "glx" (loader failed, 7)
[ 39.547] (II) LoadModule: "nvidia"
[ 39.549] (II) Loading /usr/lib64/xorg/modules/drivers/nvidia_drv.so
[ 39.552] (EE) Failed to load <b>/usr/lib64/xorg/modules/drivers/nvidia_drv.so</b>: libnvidia-rmapi-tegra.so.28.2.1: cannot open shared object file: No such file or directory
[ 39.553] (II) UnloadModule: "nvidia"
[ 39.553] (II) Unloading nvidia
[ 39.553] (EE) Failed to load module "nvidia" (loader failed, 7)
[ 39.553] (EE) No drivers available.

Note that libglx.so is tied to the server ABI. Had you used libglx.so from Nouveau, then this could have been found, but then it would not be possible for the NVIDIA “nvidia_drv.so” to be used and you’d be back to a purely software implementation. This version of X isn’t compatible with the Jetson version for hardware acceleration using the provided GPU/CUDA drivers (which were missing anyway).

If you can’t downgrade the X to the required ABI you’ll have to use a purely software Nouveau implementation.

\o/ i recompiled and downgraded xorg server and voila:
[ 3871.422] (II) Loader magic: 0x630d28
[ 3871.422] (II) Module ABI versions:
[ 3871.422] X.Org ANSI C Emulation: 0.4
[ 3871.423] X.Org Video Driver: 20.0
[ 3871.423] X.Org XInput driver : 22.1
[ 3871.423] X.Org Server Extension : 9.0
[ 3871.429] (–) using VT number 2

[ 3871.429] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[ 3871.430] (II) no primary bus or device found
[ 3871.430] (WW) “dri” will not be loaded unless you’ve specified it to be loaded elsewhere.
[ 3871.430] (II) “glx” will be loaded by default.
[ 3871.430] (II) LoadModule: “extmod”
[ 3871.431] (II) Module “extmod” already built-in
[ 3871.431] (II) LoadModule: “glx”
[ 3871.431] (II) Loading /usr/lib64/nvidia/xorg/libglx.so
[ 3871.520] (II) Module glx: vendor=“NVIDIA Corporation”
[ 3871.520] compiled for 4.0.2, module version = 1.0.0
[ 3871.520] Module class: X.Org Server Extension
[ 3871.520] (II) NVIDIA GLX Module 28.2.1 Release Build (integ_stage_rel) (buildbrain@mobile-u64-773) Thu May 17 00:15:24 PDT 2018
[ 3871.522] (II) LoadModule: “nvidia”
[ 3871.523] (II) Loading /usr/lib64/xorg/modules/drivers/nvidia_drv.so
[ 3871.533] (II) Module nvidia: vendor=“NVIDIA Corporation”
[ 3871.533] compiled for 4.0.2, module version = 1.0.0
[ 3871.534] Module class: X.Org Video Driver
[ 3871.536] (II) NVIDIA dlloader X Driver 28.2.1 Release Build (integ_stage_rel) (buildbrain@mobile-u64-773) Thu May 17 00:16:09 PDT 2018
[ 3871.536] (II) NVIDIA Unified Driver for all Supported NVIDIA GPUs
[ 3871.546] (WW) Falling back to old probe method for NVIDIA
[ 3871.548] (II) Loading sub module “fb”
[ 3871.548] (II) LoadModule: “fb”
[ 3871.549] (II) Loading /usr/lib64/xorg/modules/libfb.so
[ 3871.551] (II) Module fb: vendor=“X.Org Foundation”
[ 3871.551] compiled for 1.18.4, module version = 1.0.0
[ 3871.551] ABI class: X.Org ANSI C Emulation, version 0.4
[ 3871.551] (II) Loading sub module “wfb”
[ 3871.551] (II) LoadModule: “wfb”
[ 3871.552] (II) Loading /usr/lib64/xorg/modules/libwfb.so
[ 3871.554] (II) Module wfb: vendor=“X.Org Foundation”
[ 3871.554] compiled for 1.18.4, module version = 1.0.0
[ 3871.555] ABI class: X.Org ANSI C Emulation, version 0.4
[ 3871.555] (II) Loading sub module “ramdac”
[ 3871.555] (II) LoadModule: “ramdac”
[ 3871.555] (II) Module “ramdac” already built-in

Excellent…that’s one of the most difficult steps of porting. If you have a URL for the particular source you downloaded, plus any tips on what the “configure” step uses, I’m sure a lot of people would appreciate such tips when they go to port distributions.

what mean that ‘configure’ step? :)

anyway - on https://www.x.org/wiki/XorgModuleABIVersions i checked release needed.
on https://koji.fedoraproject.org/koji/packageinfo?packageID=63 i checked which latest 1.18 was built and downloaded src.rpm, built in mock and installed

i recall for t20 some l4t archive had drivers for multiple xorg driver abis, why not for recent chips which are in production.

I’m just thinking you wouldn’t have compiled the Xorg server without something like a “./configure” step. It is possible to use defaults, but there are so many options to an Xorg server it’s like a Sci Fi movie maze of death… :P

There have been times I’ve attempted to compile a debug version of Xorg complete with symbols so I could run it in gdb and never succeeded (both on Fedora and Ubuntu). Different “./configure” steps completely change the nature of the build.

Excellent URLs for the Xorg version checking. I even added a note at the end of this very long post:
[url]https://devtalk.nvidia.com/default/topic/793798/jetson-tk1/some-jetson-web-links/post/4383933/#4383933[/url]

Hi cz172638gd42x,

It seems like you have successfully install CentOS-7 on Tegra. I am planning to do the same on tegra tx2. Can I request you to please post steps on how to go about installing CentOS on tegra? Also, how to overcome some hiccups one might encounter during this process.

Thank you.