summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2013-03-14sna: Add handle info to sync DBGChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-14sna: Use userptr downloads for incomplete GPU damaged pixmapsChris Wilson
If the pixmap is not wholly damaged, but still contains the region to be read, then use userptr (if available). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-14sna: Add a few more assertions to track userptr through the cachesChris Wilson
i.e. make sure they don't end up in any caches. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-13sna/trapezoids: Minimally replace points for TriFanChris Wilson
The realisation dawns that it wasn't the ordering of points within the triangle, but simply that I was replacing the wrong one.
2013-03-13sna/trapezoids: Correct ordering of points within TriFranChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12sna/gen4: Tweak compilation flags to avoid mixed settings across functionsChris Wilson
Confusing gcc with different flags for supposedly inlined functions is not a good idea. References: https://bugs.freedesktop.org/show_bug.cgi?id=62198 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12uxa: don't crash when freeing an uninitialized screenAaron Plattner
When intel_scrn_create creates a screen, it sets scrn->driverPrivate to (void *)(match_data | 1). Normally, this is read by I830PreInit and then replaced with a pointer to the intel_screen_private structure. However, it's possible for the server to delete the screen before initializing it, which leads to a crash in I830FreeScreen when it tries to interpret the unaligned match_data pointer as a pointer to a intel_screen_private. Fix this by checking the low bit of the pointer and skipping the teardown code if it's set. Signed-off-by: Aaron Plattner <aplattner@nvidia.com>
2013-03-12sna/gen3: Tweak code generation for gen3_emit_composite_primitive_constant__sse2Chris Wilson
References: https://bugs.freedesktop.org/show_bug.cgi?id=62198 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12sna/gen3: Tweak code generation for ↵Chris Wilson
gen3_emit_composite_primitive_identity_gradient__sse2 References: https://bugs.freedesktop.org/show_bug.cgi?id=62198 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12sna/gen3: Reduce another use of transformsChris Wilson
Prefer the slightly cheaper _sna_get_transformed_scaled(). Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12uxa/glamor: Prevent a crash when trying to load a misconfigured glamorChris Wilson
Glamor requires that glamoregl is explicitly loaded via Section "Module" or else it currently crashes. Based on a patch by Michel Dänzer for xf86-video-ati. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12sna: Missing git-add for 09862a85eba243bChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12sna: Improve asserts that the CPU bo is not busy after synchronisationChris Wilson
Taking into account that we may not do a full synchronisation. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12sna: Mark redirect proxies with a unique idChris Wilson
This helps gen3 in particular as it uses the unique_id field of a bo to detect changes in render target. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-12sna: Apply the source offset to the transform when fixing up gradientsChris Wilson
Otherwise pixman will apply the source transform to the offsets. Reported-by: Ognian Tenchev <drJeckyll@Jeckyll.net> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=62198 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-11sna: Improve sna_copy_boxes DBG by printing the bo handlesChris Wilson
The handles of the bo are easier to track through the DBG as they are more often printed than then their addresses. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-11sna: Only allocate addition space if we need pixel dataChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-11sna: Mark the userptr as a CPU mappingChris Wilson
This helps clarify some recent asserts. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-11sna/dri: Free the event on the impossible error pathChris Wilson
Just in case we end up with bogus data, don't leak. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-11sna/dri: Free chained swaps upon CloseWindowChris Wilson
The assumption that the chained swaps are freed after the next vblank turns out to be wrong, and in effect we would leak the bo if we happened to submit the final swap faster than vrefresh and close the window before the vblank. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-11sna/dri: Reorder assert to avoid NULL dereferenceChris Wilson
Only try to dereference chain->draw after the check to see if it was already destroyed. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-11sna: Tighten checking for coherent mapsChris Wilson
Remember all the special cases where we can use a CPU mmap as a temporary substitute for a GTT mapping. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-10sna: Tweak CPU mappings to be only used if a read is requiredChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-10sna/dri: Flatten _sna_dri_destroy_buffer()Chris Wilson
One level of indentation can be trivially removed with an earlier return. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-10sna/dri: Add a couple more basic assertionsChris Wilson
To catch bad reference counting and loss of flush. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-08sna: Only shrink the maximum GPU size to fit into cacheChris Wilson
That is be very careful that we do not enlarge it past the aperture size on early gen. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-08sna/gen4: Initialise a pair of unimportant variablesChris Wilson
Should never actually affect any results. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-07sna: Fallback if we cannot fit the tiling copy into the apertureChris Wilson
If we cannot fit the source/destination and a tile into the aperture, then we cannot perform the copy and must do it using the CPU. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-07sna: Trim tile sizes to fit aperture constraintsChris Wilson
This is especially important with gen2 where we have no unmappable GTT to utilise. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-07sna: Remove the unused output and crtc listsChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-07sna: Disambiguate sna_crtc_resize()Chris Wilson
sna_crtc_resize() operates upon the whole configuration rather than a single crtc like the other sna_crtc_* so rename it to make it distinct. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-07sna: Supply a fake pipe to run completely headlessChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-07sna: Return early if there are no outputs to setupChris Wilson
Instead of reporting failure, just try to run headless. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-07intel: Relax the has-kms test slightlyChris Wilson
Do not rely on a fully populated set of CRTCs, but merely note that the GETRESOURCES ioctl returns an error if KMS is not enabled. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-06sna: Disable read-read optimisationsChris Wilson
There is still a lurking issue, so punt on the optimisation for now. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=61628 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-06sna: Lighten the wakeup handler slightlyChris Wilson
As the wakeup handler is called more frequently, we want to avoid any of the more heavyweight processing. So trim the wakeup handler down to the check to see if the GPU is idle and so we should immediately flush what we have currently queued. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Typo ('unsuported') in DBG messagesChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Assert that the pixmap is not pinned before releasing the GPU boChris Wilson
Nothing suspicious in this set, just an extra dab of paranoia. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: The GPU bo submit is still required before mapping for inplace operationsChris Wilson
As we may choose to force the stall as we would be doing a read-back in any event... Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Use drawable_gc_flags() to select placement for PolyArcChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Fix deference of just nullified GPU bo in previous commitChris Wilson
One last minute refactor too far, combining the too if(priv->gpu_bo) blocks forgot that the first block tried to free gpu_bo... Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Refactor the is-mappable test for inplace operationsChris Wilson
By moving the test into the common function for creating a mappable GPU bo, we can also consider recreating that bo when desirable. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Prefer GPU for self-copies when undamaged on the CPUChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Be explicit when checking for an idle bo after CPU synchronisationChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-05sna: Ensure that the tearfree swap is unmapped afterwardsChris Wilson
After swapping the bo for the screen pixmap, we need to make sure that we don't chase any dangling pointers. References: https://bugs.launchpad.net/ubuntu/+source/xserver-xorg-video-intel/+bug/1133490 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-04sna: Drop a local variable only used to hold a constantChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-04sna: Ensure we do not attempt to operate inplace on a very large pixmapChris Wilson
Otherwise we will fail to map it into the GTT. In theory, this should just result in the same fallback paths, but pushing that knowledge up further should help us make better decisions. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-04sna/gen3: Always prefer BLT for copiesChris Wilson
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-04sna/gen3: Perform alpha-fixup upon copy sourcesChris Wilson
This is required for copying from depth-15 surfaces onto other depths. Reported-by: Reinis Danne Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
2013-03-03sna: Only destroy the cached CLEAR picture if it existsChris Wilson
Reported-by: Reinis Danne Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>