summaryrefslogtreecommitdiffstats
path: root/src/gallium/winsys
Commit message (Collapse)AuthorAgeFilesLines
* ilo: do not set I915_EXEC_NO_RELOCChia-I Wu2014-03-101-11/+1
| | | | | | | This reverts most of commit d80f0c34b733a874adfdd3a2267e4deec345cc6b. Upon a closer reading, having the presumed offsets written is not enough to set the flag. EXEC_OBJECT_NEEDS_GTT and/or EXEC_OBJECT_WRITE of the reloc entries must also be set appropriately.
* ilo: print a warning when PPGTT is disabledChia-I Wu2014-03-102-0/+4
| | | | | Despite what the PRMs say, the driver appears to work fine when PPGTT is disabled. But at least print a warning in that case.
* ilo: require hardware logical context supportChia-I Wu2014-03-102-2/+20
| | | | The code paths are not tested for a while, and have some known issues.
* ilo: protect the decode context with a mutexChia-I Wu2014-03-101-7/+20
| | | | The decode context is not thread safe.
* ilo: set I915_EXEC_NO_RELOC when availableChia-I Wu2014-03-102-3/+15
| | | | | The winsys makes it clear that the pipe drivers should write presumed offsets. We can always set I915_EXEC_NO_RELOC when the kernel supports it.
* ilo: move ring types to winsysChia-I Wu2014-03-102-15/+19
| | | | | It results in less code despite that i915_drm.h specifies the ring type as part of the execution flags.
* ilo: winsys may limit the batch buffer sizeChia-I Wu2014-03-102-0/+3
| | | | | | The maximum batch buffer size is determined at the time of drm_intel_bufmgr_gem_init(). Make sure the pipe driver does not exceed the limit.
* ilo: PIPE_CAP_QUERY_TIMESTAMP may not be supportedChia-I Wu2014-03-102-0/+15
| | | | Reading TIMESTAMP register may fail, depending on both kernel and hardware.
* ilo: rework winsys batch buffer functionsChia-I Wu2014-03-102-38/+47
| | | | | | | | | | | Rename intel_winsys_check_aperture_size() to intel_winsys_can_submit_bo(), intel_bo_exec() to intel_winsys_submit_bo(), and intel_winsys_decode_commands() to intel_winsys_decode_bo(). Make a semantic change to ignore intel_context when the ring is not the render ring.
* ilo: replace bo alloc flags by initial domainsChia-I Wu2014-03-102-13/+12
| | | | | | The only alloc flag is INTEL_ALLOC_FOR_RENDER, which can as well be expressed by specifying the initial write domain. The change makes it obvious that we failed to set INTEL_ALLOC_FOR_RENDER in several places.
* ilo: remove intel_bo_get_size()Chia-I Wu2014-03-102-13/+0
| | | | | | Commit bfa8d21759c5f2b5b0885c696842167bd4c64fee uses it to work around a hardware limitation. But there are other ways to do it without the need for intel_bo_get_size().
* ilo: remove intel_bo_get_virtual()Chia-I Wu2014-03-102-24/+36
| | | | Make the map functions return the pointer directly.
* ilo: rework winsys bo reloc functionsChia-I Wu2014-03-102-26/+22
| | | | | | | | | | | | | Rename intel_bo_emit_reloc() to intel_bo_add_reloc(), intel_bo_clear_relocs() to intel_bo_truncate_relocs(), and intel_bo_references() to intel_bo_has_reloc(). Besides, we need intel_bo_get_offset() only to get the presumed offset afer adding a reloc entry. Remove the function and make intel_bo_add_reloc() return the presumed offset. While at it, switch to gem_bo->offset64 from gem_bo->offset.
* ilo: add a wrapper to cast struct intel_boChia-I Wu2014-03-101-23/+28
| | | | It is just drm_intel_bo, but having a wrapper makes the code cleaner.
* ilo: fix DRM_API_HANDLE_TYPE_FD exportChia-I Wu2014-03-101-2/+0
| | | | | It can be exported by drm_intel_bo_gem_export_to_prime(). The code is already in winsys, just not enabled.
* ilo: improve winsys documentation/commentsChia-I Wu2014-03-102-15/+107
| | | | | Document the interface, and add comments as to why some features are enabled and why some checks are made.
* ilo: remove intel_winsys_enable_reuse()Chia-I Wu2014-03-102-11/+3
| | | | It should be an (winsys) implementation detail.
* Revert "winsys/radeon: if there's VRAM-only usage, keep it"Marek Olšák2014-03-081-28/+12
| | | | | | | | This reverts commit 67aef6dafa29fed008ea6065c425a6a92a651be9. It caused GPU hangs. The question is why. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=75900
* winsys/radeon: if there's VRAM-only usage, keep itMarek Olšák2014-03-071-12/+28
|
* winsys/svga: Avoid calling drm getparam for max surface size on older kernelsThomas Hellstrom2014-02-281-7/+8
| | | | | | | | | | | | | This avoids the kernel driver spewing out errors about the param not being supported. Also correct the max surface size used when the kernel does not support the query. Reported-by: Brian Paul <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Reviewed-by: Charmaine Lee <[email protected]> Cc: "10.1" <[email protected]>
* winsys/xlib: move xlib_create_sw_winsys within the winsysEmil Velikov2014-02-222-1/+12
| | | | | | v2: Rebase on top of vl_winsys_xsp.c removal Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Jakob Bornecrantz <[email protected]> (v1)
* gallium/pipebuffer: change pb_cache_manager_create() size_factor to floatBrian Paul2014-02-142-2/+2
| | | | | | | Requested by Marek. Reviewed-by: Marek Olšák <[email protected]> Cc: "10.1" <[email protected]>
* svga/winsys: Propagate surface shared information to the winsysThomas Hellstrom2014-02-143-24/+29
| | | | | | | | | | | | | | | | | The linux winsys needs to know whether a surface is shared. For guest-backed surfaces we need this information to avoid allocating a mob out of the mob cache for shared surfaces, but instead allocate a shared mob, that is never put in the mob cache, from the kernel. Also previously, all surfaces were given the "shareable" attribute when allocated from the kernel. This is too permissive for client-local surfaces. Now that we have the needed info, only set the "shareable" attribute if the client indicates that it needs to share the surface. Signed-off-by: Thomas Hellstrom <[email protected]> Reviewed-by: Jakob Bornecrantz <[email protected]> Reviewed-by: Brian Paul <[email protected]> Cc: "10.1" <[email protected]>
* svga/winsys: implement GBS supportBrian Paul2014-02-1419-323/+3064
| | | | | | | This is a squash commit of many commits by Thomas Hellstrom. Reviewed-by: Thomas Hellstrom <[email protected]> Cc: "10.1" <[email protected]>
* gallium/pipebuffer: Add a cache buffer manager bypass maskThomas Hellstrom2014-02-141-1/+1
| | | | | | | | | | | | | In some situations, it may be desirable to bypass the cache at buffer creation but to insert the buffer in the cache at buffer destruction. One such situation is where we already have a kernel representation of a buffer that we want to use, but we also want to insert it in the cache when it's freed up. Signed-off-by: Thomas Hellstrom <[email protected]> Reviewed-by: José Fonseca <[email protected]> Reviewed-by: Brian Paul <[email protected]> Cc: "10.1" <[email protected]>
* pipebuffer, winsys: Add a size match parameter to the cached buffer managerThomas Hellstrom2014-02-141-1/+1
| | | | | | | | In some situations it's important to restrict the sizes of buffers that the cached buffer manager is allowed to return Signed-off-by: Thomas Hellstrom <[email protected]> Cc: "10.1" <[email protected]>
* svga: update svga_winsys interface for GBSBrian Paul2014-02-141-0/+1
| | | | | | | | This adds new interface functions for guest-backed surfaces and adds a mobid parameter to the surface_relocation() function. Reviewed-by: Thomas Hellstrom <[email protected]> Cc: "10.1" <[email protected]>
* radeon/winsys: add VCE support v4Christian König2014-02-133-1/+31
| | | | | | | | v2: add fw version query v3: add README.VCE v4: avoid error msg when kernel doesn't support it Signed-off-by: Christian König <[email protected]>
* nouveau: create only 1 shared screen between vdpau and openglMaarten Lankhorst2014-02-121-4/+74
| | | | | | | | This fixes bug 73200 "vdpau-GL interop fails due to different screen objects" in the same way radeon does. Signed-off-by: Maarten Lankhorst <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* gallium/radeon: fix warningsMarek Olšák2014-02-061-3/+3
|
* freedreno: ctx should hold ref to devRob Clark2014-02-011-1/+1
| | | | | | | | The ctx should hold ref to dev to avoid problems if screen is destroyed before ctx. Doesn't really fix the egl/glx issues, but at least it prevents things from getting much worse. Signed-off-by: Rob Clark <[email protected]>
* radeon: More missing stdio.h includes.José Fonseca2014-01-231-0/+1
|
* gallium: Use C11 thread abstractions.José Fonseca2014-01-231-1/+1
| | | | | | | Note that PIPE_ROUTINE now returns an int. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* s/Tungsten Graphics/VMware/José Fonseca2014-01-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Tungsten Graphics Inc. was acquired by VMware Inc. in 2008. Leaving the old copyright name is creating unnecessary confusion, hence this change. This was the sed script I used: $ cat tg2vmw.sed # Run as: # # git reset --hard HEAD && find include scons src -type f -not -name 'sed*' -print0 | xargs -0 sed -i -f tg2vmw.sed # # Rename copyrights s/Tungsten Gra\(ph\|hp\)ics,\? [iI]nc\.\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./g /Copyright/s/Tungsten Graphics\(,\? [iI]nc\.\)\?\(, Cedar Park\)\?\(, Austin\)\?\(, \(Texas\|TX\)\)\?\.\?/VMware, Inc./ s/TUNGSTEN GRAPHICS/VMWARE/g # Rename emails s/[email protected]/[email protected]/ s/[email protected]/[email protected]/g s/jrfonseca-at-tungstengraphics-dot-com/jfonseca-at-vmware-dot-com/ s/jrfonseca\[email protected]/[email protected]/g s/keithw\[email protected]/[email protected]/g s/[email protected]/[email protected]/g s/thomas-at-tungstengraphics-dot-com/thellstom-at-vmware-dot-com/ s/[email protected]/[email protected]/ # Remove dead links s@Tungsten Graphics (http://www.tungstengraphics.com)@Tungsten Graphics@g # C string src/gallium/state_trackers/vega/api_misc.c s/"Tungsten Graphics, Inc"/"VMware, Inc"/ Reviewed-by: Brian Paul <[email protected]>
* radeonsi: calculate NUM_BANKS for DB correctly on CIKMarek Olšák2014-01-062-0/+8
| | | | | | NUM_BANKS is not constant on CIK. Reviewed-by: Alex Deucher <[email protected]>
* radeonsi: set correct pipe config for Hawaii in DBMarek Olšák2014-01-062-0/+8
| | | | Reviewed-by: Michel Dänzer <[email protected]>
* winsys/radeon: remove superfluous distinction of casesNiels Ole Salscheider2013-12-221-15/+5
| | | | | | Signed-off-by: Niels Ole Salscheider <[email protected]> Reviewed-by: Alex Deucher <[email protected]> Signed-off-by: Marek Olšák <[email protected]>
* swrast* (gallium, classic): add MESA_copy_sub_buffer support (v3)Dave Airlie2013-12-138-11/+26
| | | | | | | | | | | | | | | | | | | | | | | This patches add MESA_copy_sub_buffer support to the dri sw loader and then to gallium state tracker, llvmpipe, softpipe and other bits. It reuses the dri1 driver extension interface, and it updates the swrast loader interface for a new putimage which can take a stride. I've tested this with gnome-shell with a cogl hacked to reenable sub copies for llvmpipe and the one piglit test. I could probably split this patch up as well. v2: pass a pipe_box, to reduce the entrypoints, as per Jose's review, add to p_screen doc comments. v3: finish off winsys interfaces, add swrast classic support as well. Reviewed-by: Jose Fonseca <[email protected]> Signed-off-by: Dave Airlie <[email protected]> swrast: add support for copy_sub_buffer
* winsys/radeon: set/get the scanout flag with the tiling ioctlsMarek Olšák2013-12-122-4/+13
| | | | | | | | | | | | | | | If we assume that all buffers allocated by the DDX are scanout, a new flag that says "this is not scanout" has to be added to support the non-scanout buffers and maintain backward compatibility. This fixes bad rendering on Wayland. The flag is defined as: #define RADEON_TILING_R600_NO_SCANOUT RADEON_TILING_SWAP_16BIT AFAIK, RADEON_TILING_SWAP_16BIT is not used on SI. Reviewed-by: Michel Dänzer <[email protected]>
* svga/winsys: Implement surface sharing using prime fd handlesThomas Hellstrom2013-12-101-18/+61
| | | | | | | | | | This needs a prime-aware vmwgfx kernel module to work properly. (With additions by Christopher James Halse Rogers <[email protected]>) Signed-off-by: Christopher James Halse Rogers <[email protected]> Signed-off-by: Thomas Hellstrom <[email protected]> Signed-off-by: Maarten Lankhorst <[email protected]>
* gallium/radeon: Implement hooks for DRI Image 7 (v2)Christopher James Halse Rogers2013-12-101-23/+83
| | | | | | | | | v2: Fix transliteration of lseek arguments Ignore busy return from RADEON_GEM_BUSY ioctl; we're only after the domain Signed-off-by: Christopher James Halse Rogers <[email protected]> Reviewed-by: Thomas Hellstrom <[email protected]> Signed-off-by: Maarten Lankhorst <[email protected]>
* radeon: Rename bo_handles hashtable to match its actual contents.Christopher James Halse Rogers2013-12-101-8/+8
| | | | | | | | It's a map of GEM name->bo, so identify it as such Signed-off-by: Christopher James Halse Rogers <[email protected]> Reviewed-by: Thomas Hellstrom <[email protected]> Signed-off-by: Maarten Lankhorst <[email protected]>
* ilo: Support DRI Image 7Christopher James Halse Rogers2013-12-101-2/+0
| | | | | | Signed-off-by: Christopher James Halse Rogers <[email protected]> Reviewed-by: Thomas Hellstrom <[email protected]> Signed-off-by: Maarten Lankhorst <[email protected]>
* gallium/winsys/drm: Prepare for passing prime fds in winsys_handleChristopher James Halse Rogers2013-12-103-1/+17
| | | | | | Signed-off-by: Christopher James Halse Rogers <[email protected]> Reviewed-by: Thomas Hellstrom <[email protected]> Signed-off-by: Maarten Lankhorst <[email protected]>
* nvc0: fixup gk110 and up not being listed in various switch statementsBen Skeggs2013-12-061-1/+2
| | | | Signed-off-by: Ben Skeggs <[email protected]>
* winsys/radeon: cleanup virtual memory nonsenseChristian König2013-11-212-20/+18
| | | | | | | | The alignment of a virtual memory area must always be at least 4096 bytes. It only worked because size was aligned to 4096 outside of the function. Signed-off-by: Christian König <[email protected]>
* gallium/winsys: compact compiler flags into Automake.incEmil Velikov2013-11-1613-32/+22
| | | | | | | | | | | | | | | | Cleanup the duplicating flags and consolidate into a sigle variable. Note: this patch adds VISIBILITY_CFLAGS to the following targets * freedreno/drm * i915/{drm,sw} * nouveau/drm * sw/fbdev * sw/null * sw/wayland * sw/wrapper * sw/xlib Signed-off-by: Emil Velikov <[email protected]>
* radeonsi: add support for Hawaii asics (v2)Alex Deucher2013-11-152-0/+2
| | | | | | | Update additional register fields. Reviewed-by: Michel Dänzer <[email protected]> Signed-off-by: Alex Deucher <[email protected]>
* winsys/radeon: use type-3 NOPs for CS padding on CIKMarek Olšák2013-11-041-2/+7
| | | | The type-2 NOPs are said to be unstable. It doesn't make a difference here.
* winsys: Correct Haiku winsys display target codeAlexander von Gluck IV2013-10-294-8/+41
| | | | | | | | | * Instead of assuming the displaytarget is the same stride / colorspace as the destination, lets actually check the source bitmap. * Fixes random stride issues in rendering Acked-by: Brian Paul <[email protected]>