Commit Graph

4113 Commits

Author SHA1 Message Date
Chris Wilson 4a27dd287c uxa: Make the glamor/uxa transition more verbose
And so hopefully make it clearer. In the process we restore the flushing
behaviour for UXA back to before the glamor intervention.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-21 13:02:34 +00:00
Chris Wilson b0d64a9567 sna: Correct end-point adjustment for stippling PolySegment
Reported-by: Roman Jarosz <kedgedev@gmail.com>
Reported-by: da_fox@mad.scientist.com
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=43134
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-21 11:54:59 +00:00
Chris Wilson a5353a7c1d sna/gen4: Use the special composite rect emission for fill_one()
In order to workaround a bug in the shaders on gen4, we need to flush
the pipeline after every rectangle. The recently introduced fill-one
mechanism for gen4, missed this vital step triggering a random hang with
an otherwise sane batchbuffer (the missing flush is hard to spot!).

Fixes regression from 86f99379ee (sna/gen4: Add fill-one).

Reported-by: Albert Damen <albrt@gmx.net>
Reported-by: Fryderyk Dziarmagowski <fdziarmagowski@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=43083
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-21 10:58:17 +00:00
Chris Wilson 3b9479dc39 sna: Micro-optimise sna_push_pixels_solid_blt()
Unroll the byte reversal as we know the row length is word aligned.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-19 19:12:31 +00:00
Chris Wilson 297f7680cf sna: Avoid the NULL damage deref
Fixes x11perf -wdcircle100 -time 1 -repeat 1 -rop GXxor

Reported-by: Fryderyk Dziarmagowski <fdziarmagowski@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=43084
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-19 16:11:42 +00:00
Chris Wilson 4a86ec5ddb sna/gen7: Apply recent SNB tuning as applicable
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-19 08:34:59 +00:00
Chris Wilson fe944d61d5 sna/gen7: Correct shifts for surface state
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-19 08:34:59 +00:00
Chris Wilson 70042400fd sna/gen7: minor tidy of redundant defines
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-18 23:47:10 +00:00
Chris Wilson f938cd1599 glamor: Include glamor cflags and libs for atypical builds
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-17 13:43:37 +00:00
Zhigang Gong eb6148a36a uxa/glamor: Turn on glamor for fill spans and rects
This commit only enables two glamor functions for
uxa_fill_spans and uxa_poly_fill_rects.

Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-17 01:10:21 +00:00
Zhigang Gong fbabe60f48 glamor: Initial commit to introduce glamor acceleration.
Added one configuration option --enable-glamor to control
whether use glamor. Added one new file intel_glamor.c to
wrap glamor egl API for intel driver's usage.
This commit doesn't really change the driver's control path.
It just adds necessary files for glamor and change some
configuration.

Reviewed-by: Eugeni Dodonov <eugeni.dodonov@intel.com>
Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-17 01:10:21 +00:00
Zhigang Gong c4c2eb1fae uxa/glamor: Introduce additional access modes to wrap glamor acceleration
Integrate glamor acceleration into UXA framework. Add
necessary flushing at the following points:

1. Flush UXA batch buffer before call into glamor.
2. Flush GL operations after return from a glamor function.
3. The point we need to flush UXA batch buffer, we also
   need to flush GL operations, for example, in
   intel_flush_callback and couple of places in intel_display.c.

Signed-off-by: Zhigang Gong <zhigang.gong@linux.intel.com>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 23:57:57 +00:00
Chris Wilson ac7df2919b Revert "Disable adding normal RTF modes for an eDP"
This reverts commit 212fa98687.

The underlying register programming for eDP is now believed to be fixed
as of linux-3.1.

References: https://bugs.freedesktop.org/show_bug.cgi?id=38012
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=41070
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 23:29:39 +00:00
Chris Wilson 24ece4a87e configure: Version bump for 2.17.0 release
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 23:14:25 +00:00
Chris Wilson 14b3176962 NEWS: Release notes for 2.17.0
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 23:13:44 +00:00
Chris Wilson c259144e3f sna: The block handler is passed an indirect pointer to the timeval
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 22:15:39 +00:00
Chris Wilson bfd2bb4027 sna: Correct dependencies for DRI2
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 22:15:39 +00:00
Chris Wilson 3771387ad1 Compile out UXA if so desired
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 22:15:39 +00:00
Chris Wilson edbeab8c4e sna: Reduce and clarify dependencies
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 22:15:39 +00:00
Chris Wilson 78d4e99fc9 sna: And keep unity happy
Rewrite the DRI layer to avoid the various bugs and shortcomings of the
Xserver and interfacing with mesa.

Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=38732
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=39044
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-16 22:14:15 +00:00
Chris Wilson aac022cbb3 sna: Optimise single pixel transfers
Surprisingly frequent.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 19:49:29 +00:00
Chris Wilson 5647e2981d sna/damage: Always reduce damage for testing PIXMAN_REGION_OUT
Reported-by: Clemens Eisserer <linuxhippy@gmail.com>
References: https://bugs.freedesktop.org/show_bug.cgi?id=42414
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 14:13:10 +00:00
Chris Wilson 405b015fe2 sna: Be explicit in all sna_damage_contains_box() tests
Clarify the exact in/out/maybe expected result when testing.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 14:06:49 +00:00
Chris Wilson 5d23149647 sna: Remove redundant 'can_fill_spans()'
Spans are almost always accelerated now...

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 14:06:49 +00:00
Chris Wilson ae9de984ad sna: Convert non-FillSolid rectilinear lines to boxes
And render using the tiled/stippled rect routines instead.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 13:49:50 +00:00
Chris Wilson e861e816f5 sna: Convert non-FillSolid rectilinear segments to boxes
And render using the tiled/stippled rect routines instead.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 13:39:34 +00:00
Chris Wilson 6fc2928f57 sna: tidy assignment of composite damage
Make sure that the damage is always set, even if only to NULL, so that
we are safe if in future the operation state is not initially cleared.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 13:05:00 +00:00
Chris Wilson 99338ebe61 sna: Check whether damage can be reduced to all-damage on moving to GPU
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 12:13:58 +00:00
Chris Wilson 00d1c539e4 sna/damage: Add a little more verbosity to debugging
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 11:20:32 +00:00
Chris Wilson 60c0fc101a sna: Refactor some common code into the common destroy-gpu-bo function
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 11:16:20 +00:00
Chris Wilson 571457e9a4 sna: Be more thorough discarding fences for large objects
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 10:32:04 +00:00
Chris Wilson e33dfbe3c0 sna/damage: Verify that all-damage covers the entire pixmap after reduction
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 09:50:24 +00:00
Chris Wilson f033172d2f sna: Fix debug compilation
Reported-by: Clemens Eisserer <linuxhippy@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=42887
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 09:32:53 +00:00
Chris Wilson 0c405595fb sna: Downgrade tiling in order to fit within fence constraints
Fixes a later assert that the fenced size is valid for kgem_create_2d()

Reported-by: Clemens Eisserer <linuxhippy@gmail.com>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=42888
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 09:30:02 +00:00
Chris Wilson 1baff9f8cf uxa/gen4+: Re-emit composite invariant after video
Reported-by: Ben Hutchings <ben@decadent.org.uk>
Bugzilla: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=635953
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-14 08:48:40 +00:00
Chris Wilson 7ad3b377a3 sna/video: Use the right pointer for unmapping
Don't just deference any old random pointer, use the one we actually
mapped in the first place!

Reported-by: Matti Hamalainen <ccr@tnsp.org>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=42880
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-13 17:53:11 +00:00
Chris Wilson 8da8809d03 sna/video: Simplify check for 915G[M] which is simply gen==30
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-13 17:49:23 +00:00
Chris Wilson cac335b979 sna/video: Constify a couple of attribute arrays
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-13 13:13:03 +00:00
Chris Wilson e592eb93db configure: Version bump for 2.16.902 snapshot
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-13 11:16:45 +00:00
Chris Wilson 56707b97dc NEWS: Details for 2.16.902
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-13 11:16:12 +00:00
Chris Wilson f0acc6c0f1 sna/composite: Attempt to reduce the damage is the operation is contained
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-13 09:57:10 +00:00
Chris Wilson 87147b63e9 sna/damage: Reduce the damage for evaluating sna_damage_is_all
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-12 20:08:13 +00:00
Chris Wilson e8799cdea4 sna: Be stricter and disallow allocation of large fenced objects
When allocating objects, we need to check the size of the full fenced
regions against the mappable limits in order to be able to mmap the
object later.

References: https://bugs.freedesktop.org/show_bug.cgi?id=42813
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-12 12:19:31 +00:00
Chris Wilson 0269ec5533 sna: Handle incremental uploads from PutImage
PutImage rarely uploads the entire image inside a single request,
instead breaking up into scanline segments to fit within the protocol
limits. A few optimisations are based on detecting when we can discard
the GPU bo for an all-dirty CPU pixmap, which are useful in this case so
check for an entirely dirty pixmap following an incremental PutImage.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-12 11:54:52 +00:00
Chris Wilson ed68f1b00a sna/gen7: Fix PRIMITIVE command
The topology is now an extra dword rather than an embedded field in the
command.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-12 11:54:52 +00:00
Chris Wilson 991ffcb60a sna: Reset the source counter if we completely dirty the CPU pixmap
For a long lived pixmap which we are repeatedly using for upload and
copying to other pixmaps, we don't want to keep to maintain a GPU
buffer. So instead, reset the source counter if we discard the GPU bo
and treat the pixmap as purely CPU.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-11 23:22:35 +00:00
Chris Wilson 403a4dd353 sna: Defer source migration for a solitary upload via CopyArea
Try to avoid allocating a GPU pixmap for PutImage followed by CopyArea.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-11 23:19:33 +00:00
Chris Wilson 11acfaa623 sna/glyph: Tweak the small mask threshold
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-11 23:19:32 +00:00
Chris Wilson c6e6ae1829 sna/glyphs: Cache the glyph pixman_image_t wrapper
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-11 14:37:07 +00:00
Chris Wilson 8f50950f46 sna/gen7: Remove stray no-op from GEN7_3DSTATE_SBE
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2011-11-11 00:16:14 +00:00