1. Computers
  2. Display Drivers
  3. Graphics Cards
  4. Memory
  5. Motherboards
  6. Processors
  7. Software
  8. Storage
  9. Operating Systems


Facebook RSS Twitter Twitter Google Plus


Phoronix Test Suite

OpenBenchmarking.org

First Phase Of X.Org GPU Hot-Plugging Works

X.Org

Published on 22 October 2011 07:26 PM EDT
Written by Michael Larabel in X.Org
9 Comments

David Airlie has demonstrated success in the first phase of his X.Org GPU/driver hot-plugging work, which eventually may lead to proper dynamic GPU switching under X.

On David Airlie's blog he has written briefly about his X.Org hot-plug work that he's been doing on and off for the past year. He's also included a video (embedded at the end of this post) that demonstrates this video hot-plugging work.

What's going on is using the xf86-video-modesetting driver with his custom X.Org Server work and xterm and GNOME Metacity. When he plugs in a USB-based DisplayLink adapter that's using his custom Linux kernel DRM driver, the USB-driven display lights up and is functional.

What goes on is that his custom X.Org Server code is started up with the respective drivers and David's major X.Org video driver ABI re-work comes into play here. One X protocol screen is exported and then when the GPU hot-plug happens, the xorg-server initializes another screen for the new device and plugs it into the single protocol screen. The driver-level pixmaps/pictures/GCs are copied to the new driver. The single protocol screen is then multi-plexed across the plugged in driver screens. David explains it as being "like Xinerama pushed down a lot further in the stack, so instead of doing iterations at the protocol level, we do it down at the acceleration level. Also I have randr code hooked up so all the outputs appear no matter what GPU they are from."

This demonstration is from a DisplayLink USB adapter, which doesn't have 3D hardware acceleration abilities. What Airlie eventually wants to get to is getting the main GPU to do the rendering and then only send the scan-out buffer to the USB device. This rendering-on-one-GPU-and-send-to-another could also be used for multi-GPU desktop systems to offload rendering work for one intensive OpenGL application/game to a secondary GPU and then piping the contents back to the primary graphics processor, among other possibilities.

While good progress has been made, David has been dabbling with this code for a year and there's still much more work ahead before we might see the code merged into mainline and deployed. "The real solution is a still a long ways off, but this is just a small light in a long tunnel, I've been hacking on this on/off for over a year now, so its nice to see something visible for the first time."

In terms of dynamic GPU switching for multi-GPU setups (such as NVIDIA Optimus and other notebooks with dual graphics processors), David says in a comment on his blog that the KMS drivers would need to be modified to work with the new X.Org Server for switching and such. Sharing of more kernel-level objects via PRIME or dmabuf is also needed.


About The Author
Michael Larabel is the principal author of Phoronix.com and founded the web-site in 2004 with a focus on enriching the Linux hardware experience and being the largest web-site devoted to Linux hardware reviews, particularly for products relevant to Linux gamers and enthusiasts but also commonly reviewing servers/workstations and embedded Linux devices. Michael has written more than 10,000 articles covering the state of Linux hardware support, Linux performance, graphics hardware drivers, and other topics. Michael is also the lead developer of the Phoronix Test Suite, Phoromatic, and OpenBenchmarking.org automated testing software. He can be followed via and or contacted via .
Latest Linux Hardware Reviews
  1. MSI X99S SLI PLUS On Linux
  2. NVIDIA GeForce GTX 970 Offers Great Linux Performance
  3. CompuLab Intense-PC2: An Excellent, Fanless, Mini PC Powered By Intel's i7 Haswell
  4. From The Atom 330 To Haswell ULT: Intel Linux Performance Benchmarks
Latest Linux Articles
  1. Open-Source Radeon 2D Performance Is Better With Ubuntu 14.10
  2. RunAbove: A POWER8 Compute Cloud With Offerings Up To 176 Threads
  3. 6-Way Ubuntu 14.10 Linux Desktop Benchmarks
  4. Ubuntu 14.10 XMir System Compositor Benchmarks
Latest Linux News
  1. Dead Island GOTY Now Available On Linux/SteamOS
  2. Ubuntu 14.04 In The Power8 Cloud From RunAbove
  3. KDE With Theoretical Client-Side Decorations, Windows 10 Influence
  4. Sandusky Lee: Great Cabinets For Storing All Your Computer Gear
  5. Fedora 21 Beta & Final Release Slip Further
  6. Mesa 10.3.2 Has A Couple Bug-Fixes
  7. RadeonSI/R600g HyperZ Support Gets Turned Back On
  8. openSUSE Factory & Tumbleweed Are Merging
  9. More Fedora Delays: Fedora 21 Beta Slips
  10. Mono Brings C# To The Unreal Engine 4
Latest Forum Discussions
  1. Users/Developers Threatening Fork Of Debian GNU/Linux
  2. Updated and Optimized Ubuntu Free Graphics Drivers
  3. HOPE: The Ease Of Python With The Speed Of C++
  4. Use Ubuntu MATE 14.10 Make it an official distro.
  5. Debian Is Back To Discussing Init Systems, Freedom of Choice
  6. AMD Radeon VDPAU Video Performance With Gallium3D
  7. Ubuntu 16.04 Might Be The Distribution's Last 32-Bit Release
  8. Linux hacker compares Solaris kernel code: