Giter Site home page Giter Site logo

radeon-profile-daemon's Introduction

System daemon for reading info about Radeon GPU clocks and volts as well as control card power profiles so the GUI radeon-profile application can be run as normal user.

Supprts opensource xf86-video-ati and xf86-video-amdgpu drivers.

Dependencies

  1. qt5-base

Build

Type:

git clone https://github.com/marazmista/radeon-profile-daemon.git &&
cd radeon-profile-daemon/radeon-profile-daemon
qmake &&
make

systemd service

There is a service file for systemd in radeon-profile-daemon/extra. If installed manually, copy service file to /etc/systemd/system/. After that, execute systemctl enable radeon-profile-daemon.service and systemctl start radeon-profile-daemon.service to make the daemon running.

Links

radeon-profile-daemon's People

Contributors

bartwillems avatar danysan1 avatar gaming4lifede avatar marazmista avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

radeon-profile-daemon's Issues

OpenRC daemon ?

Hi,
It's possible to add a support for OpenRC for the daemon ?
I'm on Gentoo and i don't use Systemd.

Thanks

radeon-profile unable to fetch GPU memory data

Hello, first of all thanks for this great piece of work. This is truly a lifesaver.
At the moment I'm using the radeon-profile-daemon in conjunction with radeon-profile. I'm on Gentoo, and not using systemd (using openrc instead), so for now i'm just starting radeon-profile-daemon as the root user.

Almost everything seems to be working fine, apart from the GPU memory fetch. Also, when I just start radeon-profile as the root user (without the daemon) this error will not occur and everything works 100%. I personally have no idea what could be wrong, do you?

Below is the error it shows when starting radeon-profile in a terminal:

(The error just goes on forever with the same messages, I just pasted a part of it so you get an idea)

/dev/dri/renderD128: Permission denied
DRM_IOCTL_AMDGPU_INFO: Permission denied
Unable to lock the shared memory: "QSharedMemory::lock: unable to lock"
Unable to lock the shared memory: "QSharedMemory::lock: unable to lock"
DRM_IOCTL_AMDGPU_INFO: Permission denied
Unable to lock the shared memory: "QSharedMemory::lock: unable to lock"
DRM_IOCTL_AMDGPU_INFO: Permission denied
DRM_IOCTL_AMDGPU_INFO: Permission denied
nable to lock the shared memory: "QSharedMemory::lock: unable to lock"
DRM_IOCTL_AMDGPU_INFO: Permission denied
DRM_IOCTL_AMDGPU_INFO: Permission denied
Unable to lock the shared memory: "QSharedMemory::lock: unable to lock"
DRM_IOCTL_AMDGPU_INFO: Permission denied
DRM_IOCTL_AMDGPU_INFO: Permission denied
Unable to lock the shared memory: "QSharedMemory::lock: unable to lock"
DRM_IOCTL_AMDGPU_INFO: Permission denied

Needs license

Hi,

this project seems to have no COPYING/LICENSE file. It would be great to have one to make sure under which terms the software comes to people.

daemon failing to start

:~$ sudo service radeon-profile-daemon restart
:~$ sudo service radeon-profile-daemon status
โ— radeon-profile-daemon.service - radeon-profile daemon
   Loaded: loaded (/etc/systemd/system/radeon-profile-daemon.service; enabled; vendor preset: enabled)
   Active: failed (Result: exit-code) since Sat 2017-03-11 20:50:44 EST; 3s ago
  Process: 8335 ExecStop=/usr/bin/killall radeon-profile-daemon (code=exited, status=1/FAILURE)
  Process: 8333 ExecStart=/usr/bin/radeon-profile-daemon (code=exited, status=203/EXEC)
 Main PID: 8333 (code=exited, status=203/EXEC)

Mar 11 20:50:44 Ubuntu systemd[1]: Started radeon-profile daemon.
Mar 11 20:50:44 Ubuntu systemd[1]: radeon-profile-daemon.service: Main process exited, code=exited, status=203/EXEC
Mar 11 20:50:44 Ubuntu killall[8335]: radeon-profile-daemon: no process found
Mar 11 20:50:44 Ubuntu systemd[1]: radeon-profile-daemon.service: Control process exited, code=exited status=1
Mar 11 20:50:44 Ubuntu systemd[1]: radeon-profile-daemon.service: Unit entered failed state.
Mar 11 20:50:44 Ubuntu systemd[1]: radeon-profile-daemon.service: Failed with result 'exit-code'.

Fan profiles with daemon only

Hi and thanks for making this utility! I want to use my custom fan profile, write it once and never think about it again, just have radeon-profile-daemon running in the background.

However, it seems as, as soon as I quit the radeon-profile GUI the fan goes back to a fixed value (just like when the daemon is not running).

Am I making some stupid newbie mistake (forgot to check the right box), or is this not possible?

Support for Raven Ridge

Hello

Could you add support for Raven Ridge, please? Not much is usable in Radeon Profile on the Ryzen 2400G at the moment.

Screenshot 1
Screenshot 2

Daemon does not communicate with client

I can't pinpoint when it actually started having this issue, but I noticed the same problem discussed in the last messages in Phoronix thread: the client returns the "you need debugfs, root privileges or the daemon running" message, yet the socket is present in /tmp.

My system is Arch 4.11.5-2-ck-piledriver x86_64, using amdgpu with an R9 390
01:00.0 VGA compatible controller: Advanced Micro Devices, Inc. [AMD/ATI] Hawaii PRO [Radeon R9 290/390] (rev 80)

I built both client and daemon with debug enabled, this is daemon's output:

% sudo env QT_LOGGING_RULES=\*.debug=true ./radeon-profile-daemon                                                                          :(
Starting in debug mode
ok
Connecting to the client
Performing task:  "0#/sys/kernel/debug/dri/0/amdgpu_pm_info#4#1#"
Elaborating a CONFIG signal
The new clocks data path is  "/sys/kernel/debug/dri/0/amdgpu_pm_info"
"/sys/kernel/debug/dri/0/amdgpu_pm_info"  will be copied into  "/tmp/amdgpu_pm_info"
Elaborating a TIMER_ON signal
Setting up timer with seconds interval:  1
Shared memory is not attached, can't write data:  "QSharedMemory::handle:: key is empty"
Performing task:  "2#1#/sys/class/drm/card0/device/hwmon/hwmon0/pwm1_enable#2#142#/sys/class/drm/card0/device/hwmon/hwmon0/pwm1#"
Elaborating a SET_VALUE signal
"1"  will be written into  "/sys/class/drm/card0/device/hwmon/hwmon0/pwm1_enable"
Elaborating a SET_VALUE signal
"142"  will be written into  "/sys/class/drm/card0/device/hwmon/hwmon0/pwm1"
Shared memory is not attached, can't write data:  "QSharedMemory::handle:: key is empty"
Performing task:  "2#147#/sys/class/drm/card0/device/hwmon/hwmon0/pwm1#"
Elaborating a SET_VALUE signal
"147"  will be written into  "/sys/class/drm/card0/device/hwmon/hwmon0/pwm1"
Shared memory is not attached, can't write data:  "QSharedMemory::handle:: key is empty"
Performing task:  "2#145#/sys/class/drm/card0/device/hwmon/hwmon0/pwm1#"
Elaborating a SET_VALUE signal
"145"  will be written into  "/sys/class/drm/card0/device/hwmon/hwmon0/pwm1"
Shared memory is not attached, can't write data:  "QSharedMemory::handle:: key is empty"
Performing task:  "2#142#/sys/class/drm/card0/device/hwmon/hwmon0/pwm1#"
Elaborating a SET_VALUE signal
"142"  will be written into  "/sys/class/drm/card0/device/hwmon/hwmon0/pwm1"
Shared memory is not attached, can't write data:  "QSharedMemory::handle:: key is empty"

last line is repeated every second.

The client debug log is much more verbose, I attached it to the post.
debug-client.txt

The client started with root privileges works as expected.

Socket is world writable

The socket radeon-profile-daemon creates is:

  • Located in /tmp, while I would expect sockets of system services to be in /run
  • World-writable, while I would expect it to be restricted to e.g. the video group
$ sudo netstat -npl | grep radeon-profile
unix  2      [ ACC ]     STREAM     LISTENING     12415381 23656/radeon-profil  /tmp/radeon-profile-daemon-server
$ ls -l /tmp/radeon-profile-daemon-server
srwxr-xrwx 1 root root 0 Apr 23 20:43 /tmp/radeon-profile-daemon-server=

Error building

Can't build, make returns this error:

$ qmake-qt4 && make
g++ -m64 -Wl,-O1 -o radeon-profile-daemon main.o rpdthread.o moc_rpdthread.o    -L/usr/lib/x86_64-linux-gnu -lQtNetwork -lQtCore -lpthread 
main.o: In function `QString::~QString()':
main.cpp:(.text._ZN7QStringD2Ev[_ZN7QStringD5Ev]+0x17): undefined reference to `QArrayData::deallocate(QArrayData*, unsigned long, unsigned long)'
main.o: In function `rpdThread::~rpdThread()':
main.cpp:(.text._ZN9rpdThreadD2Ev[_ZN9rpdThreadD5Ev]+0x4a): undefined reference to `QArrayData::deallocate(QArrayData*, unsigned long, unsigned long)'
main.o: In function `rpdThread::~rpdThread()':
main.cpp:(.text._ZN9rpdThreadD0Ev[_ZN9rpdThreadD0Ev]+0x4a): undefined reference to `QArrayData::deallocate(QArrayData*, unsigned long, unsigned long)'
collect2: error: ld returned 1 exit status
make: *** [radeon-profile-daemon] Error 1

OS: Elementary OS 0.3
qt4-qmake version: 4:4.8.5+git192-g085f851+dfsg-2ubuntu4.1+elementary3~ubuntu0.3.1
make version: 3.81-8.2ubuntu3

Does multi-GPU support work?

I am unsure whether dual-GPU support works properly with my AMD Ryzen 2400G and AMD Radeon 560:

  • Temperature readings appear odd: The Radeon Profile shows the same temperature for the Radeon card as glances shows for my CPU die
  • I would expect the Ryzen to be the primary card, because that is where the monitor is connected to, but it is the Radeon that shows a VRAM utilisation of >30%
  • Under "Connectors", both cards claim to be connected using DisplayPort, which is only true for the Ryzen, but not for the Radeon
  • The supposed-to-be Ryzen claims a fan speed of >30%, but the Radeon claims to have no fan speed at all (empty field, not even 0%)

All of this makes me think whether the cards are swapped -- whether the data displayed for the "Ryzen" is actually that of the "Radeon" card.

daemon segfaults when the GUI (radeon-profile) is started

I'm trying to setup radeon-profile-daemon to be able to run the radeon-profile GUI without the need for superuser privileges.

I've built and installed it using the archlinux AUR pkgbuild, which checked out commit 4b3e757 and compiled without problems.

The radeon-profile tool is built and installed from AUR as well, using commit b6b50c45eca34e435dead42b0757a5f7cf301b2f.

The daemon starts successfully using systemctl start radeon-profile-daemon.service but as soon as I start the GUI with normal user privileges, the daemon just segfaults.

This is the output from journalctl -elu radeon-profile-daemon after a segfault:

Dec 28 15:55:25 utgard radeon-profile-daemon[472]: 0#/sys/kernel/debug/dri/0/radeon_pm_info#1
Dec 28 15:55:25 utgard systemd[1]: radeon-profile-daemon.service: Main process exited, code=dumped, status=11/SEGV
Dec 28 15:55:25 utgard killall[663]: radeon-profile-daemon: no process found
Dec 28 15:55:25 utgard systemd[1]: radeon-profile-daemon.service: Control process exited, code=exited status=1
Dec 28 15:55:25 utgard systemd[1]: radeon-profile-daemon.service: Unit entered failed state.
Dec 28 15:55:25 utgard systemd[1]: radeon-profile-daemon.service: Failed with result 'exit-code'.
Dec 28 15:55:25 utgard systemd-coredump[661]: Process 472 (radeon-profile-) of user 0 dumped core.

      Stack trace of thread 472:
      #0  0x00007f3d8f40421c _ZN7QString6appendERKS_ (libQt5Core.so.5)
      #1  0x0000000000403f3c n/a (radeon-profile-daemon)
      #2  0x0000000000404540 n/a (radeon-profile-daemon)
      #3  0x00007f3d8f58431a _ZN11QMetaObject8activateEP7QObjectiiPPv (libQt5Core.so.5)
      #4  0x00007f3d8f58431a _ZN11QMetaObject8activateEP7QObjectiiPPv (libQt5Core.so.5)
      #5  0x00007f3d8f8fb7ae n/a (/usr/lib/libQt5Network.so.5.5.1)
      #6  0x00007f3d8f9081a1 n/a (/usr/lib/libQt5Network.so.5.5.1)
      #7  0x00007f3d8f555b8c _ZN16QCoreApplication14notifyInternalEP7QObjectP6QEvent (libQt5Core.so.5)
      #8  0x00007f3d8f5aca1d n/a (libQt5Core.so.5)
      #9  0x00007f3d8cf2bdc7 g_main_context_dispatch (libglib-2.0.so.0)
      #10 0x00007f3d8cf2c020 n/a (libglib-2.0.so.0)
      #11 0x00007f3d8cf2c0cc g_main_context_iteration (libglib-2.0.so.0)
      #12 0x00007f3d8f5ac56b _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Core.so.5)
      #13 0x00007f3d8f55357a _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5)
      #14 0x00007f3d8f55b53c _ZN16QCoreApplication4execEv (libQt5Core.so.5)
      #15 0x0000000000402595 n/a (radeon-profile-daemon)
      #16 0x00007f3d8e9b3610 __libc_start_main (libc.so.6)
      #17 0x0000000000402699 n/a (radeon-profile-daemon)

      Stack trace of thread 473:
      #0  0x00007f3d8ea7318d poll (libc.so.6)
      #1  0x00007f3d8cf2bfbc n/a (libglib-2.0.so.0)
      #2  0x00007f3d8cf2c0cc g_main_context_iteration (libglib-2.0.so.0)
      #3  0x00007f3d8f5ac56b _ZN20QEventDispatcherGlib13processEventsE6QFlagsIN10QEventLoop17ProcessEventsFlagEE (libQt5Core.so.5)
      #4  0x00007f3d8f55357a _ZN10QEventLoop4execE6QFlagsINS_17ProcessEventsFlagEE (libQt5Core.so.5)
      #5  0x00007f3d8f36fbe4 _ZN7QThread4execEv (libQt5Core.so.5)
      #6  0x00007f3d8f374b8e n/a (libQt5Core.so.5)
      #7  0x00007f3d8e77d4a4 start_thread (libpthread.so.0)
      #8  0x00007f3d8ea7c13d __clone (libc.so.6)>`

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.