Commit Graph

18 Commits

Author SHA1 Message Date
Chris Wilson 6b3ce2e870 uxa: Enable reduced fence sizes for i915
Depends on libdrm 362457715faacd3101929e5f0d8ae250d0ad09df (for
HAS_RELAXED_FENCING define).

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-10-29 11:07:50 +01:00
Adam Jackson b066ddda31 intel: Listen for hotplug uevents (V3)
This connects the kernel uevent indicating monitor hotplugging to the
RandR notification events so that X applications can be notified
automatically when monitors are connected or disconnected.

This also adds a configuration option to disable hotplug events.

V2: missed a #ifdef HAVE_UDEV around some udev-specific declarations

V3: document Hotplug option in man page

Signed-off-by: Keith Packard <keithp@keithp.com>
2010-10-22 08:35:29 -07:00
Chris Wilson 15aab1ef98 Move EDID_COMPLETE_RAWDATA define to intel.h to avoid redifinition warning
The compiler was simply warning that we defined the name prior to
including the original definition, so reorder.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-10-13 09:51:57 +01:00
Chris Wilson 707901bf98 uxa: Re-enable acceleration.
A side-effect of discriminating offscreen based on the devPrivate.ptr
was that it broke uxa_finish_access and so after any fallback to s/w on
a Pixmap, it remained in software for the reminder of its life.

Introduce an explicit boolean to mark whether or not hardware
acceleration is enabled for a pixmap (with a GEM buffer).

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-10-06 12:17:14 +01:00
Chris Wilson 516d235c5b Split shadow handling routines to their own file.
This is about to get messy, so separate out the shadow from the normal
code.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-10-04 11:10:57 +01:00
Chris Wilson ae160d7fbf shadow: Simply modify the Screen pixmap header
This is a slightly less risky strategy than having to remember to update
all pointers to the old Screen pixmap.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-10 13:19:12 +01:00
Chris Wilson 2b96c18165 Enable a shadow buffer and disable GPU acceleration.
An attempt to workaround the incoherency in gen2 chipsets, we avoid
using dynamic reallocation as much as possible.

The first step is to disable allocation of pixmaps using GEM and simply
create them in system memory without a backing buffer object. This
forces all rendering to use S/W fallbacks.

The second step is to allocate a shadow front buffer and assign that to
the Screen pixmap. This ensure that the front buffer remains in the GTT
and pinned for scanout. The shadow buffer will be rendered to in the
normal fashion via the Screen pixmap, and be marked dirty. In the block
handler, the dirty shadow buffer is then blitted (using the GPU) over
the front buffer. This should completely avoid having to move pages
around in the GTT and avoid incurring the wrath of those early chipsets.
Secondly, performance should be reasonable as we avoid the ping-pong
caused by the small aperture and weak GPU forcing software fallbacks.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-09-08 13:33:37 +01:00
Chris Wilson 42312bbd8c Remove accel_pitch_alignment
This has to be 64 on all generations currently, so replace the variable
with a constant.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-08-22 09:54:18 +01:00
Chris Wilson c882f6a22a Move registration of vsync fd from pre-init to screen-init
Marty Jack reported an issue he found where the page-flipping handler
was being lost on server reset. This results in the swap completion
notification being lost, with the sporadic hang of full screen
applications like Compiz, flash and even glxgears!

Fixes:

  Bug 29584 - Server in compute loop
  https://bugs.freedesktop.org/show_bug.cgi?id=29584

There are also several possibly related bugs with similar symptoms, i.e.
OpenGL applications hanging on missed swap notifications.

Reported-by: Marty Jack <martyj19@comcast.net>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Keith Packard <keithp@keithp.com>
2010-08-18 10:21:22 +01:00
Chris Wilson fe7dee7fe1 Remove the final references to the drmmode prefix
In particular fix the compile regression for intel_do_pageflip().

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-08-01 14:15:09 +01:00
Chris Wilson db7cd7b9f0 Rename drmmode_display to intel_display
And fixup all the drmmode_* functions to have an intel prefix and
categorise those into intel_mode, intel_crtc, intel_output and
intel_property so that the functions are a little more self-descriptive
and, more importantly, are consistent.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-08-01 11:27:29 +01:00
Kristian Høgsberg fba6651a92 Drop use of GL types in the driver
Still used in i810 for building the glx visuals.
2010-07-27 12:59:53 -04:00
Chris Wilson 2267e5928b Workaround a broken container_of define in list.h 2010-07-13 10:36:34 +01:00
Chris Wilson b2e98227d1 Remove the duplicate drmmode prototypes.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-07-13 10:15:34 +01:00
Chris Wilson 5de1b74d64 modes: There may be more than one crtc and output... DESTROY THEM ALL!
In order to cleanup all CRTCs and outputs on shutdown, we need to keep a
list of the individual structures and iterate over that list on
shutdown.

Also, the output and crtcs are configured just once and not for each
screen generation so move the shutdown to the termination and not on
CloseScreen. Oops.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-07-13 10:09:38 +01:00
Chris Wilson 5ce3f536b7 drmmode: Destroy the output on shutdown
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-07-09 14:12:43 +01:00
Chris Wilson 6ff369cd26 drmmode: Destroy Crtc on screen shutdown
Should fix:

  Bug 26946 - CRTC cursor BO leak in 2D
  https://bugs.freedesktop.org/show_bug.cgi?id=26946

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-07-09 14:12:25 +01:00
Chris Wilson 5c663ce844 Rename common infrastructure to the intel namespace.
After splitting out the i810 driver into its own legacy directory, we
can identify the common routines not as i830 but as intel. This
clarifies the code which *is* i830 specific.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2010-06-25 13:18:01 +01:00