Coder Social home page Coder Social logo

Comments (140)

friesoft avatar friesoft commented on August 30, 2024 3

@Samt43 are you talking about those mesa patches? https://lists.freedesktop.org/archives/mesa-dev/2018-February/186241.html

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024 2

It works indeed. I've selected nouveau as a module, added drm.debug=31 (to add more debugging) insmoded the moduleit and tadà:
Accleration is now available

It is still laggy with GNOME and videos are choppy, but it seems to be accelerated 👍

Thank you!

from linux-on-pixel-c.

opendata26 avatar opendata26 commented on August 30, 2024 1

You could try adding drm.debug=31 to cmdline for more debugging

from linux-on-pixel-c.

opendata26 avatar opendata26 commented on August 30, 2024 1

@denysvitali also try building as a module

from linux-on-pixel-c.

Gnurou avatar Gnurou commented on August 30, 2024 1

It indeed looks like the firmware files are not present on the initramfs, which would explain why the firmware loading function returns -ENOENT.

Building Nouveau as a module should definitely do the trick. An alternative would be to include the firmware files directly within the kernel image using CONFIG_EXTRA_FIRMWARE, but that's definitely not clean. I see no reason to not built Nouveau as a module since nobody should need it until the root FS is mounted anway.

from linux-on-pixel-c.

Gnurou avatar Gnurou commented on August 30, 2024 1

Probably not, as this appears to be for managing the non-upstream (i.e. not Nouveau) driver.

from linux-on-pixel-c.

Samt43 avatar Samt43 commented on August 30, 2024 1

@denysvitali @Gnurou @vartom I could have successfull graphical acceleration on Pixel C using 4.8 @vartom kernel and this modification Samt43/mesa@1790e46 for mesa that uses gnurou renderonly mesa branch.
With this, weston is working with gallium 0.4 and nv12b chipset and it seems to run fast !

I couldn't run Xorg unfortunately, i stuck with this :

[root@alarm alarm]# cat /var/log/Xorg.0.log                                                                                                                                                                                                                                    
[    66.430]                                                                                                                                                                                                                                                                   
X.Org X Server 1.19.6                                                                                                                                                                                                                                                          
Release Date: 2017-12-20                                                                                                                                                                                                                                                       
[    66.430] X Protocol Version 11, Revision 0                                                                                                                                                                                                                                 
[    66.430] Build Operating System: Linux 4.12.7-1-ARCH aarch64                                                                                                                                                                                                               
[    66.430] Current Operating System: Linux alarm 4.8.17+ #8 SMP PREEMPT Wed Feb 7 12:29:02 UTC 2018 aarch64                                                                                                                                                                  
[    66.430] Kernel command line: cros_secure vpr=0x08000000@0xf6800000 vmalloc=256M video=tegrafb fbcon loglevel=0 vga=current debug earlyprintk earlycon=uart8250,mmio32,0x70006000 drm.atomic=1 consoleblank=0 firmware_class.path=/lib/firmware                            
[    66.430] Build Date: 30 January 2018  11:53:15PM                                                                                                                                                                                                                           
[    66.430]                                                                                                                                                                                                                                                                   
[    66.431] Current version of pixman: 0.34.0                                                                                                                                                                                                                                 
[    66.431]    Before reporting problems, check http://wiki.x.org                                                                                                                                                                                                             
        to make sure that you have the latest version.                                                                                                                                                                                                                         
[    66.431] Markers: (--) probed, (**) from config file, (==) default setting,                                                                                                                                                                                                
        (++) from command line, (!!) notice, (II) informational,                                                                                                                                                                                                               
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.                                                                                                                                                                                                          
[    66.431] (==) Log file: "/var/log/Xorg.0.log", Time: Mon Feb 12 06:57:27 2018                                                                                                                                                                                              
[    66.431] (==) Using system config directory "/usr/share/X11/xorg.conf.d"                                                                                                                                                                                                   
[    66.431] (==) No Layout section.  Using the first Screen section.                                                                                                                                                                                                          
[    66.431] (==) No screen section available. Using defaults.                                                                                                                                                                                                                 
[    66.432] (**) |-->Screen "Default Screen Section" (0)                                                                                                                                                                                                                      
[    66.432] (**) |   |-->Monitor "<default monitor>"
[    66.432] (==) No monitor specified for screen "Default Screen Section".
        Using a default monitor configuration.
[    66.432] (==) Automatically adding devices
[    66.432] (==) Automatically enabling devices
[    66.432] (==) Automatically adding GPU devices
[    66.432] (==) Automatically binding GPU devices
[    66.432] (==) Max clients allowed: 256, resource mask: 0x1fffff
[    66.432] (WW) The directory "/usr/share/fonts/Type1/" does not exist.
[    66.432]    Entry deleted from font path.
[    66.432] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/100dpi/".
[    66.433]    Entry deleted from font path.
[    66.433]    (Run 'mkfontdir' on "/usr/share/fonts/100dpi/").
[    66.433] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/75dpi/".
[    66.433]    Entry deleted from font path.
[    66.433]    (Run 'mkfontdir' on "/usr/share/fonts/75dpi/").
[    66.433] (==) FontPath set to:
        /usr/share/fonts/misc/,
        /usr/share/fonts/TTF/,
        /usr/share/fonts/OTF/
[    66.433] (==) ModulePath set to "/usr/lib/xorg/modules"
[    66.433] (II) The server relies on udev to provide the list of input devices.
        If no devices become available, reconfigure udev or disable AutoAddDevices.
[    66.433] (II) Loader magic: 0x5c89dc1d28
[    66.433] (II) Module ABI versions:
[    66.433]    X.Org ANSI C Emulation: 0.4
[    66.433]    X.Org Video Driver: 23.0
[    66.433]    X.Org XInput driver : 24.1
[    66.433]    X.Org Server Extension : 10.0
[    66.434] (--) using VT number 2

[    66.434] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[    66.436] (II) xfree86: Adding drm device (/dev/dri/card1)
[    66.437] (II) xfree86: Adding drm device (/dev/dri/card0)
[    66.437] (II) no primary bus or device found
[    66.437]    falling back to /sys/devices/platform/50000000.host1x/drm/drm/card1
[    66.437] (II) LoadModule: "glx"
[    66.437] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[    66.441] (II) Module glx: vendor="X.Org Foundation"
[    66.441]    compiled for 1.19.6, module version = 1.0.0
[    66.441]    ABI class: X.Org Server Extension, version 10.0
[    66.441] (==) Matched modesetting as autoconfigured driver 0
[    66.441] (==) Matched fbdev as autoconfigured driver 1
[    66.441] (==) Assigned the driver to the xf86ConfigLayout
[    66.441] (II) LoadModule: "modesetting"
[    66.441] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[    66.442] (II) Module modesetting: vendor="X.Org Foundation"
[    66.442]    compiled for 1.19.6, module version = 1.19.6
[    66.442]    Module class: X.Org Video Driver
[    66.442]    ABI class: X.Org Video Driver, version 23.0
[    66.442] (II) LoadModule: "fbdev"
[    66.442] (WW) Warning, couldn't open module fbdev
[    66.442] (II) UnloadModule: "fbdev"
[    66.442] (II) Unloading fbdev
[    66.442] (EE) Failed to load module "fbdev" (module does not exist, 0)
[    66.442] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[    66.471] (II) modeset(0): using drv /dev/dri/card1
[    66.472] (II) modeset(G0): using drv /dev/dri/card0
[    66.472] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
[    66.472] (II) modeset(0): Creating default Display subsection in Screen section
        "Default Screen Section" for depth/fbbpp 24/32
[    66.472] (==) modeset(0): Depth 24, (==) framebuffer bpp 32
[    66.472] (==) modeset(0): RGB weight 888
[    66.472] (==) modeset(0): Default visual is TrueColor
[    66.472] (II) Loading sub module "glamoregl"
[    66.472] (II) LoadModule: "glamoregl"
[    66.472] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[    66.474] (II) Module glamoregl: vendor="X.Org Foundation"
[    66.474]    compiled for 1.19.6, module version = 1.0.0
[    66.474]    ABI class: X.Org ANSI C Emulation, version 0.4
[    66.474] (II) glamor: OpenGL accelerated X.org driver based.
[    66.605] (II) glamor: EGL version 1.4 (DRI2):
[    66.611] (II) modeset(0): glamor initialized
[    66.611] (II) modeset(0): Output DSI-1 has no monitor section
[    66.611] (II) modeset(0): EDID for output DSI-1
[    66.611] (II) modeset(0): Printing probed modes for output DSI-1
[    66.611] (II) modeset(0): Modeline "2560x1800"x60.0  304.42  2560 2640 2720 2800  1800 1804 1808 1812 (108.7 kHz)
[    66.611] (II) modeset(0): Output DSI-1 connected
[    66.611] (II) modeset(0): Using sloppy heuristic for initial modes
[    66.611] (II) modeset(0): Output DSI-1 using initial mode 2560x1800 +0+0
[    66.611] (==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
[    66.611] (==) modeset(0): DPI set to (96, 96)
[    66.611] (II) Loading sub module "fb"
[    66.611] (II) LoadModule: "fb"
[    66.611] (II) Loading /usr/lib/xorg/modules/libfb.so
[    66.612] (II) Module fb: vendor="X.Org Foundation"
[    66.612]    compiled for 1.19.6, module version = 1.0.0
[    66.612]    ABI class: X.Org ANSI C Emulation, version 0.4
[    66.613] (==) modeset(G0): Depth 24, (==) framebuffer bpp 32
[    66.613] (==) modeset(G0): RGB weight 888
[    66.613] (==) modeset(G0): Default visual is TrueColor
[    66.613] (II) Loading sub module "glamoregl"
[    66.613] (II) LoadModule: "glamoregl"
[    66.613] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[    66.613] (II) Module glamoregl: vendor="X.Org Foundation"
[    66.613]    compiled for 1.19.6, module version = 1.0.0
[    66.613]    ABI class: X.Org ANSI C Emulation, version 0.4
[    66.614] (II) glamor: OpenGL accelerated X.org driver based.
[    66.620] (II) glamor: EGL version 1.4 (DRI2):
[    66.623] (II) modeset(G0): glamor initialized
[    66.623] (==) modeset(G0): Using gamma correction (1.0, 1.0, 1.0)
[    66.623] (==) modeset(G0): DPI set to (96, 96)
[    66.623] (II) Loading sub module "fb"
[    66.623] (II) LoadModule: "fb"
[    66.623] (II) Loading /usr/lib/xorg/modules/libfb.so
[    66.623] (II) Module fb: vendor="X.Org Foundation"
[    66.623]    compiled for 1.19.6, module version = 1.0.0
[    66.623]    ABI class: X.Org ANSI C Emulation, version 0.4
[    66.623] (==) Depth 24 pixmap format is 32 bpp
[    66.623] (EE) modeset(G0): drmSetMaster failed: Invalid argument
[    66.623] (EE) 
Fatal server error:
[    66.624] (EE) AddScreen/ScreenInit failed for gpu driver 0 -1
[    66.624] (EE) 
[    66.625] (EE) 
Please consult the The X.Org Foundation support 
         at http://wiki.x.org
 for help. 
[    66.625] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information.
[    66.625] (EE) 
[    66.684] (EE) Server terminated with error (1). Closing log file.
[root@alarm alarm]# 

No idea why drmMaster fails, but it's fatal for Xorg.
It seems that glamor initialisation was OK, wondering if DRI3 is active (for node rendering) and if that could be the issue.

Any idea ?

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024 1

@denysvitali I started the kernel (4.17/work) now without any problems. I added all my patches and got the system start logs and the terminal command line. For further tests, i need to rebuild the rootfs.

Ps. You did not add all my patches to the kernel.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024 1

Related: https://www.phoronix.com/scan.php?page=news_item&px=Open-Source-Tegra-In-Mesa

from linux-on-pixel-c.

thierryreding avatar thierryreding commented on August 30, 2024 1

What I merged into Mesa should run fine on top of any recent release or linux-next. My for-4.17/work branch contains a bunch of patches that may be unstable.

Today's linux-next (next-20180309) should also have fixes for the green bars and things like that. I think I don't have anything else in my for-4.17/work branch that would be immediately relevant to you.

from linux-on-pixel-c.

thierryreding avatar thierryreding commented on August 30, 2024 1

@vartom can you set the following in your defconfig:

CONFIG_TEGRA_MC=y

Without that, CONFIG_TEGRA_IOMMU_SMMU will not be enabled and that in turn will prevent the file descriptor exported from Nouveau to be imported into Tegra DRM for display. This is because Tegra DRM needs the SMMU to map non-contiguous buffers.

The Tegra Gallium driver does a bad job of reporting failure to import a file descriptor. Well... not really any job at all, it basically ignores failure to import. I'm working on a patch for that. I'll also send out a patch to make sure we have TEGRA_MC and TEGRA_IOMMU_SMMU in the default configurations, which, for some reason, isn't currently the case.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024 1

@denysvitali You have the old version of Mesa library in the system!
I made a patch for you to fix this situation.

[root@alarm ~]# pacman -Q xorg-server mesa wayland libdrm
xorg-server 1.19.6+13+gd0d1a694f-1
mesa 17.3.6-1

from linux-on-pixel-c.

Echelon9 avatar Echelon9 commented on August 30, 2024

[ 4.355693] nouveau 57000000.gpu: NVIDIA GM20B (12b000a1)
[ 4.361115] nouveau 57000000.gpu: imem: using IOMMU
[ 4.366069] nouveau 57000000.gpu: Direct firmware load for nvidia/gm20b/gr/gpccs_inst.bin failed with error -2
[ 4.376079] nouveau 57000000.gpu: gr: failed to load gr/gpccs_inst
[ 4.382260] nouveau 57000000.gpu: gr ctor failed, -2
[ 4.387387] nouveau: probe of 57000000.gpu failed with error -2

The nouveau graphics driver is looking for, but not finding, the GPU firmware files. That particular binary blob has been released in a redistributable form by nvidia.

See:

Depending upon your bootloader, those files will need to be put on your initramfs or whatever the Android bootloader looks for.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Thank you for your comment, I'll try to integrate the blob file in the kernel, or put it in the /lib folder.
I'll report back my findings

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Mmm, @Echelon9 that doesn't seem to be the problem. The file is available at /usr/lib/nvidia/gm20b/gr/gpccs_inst.bin (/lib is symlinked to /usr/lib), but apparently fails to load for some (to me unknown) reason

from linux-on-pixel-c.

Echelon9 avatar Echelon9 commented on August 30, 2024

You'll want the full path to resolve to /lib/firmware/nvidia/gm20b/gr/gpccs_inst.bin in order for the kernel module to find it.

So in your approach, /lib/firmware symlinked to /usr/lib.

from linux-on-pixel-c.

Echelon9 avatar Echelon9 commented on August 30, 2024

@denysvitali any update from your further testing?

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

I'm trying to port the 4.14-rc1 kernel right now, afterwards I'll try with your suggestions. I'll report back soon! 👍

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Here is the new 4.14-rc1 dmesg

/lib is symlinked to /usr/lib

[root@alarm alarm]# ls -l /lib
lrwxrwxrwx 1 root root 7 Sep 21 19:07 /lib -> usr/lib

gpccs_inst.bin exists in /usr/lib/firmware/nvidia/gm20b/gr

[root@alarm alarm]# ls -la /usr/lib/firmware/nvidia/gm20b/gr/
total 76
drwxr-xr-x 2 root root  4096 Sep 21 19:47 .
drwxr-xr-x 5 root root  4096 Sep 21 19:08 ..
-rw-r--r-- 1 root root   576 Sep 13 19:58 fecs_bl.bin
-rw-r--r-- 1 root root  1964 Sep 13 19:58 fecs_data.bin
-rw-r--r-- 1 root root 17021 Sep 13 19:58 fecs_inst.bin
-rw-r--r-- 1 root root    76 Sep 13 19:58 fecs_sig.bin
-rw-r--r-- 1 root root  2068 Sep 13 19:58 gpccs_data.bin
-rw-r--r-- 1 root root  9964 Sep 13 19:58 gpccs_inst.bin
-rw-r--r-- 1 root root  7616 Sep 13 19:58 sw_bundle_init.bin
-rw-r--r-- 1 root root  5448 Sep 13 19:58 sw_ctx.bin
lrwxrwxrwx 1 root root    33 Sep 13 19:58 sw_method_init.bin -> ../../gm200/gr/sw_method_init.bin
-rw-r--r-- 1 root root  1432 Sep 13 19:58 sw_nonctx.bin
[root@alarm alarm]# cat /sys/module/nouveau/parameters/modeset
-1

Some users on Arch Linux Forums suggest to set this kernel flag:
nouveau.config=NvGrUseFW=1

I tried to add it, but the result is exactly the same. I also tried to add drm.atomic=1 firmware_class.path=/lib/firmware, but I get the same results: the binary doesn't get loaded

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

May be helpful later: https://www.phoronix.com/scan.php?page=news_item&px=Tegra-2-Video-Decode-Driver-V3

from linux-on-pixel-c.

Echelon9 avatar Echelon9 commented on August 30, 2024

Probably not, that relates to the older Tegra 2 GPUs. This device has a Maxwell series GPU.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Yeah, realized after I posted. Brainfart :P

from linux-on-pixel-c.

mirh avatar mirh commented on August 30, 2024

Ideas

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Maybe @Gnurou can help us, somehow

from linux-on-pixel-c.

Gnurou avatar Gnurou commented on August 30, 2024

Mmm, everything seems to be in place, so I am not sure what happens here. I happen to own a Pixel C, so maybe I can try to reproduce and investigate. However I would like to avoid flashing it since I use it for work too. Has someone ever tried to boot off an external SD card and using just fastboot boot, instead of flashing?

I also think X may still require some extra patching to take advantage of HW acceleration, I can check that once the firmware issue is solved.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@Gnurou The cleanest way to do it is to format the system partition (doesn't contain any personal data) and put the Arch Linux Arm files there (rootfs). I'll post my system.img here in a few minutes, so you can try it out.

For the kernel, you can try with my latest build (from lightbar-fix branch). This kernel boots from /system/, therefore your /data partition isn't touched at all.

Kernel

This build assumes you have the rootfs on /system (/dev/block/mmcblk0p4, limited to 3.7GB)
lightbar-fix-fd6389ade197_20171029_232625.tar.gz

Boot w/ fastboot boot boot-lightbar-fix-fd6389ade197_20171029_232625.img.unsigned, keep in mind that flashing this without signing it won't work, therefore if you keep it unsigned you'll be able to boot it only via fastboot boot

Ramdisk

In case you want to boot from sdcard / whatever, you'll need to repack the kernel with the new ramdisk. Edit this to suit your needs , repack and you're good to go.

System

I will upload it here in a few minutes (refresh the page every 10 minutes if it isn't up yet)
There you are

Flash it w/ fastboot flash system system.img

Revert back to the original state

To return to a fully functional Pixel C, download the version you had on your Pixel C, extract the zip file, go to the extracted folder, unzip image-*..zip, fastboot flash system system.img, fastboot reboot. If that doesn't work, flash recovery (fastboot flash recovery recovery.img) too

from linux-on-pixel-c.

Gnurou avatar Gnurou commented on August 30, 2024

Thanks for the instructions, although I'd rather not mess with my work device at all :) I remember booting to a SD card rootfs on my old SHIELD device, let me see if I can reproduce that result on the Pixel C too since USB seems to work. I suppose that kind of setup could be useful to other users as well.

Or maybe I can put my hands on another device just for this issue. I will come back once I have results.

from linux-on-pixel-c.

Gnurou avatar Gnurou commented on August 30, 2024

Oh wow, that's fantastic! Try setting the GPU clock to a higher speed, performance should increase:

echo b >/sys/class/drm/card1/device/pstate

... or something like that. cat pstate to see which values are acceptable.

Is this X? I would be surprised if it works out-of-the-box, last time I checked it (and Mesa) required a few external patches to connect the display and render nodes together. But maybe this has been taken care of in the meantime.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@Gnurou Yes, it is X. Although GNOME runs on Wayland.
Unfortunately I don't have any pstate in /sys/class/drm/card1/device.
Apparently the GM20b doesn't support clocking via nouveau

Little hope of reclocking becoming available for GM20x and newer GPUs as firmware now needs to be signed by NVIDIA to have the necessary access.

Here is the tree output of /sys/class/drm. I still can't figure it out why there are two cards, and why the screen looks like this on boot, instead of showing the kernel messages (and is not available until I restart lightdm a couple of times or wait a few minutes). In previous versions I was able to show the screen content by writing "1" and then "0" to /sys/class/graphics/fb0/blank. Reading on the NVIDIA forums this is used when some configuration changes (/sys/class/graphics/fb0/mode) are made. But since our implementation only supports a single mode, the only thing we can do is to blank the framebuffer, which unfortunately doesn't always help.

I can't figure out why after some minutes I get the green bars (#1) either.

Tree of /sys/class/drm:

/sys/class/drm/
|-- card0 -> ../../devices/platform/50000000.host1x/drm/drm/card0
|   |-- card0-DSI-1
|   |   |-- device -> ../../card0  [recursive, not followed]
|   |   |-- dpms
|   |   |-- edid
|   |   |-- enabled
|   |   |-- modes
|   |   |-- power
|   |   |-- status
|   |   |-- subsystem -> ../../../../../../../class/drm  [recursive, not followed]
|   |   `-- uevent
|   |-- dev
|   |-- device -> ../../../drm
|   |   |-- driver -> ../../../../bus/host1x/drivers/drm
|   |   |-- drm
|   |   |-- graphics
|   |   |-- of_node -> ../../../../firmware/devicetree/base/host1x@50000000
|   |   |-- power
|   |   |-- subsystem -> ../../../../bus/host1x
|   |   `-- uevent
|   |-- power
|   |   |-- autosuspend_delay_ms
|   |   |-- control
|   |   |-- runtime_active_time
|   |   |-- runtime_status
|   |   `-- runtime_suspended_time
|   |-- subsystem -> ../../../../../../class/drm  [recursive, not followed]
|   `-- uevent
|-- card0-DSI-1 -> ../../devices/platform/50000000.host1x/drm/drm/card0/card0-DSI-1  [recursive, not followed]
|-- card1 -> ../../devices/platform/57000000.gpu/drm/card1
|   |-- dev
|   |-- device -> ../../../57000000.gpu
|   |   |-- driver -> ../../../bus/platform/drivers/nouveau
|   |   |-- driver_override
|   |   |-- drm
|   |   |-- hwmon
|   |   |-- iommu -> ../70019000.memory-controller/iommu/70019000.memory-controller
|   |   |-- iommu_group -> ../../../kernel/iommu_groups/10
|   |   |-- modalias
|   |   |-- of_node -> ../../../firmware/devicetree/base/gpu@57000000
|   |   |-- power
|   |   |-- subsystem -> ../../../bus/platform
|   |   `-- uevent
|   |-- power
|   |   |-- autosuspend_delay_ms
|   |   |-- control
|   |   |-- runtime_active_time
|   |   |-- runtime_status
|   |   `-- runtime_suspended_time
|   |-- subsystem -> ../../../../../class/drm  [recursive, not followed]
|   `-- uevent
|-- renderD128 -> ../../devices/platform/50000000.host1x/drm/drm/renderD128
|   |-- dev
|   |-- device -> ../../../drm  [recursive, not followed]
|   |-- power
|   |   |-- autosuspend_delay_ms
|   |   |-- control
|   |   |-- runtime_active_time
|   |   |-- runtime_status
|   |   `-- runtime_suspended_time
|   |-- subsystem -> ../../../../../../class/drm  [recursive, not followed]
|   `-- uevent
|-- renderD129 -> ../../devices/platform/57000000.gpu/drm/renderD129
|   |-- dev
|   |-- device -> ../../../57000000.gpu  [recursive, not followed]
|   |-- power
|   |   |-- autosuspend_delay_ms
|   |   |-- control
|   |   |-- runtime_active_time
|   |   |-- runtime_status
|   |   `-- runtime_suspended_time
|   |-- subsystem -> ../../../../../class/drm  [recursive, not followed]
|   `-- uevent
|-- ttm -> ../../devices/virtual/drm/ttm
|   |-- buffer_objects
|   |   `-- bo_count
|   |-- memory_accounting
|   |   |-- dma_pool
|   |   |-- kernel
|   |   `-- pool
|   |-- power
|   |   |-- autosuspend_delay_ms
|   |   |-- control
|   |   |-- runtime_active_time
|   |   |-- runtime_status
|   |   `-- runtime_suspended_time
|   |-- subsystem -> ../../../../class/drm  [recursive, not followed]
|   `-- uevent
`-- version

43 directories, 46 files

The whole /sys/class/ folder

(Limited to 3 levels)
Here

Modes available

[root@alarm ~]# cat /sys/class/graphics/fb0/modes 
U:2560x1800p-0

from linux-on-pixel-c.

mirh avatar mirh commented on August 30, 2024

Little hope of reclocking becoming available for GM20x and newer GPUs as firmware now needs to be signed by NVIDIA to have the necessary access.

That's a bit outdated.
Moreover, X1 seems like the luckiest nvidia gpu since half a decade.
EDIT: *fixed last link

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

I tried the nouveau.NvFanless=true / nouveau.conifg=NvFanless=1 boot parameter, but apparently nouveau doesn't recognize it

[  790.904271] [TTM] Finalizing pool allocator
[  790.904461] [TTM] Finalizing DMA pool allocator
[  790.904521] [TTM] Zone  kernel: Used memory at exit: 0 kiB
[  793.820375] nouveau: unknown parameter 'NvFanless' ignored
[  793.821291] [drm:nouveau_drm_init [nouveau]] Loading Nouveau with parameters:
[  793.821732] [drm:nouveau_drm_init [nouveau]] ... tv_disable   : 0
[  793.822120] [drm:nouveau_drm_init [nouveau]] ... ignorelid    : 0
[  793.822470] [drm:nouveau_drm_init [nouveau]] ... duallink     : 1
[  793.822835] [drm:nouveau_drm_init [nouveau]] ... nofbaccel    : 0
[  793.823182] [drm:nouveau_drm_init [nouveau]] ... config       : NvGrUseFW=1
[  793.823551] [drm:nouveau_drm_init [nouveau]] ... debug        : (null)
[  793.823894] [drm:nouveau_drm_init [nouveau]] ... noaccel      : 0
[  793.824227] [drm:nouveau_drm_init [nouveau]] ... modeset      : -1
[  793.824553] [drm:nouveau_drm_init [nouveau]] ... runpm        : -1
[  793.824847] [drm:nouveau_drm_init [nouveau]] ... vram_pushbuf : 0
[  793.825138] [drm:nouveau_drm_init [nouveau]] ... hdmimhz      : 0
[  793.825860] nouveau 57000000.gpu: NVIDIA GM20B (12b000a1)
[  793.825896] nouveau 57000000.gpu: imem: using IOMMU
[  793.826233] [drm:drm_minor_register] 
[  793.826239] [drm:drm_minor_register] 
[  793.826401] [drm:drm_minor_register] new minor registered 129
[  793.826406] [drm:drm_minor_register] 
[  793.826507] [drm:drm_minor_register] new minor registered 1
[  793.840595] nouveau 57000000.gpu: DRM: not a PCI device; no HDMI
[  793.840827] [TTM] Zone  kernel: Available graphics memory: 1420528 kiB
[  793.840832] [TTM] Initializing pool allocator
[  793.840845] [TTM] Initializing DMA pool allocator
[  793.840872] nouveau 57000000.gpu: DRM: VRAM: 0 MiB
[  793.840877] nouveau 57000000.gpu: DRM: GART: 1048576 MiB
[  793.842907] nouveau 57000000.gpu: DRM: failed to create ce channel, -22
[  793.930577] nouveau 57000000.gpu: DRM: MM: using GRCE for buffer copies
[  793.930593] [drm] Initialized nouveau 1.3.1 20120801 for 57000000.gpu on minor 1
[  794.071684] [drm:vblank_disable_fn] disabling vblank on crtc 0

from linux-on-pixel-c.

mirh avatar mirh commented on August 30, 2024

Cause those patches haven't been pulled/mainlined yet.

from linux-on-pixel-c.

Gnurou avatar Gnurou commented on August 30, 2024

Sorry, my mistake. The pstate node has been moved to from sysfs to debugs. So you should be able to find it under /sys/kernel/debug or wherever debugfs is mounted.

Still I am not convinced that X is using acceleration at the moment. You may want to check by looking for mentions of glamor the in X logs, or running glxgears or some other GL-enabled application. My bet is that some patching is still needed.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Found it: /sys/kernel/debug/dri/1 (which is the same as /sys/kernel/debug/dri/129)

[root@alarm 1]# cat pstate 
01: core 76 MHz *
02: core 153 MHz
03: core 230 MHz
04: core 307 MHz
05: core 384 MHz
06: core 460 MHz
07: core 537 MHz
08: core 614 MHz
09: core 691 MHz
0a: core 768 MHz
0b: core 844 MHz
0c: core 921 MHz
0d: core 998 MHz
DC: core 76 MHz

=>

[root@alarm 1]# echo "0c" > pstate
[root@alarm 1]# cat pstate 
01: core 76 MHz
02: core 153 MHz
03: core 230 MHz
04: core 307 MHz
05: core 384 MHz
06: core 460 MHz
07: core 537 MHz
08: core 614 MHz
09: core 691 MHz
0a: core 768 MHz
0b: core 844 MHz
0c: core 921 MHz AC DC *
0d: core 998 MHz
DC: core 921 MHz

[root@alarm 1]# cat /var/log/Xorg.0.log | grep glamor
[  2492.509] (II) Loading sub module "glamoregl"
[  2492.509] (II) LoadModule: "glamoregl"
[  2492.509] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[  2492.511] (II) Module glamoregl: vendor="X.Org Foundation"
[  2492.511] (II) glamor: OpenGL accelerated X.org driver based.
[  2492.643] (II) glamor: EGL version 1.4 (DRI2):
[  2492.644] (EE) modeset(0): glamor initialization failed
[  2492.647] (II) Loading sub module "glamoregl"
[  2492.647] (II) LoadModule: "glamoregl"
[  2492.647] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[  2492.647] (II) Module glamoregl: vendor="X.Org Foundation"
[  2492.647] (II) glamor: OpenGL accelerated X.org driver based.
[  2492.754] (II) glamor: EGL version 1.4 (DRI2):
[  2492.760] (II) modeset(G0): glamor initialized

2017-11-01-141659_2560x1800_scrot

Doesn't look good to me :(

from linux-on-pixel-c.

opendata26 avatar opendata26 commented on August 30, 2024

startx -- -logverbose 9 -verbose 9 try this, itll give some more x debug output

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@opendata26 Here is the X log w/ verbosity set to 9 (I removed the lines after inputs, since they aren't releveant to our problem.

(II) The server relies on udev to provide the list of input devices.
        If no devices become available, reconfigure udev or disable AutoAddDevices.
(II) Loader magic: 0xaaaae3277d28
(II) Module ABI versions:
        X.Org ANSI C Emulation: 0.4
        X.Org Video Driver: 23.0
        X.Org XInput driver : 24.1
        X.Org Server Extension : 10.0
(--) using VT number 1

(II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
(II) xfree86: Adding drm device (/dev/dri/card0)
(II) xfree86: Adding drm device (/dev/dri/card1)
(II) no primary bus or device found
        falling back to /sys/devices/platform/50000000.host1x/drm/drm/card0
(II) LoadModule: "glx"
(II) Loading /usr/lib/xorg/modules/extensions/libglx.so
(II) Module glx: vendor="X.Org Foundation"
        compiled for 1.19.5, module version = 1.0.0
        ABI class: X.Org Server Extension, version 10.0
(==) Matched modesetting as autoconfigured driver 0
(==) Matched fbdev as autoconfigured driver 1
(==) Assigned the driver to the xf86ConfigLayout
(II) LoadModule: "modesetting"
(II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
(II) Module modesetting: vendor="X.Org Foundation"
        compiled for 1.19.5, module version = 1.19.5
        Module class: X.Org Video Driver
        ABI class: X.Org Video Driver, version 23.0
(II) LoadModule: "fbdev"
(II) Loading /usr/lib/xorg/modules/drivers/fbdev_drv.so
(II) Module fbdev: vendor="X.Org Foundation"
        compiled for 1.19.3, module version = 0.4.4
        Module class: X.Org Video Driver
        ABI class: X.Org Video Driver, version 23.0
(II) modesetting: Driver for Modesetting Kernel Drivers: kms
(II) FBDEV: driver for framebuffer: fbdev
(II) modeset(0): using drv /dev/dri/card0
(WW) Falling back to old probe method for fbdev
(II) Loading sub module "fbdevhw"
(II) LoadModule: "fbdevhw"
(II) Loading /usr/lib/xorg/modules/libfbdevhw.so
(II) Module fbdevhw: vendor="X.Org Foundation"
        compiled for 1.19.5, module version = 0.0.2
        ABI class: X.Org Video Driver, version 23.0
(II) modeset(G0): using drv /dev/dri/card1
(II) modeset(0): Creating default Display subsection in Screen section
        "Default Screen Section" for depth/fbbpp 24/32
(==) modeset(0): Depth 24, (==) framebuffer bpp 32
(==) modeset(0): RGB weight 888
(==) modeset(0): Default visual is TrueColor
(II) Loading sub module "glamoregl"
(II) LoadModule: "glamoregl"
(II) Loading /usr/lib/xorg/modules/libglamoregl.so
(II) Module glamoregl: vendor="X.Org Foundation"
        compiled for 1.19.5, module version = 1.0.0
        ABI class: X.Org ANSI C Emulation, version 0.4
(II) glamor: OpenGL accelerated X.org driver based.
failed to bind extensions
failed to load driver: tegra
(II) glamor: EGL version 1.4 (DRI2):
EGL_MESA_drm_image required.
(EE) modeset(0): glamor initialization failed
(II) modeset(0): ShadowFB: preferred NO, enabled NO
(II) modeset(0): Output DSI-1 has no monitor section
(II) modeset(0): Up to 1 crtcs needed for screen.
(II) modeset(0): Allocated crtc nr. 0 to this screen.
(II) modeset(0): Allocated crtc nr. 1 to this screen.
(II) modeset(0): EDID for output DSI-1
(II) modeset(0): Printing probed modes for output DSI-1
(II) modeset(0): Modeline "2560x1800"x60.0  304.42  2560 2640 2720 2800  1800 1804 1808 1812 (108.7 kHz)
(II) modeset(0): Output DSI-1 connected
(II) modeset(0): Using sloppy heuristic for initial modes
(II) modeset(0): Output DSI-1 using initial mode 2560x1800 +0+0
(==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
(==) modeset(0): DPI set to (96, 96)
(II) Loading sub module "fb"
(II) LoadModule: "fb"
(II) Loading /usr/lib/xorg/modules/libfb.so
(II) Module fb: vendor="X.Org Foundation"
        compiled for 1.19.5, module version = 1.0.0
        ABI class: X.Org ANSI C Emulation, version 0.4
(==) modeset(G0): Depth 24, (==) framebuffer bpp 32
(==) modeset(G0): RGB weight 888
(==) modeset(G0): Default visual is TrueColor
(II) Loading sub module "glamoregl"
(II) LoadModule: "glamoregl"
(II) Loading /usr/lib/xorg/modules/libglamoregl.so
(II) Module glamoregl: vendor="X.Org Foundation"
        compiled for 1.19.5, module version = 1.0.0
        ABI class: X.Org ANSI C Emulation, version 0.4
(II) glamor: OpenGL accelerated X.org driver based.
(II) glamor: EGL version 1.4 (DRI2):
(II) modeset(G0): glamor initialized
(II) modeset(G0): Up to 0 crtcs needed for screen.
(==) modeset(G0): Using gamma correction (1.0, 1.0, 1.0)
(==) modeset(G0): DPI set to (96, 96)
(II) Loading sub module "fb"
(II) LoadModule: "fb"
(II) Loading /usr/lib/xorg/modules/libfb.so
(II) Module fb: vendor="X.Org Foundation"
        compiled for 1.19.5, module version = 1.0.0
        ABI class: X.Org ANSI C Emulation, version 0.4
(II) UnloadModule: "fbdev"
(II) Unloading fbdev
(II) UnloadSubModule: "fbdevhw"
(II) Unloading fbdevhw
(==) Depth 24 pixmap format is 32 bpp
(==) modeset(G0): Backing store enabled
(==) modeset(G0): Silken mouse enabled
(II) modeset(G0): RandR 1.2 enabled, ignore the following RandR disabled message.
(==) modeset(G0): DPMS enabled
(II) modeset(G0): [DRI2] Setup complete
(II) modeset(G0): [DRI2]   DRI driver: nouveau
(II) modeset(G0): [DRI2]   VDPAU driver: nouveau
(==) modeset(0): Backing store enabled
(==) modeset(0): Silken mouse enabled
(II) modeset(0): RandR 1.2 enabled, ignore the following RandR disabled message.
(==) modeset(0): DPMS enabled
(--) RandR disabled
(II) AIGLX: Screen 0 is not DRI2 capable
(EE) AIGLX: reverting to software rendering
(II) IGLX: enabled GLX_MESA_copy_sub_buffer
(II) IGLX: Loaded and initialized swrast
(II) GLX: Initialized DRISWRAST GL provider for screen 0
(II) modeset(G0): Damage tracking initialized
(II) modeset(0): Damage tracking initialized
(II) modeset(0): Setting screen physical size to 677 x 476
(II) XKB: Reusing cached keymap
(II) config/udev: Adding input device hid-over-i2c 06CB:3370 (/dev/input/event0)
(**) hid-over-i2c 06CB:3370: Applying InputClass "libinput touchscreen catchall"
(II) LoadModule: "libinput"
(II) Loading /usr/lib/xorg/modules/input/libinput_drv.so
(II) Module libinput: vendor="X.Org Foundation"
        compiled for 1.19.3, module version = 0.26.0
        Module class: X.Org XInput Driver
        ABI class: X.Org XInput driver, version 24.1
(II) Using input driver 'libinput' for 'hid-over-i2c 06CB:3370'
        Option "_source" "server/udev"
        Option "name" "hid-over-i2c 06CB:3370"
        Option "path" "/dev/input/event0"
        Option "device" "/dev/input/event0"
        Option "major" "13"
        Option "minor" "64"
        Option "config_info" "udev:/sys/devices/platform/7000c000.i2c/i2c-0/0-0020/0018:06CB:3370.0001/input/input0/event0"
        Option "driver" "libinput"

This line caught my attention

(II) AIGLX: Screen 0 is not DRI2 capable
(EE) AIGLX: reverting to software rendering

Current boot args:

console=/dev/fb0,115200n8 consoleblank=0disp.screen0_output_mode=EDID:2560x1800p60 nouveau.config=NvGrUseFW=1,NvFanless=1 drm.debug=31 drm.atomic=1 firmware_class.path=/lib/firmware

I did symlink tegra_dri.so to nouveau_dri.so, JFYI

[root@alarm dvitali]# ls -la /usr/lib/xorg/modules/dri
total 64196
drwxr-xr-x 2 root root    4096 Nov  1 13:42 .
drwxr-xr-x 6 root root    4096 Oct 31 23:20 ..
-rwxr-xr-x 7 root root 8805160 Oct 29 15:14 kgsl_dri.so
-rwxr-xr-x 7 root root 8805160 Oct 29 15:14 kms_swrast_dri.so
-rwxr-xr-x 7 root root 8805160 Oct 29 15:14 msm_dri.so
-rwxr-xr-x 7 root root 8805160 Oct 29 15:14 nouveau_dri.so
-rwxr-xr-x 1 root root 4082128 Oct 29 15:14 nouveau_vieux_dri.so
-rwxr-xr-x 7 root root 8805160 Oct 29 15:14 swrast_dri.so
lrwxrwxrwx 1 root root      14 Nov  1 13:42 tegra_dri.so -> nouveau_dri.so
-rwxr-xr-x 7 root root 8805160 Oct 29 15:14 vc4_dri.so
-rwxr-xr-x 7 root root 8805160 Oct 29 15:14 virtio_gpu_dri.so

I also saw that there is an nvidia_drv.so in the Linux 4 Tegra drivers package. I have now tried to copy the necessary files in the correct places and I get the following, then the system hangs:

See the gist

It may also be due to the fact that all the NVIDIA libraries filled up my /system partition (which is only 3.8 GB), therefore I'm having some space problems too now 😞

from linux-on-pixel-c.

Gnurou avatar Gnurou commented on August 30, 2024

I think that's the stage where I need to look at my old Xorg an Mesa repositories. :) Let's see if I can get the system to boot and run on a device first, will probably take a few days before I can make an attempt.

from linux-on-pixel-c.

opendata26 avatar opendata26 commented on August 30, 2024

You could try disabling aglx?

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

As suggested by @mirh (in private) this may be useful

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

Hey. I downloaded the kernel and root directory of the message #2 (comment). The system does not start. Tried to rebuild the kernel, as well as no launch. I found how to solve the problem with the firmware files. The solution is to add the firmware files to the vendor's directory in initramfs or add all the files to the kernel. Unfortunately, it still did not let me run the system. Maybe to me another tablet revision or not a suitable bootloader. My revision 1.3, bootloader-dragon-google_smaug.7900.50.0.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

Did you try to connect the monitor through HDMI?

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom Unfortunately I don't have much free time to dedicate to the project 😞 . I haven't yet found a way to have an output on the HDMI.

About the rootfs, you can try to use the kernel posted here and use the /system instructions to build your own rootfs.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

Tried to turn on the drivers nouveau. Not yet figured out why, but they do not see a DSI connection:

 [    99.051] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
 [    99.052] (II) xfree86: Adding drm device (/dev/dri/card1)
 [    99.054] (II) xfree86: Adding drm device (/dev/dri/card0)
 [    99.055] (II) no primary bus or device found
 [    99.055] 	falling back to /sys/devices/platform/50000000.host1x/drm/drm/card1
 [    99.055] (II) LoadModule: "glx"
 [    99.056] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
 [    99.056] (EE) Failed to load /usr/lib/xorg/modules/extensions/libglx.so: /usr/lib/xorg/modules/extensions/libglx.so: wrong ELF class: ELFCLASS64
 [    99.056] (II) UnloadModule: "glx"
 [    99.056] (II) Unloading glx
 [    99.056] (EE) Failed to load module "glx" (loader failed, 7)
 [    99.056] (II) LoadModule: "nouveau"
 [    99.056] (II) Loading /usr/lib/xorg/modules/drivers/nouveau_drv.so
 [    99.057] (II) Module nouveau: vendor="X.Org Foundation"
 [    99.057] 	compiled for 1.19.3, module version = 1.0.15
 [    99.057] 	Module class: X.Org Video Driver
 [    99.057] 	ABI class: X.Org Video Driver, version 23.0
 [    99.057] (II) NOUVEAU driver 
 [    99.057] (II) NOUVEAU driver for NVIDIA chipset families :
 [    99.057] 	RIVA TNT        (NV04)
 [    99.057] 	RIVA TNT2       (NV05)
 [    99.057] 	GeForce 256     (NV10)
 [    99.057] 	GeForce 2       (NV11, NV15)
 [    99.057] 	GeForce 4MX     (NV17, NV18)
 [    99.057] 	GeForce 3       (NV20)
 [    99.057] 	GeForce 4Ti     (NV25, NV28)
 [    99.057] 	GeForce FX      (NV3x)
 [    99.058] 	GeForce 6       (NV4x)
 [    99.058] 	GeForce 7       (G7x)
 [    99.058] 	GeForce 8       (G8x)
 [    99.058] 	GeForce GTX 200 (NVA0)
 [    99.058] 	GeForce GTX 400 (NVC0)
 [    99.058] (II) [drm] nouveau interface version: 0.0.0
 [    99.071] (II) [drm] nouveau interface version: 1.3.1
 [    99.071] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
 [    99.071] (II) Loading sub module "dri2"
 [    99.071] (II) LoadModule: "dri2"
 [    99.071] (II) Module "dri2" already built-in
 [    99.072] (--) NOUVEAU(0): Chipset: "NVIDIA NV00"
 [    99.072] (==) NOUVEAU(0): Depth 24, (--) framebuffer bpp 32
 [    99.072] (==) NOUVEAU(0): RGB weight 888
 [    99.072] (==) NOUVEAU(0): Default visual is TrueColor
 [    99.072] (==) NOUVEAU(0): Using HW cursor
 [    99.072] (==) NOUVEAU(0): Allowed maximum DRI level 2.
 [    99.072] (==) NOUVEAU(0): Page flipping disabled: no kernel support
 [    99.072] (==) NOUVEAU(0): Swap limit set to 1 [Max allowed 2]
 [    99.072] (==) NOUVEAU(0): Page flipping synced to vblank by ddx.
 [    99.072] (II) NOUVEAU(0): Initializing outputs ...
 [    99.072] (II) NOUVEAU(0): **Output Unknown16-1** using monitor section Monitor0
 [    99.072] (**) NOUVEAU(0): Option "Ignore" "1"
 [    99.072] (II) NOUVEAU(0): 0 crtcs needed for screen.

Edit by @denysvitali: Formatting

from linux-on-pixel-c.

Samt43 avatar Samt43 commented on August 30, 2024

It seems that you have issues with your libglx that is at the wrong format.
Another thing @Gnurou can confirm, but I don't think we have to use Nouveau DDX driver but modesetting instead using glamor to accelerate X commands.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@Samt43 For kernel tests, I use the assembly of the rootfs from denysvitali https://github.com/denysvitali/linux-on-pixel-c direct link https://ded1.denv.it/pixel-c/arch-xfce-lightdm.tar.gz
it works quite smoothly.
Your earlier image of rootfs also works, but graphics drawing is much slower.

X.Org X Server 1.19.3
Release Date: 2017-03-15
[    27.336] X Protocol Version 11, Revision 0
[    27.336] Build Operating System: Linux 3.10.96-3-ARCH armv7l 
[    27.336] Current Operating System: Linux pixel-c 4.15.2+ #33 SMP PREEMPT Wed Feb 14 21:07:55 +07 2018 aarch64
[    27.336] Kernel command line: cros_secure vpr=0x08000000@0xf6800000 cros_legacy init=/init rw fbcon loglevel=0 debug earlyprintk drm.atomic=1 no_console_suspend firmware_class.path=/lib/firmware
[    27.336] Build Date: 10 April 2017  01:19:09AM
[    27.336]  
[    27.336] Current version of pixman: 0.34.0
[    27.336] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[    27.336] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[    27.337] (==) Log file: "/var/log/Xorg.0.log", Time: Wed Feb 14 17:07:25 2018
[    27.343] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[    27.344] (==) No Layout section.  Using the first Screen section.
[    27.344] (==) No screen section available. Using defaults.
[    27.344] (**) |-->Screen "Default Screen Section" (0)
[    27.344] (**) |   |-->Monitor "<default monitor>"
[    27.347] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[    27.347] (==) Automatically adding devices
[    27.347] (==) Automatically enabling devices
[    27.347] (==) Automatically adding GPU devices
[    27.347] (==) Automatically binding GPU devices
[    27.347] (==) Max clients allowed: 256, resource mask: 0x1fffff
[    27.359] (WW) The directory "/usr/share/fonts/Type1/" does not exist.
[    27.359] 	Entry deleted from font path.
[    27.359] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/100dpi/".
[    27.359] 	Entry deleted from font path.
[    27.359] 	(Run 'mkfontdir' on "/usr/share/fonts/100dpi/").
[    27.359] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/75dpi/".
[    27.359] 	Entry deleted from font path.
[    27.359] 	(Run 'mkfontdir' on "/usr/share/fonts/75dpi/").
[    27.359] (==) FontPath set to:
	/usr/share/fonts/misc/,
	/usr/share/fonts/TTF/,
	/usr/share/fonts/OTF/
[    27.359] (==) ModulePath set to "/usr/lib/xorg/modules"
[    27.359] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[    27.360] (II) Loader magic: 0x1f2ee0
[    27.360] (II) Module ABI versions:
[    27.360] 	X.Org ANSI C Emulation: 0.4
[    27.360] 	X.Org Video Driver: 23.0
[    27.360] 	X.Org XInput driver : 24.1
[    27.360] 	X.Org Server Extension : 10.0
[    27.361] (++) using VT number 7

[    27.361] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[    27.363] (II) xfree86: Adding drm device (/dev/dri/card1)
[    27.373] (II) xfree86: Adding drm device (/dev/dri/card0)
[    27.374] (II) no primary bus or device found
[    27.374] 	falling back to /sys/devices/platform/50000000.host1x/drm/drm/card1
[    27.375] (II) LoadModule: "glx"
[    27.377] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[    27.378] (EE) Failed to load /usr/lib/xorg/modules/extensions/libglx.so: /usr/lib/xorg/modules/extensions/libglx.so: wrong ELF class: ELFCLASS64
[    27.378] (II) UnloadModule: "glx"
[    27.378] (II) Unloading glx
[    27.378] (EE) Failed to load module "glx" (loader failed, 7)
[    27.378] (==) Matched modesetting as autoconfigured driver 0
[    27.378] (==) Matched fbdev as autoconfigured driver 1
[    27.378] (==) Assigned the driver to the xf86ConfigLayout
[    27.378] (II) LoadModule: "modesetting"
[    27.378] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[    27.380] (II) Module modesetting: vendor="X.Org Foundation"
[    27.380] 	compiled for 1.19.3, module version = 1.19.3
[    27.380] 	Module class: X.Org Video Driver
[    27.380] 	ABI class: X.Org Video Driver, version 23.0
[    27.381] (II) LoadModule: "fbdev"
[    27.381] (WW) Warning, couldn't open module fbdev
[    27.381] (II) UnloadModule: "fbdev"
[    27.381] (II) Unloading fbdev
[    27.381] (EE) Failed to load module "fbdev" (module does not exist, 0)
[    27.381] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[    27.423] (II) modeset(0): using drv /dev/dri/card1
[    27.424] (II) modeset(G0): using drv /dev/dri/card0
[    27.424] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
[    27.424] (II) modeset(0): Creating default Display subsection in Screen section
	"Default Screen Section" for depth/fbbpp 24/32
[    27.424] (==) modeset(0): Depth 24, (==) framebuffer bpp 32
[    27.424] (==) modeset(0): RGB weight 888
[    27.424] (==) modeset(0): Default visual is TrueColor
[    27.424] (II) Loading sub module "glamoregl"
[    27.424] (II) LoadModule: "glamoregl"
[    27.424] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[    27.448] (II) Module glamoregl: vendor="X.Org Foundation"
[    27.448] 	compiled for 1.19.3, module version = 1.0.0
[    27.448] 	ABI class: X.Org ANSI C Emulation, version 0.4
[    27.448] (II) glamor: OpenGL accelerated X.org driver based.
[    28.106] (II) glamor: EGL version 1.4 (DRI2):
[    28.106] EGL_MESA_drm_image required.
[    28.107] (EE) modeset(0): glamor initialization failed
[    28.107] (II) modeset(0): ShadowFB: preferred NO, enabled NO
[    28.107] (II) modeset(0): Output DSI-1 has no monitor section
[    28.108] (II) modeset(0): EDID for output DSI-1
[    28.108] (II) modeset(0): Printing probed modes for output DSI-1
[    28.108] (II) modeset(0): Modeline "2560x1800"x60.0  304.42  2560 2640 2720 2800  1800 1804 1808 1812 (108.7 kHz)
[    28.108] (II) modeset(0): Output DSI-1 connected
[    28.108] (II) modeset(0): Using sloppy heuristic for initial modes
[    28.108] (II) modeset(0): Output DSI-1 using initial mode 2560x1800 +0+0
[    28.108] (==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
[    28.108] (==) modeset(0): DPI set to (96, 96)
[    28.108] (II) Loading sub module "fb"
[    28.108] (II) LoadModule: "fb"
[    28.108] (II) Loading /usr/lib/xorg/modules/libfb.so
[    28.111] (II) Module fb: vendor="X.Org Foundation"
[    28.111] 	compiled for 1.19.3, module version = 1.0.0
[    28.111] 	ABI class: X.Org ANSI C Emulation, version 0.4
[    28.112] (==) modeset(G0): Depth 24, (==) framebuffer bpp 32
[    28.112] (==) modeset(G0): RGB weight 888
[    28.112] (==) modeset(G0): Default visual is TrueColor
[    28.112] (II) Loading sub module "glamoregl"
[    28.112] (II) LoadModule: "glamoregl"
[    28.113] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[    28.113] (II) Module glamoregl: vendor="X.Org Foundation"
[    28.113] 	compiled for 1.19.3, module version = 1.0.0
[    28.113] 	ABI class: X.Org ANSI C Emulation, version 0.4
[    28.113] (II) glamor: OpenGL accelerated X.org driver based.
[    28.167] (II) glamor: EGL version 1.4 (DRI2):
[    28.230] (II) modeset(G0): glamor initialized
[    28.230] (==) modeset(G0): Using gamma correction (1.0, 1.0, 1.0)
[    28.230] (==) modeset(G0): DPI set to (96, 96)
[    28.230] (II) Loading sub module "fb"
[    28.230] (II) LoadModule: "fb"
[    28.231] (II) Loading /usr/lib/xorg/modules/libfb.so
[    28.231] (II) Module fb: vendor="X.Org Foundation"
[    28.231] 	compiled for 1.19.3, module version = 1.0.0
[    28.231] 	ABI class: X.Org ANSI C Emulation, version 0.4
[    28.231] (==) Depth 24 pixmap format is 32 bpp
[    28.300] (==) modeset(G0): Backing store enabled
[    28.300] (==) modeset(G0): Silken mouse enabled
[    28.302] (II) modeset(G0): RandR 1.2 enabled, ignore the following RandR disabled message.
[    28.304] (==) modeset(G0): DPMS enabled
[    28.304] (II) modeset(G0): [DRI2] Setup complete
[    28.305] (II) modeset(G0): [DRI2]   DRI driver: nouveau
[    28.305] (II) modeset(G0): [DRI2]   VDPAU driver: nouveau
[    28.327] (==) modeset(0): Backing store enabled
[    28.327] (==) modeset(0): Silken mouse enabled
[    28.327] (II) modeset(0): RandR 1.2 enabled, ignore the following RandR disabled message.
[    28.339] (==) modeset(0): DPMS enabled
[    28.339] (--) RandR disabled
[    28.374] (II) modeset(G0): Damage tracking initialized
[    28.374] (II) modeset(0): Damage tracking initialized
[    28.374] (II) modeset(0): Setting screen physical size to 677 x 476
[    28.528] (II) config/udev: Adding input device hid-over-i2c 06CB:3370 (/dev/input/event0)
[    28.528] (**) hid-over-i2c 06CB:3370: Applying InputClass "libinput touchscreen catchall"
[    28.528] (II) LoadModule: "libinput"
[    28.528] (II) Loading /usr/lib/xorg/modules/input/libinput_drv.so
[    28.541] (II) Module libinput: vendor="X.Org Foundation"

from linux-on-pixel-c.

Samt43 avatar Samt43 commented on August 30, 2024

Great, can you run glxinfo ?
If that works, it would mean that with a 4.15 kernel, everything is there to enable graphical acceleration for tegra without any mesa patch ! :)

from linux-on-pixel-c.

Samt43 avatar Samt43 commented on August 30, 2024

Hi @vartom,
I compiled you kernel 4.15, and i could run X correctly. I used the lastest rootfs available by build system.
Unfortunatly, llvmpipe was used for 3d rendering and UI was a bit slow.
Could you run glxinfo to know if your config is using GPU correctly ? It seems according to the log that you were really using nouveau DRI driver :)

Thanks a lot in adavance,

Samt43

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

In the system that I try there is no glxinfo.
In which particular version of the system do you have a problem with 3D?
I have now tried this https://github.com/denysvitali/tegra-nouveau-rootfs/releases/tag/untagged-439d9f4a817e73403582. It seems to be running asked for a password, but then does not boot.

from linux-on-pixel-c.

Samt43 avatar Samt43 commented on August 30, 2024

Seems like you have to install gnome-shell or xfce4 in order to have something after boot. (i had the same issue)
I could do some test and i have the same logs as yours. We only have software rendering for now, it seems that it's due to this :
AIGLX: Screen 0 is not DRI2 capable

I could have acceleration working with a mesa patched some days ago but only for wayland,
I continue to look on this,

Samt

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

It might look like this,

[   166.001] Build Operating System: Linux 4.12.7-1-ARCH aarch64 
[   166.006] Current Operating System: Linux alarm 4.15.2+ #68 SMP PREEMPT Sat Feb 24 15:35:11 +07 2018 aarch64
[   166.007] Kernel command line: cros_secure vpr=0x08000000@0xf6800000 cros_legacy root=/dev/sdb1 rootwait rw init=/init fbcon loglevel=0 debug earlyprintk drm.atomic=1 no_console_suspend firmware_class.path=/lib/firmware
[   166.017] Build Date: 30 January 2018  11:53:15PM
[   166.023]  
[   166.028] Current version of pixman: 0.34.0
[   166.039] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[   166.039] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[   166.061] (==) Log file: "/var/log/Xorg.0.log", Time: Sat Feb 24 13:35:45 2018
[   166.070] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[   166.072] (==) No Layout section.  Using the first Screen section.
[   166.072] (==) No screen section available. Using defaults.
[   166.072] (**) |-->Screen "Default Screen Section" (0)
[   166.072] (**) |   |-->Monitor "<default monitor>"
[   166.078] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[   166.078] (==) Automatically adding devices
[   166.078] (==) Automatically enabling devices
[   166.078] (==) Automatically adding GPU devices
[   166.078] (==) Automatically binding GPU devices
[   166.078] (==) Max clients allowed: 256, resource mask: 0x1fffff
[   166.098] (WW) The directory "/usr/share/fonts/Type1/" does not exist.
[   166.098] 	Entry deleted from font path.
[   166.099] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/100dpi/".
[   166.099] 	Entry deleted from font path.
[   166.099] 	(Run 'mkfontdir' on "/usr/share/fonts/100dpi/").
[   166.100] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/75dpi/".
[   166.100] 	Entry deleted from font path.
[   166.100] 	(Run 'mkfontdir' on "/usr/share/fonts/75dpi/").
[   166.100] (==) FontPath set to:
	/usr/share/fonts/misc/,
	/usr/share/fonts/TTF/,
	/usr/share/fonts/OTF/
[   166.100] (==) ModulePath set to "/usr/lib/xorg/modules"
[   166.100] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[   166.102] (II) Loader magic: 0x556eacdd28
[   166.102] (II) Module ABI versions:
[   166.102] 	X.Org ANSI C Emulation: 0.4
[   166.102] 	X.Org Video Driver: 23.0
[   166.102] 	X.Org XInput driver : 24.1
[   166.102] 	X.Org Server Extension : 10.0
[   166.104] (++) using VT number 1

[   166.104] (--) controlling tty is VT number 1, auto-enabling KeepTty
[   166.107] (II) systemd-logind: took control of session /org/freedesktop/login1/session/_31
[   166.109] (II) xfree86: Adding drm device (/dev/dri/card0)
[   166.110] (II) systemd-logind: got fd for /dev/dri/card0 226:0 fd 11 paused 0
[   166.111] (II) xfree86: Adding drm device (/dev/dri/card1)
[   166.112] (II) systemd-logind: got fd for /dev/dri/card1 226:1 fd 12 paused 0
[   166.112] (II) no primary bus or device found
[   166.112] 	falling back to /sys/devices/platform/50000000.host1x/drm/drm/card0
[   166.112] (II) LoadModule: "glx"
[   166.116] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[   166.154] (II) Module glx: vendor="X.Org Foundation"
[   166.154] 	compiled for 1.19.6, module version = 1.0.0
[   166.154] 	ABI class: X.Org Server Extension, version 10.0
[   166.156] (==) Matched modesetting as autoconfigured driver 0
[   166.157] (==) Matched fbdev as autoconfigured driver 1
[   166.157] (==) Assigned the driver to the xf86ConfigLayout
[   166.157] (II) LoadModule: "modesetting"
[   166.157] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[   166.161] (II) Module modesetting: vendor="X.Org Foundation"
[   166.161] 	compiled for 1.19.6, module version = 1.19.6
[   166.161] 	Module class: X.Org Video Driver
[   166.161] 	ABI class: X.Org Video Driver, version 23.0
[   166.161] (II) LoadModule: "fbdev"
[   166.162] (WW) Warning, couldn't open module fbdev
[   166.162] (II) UnloadModule: "fbdev"
[   166.162] (II) Unloading fbdev
[   166.162] (EE) Failed to load module "fbdev" (module does not exist, 0)
[   166.162] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[   166.162] (II) modeset(0): using drv /dev/dri/card0
[   166.162] (II) modeset(G0): using drv /dev/dri/card1
[   166.162] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
[   166.162] (II) modeset(0): Creating default Display subsection in Screen section
	"Default Screen Section" for depth/fbbpp 24/32
[   166.162] (==) modeset(0): Depth 24, (==) framebuffer bpp 32
[   166.162] (==) modeset(0): RGB weight 888
[   166.162] (==) modeset(0): Default visual is TrueColor
[   166.162] (II) Loading sub module "glamoregl"
[   166.162] (II) LoadModule: "glamoregl"
[   166.163] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[   166.204] (II) Module glamoregl: vendor="X.Org Foundation"
[   166.204] 	compiled for 1.19.6, module version = 1.0.0
[   166.204] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   166.204] (II) glamor: OpenGL accelerated X.org driver based.
[   166.255] (II) glamor: EGL version 1.4 (DRI2):
[   166.272] (II) modeset(0): glamor initialized
[   166.272] (II) modeset(0): Output DSI-1 has no monitor section
[   166.273] (II) modeset(0): EDID for output DSI-1
[   166.273] (II) modeset(0): Printing probed modes for output DSI-1
[   166.273] (II) modeset(0): Modeline "2560x1800"x60.0  304.42  2560 2640 2720 2800  1800 1804 1808 1812 (108.7 kHz)
[   166.273] (II) modeset(0): Output DSI-1 connected
[   166.273] (II) modeset(0): Using sloppy heuristic for initial modes
[   166.273] (II) modeset(0): Output DSI-1 using initial mode 2560x1800 +0+0
[   166.273] (==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
[   166.273] (==) modeset(0): DPI set to (96, 96)
[   166.273] (II) Loading sub module "fb"
[   166.273] (II) LoadModule: "fb"
[   166.273] (II) Loading /usr/lib/xorg/modules/libfb.so
[   166.281] (II) Module fb: vendor="X.Org Foundation"
[   166.281] 	compiled for 1.19.6, module version = 1.0.0
[   166.281] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   166.281] (==) modeset(G0): Depth 24, (==) framebuffer bpp 32
[   166.281] (==) modeset(G0): RGB weight 888
[   166.281] (==) modeset(G0): Default visual is TrueColor
[   166.281] (II) Loading sub module "glamoregl"
[   166.281] (II) LoadModule: "glamoregl"
[   166.281] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[   166.281] (II) Module glamoregl: vendor="X.Org Foundation"
[   166.281] 	compiled for 1.19.6, module version = 1.0.0
[   166.281] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   166.281] (II) glamor: OpenGL accelerated X.org driver based.
[   166.501] (II) glamor: EGL version 1.4 (DRI2):
[   166.613] (II) modeset(G0): glamor initialized
[   166.613] (==) modeset(G0): Using gamma correction (1.0, 1.0, 1.0)
[   166.613] (==) modeset(G0): DPI set to (96, 96)
[   166.613] (II) Loading sub module "fb"
[   166.613] (II) LoadModule: "fb"
[   166.614] (II) Loading /usr/lib/xorg/modules/libfb.so
[   166.614] (II) Module fb: vendor="X.Org Foundation"
[   166.614] 	compiled for 1.19.6, module version = 1.0.0
[   166.614] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   166.614] (==) Depth 24 pixmap format is 32 bpp
[   166.849] (==) modeset(G0): Backing store enabled
[   166.849] (==) modeset(G0): Silken mouse enabled
[   166.854] (II) modeset(G0): RandR 1.2 enabled, ignore the following RandR disabled message.
[   166.860] (==) modeset(G0): DPMS enabled
[   166.860] (II) modeset(G0): [DRI2] Setup complete
[   166.860] (II) modeset(G0): [DRI2]   DRI driver: nouveau
[   166.860] (II) modeset(G0): [DRI2]   VDPAU driver: nouveau
[   167.040] (==) modeset(0): Backing store enabled
[   167.040] (==) modeset(0): Silken mouse enabled
[   167.041] (II) modeset(0): RandR 1.2 enabled, ignore the following RandR disabled message.
[   167.053] (==) modeset(0): DPMS enabled
[   167.053] (II) modeset(0): [DRI2] Setup complete
[   167.053] (II) modeset(0): [DRI2]   DRI driver: tegra
[   167.053] (II) modeset(0): [DRI2]   VDPAU driver: tegra
[   167.053] (--) RandR disabled
[   167.293] (II) AIGLX: enabled GLX_MESA_copy_sub_buffer
[   167.293] (II) AIGLX: enabled GLX_ARB_create_context
[   167.293] (II) AIGLX: enabled GLX_ARB_create_context_profile
[   167.293] (II) AIGLX: enabled GLX_EXT_create_context_es{,2}_profile
[   167.293] (II) AIGLX: enabled GLX_INTEL_swap_event
[   167.293] (II) AIGLX: enabled GLX_SGI_swap_control
[   167.293] (II) AIGLX: enabled GLX_EXT_framebuffer_sRGB
[   167.293] (II) AIGLX: enabled GLX_ARB_fbconfig_float
[   167.293] (II) AIGLX: enabled GLX_EXT_fbconfig_packed_float
[   167.294] (II) AIGLX: GLX_EXT_texture_from_pixmap backed by buffer objects
[   167.300] (II) AIGLX: Loaded and initialized tegra
[   167.300] (II) GLX: Initialized DRI2 GL provider for screen 0
[   167.337] (II) modeset(G0): Damage tracking initialized
[   167.370] (II) modeset(0): Damage tracking initialized
[   167.370] (II) modeset(0): Setting screen physical size to 677 x 476
[   167.593] (II) config/udev: Adding input device hid-over-i2c 06CB:3370 (/dev/input/event0)
[   167.593] (**) hid-over-i2c 06CB:3370: Applying InputClass "libinput touchscreen catchall"
[   167.593] (II) LoadModule: "libinput"
[   167.593] (II) Loading /usr/lib/xorg/modules/input/libinput_drv.so

But this is not stable (. kmscube works through time and sometimes takes off with errors. weston-launch does not start. startx giving out 3 rectangles
All this was received on the assembled rootfs with the settings approximated to the original ones. Using the drivers drm and mesa from cgit.freedesktop.org/~tagr

from linux-on-pixel-c.

Samt43 avatar Samt43 commented on August 30, 2024

@friesoft No I was talking about this patch Samt43/mesa@d64c261
From the renderonly branch of @Gnurou plus the patch I made to Port it on Pixel c : https://github.com/Samt43/mesa/commits/renderonly
With this compiled and installed using the rootfs scripts, I could run Weston correctly with acceleration.
The patches that you are talking about are very recent and seem to be equivalent to @Gnurou patch but uses more recent features of the kernel.
This is a great hope for us, and according to the description it should work for Pixel C.
I will try to compile a 4.16 kernel soon and try to compile Mesa with these patches when I will get some time !
Thanks a lot for the infos !

Edit : it seems @vartom already tried to compile mesa from this and that resulted in an instable UI.
@vartom don't we need a 4.16 kernel for this ?

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@Samt43 The 4.16 kernel doesn't seem to work. Apparently they've messed up with some arm instructions. We'll have to wait for a new tagged release (that will be released today)

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@Samt43 @denysvitali It is possible that for this (mesa) you need the kernel 4.17 https://github.com/thierryreding/linux/tree/for-4.17/work
In patches, the general line of updates is viewed "Support sync FDs ..."

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

I've tried the for-4.17/work kernel, unfortunately it doesn't work. The display stays black. I'll push the kernel source (and a prebuilt image) as soon as possible.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@thierryreding for-4.17/work boot image is available here (source on my repo) whilst the latest 4.16-rc3 kernel boot image is available here

Please note that both images use my initramfs, which requires the rootfs in /system (/dev/block/mmcblk0p4).
You can still unpack / repack it to boot the kernel image with another initramfs.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Can you push your version of the kernel?

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

https://github.com/vartom/linux/commits/for-4.17/work

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Oh I guess I missed your linux fork, I was looking at your linux-smaug repo.
Btw, I've tried the branch w/ your patches and added some of mines, it boots but unfortunately it is still not accelerated, even with drm, mesa and wayland compiled from thierryreding's repo

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali @Samt43
Can you correct the kernel compilation script (build-linux) so that it can work in the travis-ci?
This is necessary for the modules to be loaded at the time the system is started.
It is necessary to include in the system the same version of the kernel that is used as a boot

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

Faced the problem of lack of time to build through Travis. A limit of 50 minutes is not enough for building with the kernel. But the most not logical, is that the assembled assemblies of the rootfs on the home PC do not enter the graphical shell. The same is collected on Travis, it starts normally.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

You're probably missing the ./scripts/generate-rootfs call. This scripts fixes all the permissions on the rootfs.

About the build time of Travis: I'll set up a Jenkins job on one of my own servers (probably jenkins.mastodonti.co) and give us access through the @pixelc-linux organization.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

I used it(./scripts/generate-rootfs), but instead of sudo tar -cvpzf $TOP/out/rootfs.tar.gz ,
i used sudo rsync -aAXv $TOP/out/target/$ARCH/ArchLinuxArm/* $USB_MOUNT/ maybe this is the problem. Now I'll check.
Checked. This is the problem.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom
Did you solve the problem you were having?

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali I do not have so much time now to check everything that I wanted.
I wanted to check again the next set, mesa and drm from @thierryreding, with the 4.15 kernel.
I can not configure the 4.17 kernel to run the nouveau driver as a module. And there are such mistakes Failed to set up IOMMU for device 57000000.gpu; retaining platform DMA ops

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

In the last test, I checked it. Does not load into the GUI. This makes one think of something else that the kernel or DTs are not all included for the stable operation of the GPU.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024
[   118.945] Current Operating System: Linux alarm 4.15.6+ #76 SMP PREEMPT Sun Mar 4 22:54:21 +07 2018 aarch64
[   118.945] Kernel command line: cros_secure vpr=0x08000000@0xf6800000 cros_legacy init=/init rw fbcon loglevel=0 debug earlyprintk drm.atomic=1 no_console_suspend firmware_class.path=/lib/firmware
[   118.945] Build Date: 30 January 2018  11:53:15PM
[   118.945]  
[   118.945] Current version of pixman: 0.34.0
[   118.945] 	Before reporting problems, check http://wiki.x.org
	to make sure that you have the latest version.
[   118.945] Markers: (--) probed, (**) from config file, (==) default setting,
	(++) from command line, (!!) notice, (II) informational,
	(WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[   118.946] (==) Log file: "/var/log/Xorg.0.log", Time: Fri Mar  9 15:34:29 2018
[   118.947] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[   118.949] (==) No Layout section.  Using the first Screen section.
[   118.949] (==) No screen section available. Using defaults.
[   118.949] (**) |-->Screen "Default Screen Section" (0)
[   118.949] (**) |   |-->Monitor "<default monitor>"
[   118.955] (==) No monitor specified for screen "Default Screen Section".
	Using a default monitor configuration.
[   118.955] (==) Automatically adding devices
[   118.955] (==) Automatically enabling devices
[   118.955] (==) Automatically adding GPU devices
[   118.955] (==) Automatically binding GPU devices
[   118.955] (==) Max clients allowed: 256, resource mask: 0x1fffff
[   118.955] (WW) The directory "/usr/share/fonts/Type1/" does not exist.
[   118.955] 	Entry deleted from font path.
[   118.955] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/100dpi/".
[   118.955] 	Entry deleted from font path.
[   118.955] 	(Run 'mkfontdir' on "/usr/share/fonts/100dpi/").
[   118.955] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/75dpi/".
[   118.955] 	Entry deleted from font path.
[   118.955] 	(Run 'mkfontdir' on "/usr/share/fonts/75dpi/").
[   118.955] (==) FontPath set to:
	/usr/share/fonts/misc/,
	/usr/share/fonts/TTF/,
	/usr/share/fonts/OTF/
[   118.955] (==) ModulePath set to "/usr/lib/xorg/modules"
[   118.955] (II) The server relies on udev to provide the list of input devices.
	If no devices become available, reconfigure udev or disable AutoAddDevices.
[   118.957] (II) Loader magic: 0x58510dcd28
[   118.957] (II) Module ABI versions:
[   118.957] 	X.Org ANSI C Emulation: 0.4
[   118.958] 	X.Org Video Driver: 23.0
[   118.958] 	X.Org XInput driver : 24.1
[   118.958] 	X.Org Server Extension : 10.0
[   118.959] (++) using VT number 2

[   118.963] (II) systemd-logind: took control of session /org/freedesktop/login1/session/c2
[   118.965] (II) xfree86: Adding drm device (/dev/dri/card0)
[   118.966] (II) systemd-logind: got fd for /dev/dri/card0 226:0 fd 12 paused 0
[   118.967] (II) xfree86: Adding drm device (/dev/dri/card1)
[   118.968] (II) systemd-logind: got fd for /dev/dri/card1 226:1 fd 13 paused 0
[   118.969] (II) no primary bus or device found
[   118.969] 	falling back to /sys/devices/platform/50000000.host1x/drm/drm/card0
[   118.969] (II) LoadModule: "glx"
[   118.972] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[   118.987] (II) Module glx: vendor="X.Org Foundation"
[   118.987] 	compiled for 1.19.6, module version = 1.0.0
[   118.987] 	ABI class: X.Org Server Extension, version 10.0
[   118.989] (==) Matched modesetting as autoconfigured driver 0
[   118.989] (==) Matched fbdev as autoconfigured driver 1
[   118.989] (==) Assigned the driver to the xf86ConfigLayout
[   118.989] (II) LoadModule: "modesetting"
[   118.991] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[   118.996] (II) Module modesetting: vendor="X.Org Foundation"
[   118.996] 	compiled for 1.19.6, module version = 1.19.6
[   118.996] 	Module class: X.Org Video Driver
[   118.996] 	ABI class: X.Org Video Driver, version 23.0
[   118.996] (II) LoadModule: "fbdev"
[   118.996] (WW) Warning, couldn't open module fbdev
[   118.996] (II) UnloadModule: "fbdev"
[   118.996] (II) Unloading fbdev
[   118.996] (EE) Failed to load module "fbdev" (module does not exist, 0)
[   118.996] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[   118.996] (II) modeset(0): using drv /dev/dri/card0
[   118.997] (II) modeset(G0): using drv /dev/dri/card1
[   118.997] (WW) VGA arbiter: cannot open kernel arbiter, no multi-card support
[   118.997] (II) modeset(0): Creating default Display subsection in Screen section
	"Default Screen Section" for depth/fbbpp 24/32
[   118.997] (==) modeset(0): Depth 24, (==) framebuffer bpp 32
[   118.997] (==) modeset(0): RGB weight 888
[   118.997] (==) modeset(0): Default visual is TrueColor
[   118.997] (II) Loading sub module "glamoregl"
[   118.997] (II) LoadModule: "glamoregl"
[   118.997] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[   119.009] (II) Module glamoregl: vendor="X.Org Foundation"
[   119.009] 	compiled for 1.19.6, module version = 1.0.0
[   119.009] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   119.009] (II) glamor: OpenGL accelerated X.org driver based.
[   119.046] (II) glamor: EGL version 1.4 (DRI2):
[   119.055] (II) modeset(0): glamor initialized
[   119.055] (II) modeset(0): Output DSI-1 has no monitor section
[   119.055] (II) modeset(0): EDID for output DSI-1
[   119.055] (II) modeset(0): Printing probed modes for output DSI-1
[   119.055] (II) modeset(0): Modeline "2560x1800"x60.0  304.42  2560 2640 2720 2800  1800 1804 1808 1812 (108.7 kHz)
[   119.055] (II) modeset(0): Output DSI-1 connected
[   119.055] (II) modeset(0): Using sloppy heuristic for initial modes
[   119.055] (II) modeset(0): Output DSI-1 using initial mode 2560x1800 +0+0
[   119.055] (==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
[   119.055] (==) modeset(0): DPI set to (96, 96)
[   119.055] (II) Loading sub module "fb"
[   119.055] (II) LoadModule: "fb"
[   119.056] (II) Loading /usr/lib/xorg/modules/libfb.so
[   119.063] (II) Module fb: vendor="X.Org Foundation"
[   119.063] 	compiled for 1.19.6, module version = 1.0.0
[   119.063] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   119.064] (==) modeset(G0): Depth 24, (==) framebuffer bpp 32
[   119.064] (==) modeset(G0): RGB weight 888
[   119.064] (==) modeset(G0): Default visual is TrueColor
[   119.064] (II) Loading sub module "glamoregl"
[   119.064] (II) LoadModule: "glamoregl"
[   119.064] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[   119.064] (II) Module glamoregl: vendor="X.Org Foundation"
[   119.064] 	compiled for 1.19.6, module version = 1.0.0
[   119.064] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   119.064] (II) glamor: OpenGL accelerated X.org driver based.
[   119.084] (II) glamor: EGL version 1.4 (DRI2):
[   119.086] (II) modeset(G0): glamor initialized
[   119.086] (==) modeset(G0): Using gamma correction (1.0, 1.0, 1.0)
[   119.086] (==) modeset(G0): DPI set to (96, 96)
[   119.086] (II) Loading sub module "fb"
[   119.086] (II) LoadModule: "fb"
[   119.087] (II) Loading /usr/lib/xorg/modules/libfb.so
[   119.087] (II) Module fb: vendor="X.Org Foundation"
[   119.087] 	compiled for 1.19.6, module version = 1.0.0
[   119.087] 	ABI class: X.Org ANSI C Emulation, version 0.4
[   119.087] (==) Depth 24 pixmap format is 32 bpp
[   119.109] (WW) glamor256: Failed to get GLSL version
[   119.109] (EE) modeset(G0): Failed to initialize glamor at ScreenInit() time.
[   119.109] (EE) 
Fatal server error:
[   119.109] (EE) AddScreen/ScreenInit failed for gpu driver 0 -1
[   119.109] (EE) 
[   119.109] (EE) 

Today's assembly with a fresh mesa. the login greeted. Graphics buggy. X did not start.
https://travis-ci.org/vartom/tegra-nouveau-rootfs/builds/351320319
https://github.com/vartom/tegra-nouveau-rootfs/releases/tag/untagged-06c3cfac81bb8c29d3c0

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

Graphics buggy in the Gnome. the mouse pointer is lost. Tried it with kernels 4.15 and 4.16 (next). X did not start. Where there are these glitches I do not know.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

What about xfce4? GNOME defaults to Wayland, have you tried with GNOME on Xorg?

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

xfce4 I did not try, previously it worked well. GNOME on Xorg tried - does not start, I write about it.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali try it
https://github.com/vartom/tegra-nouveau-rootfs/releases/tag/untagged-5f083c056d22f9c2d074

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom Kernel image? Should I rebuild it from next-20180309?

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

Kernel 4.15.y, nouveau driver in kernel, not modul. I think the drivers for GPU do not work. I do not see anything new from the new version of Mesa.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Can you please try to build the linux-next-20180309 and the newest version of mesa?
As Thierry said, it should work. Probably what you're doing wrong now is that you're using linux-4.15.y which doesn't include Thierry's patches.

I can't test it right now, I'll look into it ASAP, but if you have some spare time you can try as I instructed

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

Probably what you're doing wrong now is that you're using linux-4.15.y which doesn't include Thierry's patches.

It does not matter, I try linux-next-20180309
If the return to the modular nouveau driver load does not help, it can be said that their patches do not work with the built-in dsi panel.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali @thierryreding i try modular nouveau driver, linux-next-20180309 and the newest version of mesa. It does not matter. X did not start.
The only difference is when you start kmscube not have to write the key --device=/dev/dri/card1
Maybe this is some sort of problem when assembling Xorg?

Xorg.0.log

from linux-on-pixel-c.

thierryreding avatar thierryreding commented on August 30, 2024

@vartom can you provide the output of dmesg and the exact kernel configuration that you're using? According to Xorg.0.log there seem to be changes on top of next-20180309, perhaps post those as well, just to make sure they aren't potentially breaking anything.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@thierryreding kernel configuration https://github.com/vartom/linux-smaug/blob/test/arch/arm64/configs/tegra21_defconfig
I also tried with this configuration
https://github.com/vartom/linux-smaug/blob/test/arch/arm64/configs/defconfig
I can not drop the kernel log now, not at home.

from linux-on-pixel-c.

thierryreding avatar thierryreding commented on August 30, 2024

@vartom your configuration looks okay. dmesg should provide some more clues.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@thierryreding dmesg-1520793876.txt

from linux-on-pixel-c.

thierryreding avatar thierryreding commented on August 30, 2024

This doesn't show anything related to nouveau. Are you sure the device is enabled in device tree and the driver is built-in or loaded?

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom Can you include the nouveau module in the kernel?
Set this to y

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@thierryreding dmesg-1520862223.txt
nouveau in the kernel

from linux-on-pixel-c.

thierryreding avatar thierryreding commented on August 30, 2024

This looks all very normal, no indication that anything went wrong.

Can you list the exact versions of kernel, libdrm, mesa and X that you're using, perhaps I can reproduce somehow. Also, how do you run X, what window manager/desktop environment do you use?

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@thierryreding I'm pretty sure he is using this rootfs which is our custom fork of @Gnurou work.

Vartom's rootfs is available here

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

When the lightdm does not load, that is, I continue to see the log instead of the desktop. I go to VT through Ctrl + alt + f4. I enter as a root. I can run a kmscube but after exiting on Ctrl + c, I do not see the text VT. I make run a startx, it gives an error Fatal server error: [ 119.109] (EE) AddScreen/ScreenInit failed for gpu driver 0 -1 and then the text VT is returned. I can again start kmscube. The only thing I do not know is why the output from kmskube does not return text to VT.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

I checked CONFIG_TEGRA_MC=y and TEGRA_IOMMU_SMMU=y in .config.
as I wrote earlier on kernels 4.17 and next-20180309 I see such an error

And there are such mistakes Failed to set up IOMMU for device 57000000.gpu; retaining platform DMA ops

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

I tried to merge the next-20180309 into my 4.15.y kernel, and this is the result. Unfortunately the next-20180309 had some troubles with our patches - therefore the panel didn't show any image.

I hope I didn't messed up anything in the merge.

Here is the Xorg.log after the nouveau module was dynamically loaded:

[   160.612] 
X.Org X Server 1.19.6
Release Date: 2017-12-20
[   160.612] X Protocol Version 11, Revision 0
[   160.612] Build Operating System: Linux 4.14.13-1-ARCH armv7l 
[   160.612] Current Operating System: Linux alarm 4.16.0-rc4-next-20180309+ #126 SMP PREEMPT Mon Mar 12 21:03:21 UTC 2018 aarch64
[   160.612] Kernel command line: cros_secure vpr=0x08000000@0xf6800000 fbcon video=tegrafb debug earlyprintk earlycon=uart8250,mmio32,0x70006000 drm.atomic=1 consoleblank=0 firmware_class.path=/lib/firmware
[   160.613] Build Date: 31 January 2018  06:57:16AM
[   160.613]  
[   160.613] Current version of pixman: 0.34.0
[   160.613]    Before reporting problems, check http://wiki.x.org
        to make sure that you have the latest version.
[   160.613] Markers: (--) probed, (**) from config file, (==) default setting,
        (++) from command line, (!!) notice, (II) informational,
        (WW) warning, (EE) error, (NI) not implemented, (??) unknown.
[   160.613] (==) Log file: "/var/log/Xorg.0.log", Time: Mon Mar 12 21:07:15 2018
[   160.614] (==) Using system config directory "/usr/share/X11/xorg.conf.d"
[   160.614] (==) No Layout section.  Using the first Screen section.
[   160.614] (==) No screen section available. Using defaults.
[   160.614] (**) |-->Screen "Default Screen Section" (0)
[   160.614] (**) |   |-->Monitor "<default monitor>"
[   160.615] (==) No monitor specified for screen "Default Screen Section".
        Using a default monitor configuration.
[   160.615] (==) Automatically adding devices
[   160.615] (==) Automatically enabling devices
[   160.615] (==) Automatically adding GPU devices
[   160.615] (==) Automatically binding GPU devices
[   160.615] (==) Max clients allowed: 256, resource mask: 0x1fffff
[   160.616] (WW) The directory "/usr/share/fonts/Type1/" does not exist.
[   160.616]    Entry deleted from font path.
[   160.616] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/100dpi/".
[   160.616]    Entry deleted from font path.
[   160.616]    (Run 'mkfontdir' on "/usr/share/fonts/100dpi/").
[   160.616] (WW) `fonts.dir' not found (or not valid) in "/usr/share/fonts/75dpi/".
[   160.616]    Entry deleted from font path.
[   160.616]    (Run 'mkfontdir' on "/usr/share/fonts/75dpi/").
[   160.616] (==) FontPath set to:
        /usr/share/fonts/misc/,
        /usr/share/fonts/TTF/,
        /usr/share/fonts/OTF/
[   160.616] (==) ModulePath set to "/usr/lib/xorg/modules"
[   160.616] (II) The server relies on udev to provide the list of input devices.
        If no devices become available, reconfigure udev or disable AutoAddDevices.
[   160.616] (II) Loader magic: 0xd17f00
[   160.616] (II) Module ABI versions:
[   160.616]    X.Org ANSI C Emulation: 0.4
[   160.616]    X.Org Video Driver: 23.0
[   160.616]    X.Org XInput driver : 24.1
[   160.617]    X.Org Server Extension : 10.0
[   160.618] (++) using VT number 7

[   160.619] (II) systemd-logind: logind integration requires -keeptty and -keeptty was not provided, disabling logind integration
[   160.622] (II) xfree86: Adding drm device (/dev/dri/card0)
[   160.624] (II) xfree86: Adding drm device (/dev/dri/card1)
[   160.626] (II) no primary bus or device found
[   160.626]    falling back to /sys/devices/platform/50000000.host1x/drm/drm/card0
[   160.626] (II) LoadModule: "glx"
[   160.627] (II) Loading /usr/lib/xorg/modules/extensions/libglx.so
[   160.631] (II) Module glx: vendor="X.Org Foundation"
[   160.631]    compiled for 1.19.6, module version = 1.0.0
[   160.631]    ABI class: X.Org Server Extension, version 10.0
[   160.631] (==) Matched modesetting as autoconfigured driver 0
[   160.632] (==) Matched fbdev as autoconfigured driver 1
[   160.632] (==) Assigned the driver to the xf86ConfigLayout
[   160.632] (II) LoadModule: "modesetting"
[   160.632] (II) Loading /usr/lib/xorg/modules/drivers/modesetting_drv.so
[   160.633] (II) Module modesetting: vendor="X.Org Foundation"
[   160.633]    compiled for 1.19.6, module version = 1.19.6
[   160.633]    Module class: X.Org Video Driver
[   160.633]    ABI class: X.Org Video Driver, version 23.0
[   160.633] (II) LoadModule: "fbdev"
[   160.634] (WW) Warning, couldn't open module fbdev
[   160.634] (II) UnloadModule: "fbdev"
[   160.634] (II) Unloading fbdev
[   160.634] (EE) Failed to load module "fbdev" (module does not exist, 0)
[   160.634] (II) modesetting: Driver for Modesetting Kernel Drivers: kms
[   160.640] (II) modeset(0): using drv /dev/dri/card0
[   160.641] (II) modeset(G0): using drv /dev/dri/card1
[   160.641] (II) modeset(0): Creating default Display subsection in Screen section
        "Default Screen Section" for depth/fbbpp 24/32
[   160.641] (==) modeset(0): Depth 24, (==) framebuffer bpp 32
[   160.642] (==) modeset(0): RGB weight 888
[   160.642] (==) modeset(0): Default visual is TrueColor
[   160.642] (II) Loading sub module "glamoregl"
[   160.642] (II) LoadModule: "glamoregl"
[   160.642] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[   160.646] (II) Module glamoregl: vendor="X.Org Foundation"
[   160.646]    compiled for 1.19.6, module version = 1.0.0
[   160.646]    ABI class: X.Org ANSI C Emulation, version 0.4
[   160.646] (II) glamor: OpenGL accelerated X.org driver based.
[   160.822] (II) glamor: EGL version 1.4 (DRI2):
[   160.822] EGL_MESA_drm_image required.
[   160.824] (EE) modeset(0): glamor initialization failed
[   160.824] (II) modeset(0): ShadowFB: preferred NO, enabled NO
[   160.824] (II) modeset(0): Output DSI-1 has no monitor section
[   160.825] (II) modeset(0): EDID for output DSI-1
[   160.825] (II) modeset(0): Printing probed modes for output DSI-1
[   160.825] (II) modeset(0): Modeline "2560x1800"x60.0  304.42  2560 2640 2720 2800  1800 1804 1808 1812 (108.7 kHz)
[   160.825] (II) modeset(0): Output DSI-1 connected
[   160.825] (II) modeset(0): Using sloppy heuristic for initial modes
[   160.825] (II) modeset(0): Output DSI-1 using initial mode 2560x1800 +0+0
[   160.825] (==) modeset(0): Using gamma correction (1.0, 1.0, 1.0)
[   160.825] (==) modeset(0): DPI set to (96, 96)
[   160.825] (II) Loading sub module "fb"
[   160.825] (II) LoadModule: "fb"
[   160.826] (II) Loading /usr/lib/xorg/modules/libfb.so
[   160.827] (II) Module fb: vendor="X.Org Foundation"
[   160.827]    compiled for 1.19.6, module version = 1.0.0
[   160.827]    ABI class: X.Org ANSI C Emulation, version 0.4
[   160.829] (==) modeset(G0): Depth 24, (==) framebuffer bpp 32
[   160.829] (==) modeset(G0): RGB weight 888
[   160.829] (==) modeset(G0): Default visual is TrueColor
[   160.829] (II) Loading sub module "glamoregl"
[   160.829] (II) LoadModule: "glamoregl"
[   160.830] (II) Loading /usr/lib/xorg/modules/libglamoregl.so
[   160.830] (II) Module glamoregl: vendor="X.Org Foundation"
[   160.830]    compiled for 1.19.6, module version = 1.0.0
[   160.830]    ABI class: X.Org ANSI C Emulation, version 0.4
[   160.830] (II) glamor: OpenGL accelerated X.org driver based.
[   160.871] (II) glamor: EGL version 1.4 (DRI2):
[   160.881] (II) modeset(G0): glamor initialized
[   160.882] (==) modeset(G0): Using gamma correction (1.0, 1.0, 1.0)
[   160.882] (==) modeset(G0): DPI set to (96, 96)
[   160.882] (II) Loading sub module "fb"
[   160.882] (II) LoadModule: "fb"
[   160.882] (II) Loading /usr/lib/xorg/modules/libfb.so
[   160.883] (II) Module fb: vendor="X.Org Foundation"
[   160.883]    compiled for 1.19.6, module version = 1.0.0
[   160.883]    ABI class: X.Org ANSI C Emulation, version 0.4
[   160.883] (==) Depth 24 pixmap format is 32 bpp
[   160.964] (==) modeset(G0): Backing store enabled
[   160.964] (==) modeset(G0): Silken mouse enabled
[   160.964] (II) modeset(G0): RandR 1.2 enabled, ignore the following RandR disabled message.
[   160.965] (==) modeset(G0): DPMS enabled
[   160.965] (II) modeset(G0): [DRI2] Setup complete
[   160.965] (II) modeset(G0): [DRI2]   DRI driver: nouveau
[   160.965] (II) modeset(G0): [DRI2]   VDPAU driver: nouveau
[   161.001] (==) modeset(0): Backing store enabled
[   161.001] (==) modeset(0): Silken mouse enabled
[   161.001] (II) modeset(0): RandR 1.2 enabled, ignore the following RandR disabled message.
[   161.006] (==) modeset(0): DPMS enabled
[   161.007] (--) RandR disabled
[   161.020] (II) AIGLX: Screen 0 is not DRI2 capable
[   161.020] (EE) AIGLX: reverting to software rendering
[   161.025] (II) IGLX: enabled GLX_MESA_copy_sub_buffer
[   161.027] (II) IGLX: Loaded and initialized swrast
[   161.027] (II) GLX: Initialized DRISWRAST GL provider for screen 0
[   161.189] (II) modeset(G0): Damage tracking initialized
[   161.191] (II) modeset(0): Damage tracking initialized
[   161.191] (II) modeset(0): Setting screen physical size to 677 x 476
[   161.412] (II) config/udev: Adding input device hid-over-i2c 06CB:3370 (/dev/input/event0)
[   161.412] (**) hid-over-i2c 06CB:3370: Applying InputClass "libinput touchscreen catchall"
[   161.412] (II) LoadModule: "libinput"
[   161.413] (II) Loading /usr/lib/xorg/modules/input/libinput_drv.so
[   161.419] (II) Module libinput: vendor="X.Org Foundation"
[   161.419]    compiled for 1.19.3, module version = 0.26.0
[   161.419]    Module class: X.Org XInput Driver
[   161.419]    ABI class: X.Org XInput driver, version 24.1
[   161.421] (II) Using input driver 'libinput' for 'hid-over-i2c 06CB:3370'
[   161.421] (**) hid-over-i2c 06CB:3370: always reports core events
[   161.421] (**) Option "Device" "/dev/input/event0"
[   161.421] (**) Option "_source" "server/udev"
[   161.425] (II) event0  - hid-over-i2c 06CB:3370: is tagged by udev as: Touchscreen
[   161.425] (II) event0  - hid-over-i2c 06CB:3370: device is a touch device
[   161.425] (II) event0  - hid-over-i2c 06CB:3370: device removed
[   161.464] (**) Option "config_info" "udev:/sys/devices/platform/7000c000.i2c/i2c-0/0-0020/0018:06CB:3370.0001/input/input0/event0"
[   161.465] (II) XINPUT: Adding extended input device "hid-over-i2c 06CB:3370" (type: TOUCHSCREEN, id 6)
[   161.465] (**) Option "AccelerationScheme" "none"
[   161.465] (**) hid-over-i2c 06CB:3370: (accel) selected scheme none/0
[   161.465] (**) hid-over-i2c 06CB:3370: (accel) acceleration factor: 2.000
[   161.465] (**) hid-over-i2c 06CB:3370: (accel) acceleration threshold: 4
[   161.468] (II) event0  - hid-over-i2c 06CB:3370: is tagged by udev as: Touchscreen
[   161.468] (II) event0  - hid-over-i2c 06CB:3370: device is a touch device
[   161.472] (II) config/udev: Adding input device hid-over-i2c 06CB:3370 (/dev/input/mouse0)
[   161.472] (II) No input driver specified, ignoring this device.
[   161.472] (II) This device may have been added with another device file.
[   161.477] (II) config/udev: Adding input device hid-over-i2c 06CB:3370 System Control (/dev/input/event1)
[   161.477] (**) hid-over-i2c 06CB:3370 System Control: Applying InputClass "libinput keyboard catchall"
[   161.477] (II) Using input driver 'libinput' for 'hid-over-i2c 06CB:3370 System Control'
[   161.477] (**) hid-over-i2c 06CB:3370 System Control: always reports core events
[   161.477] (**) Option "Device" "/dev/input/event1"
[   161.477] (**) Option "_source" "server/udev"
[   161.480] (II) event1  - hid-over-i2c 06CB:3370 System Control: is tagged by udev as: Keyboard
[   161.480] (II) event1  - hid-over-i2c 06CB:3370 System Control: device is a keyboard
[   161.480] (II) event1  - hid-over-i2c 06CB:3370 System Control: device removed
[   161.516] (**) Option "config_info" "udev:/sys/devices/platform/7000c000.i2c/i2c-0/0-0020/0018:06CB:3370.0001/input/input3/event1"
[   161.517] (II) XINPUT: Adding extended input device "hid-over-i2c 06CB:3370 System Control" (type: KEYBOARD, id 7)
[   161.521] (II) event1  - hid-over-i2c 06CB:3370 System Control: is tagged by udev as: Keyboard
[   161.521] (II) event1  - hid-over-i2c 06CB:3370 System Control: device is a keyboard
[   161.524] (II) config/udev: Adding input device gpio-keys (/dev/input/event2)
[   161.524] (**) gpio-keys: Applying InputClass "libinput keyboard catchall"
[   161.524] (II) Using input driver 'libinput' for 'gpio-keys'
[   161.524] (**) gpio-keys: always reports core events
[   161.524] (**) Option "Device" "/dev/input/event2"
[   161.524] (**) Option "_source" "server/udev"
[   161.527] (II) event2  - gpio-keys: is tagged by udev as: Keyboard Switch
[   161.527] (II) event2  - gpio-keys: device is a keyboard
[   161.527] (II) event2  - gpio-keys: device is a switch device
[   161.527] (II) event2  - gpio-keys: device is a switch device
[   161.527] (II) event2  - gpio-keys: device removed
[   161.544] (**) Option "config_info" "udev:/sys/devices/platform/gpio-keys/input/input6/event2"
[   161.544] (II) XINPUT: Adding extended input device "gpio-keys" (type: KEYBOARD, id 8)
[   161.548] (II) event2  - gpio-keys: is tagged by udev as: Keyboard Switch
[   161.548] (II) event2  - gpio-keys: device is a keyboard
[   161.548] (II) event2  - gpio-keys: device is a switch device
[   161.548] (II) event2  - gpio-keys: device is a switch device
[   162.943] (II) modeset(0): Disabling kernel dirty updates, not required.

glxinfo-4.16.0-rc4-next-20180309+.log

dmesg-2018-03-12_21:19:16-4.16.0-rc4-next-20180309+.log

Boot image - boot-linux-4.17-next-5b1c93553e12_20180312_210403

Packages:

[root@alarm ~]# pacman -Q xorg-server mesa wayland libdrm
xorg-server 1.19.6+13+gd0d1a694f-1
mesa 17.3.6-1
wayland 1.14.0-1
libdrm 2.4.91-1.1

Tested w/ GDM and LightDM. LightDM (Xorg) is okay, but it isn't accelerated.
GDM is ultra-slow, even w/ 0d (998 MHz) set in /sys/kernel/debug/dri/129/pstate:

[root@alarm ~]# cat /sys/kernel/debug/dri/129/pstate 
01: core 76 MHz
02: core 153 MHz
03: core 230 MHz
04: core 307 MHz
05: core 384 MHz
06: core 460 MHz
07: core 537 MHz
08: core 614 MHz
09: core 691 MHz
0a: core 768 MHz
0b: core 844 MHz
0c: core 921 MHz
0d: core 998 MHz AC DC *
DC: core 998 MHz

glxgers reports low FPS when is maximized on Xorg (around 40 FPS, the rendering is obviously done on the CPU)

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@thierryreding I think the problem can be in this patch
vartom/linux-smaug@2a8102d
in 4.15 it is not present and I see it in the kernel log

0.190265] tegra-mc 70019000.memory-controller: no memory timings for RAM code 0 registered
[    0.190563] iommu: Adding device reg-dummy to group 0
[    0.190585] iommu: Adding device f66cc000.ramoops to group 1
[    0.190627] iommu: Adding device 50000000.host1x to group 2
[    0.190648] iommu: Adding device 54100000.tsec to group 3
[    0.190690] iommu: Adding device 54200000.dc to group 4
[    0.190727] iommu: Adding device 54240000.dc to group 5
[    0.190746] iommu: Adding device 54300000.dsi to group 6
[    0.190780] iommu: Adding device 54340000.vic to group 7
[    0.190803] iommu: Adding device 54400000.dsi to group 8
[    0.190822] iommu: Adding device 545c0000.dpaux to group 9
[    0.190859] iommu: Adding device 57000000.gpu to group 10
[    0.190879] iommu: Adding device 60005000.timer to group 11
[    0.190898] iommu: Adding device 60007000.flow-controller to group 12
[    0.190918] iommu: Adding device 6000d000.gpio to group 13
[    0.190940] iommu: Adding device 60020000.dma to group 14
[    0.190958] iommu: Adding device 70000800.apbmisc to group 15
[    0.190976] iommu: Adding device 700008d4.pinmux to group 16
[    0.190993] iommu: Adding device 70006000.serial to group 17
[    0.191015] iommu: Adding device 70006200.serial to group 18
[    0.191033] iommu: Adding device 70006300.serial to group 19
[    0.191053] iommu: Adding device 7000c000.i2c to group 20
[    0.191071] iommu: Adding device 7000c400.i2c to group 21
[    0.191089] iommu: Adding device 7000c500.i2c to group 22
[    0.191107] iommu: Adding device 7000d000.i2c to group 23
[    0.191127] iommu: Adding device 7000d100.i2c to group 24
[    0.191146] iommu: Adding device 7000e000.rtc to group 25
[    0.191165] iommu: Adding device 7000e400.pmc to group 26
[    0.191183] iommu: Adding device 7000f800.fuse to group 27
[    0.191201] iommu: Adding device 70019000.memory-controller to group 28
[    0.191422] iommu: Adding device 70090000.usb to group 29
[    0.191501] iommu: Adding device 7009f000.padctl to group 30
[    0.191607] iommu: Adding device 700b0600.sdhci to group 31
[    0.191719] iommu: Adding device 700b0200.sdhci to group 32
[    0.191797] iommu: Adding device 700e3000.mipi to group 33
[    0.191862] iommu: Adding device aconnect@702c0000 to group 34
[    0.191986] iommu: Adding device timer to group 35
[    0.192098] iommu: Adding device 700e2000.thermal-sensor to group 36
[    0.192162] iommu: Adding device clocks to group 37
[    0.192226] iommu: Adding device gpio-keys to group 38
[    0.192311] iommu: Adding device max98357a to group 39
[    0.192377] iommu: Adding device sound to group 40
[    0.192446] iommu: Adding device psci to group 41
[    0.192503] iommu: Adding device regulators to group 42
[    0.192572] iommu: Adding device regulators:regulator@0 to group 43
[    0.192644] iommu: Adding device regulators:regulator@1 to group 44
[    0.192710] iommu: Adding device regulators:regulator@2 to group 45
[    0.192777] iommu: Adding device regulators:regulator@3 to group 46
[    0.192842] iommu: Adding device regulators:regulator@4 to group 47
[    0.192918] iommu: Adding device regulators:regulator@5 to group 48
[    0.192989] iommu: Adding device regulators:regulator@6 to group 49
[    0.193053] iommu: Adding device regulators:regulator@7 to group 50
[    0.198049] of_get_named_gpiod_flags: can't parse 'gpio' property of node '/regulators/regulator@0[0]'
. . . 

in 4.16 / 4.17 it is, and I see it in the kernel log

[    0.201139] tegra-mc 70019000.memory-controller: no memory timings for RAM code 0 registered
[    0.201460] iommu: Adding device 50000000.host1x to group 0
[    0.201493] iommu: Adding device 54200000.dc to group 1
[    0.201521] iommu: Adding device 54240000.dc to group 1
[    0.201551] iommu: Adding device 54340000.vic to group 2
[    0.201584] iommu: Adding device 57000000.gpu to group 3
[    0.207722] cryptd: max_cpu_qlen set to 1000
. . . 
[    0.609969] Failed to set up IOMMU for device 50000000.host1x; retaining platform DMA ops
[    0.610920] Failed to set up IOMMU for device 54200000.dc; retaining platform DMA ops
[    0.619128] Failed to set up IOMMU for device 54240000.dc; retaining platform DMA ops
[    0.627469] of_get_named_gpiod_flags: can't parse 'nvidia,hpd-gpio' property of node '/host1x@50000000/dsi@54300000[0]'
[    0.627503] tegra-dsi 54300000.dsi: Looking up avdd-dsi-csi-supply from device tree
[    0.627521] tegra-dsi 54300000.dsi: cannot get VDD supply
[    0.627713] tegra-dpaux 545c0000.dpaux: Looking up vdd-supply from device tree
[    0.630309] Failed to set up IOMMU for device 54340000.vic; retaining platform DMA ops

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom Thanks, I've merged the PR and I'm now rebuilding the rootfs. I'll try again once it's ready 🚀

from linux-on-pixel-c.

thierryreding avatar thierryreding commented on August 30, 2024

@vartom That should be unrelated. There are corresponding patches in Tegra DRM to make use of the IOMMU groups, but 4.15 should work identically. Effectively the result in programming of the SMMU and behaviour in Tegra DRM and Nouveau should be unchanged.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

Meh. I'm having some troubles compiling mesa (from git) for arm64. It fails at:

In file included from /run/media/dvitali/Shared/tegra-rootfs/out/target/aarch64/ArchLinuxArm/usr/include/libunwind.h:7:0,
                 from /run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.h:35,
                 from /run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:37:
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c: In function ‘debug_backtrace_capture’:
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:114:4: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘asm’
    unw_getcontext(&context);
    ^
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:114:4: error: lvalue required as left operand of assignment
    unw_getcontext(&context);
    ^
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:114:4: error: ‘unw_base’ undeclared (first use in this function); did you mean ‘unw_ctx’?
    unw_getcontext(&context);
    ^
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:114:4: note: each undeclared identifier is reported only once for each function it appears in
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c: At top level:
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:288:0: error: unterminated #else
 #if defined(HAVE_LIBUNWIND)
 
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:199:0: error: unterminated #else
 #if defined(HAVE_LIBUNWIND)
 
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:39:0: error: unterminated #else
 #if defined(HAVE_LIBUNWIND)
 
In file included from /run/media/dvitali/Shared/tegra-rootfs/out/target/aarch64/ArchLinuxArm/usr/include/libunwind.h:7:0,
                 from /run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.h:35,
                 from /run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:37:
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c: In function ‘debug_backtrace_capture’:
/run/media/dvitali/Shared/tegra-rootfs/mesa/src/gallium/auxiliary/util/u_debug_stack.c:114:4: error: invalid lvalue in asm output 0
    unw_getcontext(&context);

This seems to be related to this

@vartom how did you build mesa for arm64? I'm using tegra-nouveau-rootfs with the following:

./scripts/download-gcc && ./scripts/download-rootfs && ./scripts/prepare-rootfs  && ./scripts/build-drm && ./scripts/build-mesa && ./scripts/build-wayland && ./scripts/generate-rootfs

and it's failing at ./scripts/build-mesa

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali --disable-libunwind in build-mesa.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom I figured it out after a couple tries denysvitali/tegra-rootfs-scripts@0b4c661 👍
Thank you!

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali
I'm not sure that the installation of a new version of the Mesa libraries is successful. I still see(pacman -Q mesa) the old version of the Mesa libraries.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom That's because the mesa package gets installed in the prepare-ArchLinuxArm via the mesa-demos package.

But if you run the prepare-rootfs first, and then build the mesa package, you'll end up having the compiled mesa installed, but still have the package in pacman -Q mesa with the old version.

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali The installation of a new version of the mez libraries goes to the opt / nouveau directory.
Further with this, it will be prescribed that this should be used. Now it seems to me that this does not work or does not work correctly.
for example, a kmcube can call a new version and the graphical desktop(lightdm, Xorg) does not.

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom Are you sure about that?
Check this line and this part...
Mesa will be installed in the rootfs

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali
Yes, I am sure. https://github.com/vartom/tegra-nouveau-rootfs#compiling-mesa

from linux-on-pixel-c.

denysvitali avatar denysvitali commented on August 30, 2024

@vartom
That's just the README. The scripts aren't building mesa in /opt/nouveau...

Try adding:

echo "Running make for $PACKAGE: sysroot is $SYSROOT"

on run_make() in env.sh. Then build mesa.

Running make for mesa: sysroot is /run/media/dvitali/Shared/tegra-rootfs/out/target/aarch64/ArchLinuxArm

from linux-on-pixel-c.

vartom avatar vartom commented on August 30, 2024

@denysvitali
Pay attention to this
NV_PREFIX in env.sh
run_autogen in env.sh
run_autogen in build-mesa, build-drm, build-kmscube, ..
And look at the presence of the directory /opt/nouveau in the rootfs.

from linux-on-pixel-c.

Related Issues (11)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.