Skip to content

Commit f64122c

Browse files
committed
drm: add new QXL driver. (v1.4)
QXL is a paravirtual graphics device used by the Spice virtual desktop interface. The drivers uses GEM and TTM to manage memory, the qxl hw fencing however is quite different than normal TTM expects, we have to keep track of a number of non-linear fence ids per bo that we need to have released by the hardware. The releases are freed from a workqueue that wakes up and processes the release ring. releases are suballocated from a BO, there are 3 release categories, drawables, surfaces and cursor cmds. The hw also has 3 rings for commands, cursor and release handling. The hardware also have a surface id tracking mechnaism and the driver encapsulates it completely inside the kernel, userspace never sees the actual hw surface ids. This requires a newer version of the QXL userspace driver, so shouldn't be enabled until that has been placed into your distro of choice. Authors: Dave Airlie, Alon Levy v1.1: fixup some issues in the ioctl interface with padding v1.2: add module device table v1.3: fix nomodeset, fbcon leak, dumb bo create, release ring irq, don't try flush release ring (broken hw), fix -modesetting. v1.4: fbcon cpu usage reduction + suitable accel flags. Signed-off-by: Alon Levy <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
1 parent afe6804 commit f64122c

25 files changed

+7260
-0
lines changed

drivers/gpu/drm/Kconfig

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -220,3 +220,5 @@ source "drivers/gpu/drm/tegra/Kconfig"
220220
source "drivers/gpu/drm/omapdrm/Kconfig"
221221

222222
source "drivers/gpu/drm/tilcdc/Kconfig"
223+
224+
source "drivers/gpu/drm/qxl/Kconfig"

drivers/gpu/drm/Makefile

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,4 +52,5 @@ obj-$(CONFIG_DRM_SHMOBILE) +=shmobile/
5252
obj-$(CONFIG_DRM_TEGRA) += tegra/
5353
obj-$(CONFIG_DRM_OMAP) += omapdrm/
5454
obj-$(CONFIG_DRM_TILCDC) += tilcdc/
55+
obj-$(CONFIG_DRM_QXL) += qxl/
5556
obj-y += i2c/

drivers/gpu/drm/qxl/Kconfig

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
config DRM_QXL
2+
tristate "QXL virtual GPU"
3+
depends on DRM && PCI
4+
select FB_SYS_FILLRECT
5+
select FB_SYS_COPYAREA
6+
select FB_SYS_IMAGEBLIT
7+
select DRM_KMS_HELPER
8+
select DRM_TTM
9+
help
10+
QXL virtual GPU for Spice virtualization desktop integration. Do not enable this driver unless your distro ships a corresponding X.org QXL driver that can handle kernel modesetting.

drivers/gpu/drm/qxl/Makefile

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
#
2+
# Makefile for the drm device driver. This driver provides support for the
3+
# Direct Rendering Infrastructure (DRI) in XFree86 4.1.0 and higher.
4+
5+
ccflags-y := -Iinclude/drm
6+
7+
qxl-y := qxl_drv.o qxl_kms.o qxl_display.o qxl_ttm.o qxl_fb.o qxl_object.o qxl_gem.o qxl_cmd.o qxl_image.o qxl_draw.o qxl_debugfs.o qxl_irq.o qxl_dumb.o qxl_ioctl.o qxl_fence.o qxl_release.o
8+
9+
obj-$(CONFIG_DRM_QXL)+= qxl.o

0 commit comments

Comments
 (0)