You are not logged in.

#1 2022-04-27 08:38:12

RounakDutta
Member
From: West Bengal, India
Registered: 2022-02-11
Posts: 173
Website

[SOLVED] What is DRM and How to enable KMS ?

I use GTX 1650 as my graphics card and I play games like gta 5 , apex legends etc etc. Today I was just reading the arch wiki and I read the DRM subtopic . So I want to know what is drm and does drm improves the perfomance of the game I am running? Do I really need drm?

Last edited by RounakDutta (2022-05-07 09:29:01)

Offline

#2 2022-04-27 12:23:48

Slithery
Administrator
From: Norfolk, UK
Registered: 2013-12-01
Posts: 5,776

Re: [SOLVED] What is DRM and How to enable KMS ?


No, it didn't "fix" anything. It just shifted the brokeness one space to the right. - jasonwryan
Closing -- for deletion; Banning -- for muppetry. - jasonwryan

aur - dotfiles

Offline

#3 2022-04-27 12:27:12

Lone_Wolf
Forum Moderator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 11,952

Re: [SOLVED] What is DRM and How to enable KMS ?

Direct Rendering Manager and Kernel Mode Setting are an essential part of the linux graphics stack, without them graphics options vary from very limited to no graphic environment at all.

Edit: slithery' link is useful , here are two more
https://www.reddit.com/r/archlinux/comm … m/djsc8at/
https://en.wikipedia.org/wiki/Direct_Rendering_Manager

Last edited by Lone_Wolf (2022-04-27 12:28:17)


Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.


(A works at time B)  && (time C > time B ) ≠  (A works at time C)

Online

#4 2022-04-28 03:18:27

RounakDutta
Member
From: West Bengal, India
Registered: 2022-02-11
Posts: 173
Website

Re: [SOLVED] What is DRM and How to enable KMS ?

Lone_Wolf wrote:

Direct Rendering Manager and Kernel Mode Setting are an essential part of the linux graphics stack, without them graphics options vary from very limited to no graphic environment at all.

Edit: slithery' link is useful , here are two more
https://www.reddit.com/r/archlinux/comm … m/djsc8at/
https://en.wikipedia.org/wiki/Direct_Rendering_Manager

Umm I use two kernels ( linux-zen and linux) so I edited my /etc/default/grub file to

 GRUB_CMDLINE_LINUX_DEFAULT="loglevel=3 quiet nvidia-drm.modeset=1"

This will enable drm but do I need pacman hook and add modules to /etc/mkinitcpio?
So I edited the Pacman hook (/etc/pacman.d/hooks/nvidia.hook) -

[Trigger]
Operation=Install
Operation=Upgrade
Operation=Remove
Type=Package
Target=nvidia nvidia-dkms
Target=linux linux-zen
# Change the linux part above and in the Exec line if a different kernel is used

[Action]
Description=Update Nvidia module in initcpio
Depends=mkinitcpio
When=PostTransaction
NeedsTargets
Exec=/bin/sh -c 'while read -r trg; do case $trg in linux && linux-zen) exit 0; esac; done; /usr/bin/mkinitcpio -P'

Did I set the pacman hook correctly ? Or did I do some thing wrong?
I also need to add module in /etc/mkinitcpio.conf

 MODULES=(nvidia, nvidia_modeset, nvidia_uvm and nvidia_drm)

?

Last edited by RounakDutta (2022-04-28 03:28:11)

Offline

#5 2022-04-28 06:28:49

seth
Member
Registered: 2012-09-03
Posts: 51,560

Re: [SOLVED] What is DRM and How to enable KMS ?

I also need to add module in /etc/mkinitcpio.conf

MODULES=(nvidia, nvidia_modeset, nvidia_uvm and nvidia_drm)

LITERALLY??
The list is space separated… don't copy and paste random strings from the wiki.

Did I set the pacman hook correctly ?

No. Where did you find this nonsense?

Target=foo
Target=bar

NOT

Target=foo bar

and "case $trg in linux && linux-zen)" isn't valid shell syntax at all - the example in the wiki exits the script when it reads "linux".
Do you think that's supposed to be the second or the last matching target?
(Hint: there's a related note in the wiki below the example you used as base)

Also, htf does any of that relate to the general inquiry of what DRM is, ie. the topic of this thread?

Offline

#6 2022-04-28 07:46:59

RounakDutta
Member
From: West Bengal, India
Registered: 2022-02-11
Posts: 173
Website

Re: [SOLVED] What is DRM and How to enable KMS ?

seth wrote:

LITERALLY??
The list is space separated… don't copy and paste random strings from the wiki.

ok so I am keeping the HOOKS() empty because in archwiki it is written that it is optional and just adding the kernel parameter should suffice.

seth wrote:

No. Where did you find this nonsense?

Target=foo
Target=bar

NOT

Target=foo bar

Oh sorry I changed it. To keep things simple I uninstalled linux kernel (I am using linux-zen) because I dont really need it. I installed nvidia-dkms drivers -

 [rounak@archissexy ~]$ cat /etc/pacman.d/hooks/nvidia.hook
[Trigger]
Operation=Install
Operation=Upgrade
Operation=Remove
Type=Package
Target=nvidia-dkms
Target=linux-zen
# Change the linux part above and in the Exec line if a different kernel is used

[Action]
Description=Update Nvidia module in initcpio
Depends=mkinitcpio
When=PostTransaction
NeedsTargets
Exec=/bin/sh -c 'while read -r trg; do case $trg in linux-zen) exit 0; esac; done; /usr/bin/mkinitcpio -P'
[rounak@archissexy ~]$ 
seth wrote:

Also, htf does any of that relate to the general inquiry of what DRM is, ie. the topic of this thread?

Actually I wanted to know about drm and I wanted to know whether I need it or not. So now that I need drm (so that I can play games) . I changed the title of the topic (I forgot to edit the title of of topic. )

seth wrote:

and "case $trg in linux && linux-zen)" isn't valid shell syntax at all - the example in the wiki exits the script when it reads "linux".
Do you think that's supposed to be the second or the last matching target?
(Hint: there's a related note in the wiki below the example you used as base)

oh lol - http://0x0.st/oT7r.png

Last edited by RounakDutta (2022-04-28 07:58:40)

Offline

#7 2022-04-28 07:58:09

Raynman
Member
Registered: 2011-10-22
Posts: 1,539

Re: [SOLVED] What is DRM and How to enable KMS ?

You somehow focus too much on DRM in the secion "DRM kernel mode setting". KMS is part of DRM, but that section specifically addresses KMS, as does you thread, so you should replace DRM in the title with KMS.

Last edited by Raynman (2022-04-28 08:27:52)

Offline

#8 2022-04-28 08:13:19

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 21,754

Re: [SOLVED] What is DRM and How to enable KMS ?

And to help with the underlying reasoning for why you're even attempting this, KMS is unlikely to give you more FPS just on it's own. What it does do however is allow more seamless VT switches and enable Wayland support if you think to try and use it. None of those are going to inherently give you any more noticeable performance so if that is what you are looking for then just setting this won't help

Offline

#9 2022-05-07 09:28:50

RounakDutta
Member
From: West Bengal, India
Registered: 2022-02-11
Posts: 173
Website

Re: [SOLVED] What is DRM and How to enable KMS ?

Sorry for the late reply. I was busy. It took me a while to understand what drm and kms does. I went to several articles. The arcticles mentioned by @Slithery and @Lone_Wolf made it easier for me to understand what drm actually does. I understood that I don't really need drm but still I enabled it (if I need it in the future ¯\_(ツ)_/¯ ). Marking the post as [SOLVED]

Last edited by RounakDutta (2022-05-07 09:41:36)

Offline

Board footer

Powered by FluxBB