- 14 Jan, 2014 2 commits
-
-
Randy Dunlap authored
Fix build error: qxl uses crc32 functions so it needs to select CRC32. Also use angle quotes around a kernel header file name. drivers/built-in.o: In function `qxl_display_read_client_monitors_config': (.text+0x19d754): undefined reference to `crc32_le' Signed-off-by:
Randy Dunlap <rdunlap@infradead.org> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Rashika authored
Mark function qxl_device_init() as static in drm/qxl/qxl_kms.c because it is not used outside this file. This eliminates the following warning in drm/qxl/qxl_kms.c: drivers/gpu/drm/qxl/qxl_kms.c:118:5: warning: no previous prototype for ‘qxl_device_init’ [-Wmissing-prototypes] Signed-off-by:
Rashika Kheria <rashika.kheria@gmail.com> Reviewed-by:
Josh Triplett <josh@joshtriplett.org> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 18 Dec, 2013 3 commits
-
-
Daniel Vetter authored
Less yelling ftw! Signed-off-by:
Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Daniel Vetter authored
I've killed them a long time ago in drm/i915, let's get rid of this remnant of shared drm core days for good. Signed-off-by:
Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Ville Syrjälä authored
Not all drivers will need take all the modeset locks for dirtyfb, so push the locking down to the drivers. Signed-off-by:
Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by:
Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by:
Jakob Bornecrantz <jakob@vmware.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 28 Nov, 2013 1 commit
-
-
Dave Airlie authored
wow no idea how I got this far without seeing this, leaking the entries in the list makes kmalloc-64 slab grow. References: https://bugzilla.kernel.org/show_bug.cgi?id=65121 Cc: stable@vger.kernel.org Reported-by:
Matthew Stapleton <matthew4196@gmail.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 06 Nov, 2013 3 commits
-
-
Dave Airlie authored
So GNOME userspace has an issue with when it rescans for modes on hotplug events, if the monitor has no EDID it assumes that nothing has changed on EDID as with real hw we'd never have new modes without a new EDID, and they kind off rely on the behaviour now, however with virtual GPUs we would like to rescan the modes and get a new preferred mode on hotplug events to handle dynamic guest resizing (where you resize the host window and the guest resizes with it). This is a simple property we can make userspace watch for to trigger new behaviour based on it, and can be used to replaced EDID hacks in virtual drivers. Acked-by: Marc-André Lureau <marcandre.lureau@gmail.com> (on irc) Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Gerd Hoffmann authored
Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Gerd Hoffmann authored
qxl devices can have a 64bit surface bar, which is quite handy if you need a bit more surface memory. So try to use it if it is present. Note that this bar might be mapped above 4g. QEMU command line to check that out: qemu-system-x86_64 -m 4g \ -vga qxl -global qxl-vga.vram64_size_mb=512 \ $otheroptions Signed-off-by:
Gerd Hoffmann <kraxel@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 04 Nov, 2013 1 commit
-
-
Dave Airlie authored
If we are using deferred io due to plymouth or X.org fbdev driver we will oops in memcpy due to this pointless multiply here, removing it fixes fbdev to start and not oops. Cc: stable@vger.kernel.org Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 23 Oct, 2013 4 commits
-
-
Marc-André Lureau authored
To disable a monitor, a Spice client sends a monitor config with the monitor resolution to 0x0. However, before qxl_crtc_disable() is reached after the hotplug event, it can happen that another monitor is reconfigured, and qxl_send_monitors_config() is called with the old config, which will re-enable the monitor on the client. Reset config if monitor is found disconnected, during drm_helper_hpd_irq_event(). Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Marc-André Lureau authored
All hard-coded resolutions are passing this check. Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Marc-André Lureau authored
By default, 1024x768 is the preferred resolution. However, when a monitor config is given, it should be the only preferred resolution. Note that the monitor config resolution is passed to qxl_add_common_modes() to avoid adding a duplicate mode without the preferred resolution. That would discard the previous monitor config preferred bit. Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Marc-André Lureau authored
drm_helper_hpd_irq_event() only notifies when the connector status changed. However, Spice monitor config can change while the connector is connected, to support arbitrary resolution. Do an hotplug event if it wasn't done by drm_helper_hpd_irq_event(). Signed-off-by:
Marc-André Lureau <marcandre.lureau@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 11 Oct, 2013 1 commit
-
-
Daniel Vetter authored
For drivers which might want to disable fbdev legacy support. Select the new option in all drivers for now, so this shouldn't result in any change. Drivers need some work anyway to make fbdev support optional (if they have it implemented, that is), so the recommended way to expose this is by adding per-driver options. At least as long as most drivers don't support disabling the fbdev support. v2: Update for new drm drivers msm and rcar-du. Note that Rob's msm driver can already take advantage of this, which allows us to build msm without any fbdev depencies in the kernel! v3: Move the MODULE_* stuff from the fbdev helper file to drm_crtc_helper.c. Cc: David Herrmann <dh.herrmann@gmail.com> Cc: Rob Clark <robdclark@gmail.com> Reviewed-by:
Rob Clark <robdclark@gmail.com> Acked-by:
Dave Airlie <airlied@linux.ie> Reviewed-by:
Chon Ming Lee <chon.ming.lee@intel.com> Signed-off-by:
Daniel Vetter <daniel.vetter@ffwll.ch>
-
- 09 Oct, 2013 1 commit
-
-
David Herrmann authored
All drivers embed gem-objects into their own buffer objects. There is no reason to keep drm_gem_object_alloc(), gem->driver_private and ->gem_init_object() anymore. New drivers are highly encouraged to do the same. There is no benefit in allocating gem-objects separately. Cc: Dave Airlie <airlied@gmail.com> Cc: Alex Deucher <alexdeucher@gmail.com> Cc: Daniel Vetter <daniel@ffwll.ch> Cc: Jerome Glisse <jglisse@redhat.com> Cc: Rob Clark <robdclark@gmail.com> Cc: Inki Dae <inki.dae@samsung.com> Cc: Ben Skeggs <skeggsb@gmail.com> Cc: Patrik Jakobsson <patrik.r.jakobsson@gmail.com> Signed-off-by:
David Herrmann <dh.herrmann@gmail.com> Acked-by:
Alex Deucher <alexander.deucher@amd.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 27 Aug, 2013 1 commit
-
-
David Herrmann authored
GEM does already a good job in tracking access to gem buffers via handles and drm_vma access management. However, TTM drivers currently do not verify this during mmap(). TTM provides the verify_access() callback to test this. So fix all drivers to actually call into gem+vma to verify access instead of always returning 0. All drivers assume that user-space can only get access to TTM buffers via GEM handles. So whenever the verify_access() callback is called from ttm_bo_mmap(), the buffer must have a valid embedded gem object. This is true for all TTM+GEM drivers. But that's why this patch doesn't touch pure TTM drivers (ie, vmwgfx). v2: Switch to drm_vma_node_verify_access() to correctly return -EACCES if access was denied. Cc: Dave Airlie <airlied@redhat.com> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Ben Skeggs <bskeggs@redhat.com> Cc: Maarten Lankhorst <maarten.lankhorst@canonical.com> Cc: Jerome Glisse <jglisse@redhat.com> Signed-off-by:
David Herrmann <dh.herrmann@gmail.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 19 Aug, 2013 1 commit
-
-
Daniel Vetter authored
So I've stumbled over drm_fasync and wondered what it does. Digging that up is quite a story. First I've had to read up on what this does and ended up being rather bewildered why peopled loved signals so much back in the days that they've created SIGIO just for that ... Then I wondered how this ever works, and what that strange "No-op." comment right above it should mean. After all calling the core fasync helper is pretty obviously not a noop. After reading through the kernels FASYNC implementation I've noticed that signals are only sent out to the processes attached with FASYNC by calling kill_fasync. No merged drm driver has ever done that. After more digging I've found out that the only driver that ever used this is the so called GAMMA driver. I've frankly never heard of such a gpu brand ever before. Now FASYNC seems to not have been the only bad thing with that driver, since Dave Airlie removed it from the drm driver with prejudice: commit 1430163b4bbf7b00367ea1066c1c5fe85dbeefed Author: Dave Airlie <airlied@linux.ie> Date: Sun Aug 29 12:04:35 2004 +0000 Drop GAMMA DRM from a great height ... Long story short, the drm fasync support seems to be doing absolutely nothing. And the only user of it was never merged into the upstream kernel. And we don't need any fops->fasync callback since the fcntl implementation in the kernel already implements the noop case correctly. So stop this particular cargo-cult and rip it all out. v2: Kill drm_fasync assignments in rcar (newly added) and imx drivers (somehow I've missed that one in staging). Also drop the reference in the drm DocBook. ARM compile-fail reported by Rob Clark. v3: Move the removal of dev->buf_asnyc assignment in drm_setup to this patch here. v4: Actually git add ... tsk. Cc: Dave Airlie <airlied@linux.ie> Cc: Laurent Pinchart <laurent.pinchart@ideasonboard.com> Cc: Rob Clark <robdclark@gmail.com> Acked-by:
Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by:
Daniel Vetter <daniel.vetter@ffwll.ch> Reviewed-by:
David Herrmann <dh.herrmann@gmail.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 18 Aug, 2013 1 commit
-
-
David Herrmann authored
These two helpers are unused. Remove them. They rely on gem_obj->driver_private, which is set to NULL during setup. As this field isn't used by the driver, anymore, we can remove this assignment as well. Signed-off-by:
David Herrmann <dh.herrmann@gmail.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 07 Aug, 2013 1 commit
-
-
Rob Clark authored
Because, there is no reason for it not to be const. v1: original v2: fix compile break in vmwgfx, and couple related cleanups suggested by Ville Syrjälä Signed-off-by:
Rob Clark <robdclark@gmail.com> Reviewed-by:
Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by:
Alex Deucher <alexander.deucher@amd.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 06 Aug, 2013 1 commit
-
-
Daniel Vetter authored
All the gem based kms drivers really want the same function to destroy a dumb framebuffer backing storage object. So give it to them and roll it out in all drivers. This still leaves the option open for kms drivers which don't use GEM for backing storage, but it does decently simplify matters for gem drivers. Acked-by:
Inki Dae <inki.dae@samsung.com> Acked-by:
Laurent Pinchart <laurent.pinchart@ideasonboard.com> Cc: Intel Graphics Development <intel-gfx@lists.freedesktop.org> Cc: Ben Skeggs <skeggsb@gmail.com> Reviwed-by:
Rob Clark <robdclark@gmail.com> Cc: Alex Deucher <alexdeucher@gmail.com> Acked-by:
Patrik Jakobsson <patrik.r.jakobsson@gmail.com> Signed-off-by:
Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 25 Jul, 2013 1 commit
-
-
David Herrmann authored
Use the new vma-manager infrastructure. This doesn't change any implementation details as the vma-offset-manager is nearly copied 1-to-1 from TTM. The vm_lock is moved into the offset manager so we can drop it from TTM. During lookup, we use the vma locking helpers to take a reference to the found object. In all other scenarios, locking stays the same as before. We always guarantee that drm_vma_offset_remove() is called only during destruction. Hence, helpers like drm_vma_node_offset_addr() are always safe as long as the node has a valid offset. This also drops the addr_space_offset member as it is a copy of vm_start in vma_node objects. Use the accessor functions instead. v4: - remove vm_lock - use drm_vma_offset_lock_lookup() to protect lookup (instead of vm_lock) Cc: Dave Airlie <airlied@redhat.com> Cc: Ben Skeggs <bskeggs@redhat.com> Cc: Maarten Lankhorst <maarten.lankhorst@canonical.com> Cc: Martin Peres <martin.peres@labri.fr> Cc: Alex Deucher <alexander.deucher@amd.com> Cc: Thomas Hellstrom <thellstrom@vmware.com> Signed-off-by:
David Herrmann <dh.herrmann@gmail.com> Reviewed-by:
Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by:
Dave Airlie <airlied@gmail.com>
-
- 24 Jul, 2013 3 commits
-
-
Dave Airlie authored
The recent addition of lockdep support to reservations and their subsequent use by TTM showed up a number of potential problems with the way qxl was using TTM objects. a) it was allocating objects, and reserving them later without validating underneath the reservation, which meant in extreme conditions the objects could be evicted before the reservation ever used them. b) it was reserving objects straight after allocating them, but with no ability to back off should the reservations fail. It now allocates the necessary objects then does a complete reservation pass on them to avoid deadlocks. c) it had two lists per release tracking objects, unnecessary complicating the reservation process. This patch removes the dual object tracking, adds reservations ticket support to the release and fence object handling. It then ports the internal fb drawing code and the userspace facing ioctl to use the new interfaces properly, along with cleanup up the error ...
-
Dave Airlie authored
In order to fix an issue with reservations we need to create the releases as pre-pinned objects, this changes the placement interface and bo creation interface to allow creating pinned objects to save nested reservations later. This is just a stepping stone to main fix which follows to actually fix how qxl deals with reservations. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
Due to the nature of qxl hw we cannot queue operations while in an irq context, so we queue these operations as best we can until atomic allocations fail, and dequeue them later in a work queue. Daniel looked over the locking on the list and agrees it should be sufficent. The atomic allocs use no warn, as the last thing we want if we haven't memory to allocate space for a printk in an irq context is more printks. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 05 Jul, 2013 9 commits
-
-
Dave Airlie authored
This uses the helper to deal with hotplug so fbdev gets included. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
This adds suspend/resume and hibernate support for the KMS driver. it evicts all the objects, turns off the outputs, and waits for the hw to go idle, On resume, it resets the memslots, rings, monitors object and forces modeset. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
This just ports some APIs like radeon uses to provide hooks for s/r to call. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
This prepare the ring code for s/r additions, the release ring will need reinitialising. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
this splits out initing the hw memslots from the guest info, and creates an entrypoint for s/r to use. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
This splits the creation of the monitors config object out so we can re-use it across suspend/resume later. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
This just sets the qxl time on the drawables. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
This adds support for a default of 4 heads, with a command line parameter to change the default number. It also overhauls the modesetting code to handle this case properly, and send the correct things to the hardware at the right time. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Dave Airlie authored
qxl has a feature to allow the userspace driver do arbitrary resizes when the viewer resizes, this fixes it by removing unnecessary code from the kernel side. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 28 Jun, 2013 2 commits
-
-
Dave Airlie authored
Reported-by:
Mathieu Desnoyers <mathieu.desnoyers@efficios.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
Maarten Lankhorst authored
Now that the code is compatible in semantics, flip the switch. Use ww_mutex instead of the homegrown implementation. ww_mutex uses -EDEADLK to signal that the caller has to back off, and -EALREADY to indicate this buffer is already held by the caller. ttm used -EAGAIN and -EDEADLK for those, respectively. So some changes were needed to handle this correctly. Signed-off-by:
Maarten Lankhorst <maarten.lankhorst@canonical.com> Reviewed-by:
Jerome Glisse <jglisse@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 27 Jun, 2013 1 commit
-
-
Dave Airlie authored
This uses the cursor hotspot info from userspace and passes it to the qxl hw layer. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 17 Jun, 2013 1 commit
-
-
Ville Syrjälä authored
Many of the drivers didn't implement palette/gamma handling, but were forced to provide stubs for the hooks to avoid drm_fb_helper from oopsing. Now that the hooks are optional, we can eliminate all the stubs. Signed-off-by:
Ville Syrjälä <ville.syrjala@linux.intel.com> Reviewed-by:
Daniel Vetter <daniel.vetter@ffwll.ch> Signed-off-by:
Dave Airlie <airlied@gmail.com>
-
- 31 May, 2013 1 commit
-
-
Dave Airlie authored
Just the usual printk related warnings. Signed-off-by:
Dave Airlie <airlied@redhat.com>
-
- 28 May, 2013 1 commit
-
-
Andrew Jones authored
Signed-off-by:
Andrew Jones <drjones@redhat.com> Signed-off-by:
Dave Airlie <airlied@redhat.com>
-