LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware
User Name
Password
Slackware This Forum is for the discussion of Slackware Linux.

Notices


Reply
  Search this Thread
Old 09-01-2020, 10:13 PM   #1
ernie young
Member
 
Registered: Feb 2016
Distribution: Slackware -current x64 Multilib
Posts: 101

Rep: Reputation: Disabled
Vulkaninfo amdgpu on -current


Hello,

I ran vulkaninfo on both user & root and get the same error:
Code:
vulkaninfo
ERROR: [Loader Message] Code 0 : /usr/lib/libvulkan_radeon.so: wrong ELF class: ELFCLASS32
ERROR: [Loader Message] Code 0 : /usr/lib/libvulkan_intel.so: wrong ELF class: ELFCLASS32
ERROR at /tmp/Vulkan-Tools-sdk-1.2.141.0/vulkaninfo/vulkaninfo.h:240:vkEnumerateInstanceExtensionProperties failed with ERROR_INITIALIZATION_FAILED
I have looked at other information of people going through the same thing but I feel that I am missing something subtle. I tried appending
Quote:
radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1
to my elilo.conf but it disappears after rebooting (I had a generic kernel but it was erased when I ran eliloconfig previously; will work on this after I resolve this issue). I noticed that from /var/log/Xorg.0.log there's no amdgpu.

In addition, I tried setting up /modprod./amdgpu.conf (quote above) &
Code:
echo "blacklist radeon" > /etc/modprobe.d/blacklist.radeon.conf
from these websites respectively:
https://www.linuxquestions.org/quest...pu-4175639096/
https://www.linuxquestions.org/quest...el-4175543839/

Thank you in advance for any help provided.
 
Old 09-01-2020, 11:22 PM   #2
Fat_Elvis
Member
 
Registered: Oct 2016
Distribution: FreeDOS 1.2
Posts: 309

Rep: Reputation: 92
Curiously, my "vulkaninfo" produces the same two errors, but not the third, followed by the full output, starting with: Vulkan Instance Version 1.2.141.

While I am not well versed in Vulkan, It seems that you are running on the radeon driver.

My /etc/X11/xorg.conf has this right now:
Code:
Section "Device"                                                               
        Identifier      "AMD"                                                  
        Driver          "amdgpu"                                               
        Option          "DRI3" "true"                                          
        Option          "TearFree" "true"                                      
        Option          "scaling mode" "Full aspect"                           
        Option          "DeleteUnusedDP12Displays" "true"                      
EndSection
/var/log/Xorg.0.log has this:

Code:
[ 29872.000] (II) LoadModule: "amdgpu"                                         
[ 29872.000] (II) Loading /usr/lib64/xorg/modules/drivers/amdgpu_drv.so        
[ 29872.001] (II) Module amdgpu: vendor="X.Org Foundation"
Try this:
Code:
glxgears -info | head -n5
What does the output say? You may be using a device not supported by the amdgpu driver.

I personally have nothing appended to my kernel parameters, and it works as it should with a fairly recent card.

EDIT: Oh, also, I see that you are running -current, but to other users with a similar problem: if your AMD graphics card is very recent, Slackware 14.2 does not have the most recent X11/Mesa/DRM software to support it, even if you use the most recent kernel. In that case, you will need to switch to the -current branch.

Last edited by Fat_Elvis; 09-01-2020 at 11:46 PM.
 
Old 09-02-2020, 03:40 AM   #3
giomat
Member
 
Registered: Jul 2017
Posts: 338

Rep: Reputation: 238Reputation: 238Reputation: 238
Quote:
Originally Posted by ernie young View Post
... I tried appending to my elilo.conf but it disappears after rebooting (I had a generic kernel but it was erased when I ran eliloconfig previously; will work on this after I resolve this issue). I noticed that from /var/log/Xorg.0.log there's no amdgpu...
I think here is your problem, i never had issues with vulkan on my hd7870, appending the parameters that you listed to the boot config was enough, but I'm using normal lilo with the huge kernel.
What is your GPU by the way?
 
Old 09-02-2020, 04:59 AM   #4
Fat_Elvis
Member
 
Registered: Oct 2016
Distribution: FreeDOS 1.2
Posts: 309

Rep: Reputation: 92
Quote:
Originally Posted by giomat View Post
I think here is your problem, i never had issues with vulkan on my hd7870, appending the parameters that you listed to the boot config was enough, but I'm using normal lilo with the huge kernel.
What is your GPU by the way?

Are you certain your GPU is supported by the amdgpu driver?
 
Old 09-02-2020, 06:59 PM   #5
ernie young
Member
 
Registered: Feb 2016
Distribution: Slackware -current x64 Multilib
Posts: 101

Original Poster
Rep: Reputation: Disabled
Fat_Elvis & giomat, thank you for the help. So I get home from work and I powered up my computer and long an behold, my vulkan is working. Not sure why but my new system has been acting with a lot of glitches since I installed it a few days ago. (I had a partition gone wrong and took the courage to go from 14.2 to -current.)

Code:
$ glxgears -info | head -n5
Running synchronized to the vertical refresh.  The framerate should be
approximately the same as the monitor refresh rate.
GL_RENDERER   = AMD Radeon HD 7800 Series (PITCAIRN, DRM 3.35.0, 5.4.60, LLVM 10.0.1)
GL_VERSION    = 4.6 (Compatibility Profile) Mesa 20.1.6
GL_VENDOR     = X.Org
It's the same card as yours giomat: HD 7870

Since I don't have it in the bootloader, it got it from /etc/modprod.d/. We'll see how it plays going forward.

Last edited by ernie young; 09-02-2020 at 09:24 PM.
 
Old 09-02-2020, 08:35 PM   #6
walecha
Member
 
Registered: Jan 2010
Location: Malang, +62
Distribution: slackware
Posts: 174

Rep: Reputation: 42
If this GPU is not the primary GPU or this GPU is the primary GPU but you don't need to see some kernel early printk or you are ok with 1 or 2 seconds of blank screen until the primary GPU framebuffer, then adding these line into /etc/modprobe/gpu.conf is sufficient to use amdgpu driver instead of radeon driver:

Code:
$ echo 'options radeon cik_support=0 si_support=0' | sudo tee -a /etc/modprobe/gpu.conf
$ echo 'options amdgpu cik_support=1 si_support=1 dc=1' | sudo tee -a /etc/modprobe/gpu.conf
When udev is started, the first line will disable support for CIK and SI models in radeon driver and then second line will enable support for CIK and SI models in amdgpu driver and using it to control the GPU.

If this GPU is the primary GPU and you want to see some kernel printk just after bootloader boots the kernel until GPU framebuffer takes over, then you have to include amdgpu driver into your initrd and add this line into your bootloader configuration:
Code:
radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1
The full configuration /etc/X11/Xorg.conf is not required anymore in the normal use of recent Xorg (maybe starting from version 1.19) or if you are using wayland because Xorg or wayland will use udev to initialize the required hardware and input/output events. You can add some configuration in /etc/X11/xorg.conf.d/tuning_or_quirk.conf for special tuning or some quirk for buggy hardware like this:

Code:
$ cat /etc/X11/xorg.conf.d/20-intel.conf 
Section "Device"
    BusID      "PCI:0:2:0"
    Identifier "Intel Graphics"
    ## Default using xf86-video-intel
    Driver     "intel"
    Option     "AccelMethod" "sna"
    Option     "TearFree"    "true"
    Option     "SwapbuffersWait"  "true"
    Option     "ZaphodHeads" "VGA1,HDMI1,DP1"
    Option     "Backlight" "intel_backlight"
    ## Use xf86-video-modesetting
    #Driver     "modesetting"
    #Option     "AccelMethod" "glamor"
    ## global options
    Option     "DRI" "3"
EndSection
 
Old 09-02-2020, 11:23 PM   #7
orbea
Senior Member
 
Registered: Feb 2015
Distribution: Slackware64-current
Posts: 1,950

Rep: Reputation: Disabled
Is this 64-bit or 32-bit Slackware? Do you have multilib? I believe vulkaninfo uses the icd files in /usr/share/vulkan/icd.d. Here it loads 'radeon_icd.i686.json' first which shows a similar message and then produces the correct output with radeon_icd.x86_64.json. It will have the opposite behavior if I run /usr/bin/32/vulkaninfo instead.
 
Old 09-03-2020, 06:49 PM   #8
ernie young
Member
 
Registered: Feb 2016
Distribution: Slackware -current x64 Multilib
Posts: 101

Original Poster
Rep: Reputation: Disabled
@walecha, yes, the Radeon card is the main one, with also integrated graphics from my Intel processor.I have updated the modprod.d/gpu.conf file. As for the bootloader, that requires a bit more time and understanding on my part. Thank you for your help.

@orbea, good questions, forgot to mention x64 & multilib. Thank you again for your help.

If you see that I am missing gaps, please feel free to point them out.
 
Old 09-04-2020, 12:10 PM   #9
Fat_Elvis
Member
 
Registered: Oct 2016
Distribution: FreeDOS 1.2
Posts: 309

Rep: Reputation: 92
Quote:
Originally Posted by walecha View Post
The full configuration /etc/X11/Xorg.conf is not required anymore in the normal use of recent Xorg (maybe starting from version 1.19) or if you are using wayland because Xorg or wayland will use udev to initialize the required hardware and input/output events. You can add some configuration in /etc/X11/xorg.conf.d/tuning_or_quirk.conf for special tuning or some quirk for buggy hardware like this:
Yes, most common hardware works just fine without, but Xorg.conf is still very useful for tuning input devices, or driver options like the very useful "TearFree" present on "intel" and "amdgpu" drivers.

Thanks for the tip about the xorg.conf.d folder. I suppose this has the same effect as collating all options in one file.
 
Old 09-04-2020, 12:21 PM   #10
Fat_Elvis
Member
 
Registered: Oct 2016
Distribution: FreeDOS 1.2
Posts: 309

Rep: Reputation: 92
Quote:
Originally Posted by ernie young View Post
Code:
$ glxgears -info | head -n5
Running synchronized to the vertical refresh.  The framerate should be
approximately the same as the monitor refresh rate.
GL_RENDERER   = AMD Radeon HD 7800 Series (PITCAIRN, DRM 3.35.0, 5.4.60, LLVM 10.0.1)
GL_VERSION    = 4.6 (Compatibility Profile) Mesa 20.1.6
GL_VENDOR     = X.Org
I can't find the official amdgpu pages right now, as usual with most freedesktop.org projects, but the Gentoo wiki seems to list your PITCAIRN GPU as being supported by the driver. You also have sufficiently recent Mesa and DRM versions.

https://wiki.gentoo.org/wiki/AMDGPU

Quote:
Originally Posted by ernie young View Post
So I get home from work and I powered up my computer and long an behold, my vulkan is working.
Glad to hear that.

I have also had some problems (the video getting corrupted, and hanging completely in my case) sporadically since I have installed a new mainboard, and I am convinced this is a hardware/ROM issue. This is usually solved with a hard reboot. It only happens within minutes of a reboot, so it isn't a real problem, but I wonder if it happens to other AMD CPU and/or AMD GPU owners.

Last edited by Fat_Elvis; 09-04-2020 at 12:35 PM.
 
Old 10-04-2020, 06:43 PM   #11
ernie young
Member
 
Registered: Feb 2016
Distribution: Slackware -current x64 Multilib
Posts: 101

Original Poster
Rep: Reputation: Disabled
Talking

I have been playing with the part of walecha
Quote:
you have to include amdgpu driver into your initrd and add this line into your bootloader configuration:
Code:
radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1
however I don't know how to do this. For example, on the bootloader I have included it as follows:
Code:
append="radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1"
chooser=simple
delay=100
timeout=100
#
image = /boot/vmlinuz-generic-5.4.60  
 initrd = /boot/initrd_5.4.60.gz  
 root = /dev/sda2  
 label = 5.4.60  
 read-only

image=vmlinuz
        label=vmlinuz
        initrd=initrd.gz
        read-only
        append="root=/dev/sda2 vga=normal ro"
Furthermore, how do I update elilo because when I use eliloconfig my generic block gets erased. Should I be using efibootmgr?

Also, how do I include amdgpu on my initrd?
Code:
# initrd created with 'mkinitrd -c -k 5.4.60 -f ext4 -r /dev/sda2 -m xhci-pci:ohci-pci:ehci-pci:xhci-hcd:uh 
ci-hcd:ehci-hcd:hid:usbhid:i2c-hid:hid_generic:hid-asus:hid-cherry:hid-logitech:hid-logitech-dj:hid-logitec 
h-hidpp:hid-lenovo:hid-microsoft:hid_multitouch:jbd2:mbcache:crc32c_intel:crc32c_generic:ext4 -u -o /boot/i 
nitrd.gz'
I have looked into different posts, Slackware guides and websites but I haven't really found these specifications. I am still learning to make the connections. Thank you in advance.

Bonus question : do I have to recompile VIM to have it copy from VIM to paste outside, like to LQ? :-) Pasting into VIM with Shift+Insert from outside, works.
 
Old 10-05-2020, 12:11 AM   #12
walecha
Member
 
Registered: Jan 2010
Location: Malang, +62
Distribution: slackware
Posts: 174

Rep: Reputation: 42
Quote:
Originally Posted by ernie young View Post
Furthermore, how do I update elilo because when I use eliloconfig my generic block gets erased. Should I be using efibootmgr?
EFI bootloader like elilo, grub, or refind does not need to be updated/reinit like lilo. Just edit/change the config file and it will using new boot configuration on the next boot.

Quote:
Originally Posted by ernie young View Post
Also, how do I include amdgpu on my initrd?
Code:
# initrd created with 'mkinitrd -c -k 5.4.60 -f ext4 -r /dev/sda2 -m xhci-pci:ohci-pci:ehci-pci:xhci-hcd:uh 
ci-hcd:ehci-hcd:hid:usbhid:i2c-hid:hid_generic:hid-asus:hid-cherry:hid-logitech:hid-logitech-dj:hid-logitec 
h-hidpp:hid-lenovo:hid-microsoft:hid_multitouch:jbd2:mbcache:crc32c_intel:crc32c_generic:ext4 -u -o /boot/i 
nitrd.gz'
Just add amdgpu in the modules list eg.
Code:
-m xhci-pci:ohci-pci:other-module:another-module:amdgpu
 
Old 10-05-2020, 02:48 PM   #13
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by ernie young View Post
Code:
append="radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1"
chooser=simple
delay=100
timeout=100
#
image = /boot/vmlinuz-generic-5.4.60  
 initrd = /boot/initrd_5.4.60.gz  
 root = /dev/sda2  
 label = 5.4.60  
 read-only

image=vmlinuz
        label=vmlinuz
        initrd=initrd.gz
        read-only
        append="root=/dev/sda2 vga=normal ro"
As far as I know, you can't stack appends with elilo (regular lilo supported a global "append" option and then an "addappend" option that could be in the individual stanzas). I also don't know if elilo supports a global append. You may need to add them for every stanza (which is what I do).

Also, with elilo, you need to have all kernels and initrds residing on the EFI partition (the easiest would be to have them located directly in the EFI/Slackware/ folder, which is where eliloconfig stores them). You would need to copy the 5.4.60 kernel and initrd from /boot to /boot/efi/EFI/Slackware and update the location in the stanza or elilo won't be able to boot them.

I would try an elilo.conf like the following:

Code:
chooser=simple
delay=100
timeout=100
#
image=vmlinuz-generic-5.4.60  
  initrd=initrd_5.4.60.gz  
  root=/dev/sda2  
  label=5.4.60
  append="append="radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1 vga=normal"
  read-only

image=vmlinuz
  label=vmlinuz
  initrd=initrd.gz
  read-only
  append="append="radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1 root=/dev/sda2 vga=normal"
Quote:
Originally Posted by ernie young View Post
Furthermore, how do I update elilo because when I use eliloconfig my generic block gets erased. Should I be using efibootmgr?
I'm not a fan of using eliloconfig for anything other than initial set up. It doesn't allow you to keep customizations in your elilo.conf. The nice thing with elilo (and other UEFI bootloaders) is once the efi stub is registered with your motherboard's firmware, you don't need to do anything other than updating the conf file. It doesn't require running anything after updating the conf (unlike lilo, which required you to run lilo to save everything). I just copy my kernel and initrd to the /boot/efi/EFI/Slackware folder and then update the elilo.conf to point to the new files.
 
Old 10-06-2020, 07:17 PM   #14
ernie young
Member
 
Registered: Feb 2016
Distribution: Slackware -current x64 Multilib
Posts: 101

Original Poster
Rep: Reputation: Disabled
Luckily, the huge kernel is working well and can load my OS, but my generic kernel loads an error of ninety nines (99). This is how I tweaked the new elilo.conf:
Code:
chooser=simple
delay=100
timeout=100

# generic kernel
image = /boot/vmlinuz-generic-5.4.60  
 initrd=initrd_5.4.60.gz  
 root=/dev/sda2  
 label=5.4.60  
 read-only
 append="radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1 resume=/dev/sdb2"

# huge kernel
image=vmlinuz
        label=vmlinuz
        initrd=initrd.gz
        read-only
        append="root=/dev/sda2 vga=normal ro"
I also commented out the two lines from /etc/modprod.d/gpu.conf unless I need them:
Code:
options radeon cik_support=0 si_support=0
options amdgpu cik_support=1 si_support=1 dc=1
I did add what walecha suggested to the mkinitrd. @Walecha, how did you come across this "other-module:another-module:amdgpu"? I looked for something to reference for the future but could not find this specific line on the net.

@bassmadrigal, I saw this as a typo on your comment, but would like to be sure:
Quote:
append="append=
Thank you walecha and bassmadrigal.

Last edited by ernie young; 10-06-2020 at 07:22 PM.
 
Old 10-06-2020, 08:12 PM   #15
bassmadrigal
LQ Guru
 
Registered: Nov 2003
Location: West Jordan, UT, USA
Distribution: Slackware
Posts: 8,792

Rep: Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656Reputation: 6656
Quote:
Originally Posted by ernie young View Post
Luckily, the huge kernel is working well and can load my OS, but my generic kernel loads an error of ninety nines (99). This is how I tweaked the new elilo.conf:
Code:
chooser=simple
delay=100
timeout=100

# generic kernel
image = /boot/vmlinuz-generic-5.4.60  
 initrd=initrd_5.4.60.gz  
 root=/dev/sda2  
 label=5.4.60  
 read-only
 append="radeon.si_support=0 radeon.cik_support=0 amdgpu.si_support=1 amdgpu.cik_support=1 amdgpu.dc=1 resume=/dev/sdb2"

# huge kernel
image=vmlinuz
        label=vmlinuz
        initrd=initrd.gz
        read-only
        append="root=/dev/sda2 vga=normal ro"
You need to move your generic kernel to /boot/efi/EFI/Slackware and change the elilo.conf to remove the /boot/ from the image line (make sure your initrd is in there as well).

Quote:
Originally Posted by ernie young View Post
@bassmadrigal, I saw this as a typo on your comment, but would like to be sure:
Yep, a typo. Good catch!
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Unable to run Vulkan in Slackware64-current with amdgpu ScrambledLogic Slackware 15 09-26-2018 12:32 PM
[SOLVED] Slackware-current: amdgpu abi error hj1967 Slackware 10 05-13-2018 02:26 AM
[Slackware64-current] newest kernel with better amdgpu support. drigohighlander Slackware 11 02-24-2018 10:03 AM
Slackware 14.2-current + AMDGPU-pro = unable to startx BattKajs Slackware 5 10-12-2017 11:43 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Distributions > Slackware

All times are GMT -5. The time now is 10:38 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration