Skip to content

Is it possible to have two boot loader entries for two different GPU drivers?

Hello everyone,

I'd like to have an easy system allowing me to boot with two different GPU drivers: amdgpu and radeon.

My graphics card is the "AMD Radeon HD 7870 GHz Edition" which has GCN 1.0 and is therefore very barely supported by amdgpu. I've been using amdgpu for a few months now, with good results. However, there are a few applications (mostly games) that give me trouble with the newer drivers, but work with radeon.

Now, I'd like to keep using amdgpu for the majority of time and simply boot with the radeon drivers activated for the occasional gaming session.

Would it be possible to achieve this with for example GRUB? The relevant line in my /etc/default/grub config file looks like this: GRUB_CMDLINE_LINUX_DEFAULT="radeon.si_support=0 amdgpu.si_support=1.

Assuming I can have xf86-video-amdgpu and xf86-video-ati both installed at the same time and simply need to switch around these options when booting via GRUB, would it be possible to create two boot loader entries with only the one line being different every time I install a kernel update? If so, how?

Thanks for reading and have a nice weekend.

16 points6 comments
Open on Reddit
About this post
Posted
Archived
Score
16 · 100% up
Kind
Text
ID
e7tnui

Author

2
posts
0
comments
0
media
View profile

7 comments

I've got no idea how to do this with grub (the kernel line seems to be a default shared among all kernels?), but in systemd-boot this would be as simple as having two bootloader entry files, one per configuration.

7 points

I came here to say the same. systemd-boot is much simpler than grub. IMO.

3 points

You could add it directly to your grub.conf in /boot/grub,but that way you'd have to manually edit it after every update (because grub-mkinstall or whatever will overwrite it).

I also found this: https://computingforgeeks.com/how-to-manually-add-menu-entry-to-grub2-menu-on-arch-linux/ It looks like it will get auto-generated if you place a file in /etc/grub.d.

6 points

I can't help with how to tell Grub to tell the kernel to load a given module and not another, but I can offer this: The grub config file in /boot/grub/ is meant to be generated by the grub-mkconfig tool, and one may want to avoid handling it directly (you can, it's just extra work). Instead, look into the other (because of course there's another) grub config in /etc/default/grub. This file is meant to control how the other is generated.

2 points

That's is exactly what he's been tinkering around with. He basically wants to boot the same kernel,but with different parameters (for amdgpu vs Radeon,I had exactly the same just two days ago,but I didn't set up two boot options,I just decided to stick with amdgpu) if I understood it correctly. And the grub-mkinstall should respect the /etc/grub.d/ files,so that sounds like the way to go (and yes,manually editing the grub.conf is only a temporary solution as mentioned earlier).

2 points
unknown author

Deleted before we saved it.

1 points

Keyboard shortcuts

Move and act

jork
Next / previous post or comment
Enteroro
Open the post
f
Open the media viewer
s
Save
h
Hide (the toast has Undo)
Tab
Right after an action: the toast's Undo
x
Collapse the comment
v
Next layout: cards, compact, grid

Go to

/
Search
gthenh
Home
gthena
All
gthens
Subreddits
gthenl
Library
?
This list
Esc
Close a menu or this list

In the viewer

←or→
Previous / next file
↑or↓
Previous / next post
korj
Previous / next post
Space
Play / pause
m
Mute
z
Zoom
s
Save
o
Open the post (on its own page: back to it)
Esc
Close

Keys do nothing while you type in a box.