marazmista / radeon-profile-daemon

Daemon for radeon-profile GUI
GNU General Public License v2.0
118 stars 23 forks source link

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

Closed foxxx0 closed 8 years ago

foxxx0 commented 8 years ago

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 4b3e75713813dbfbadd70868c9bacc7b29a19f8d 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)>`
marazmista commented 8 years ago

Thanks for report. Segfault was easy to fix, but I've run into some problems with fix that I need to sort out (no clocks read at all). This segfault happen, when you uncheck 'Refresh data without request' in configuration on on Daemon tab, and close radeon-profile with such config. Later there is no way back, because Daemon tab is disabled when daemon is not running (and it is not running because of this bug). As a workaround you can change option daemonAutoRefresh to true in radeon-profile config file in home directory (~/.radeon-profile-settings) and start everything again.

foxxx0 commented 8 years ago

Eventually I ended up dumping the BIOS of my card, editing the fan control curve there and re-flashed it onto the gpu. Working just fine as soon as the gpu leaves the "bios" state, then the fan speed is reduced to a minimum.

So right now I am using radeon-profile only for some monitoring and graphs without the need for the daemon. But thanks for the feedback, some others may like to see this fixed.

marazmista commented 8 years ago

Fixed here: 95bca5bcfb0f19f4e8807ea7c9873579e4eab4ef