Razer blade pro

Hello fellow spacemans,

I am blown away from this distro reallly awesome work ! love the kernel modules for the essentials !

I have a razer blade pro and it’s working pretty well (just some heating issues) and I would love to support the community and being able to control the heating of this awesome machine !

I am a software engineer during the day and I always been curious of how a kernel module really works at the moment I am using the https://github.com/rnd-ash/razer-laptop-control * but I guess that works only with certain types of kernels and for some reason its not starting at the startup even if I add it to the systemctl enable option)

As an enginner I learned that libraries continuously update and the code itself changes as well breaking a lot of dependent libraries so I guess that’s what happening here !

I would love to understand how the keyboard module or which keyboard module is installed by default since I am able to get the apple keyboard to work seamlessly too :smiley:

If anybody can shed some light on the topic so we can def improve performances on the razer

What does:

sudo systemctl status <insert module name>

Report?

× razerdaemon.service - Razer laptop control daemon
     Loaded: loaded (/etc/systemd/system/razerdaemon.service; enabled; >
     Active: failed (Result: exit-code) since Mon 2021-08-16 11:12:16 W>
    Process: 586 ExecStart=/usr/share/razercontrol/daemon (code=exited,>
   Main PID: 586 (code=exited, status=101)
        CPU: 2ms

aug 16 11:12:14 archblade systemd[1]: Started Razer laptop control daem>
aug 16 11:12:14 archblade daemon[586]: Waiting for sysfs to be ready
aug 16 11:12:15 archblade daemon[586]: Waiting for sysfs to be ready
aug 16 11:12:16 archblade daemon[586]: Sysfs ready! Starting daemon
aug 16 11:12:16 archblade daemon[586]: thread 'main' panicked at 'calle>
aug 16 11:12:16 archblade daemon[586]: note: run with `RUST_BACKTRACE=1>
aug 16 11:12:16 archblade systemd[1]: razerdaemon.service: Main process>
aug 16 11:12:16 archblade systemd[1]: razerdaemon.service: Failed with >
lines 1-15/15 (END)...skipping...
× razerdaemon.service - Razer laptop control daemon
     Loaded: loaded (/etc/systemd/system/razerdaemon.service; enabled; vendor preset: disabled)
     Active: failed (Result: exit-code) since Mon 2021-08-16 11:12:16 WEST; 6min ago
    Process: 586 ExecStart=/usr/share/razercontrol/daemon (code=exited, status=101)
   Main PID: 586 (code=exited, status=101)
        CPU: 2ms

aug 16 11:12:14 archblade systemd[1]: Started Razer laptop control daemon.
aug 16 11:12:14 archblade daemon[586]: Waiting for sysfs to be ready
aug 16 11:12:15 archblade daemon[586]: Waiting for sysfs to be ready
aug 16 11:12:16 archblade daemon[586]: Sysfs ready! Starting daemon
aug 16 11:12:16 archblade daemon[586]: thread 'main' panicked at 'called `Option::unwrap()` on a `None` value', src/driver_sysfs.rs:21:14
aug 16 11:12:16 archblade daemon[586]: note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
aug 16 11:12:16 archblade systemd[1]: razerdaemon.service: Main process exited, code=exited, status=101/n/a
aug 16 11:12:16 archblade systemd[1]: razerdaemon.service: Failed with result 'exit-code'.

Thanks for the tip I usually just restart it

after restarting it…

● razerdaemon.service - Razer laptop control daemon
     Loaded: loaded (/etc/systemd/system/razerdaemon.service; enabled; vendor preset: disabled)
     Active: active (running) since Mon 2021-08-16 11:40:36 WEST; 2s ago
   Main PID: 21571 (daemon)
      Tasks: 3 (limit: 19017)
     Memory: 360.0K
        CPU: 42ms
     CGroup: /system.slice/razerdaemon.service
             └─21571 /usr/share/razercontrol/daemon

aug 16 11:40:36 archblade systemd[1]: Started Razer laptop control daemon.
aug 16 11:40:36 archblade daemon[21571]: Sysfs ready! Starting daemon
aug 16 11:40:36 archblade daemon[21571]: Power source changed! Now BAT

But I am wondering if this solution really works since it\s still a third party tool

Looks like it needs some sort of start-up delay, perhaps put it in a script with a sleep and edit the service.

yeah totally. But I am a bit more interested of how maybe add it as a kernel module or even trying to manage it a bit better ?

Perhaps if you need to add a delay before the system is started, you could try editing the service and add something like:

[Service]
ExecStartPre=/bin/sleep n
.
.
.

Set n to appropriate number of seconds.

Check systemctl edit UNIT

You probably cannot, unless you have the skills to rewrite the existing binaries into kernel modules, I certainly haven’t.

https://www.thegeekstuff.com/2013/07/write-linux-kernel-module/

1 Like

I also installed tlp but it looks like the fan control is a bit of a harder problem that I thought… so the utility is just an interface for the kernel module uh anybody developed something like this before ?

It doesn’t look that bad maybe can even be done in RUST I heard a lot of tools are migrating :grin: