Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Nvidia driver screwed my KDE Plasma 5 desktop
View unanswered posts
View posts from last 24 hours
View posts from last 7 days

 
Reply to topic    Gentoo Forums Forum Index Desktop Environments
View previous topic :: View next topic  
Author Message
Latrina
n00b
n00b


Joined: 13 Aug 2017
Posts: 62
Location: Cambridge, UK

PostPosted: Mon Aug 13, 2018 10:26 am    Post subject: Nvidia driver screwed my KDE Plasma 5 desktop Reply with quote

Hello folks,

I have a ThinkPad W530 with a Optimus Hybrid GPU, that is an Intel HD4000 and a nvidia K1000M. Yesterday I decided to install the nvidia driver, which seems to be working, however it has messed up my Plasma Desktop.

So what I am getting is primarily awful tearing all over, and the Desktop bar is badly misshapen and it gets worse as I resize it, see here https://i.imgur.com/9tQDWsS.jpg .

I have tried rebuilding qtcore and mesa as someone else suggested, however it made no difference. I have also added vaulkan driver to mesa but no go. Not sure if that is needed to be enabled somewhere.

Sometimes I can temporarily address the tearing and desktop bar issues by playing around with the KDE Compositor options randomly. It takes me about half an hour of tries and it is totally random. It only last one session though.

This is my current configuration.

Code:

psammarco@ThinkPad ~ $ equery u mesa
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for media-libs/mesa-17.3.9:
 U I
 - - abi_x86_32           : 32-bit (x86) libraries
 - - bindist              : Disable patent-encumbered ARB_texture_float, EXT_texture_shared_exponent, and
                            EXT_packed_float extensions.
 + + classic              : Build drivers based on the classic architecture.
 - - d3d9                 : Enable Direct 3D9 API through Nine state tracker. Can be used together with patched
                            wine.
 - - debug                : Enable extra debug codepaths, like asserts and extra output. If you want to get
                            meaningful backtraces see
                            https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
 + + dri3                 : Enable DRI3 support.
 + + egl                  : Enable EGL support.
 + + gallium              : Build drivers based on Gallium3D, the new architecture for 3D graphics drivers.
 + + gbm                  : Enable the Graphics Buffer Manager for EGL on KMS.
 - - gles1                : Enable GLESv1 support.
 - - gles2                : Enable GLESv2 support.
 + + llvm                 : Enable LLVM backend for Gallium3D.
 + + nptl                 : Enable support for Native POSIX Threads Library, the new threading module (requires
                            linux-2.6 or better usually)
 - - opencl               : Enable the Clover Gallium OpenCL state tracker.
 - - openmax              : Enable OpenMAX video decode/encode acceleration for Gallium3D.
 - - osmesa               : Build the Mesa library for off-screen rendering.
 - - pax_kernel           : Enable if the user plans to run the package under a pax enabled hardened kernel
 - - pic                  : disable optimized assembly code that is not PIC friendly
 - - unwind               : Add support for stack trace unwinding and function name resolution
 + + vaapi                : Enable Video Acceleration API for hardware decoding
 - - valgrind             : Compile in valgrind memory hints
 + + vdpau                : Enable the VDPAU acceleration interface for the Gallium3D Video Layer.
 - - video_cards_i915     : VIDEO_CARDS setting to build driver for Intel i915 video cards
 + + video_cards_i965     : VIDEO_CARDS setting to build driver for Intel i965 video cards
 + + video_cards_intel    : VIDEO_CARDS setting to build driver for Intel video cards
 - - video_cards_nouveau  : VIDEO_CARDS setting to build reverse-engineered driver for nvidia cards
 - - video_cards_r100     : VIDEO_CARDS setting to build only r100 based chips code for radeon
 - - video_cards_r200     : VIDEO_CARDS setting to build only r200 based chips code for radeon
 - - video_cards_r300     : VIDEO_CARDS setting to build only r300, r400 and r500 based chips code for radeon
 - - video_cards_r600     : VIDEO_CARDS setting to build only r600, r700, Evergreen and Northern Islands based
                            chips code for radeon
 - - video_cards_radeon   : VIDEO_CARDS setting to build driver for ATI radeon video cards
 - - video_cards_radeonsi : VIDEO_CARDS setting to build only Southern Islands based chips code for radeon
 - - video_cards_virgl    : VIDEO_CARDS setting to build driver for virgil (virtual 3D GPU)
 - - video_cards_vmware   : VIDEO_CARDS setting to build driver for vmware video cards
 + + vulkan               : Enable Vulkan drivers
 + + wayland              : Enable support for dev-libs/wayland
 + + xa                   : Enable the XA (X Acceleration) API for Gallium3D.
 - - xvmc                 : Enable the XvMC acceleration interface for the Gallium3D Video Layer.
psammarco@ThinkPad ~ $


psammarco@ThinkPad ~ $ equery u nvidia-drivers
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for x11-drivers/nvidia-drivers-396.45:
 U I
 + + X           : Install the X.org driver, OpenGL libraries, XvMC libraries, and VDPAU libraries
 + + abi_x86_32  : 32-bit (x86) libraries
 + + acpi        : Add support for Advanced Configuration and Power Interface
 + + compat      : Install non-GLVND libGL for backwards compatibility
 + + driver      : Install the kernel driver module
 - - gtk3        : Install nvidia-settings with support for GTK+ 3
 + + kms         : Enable support for kernel mode setting (KMS)
 + + multilib    : On 64bit systems, if you want to be able to compile 32bit and 64bit binaries
 - - pax_kernel  : PaX patches from the PaX project
 - - static-libs : Build static versions of dynamic libraries as well
 + + tools       : Install additional tools such as nvidia-settings
 - - uvm         : Install the Unified Memory kernel module (nvidia-uvm) for sharing memory between CPU and GPU in
                   CUDA programs
 - - wayland     : Enable dev-libs/wayland backend
psammarco@ThinkPad ~ $

psammarco@ThinkPad ~ $ equery u  x11-base/xorg-server
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for x11-base/xorg-server-1.19.5-r2:
 U I
 - - debug       : Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful
                   backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
 - - dmx         : Build the Distributed Multiheaded X server
 - - doc         : Add extra documentation (API, Javadoc, etc). It is recommended to enable per package instead of
                   globally
 + + glamor      : Enable Glamor OpenGL 2D acceleration
 + + ipv6        : Add support for IP version 6
 - - kdrive      : Build the kdrive X servers
 - - libressl    : Use dev-libs/libressl instead of dev-libs/openssl when applicable (see also the ssl useflag)
 - - minimal     : Install a very minimal build (disables, for example, plugins, fonts, most drivers, non-critical
                   features)
 - - static-libs : Build static versions of dynamic libraries as well
 + + suid        : Enable setuid root program, with potential security risks
 - - systemd     : Enable use of systemd-specific libraries and features like socket activation or session tracking
 - - tslib       : Build with tslib support for touchscreen devices
 + + udev        : Enable virtual/udev integration (device discovery, power and storage device support, etc)
 - - unwind      : Enable libunwind usage for backtraces
 - - wayland     : Enable dev-libs/wayland backend
 - - xcsecurity  : Build Security extension
 - - xephyr      : Build the Xephyr server
 - - xnest       : Build the Xnest server
 + + xorg        : Build the Xorg X server (HIGHLY RECOMMENDED)
 - - xvfb        : Build the Xvfb server

psammarco@ThinkPad ~ $ equery u  x11-base/xorg-drivers
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for x11-base/xorg-drivers-1.19:
 U I
 - - input_devices_elographics : INPUT_DEVICES setting to build driver for elographics input devices
 + + input_devices_evdev       : INPUT_DEVICES setting to build driver for evdev input devices
 - - input_devices_joystick    : INPUT_DEVICES setting to build driver for joystick input devices
 + + input_devices_keyboard    : INPUT_DEVICES setting to build driver for keyboard input devices
 + + input_devices_libinput    : INPUT_DEVICES setting to build driver for libinput input devices
 - - input_devices_mouse       : INPUT_DEVICES setting to build driver for mouse input devices
 + + input_devices_synaptics   : INPUT_DEVICES setting to build driver for synaptics input devices
 - - input_devices_tslib       : INPUT_DEVICES setting to build driver for tslib input devices
 - - input_devices_vmmouse     : INPUT_DEVICES setting to build driver for vmmouse input devices
 - - input_devices_void        : INPUT_DEVICES setting to build driver for void/dummy input devices
 - - input_devices_wacom       : INPUT_DEVICES setting to build driver for wacom input devices
 - - video_cards_amdgpu        : VIDEO_CARDS setting to build driver for AMDGPU video cards
 - - video_cards_ast           : VIDEO_CARDS setting to build driver for ASpeedTech video cards
 - - video_cards_dummy         : VIDEO_CARDS setting to build driver for dummy video cards
 - - video_cards_fbdev         : VIDEO_CARDS setting to build driver for fbdev video cards
 - - video_cards_glint         : VIDEO_CARDS setting to build driver for glint video cards
 - - video_cards_i915          : VIDEO_CARDS setting to build driver for Intel i915 video cards
 + + video_cards_i965          : VIDEO_CARDS setting to build driver for Intel i965 video cards
 + + video_cards_intel         : VIDEO_CARDS setting to build driver for Intel video cards
 - - video_cards_mga           : VIDEO_CARDS setting to build driver for mga video cards
 - - video_cards_nouveau       : VIDEO_CARDS setting to build reverse-engineered driver for nvidia cards
 - - video_cards_nv            : VIDEO_CARDS setting to build driver for nv video cards
 + + video_cards_nvidia        : VIDEO_CARDS setting to build driver for nvidia video cards
 - - video_cards_qxl           : VIDEO_CARDS setting to build driver for qxl (QEMU virtual GPU)
 - - video_cards_r128          : VIDEO_CARDS setting to build driver for ATI r128 video cards
 - - video_cards_radeon        : VIDEO_CARDS setting to build driver for ATI radeon video cards
 - - video_cards_radeonsi      : VIDEO_CARDS setting to build only Southern Islands based chips code for radeon
 - - video_cards_siliconmotion : VIDEO_CARDS setting to build driver for siliconmotion video cards
 - - video_cards_vesa          : VIDEO_CARDS setting to build driver for vesa video cards
 - - video_cards_via           : VIDEO_CARDS setting to build driver for via video cards
 - - video_cards_virtualbox    : VIDEO_CARDS setting to build driver for virtualbox emulation
 - - video_cards_vmware        : VIDEO_CARDS setting to build driver for vmware video cards
psammarco@ThinkPad ~ $

psammarco@ThinkPad ~ $ equery u kde-plasma/plasma-desktop
[ Legend : U - final flag setting for installation]
[        : I - package is installed with flag     ]
[ Colors : set, unset                             ]
 * Found these USE flags for kde-plasma/plasma-desktop-5.12.5-r1:
 U I
 - - appstream        : Enable AppStream software metadata support
 - - debug            : Enable extra debug codepaths, like asserts and extra output. If you want to get meaningful
                        backtraces see https://wiki.gentoo.org/wiki/Project:Quality_Assurance/Backtraces
 + + fontconfig       : Support for configuring and customizing font access via media-libs/fontconfig
 + + handbook         : Enable handbooks generation for packages by KDE
 - - ibus             : Use ibus input method via app-i18n/ibus
 + + mouse            : Enable mouse KCM
 + + pulseaudio       : Add support for PulseAudio sound server
 - - scim             : Enable applets that use app-i18n/scim
 + + semantic-desktop : Cross-KDE support for semantic search and information retrieval
 - - test             : Workaround to pull in packages needed to run with FEATURES=test. Portage-2.1.2 handles this
                        internally, so don't set it in make.conf/package.use anymore
 + + touchpad         : Enable touchpad KCM
psammarco@ThinkPad ~ $


The Xorg configuration can be found here https://pastebin.com/CEK01gfy

Code:
psammarco@ThinkPad ~ $ sudo eselect opengl list
Available OpenGL implementations:
  [1]   nvidia *
  [2]   xorg-x11
psammarco@ThinkPad ~ $


I also added export __GL_YIELD="USLEEP to /etc/profile.d/tearfree_kde.sh but made no real difference. As I said, I tried OpenGL 2.0, 3.1 but no go. Xrandr seems to address the desktop bar issue, however it gives me all kind of different craziness. With the Intel driver it all works fine.

Any idea would be much appreciated. Thanks. :)
_________________
Enslaved by Systemd and all the linuxisms that come with it. :|
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1179

PostPosted: Mon Aug 13, 2018 11:14 am    Post subject: Reply with quote

Not sure it would help others maybe to diagnose better if perhaps you address how close to this wiki you followed:

https://wiki.gentoo.org/wiki/NVIDIA/Optimus

Including this section here about preparatory steps before launching into an X session

https://wiki.gentoo.org/wiki/NVIDIA/Optimus#Before_starting_X

Lastly, since you only mentioned KDE and Plasma, have you tested it with other smaller (tiny) window managers to see if the issue persists there? If not then a good place to start would probably be reinstalling kde including whatever meta packages that has.

I apologize in advance if the advice doesn't seem to help, but maybe there is some better way to figure out through the log faculties of what is causing the issue, but I am not that much an expert to know myself. I would be curious to see what happens if you switched to a different display manager only. Or else tried running a session-less window manager like i3 or awesome and see what happens there. These are just ideas.
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1179

PostPosted: Mon Aug 13, 2018 11:16 am    Post subject: Reply with quote

This too would appear pertinent, and not so sure if you had seen it.

https://wiki.gentoo.org/wiki/Lenovo_Thinkpad_W530

Have you gone through the BIOS to set your discrete graphics mode?
Back to top
View user's profile Send private message
Latrina
n00b
n00b


Joined: 13 Aug 2017
Posts: 62
Location: Cambridge, UK

PostPosted: Mon Aug 13, 2018 1:10 pm    Post subject: Reply with quote

LIsLinuxIsSogood wrote:
Not sure it would help others maybe to diagnose better if perhaps you address how close to this wiki you followed:

https://wiki.gentoo.org/wiki/NVIDIA/Optimus

Including this section here about preparatory steps before launching into an X session

https://wiki.gentoo.org/wiki/NVIDIA/Optimus#Before_starting_X

Lastly, since you only mentioned KDE and Plasma, have you tested it with other smaller (tiny) window managers to see if the issue persists there? If not then a good place to start would probably be reinstalling kde including whatever meta packages that has.

I apologize in advance if the advice doesn't seem to help, but maybe there is some better way to figure out through the log faculties of what is causing the issue, but I am not that much an expert to know myself. I would be curious to see what happens if you switched to a different display manager only. Or else tried running a session-less window manager like i3 or awesome and see what happens there. These are just ideas.


Unfortunately I have done all of that.
_________________
Enslaved by Systemd and all the linuxisms that come with it. :|
Back to top
View user's profile Send private message
Latrina
n00b
n00b


Joined: 13 Aug 2017
Posts: 62
Location: Cambridge, UK

PostPosted: Mon Aug 13, 2018 1:12 pm    Post subject: Reply with quote

LIsLinuxIsSogood wrote:
This too would appear pertinent, and not so sure if you had seen it.

https://wiki.gentoo.org/wiki/Lenovo_Thinkpad_W530

Have you gone through the BIOS to set your discrete graphics mode?


You can only use the Intel alone or you need to use the Optimus option. The discrete graphic alone wont make the system start as the Nvidia does need the Intel GPU to write/ reproduce frames to it.
_________________
Enslaved by Systemd and all the linuxisms that come with it. :|
Back to top
View user's profile Send private message
LIsLinuxIsSogood
Veteran
Veteran


Joined: 13 Feb 2016
Posts: 1179

PostPosted: Fri Aug 17, 2018 12:17 am    Post subject: Reply with quote

EDIT: Have you considered using Bumbelbee the project looks
So I'm actually not trying to suggest you have to limit your options, but have you considered just running the integrated graphics portion of the dual gpu that is the intel side of it since you said yourself that everything works with that?
What end purpose does it serve to have the nvidia stuff working? Unless you are gaming or something it may make little difference...do you catch my drift there??
Just trying to help..especially since it seems like the nvidia and nouveau driver are repsonsible for the issue in the first place I would also think this thread could be moved to Kernel/Hardware instead of DE...
Back to top
View user's profile Send private message
bandreabis
Advocate
Advocate


Joined: 18 Feb 2005
Posts: 2490
Location: イタリアのロディで

PostPosted: Wed Sep 05, 2018 1:32 pm    Post subject: Reply with quote

LIsLinuxIsSogood wrote:
EDIT: Have you considered using Bumbelbee the project looks
So I'm actually not trying to suggest you have to limit your options, but have you considered just running the integrated graphics portion of the dual gpu that is the intel side of it since you said yourself that everything works with that?
What end purpose does it serve to have the nvidia stuff working? Unless you are gaming or something it may make little difference...do you catch my drift there??
Just trying to help..especially since it seems like the nvidia and nouveau driver are repsonsible for the issue in the first place I would also think this thread could be moved to Kernel/Hardware instead of DE...


HDMI is why I tried and tried to have nvidia working on my pc
_________________
Il numero di post non fa di me un esperto! Anzi!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Desktop Environments All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum