summaryrefslogtreecommitdiffstats
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* mesa: Implement a new GL_MESA_tile_raster_order extension.Eric Anholt2017-10-101-0/+6
| | | | | | | | | | | | | | The intent is to use this extension on vc4 to allow X11 to do overlapping CopyArea() within a pixmap without first blitting the pixmap to a temporary. With associated glamor patches, improves x11perf -copywinwin100 performance on a Raspberry Pi 3 from ~4700/sec to ~5130/sec, and is an even larger boost to uncomposited window movement performance (most copywinwin100 copies don't overlap). v2: Fix glIsEnabled() on the new enums. v3: Drop the local spec since I'm upstreaming the spec. Reviewed-by: Nicolai Hähnle <[email protected]>
* dri_interface: add an error-returning version of createImageFromRenderbufferNicolai Hähnle2017-10-101-1/+18
| | | | | | | | | We ought to be able to distinguish between allocation errors and bad parameters (non-existent renderbuffer object). Bumps the version of the DRI Image extension to 17. Reviewed-by: Eric Engestrom <[email protected]>
* meson: build glxDylan Baker2017-10-091-1/+1
| | | | | | | | | | | | | | | | | | | | | This gets GLX and the loader building. The resulting GLX and i965 have been tested on piglit and seem to work fine. This patch leaves a lot of todo's in it's wake, GLX is quite complicated, and the build options involved are many, and the goal at the moment is to get dri and gallium drivers building. v2: - fix typo "vaule" -> "value" - put the not on the correct element of the conditional - Put correct description of dri3 option in this patch not the next one (Eric A) - fix non glvnd version (Eric A) - build glx tests - move loader include variables to this patch (Eric A) v3: - set the version correctly for GL_LIB_NAME in libglx v4: - set pkgconfig private fields Signed-off-by: Dylan Baker <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* meson: Build i965 and dri stackDylan Baker2017-10-091-0/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | This gets pretty much the entire classic tree building, as well as i965, including the various glapis. There are some workarounds for bugs that are fixed in meson 0.43.0, which is due out on October 8th. I have tested this with piglit using glx. v2: - fix typo "vaule" -> "value" - use gtest dep instead of linking to libgtest (rebase error) - use gtest dep instead of linking against libgtest (rebase error) - copy the megadriver, then create hard links from that, then delete the megadriver. This matches the behavior of the autotools build. (Eric A) - Use host_machine instead of target_machine (Eric A) - Put a comment in the right place (Eric A) - Don't have two variables for the same information (Eric A) - Put pre_args at top of file in this patch (Eric A) - Fix glx generators in this patch instead of next (Eric A) - Remove -DMESON hack (Eric A) - add sha1_h to mesa in this patch (Eric A) - Put generators in loops when possible to reduce code in mapi/glapi/gen (Eric A) v3: - put HAVE_X11_PLATFORM in this patch Signed-off-by: Dylan Baker <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* meson: Add build Intel "anv" vulkan driverDylan Baker2017-09-271-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This allows building and installing the Intel "anv" Vulkan driver using meson and ninja, the driver has been tested against the CTS and has seems to pass the same series of tests (they both segfault when the CTS tries to run wayland wsi tests). There are still a mess of TODO, XXX, and FIXME comments in here. Those are mostly for meson bugs I'm trying to fix, or for additional things to implement for other drivers/features. I have configured all intermediate libraries and optional tools to not build by default, meaning they will only be built if they're pulled in as a dependency of a target that will actually be installed) this allows us to avoid massive if chains, while ensuring that only the bits that need to be built are. v2: - enable anv, x11, and wayland by default - add configure option to disable valgrind v3: - fix typo in meson_options (Nicholas) v4: - Remove dead code (Eric) - Remove change to generator that was from v0 (Eric) - replace if chain with loop (Eric) - Fix typos (Eric) - define HAVE_DLOPEN for both libdl and builtin dl cases (Eric) v5: - rebase on util string buffer implementation Signed-off-by: Dylan Baker <[email protected]> Reviewed-by: Eric Anholt <[email protected]> (v4)
* Revert "intel: Remove unused Kabylake pci idsAnuj Phogat2017-09-211-0/+8
| | | | | | | | | | | | drm-intel is in favor of keeping the unused pci-id's which are still listed in the h/w specs. To keep it uniform across multiple gfx stack components, I'm reverting below Mesa patches: b2dae9f8fd310c19e66b161a7ee9845af78f73e0 ebc5ccf3cc88990248695e833d9ff11e10d91240. Signed-off-by: Anuj Phogat <[email protected]> Reviewed-by: Rodrigo Vivi <[email protected]>
* vulkan: Add #ifdef hack to vk_android_native_buffer.hChad Versace2017-09-181-0/+5
| | | | | | | | | | | | | | | | This patch consolidates many potential `#ifdef ANDROID` messes throughout src/vulkan and src/intel/vulkan into a simple, localized hack. The hack is an `#ifdef ANDROID` in vk_android_native_buffer.h that, on non-Android platorms, avoids including the Android platform headers and typedefs any Android-specific types to void*. This hack doesn't remove *all* the `#ifdef ANDROID`s in upcoming patches, but it does remove a lot. I first tried implementing VK_ANDROID_native_buffer without this hack, but eventually gave up when the yak shaving became too much. Reviewed-by: Tapani Pälli <[email protected]>
* vulkan: Import vk_android_native_buffer.hChad Versace2017-09-181-0/+91
| | | | | | | | | | | | | | | Just as Mesa imports the Khronos Vulkan headers, it should import this Android-private Vulkan header too. This guarantees that Mesa will continue to build even when upstream Android breaks header compatibility. This header is only for *implementers* of Vulkan, not for consumers of Vulkan. Imported from tag 'android-7.1.1_r28' in aosp/frameworks/native. References: https://android.googlesource.com/platform/frameworks/native/+/android-7.1.1_r28/vulkan/include/vulkan/vk_android_native_buffer.h Reviewed-by: Tapani Pälli <[email protected]>
* vulkan: update headers & registry to VK 1.0.61Lionel Landwerlin2017-09-151-58/+460
| | | | | Signed-off-by: Lionel Landwerlin <[email protected]> Acked-by: Jason Ekstrand <[email protected]>
* dri/image: Add a format modifier attributes queryJason Ekstrand2017-09-141-1/+26
| | | | | Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Daniel Stone <[email protected]>
* intel: Remove unused Kabylake pci idAnuj Phogat2017-09-111-1/+0
| | | | | | | I missed this one in Mesa commit ebc5ccf. Signed-off-by: Anuj Phogat <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* intel: Add brand string for KBL-RAnuj Phogat2017-09-061-1/+1
| | | | | Signed-off-by: Anuj Phogat <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* intel: Change a KBL pci id to GT2 from GT1.5Anuj Phogat2017-09-061-1/+1
| | | | | Signed-off-by: Anuj Phogat <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* intel: Fix few KBL brand stringsAnuj Phogat2017-09-061-2/+2
| | | | | Signed-off-by: Anuj Phogat <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* intel: Remove unused Kabylake pci idsAnuj Phogat2017-09-061-7/+0
| | | | | | | These PCI IDs are not used in any Kabylake SKUs. Signed-off-by: Anuj Phogat <[email protected]> Reviewed-by: Matt Turner <[email protected]>
* drm-uapi: Update headers from drm-nextJason Ekstrand2017-08-285-9/+124
| | | | Reviewed-by: Lionel Landwerlin <[email protected]>
* dri_interface.h: add missing stdint.h includeEmil Velikov2017-08-261-0/+2
| | | | | | | | Required for uint32_t and friends. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Eric Engestrom <[email protected]> Reviewed-by: Nicolai Hähnle <[email protected]>
* khronos/egl: remove dependency on Android NDK headerEric Engestrom2017-08-251-2/+1
| | | | | | | Khronos: https://github.com/KhronosGroup/EGL-Registry/pull/22 Suggested-by: Emil Velikov <[email protected]> Reviewed-by: Rob Herring <[email protected]> Signed-off-by: Eric Engestrom <[email protected]>
* include: Sync Khronos headers for OpenGL 4.6Adam Jackson2017-08-244-11/+136
| | | | | | | | Taken from c21e602b9fda1d3bbaecb08194592f67e6a0649b from OpenGL-Registry. (This time without breaking glext.h.) Signed-off-by: Adam Jackson <[email protected]> Acked-by: Ilia Mirkin <[email protected]>
* Revert "include: Sync Khronos headers for OpenGL 4.6"Adam Jackson2017-08-244-136/+16
| | | | | | Broke the BUILDING_MESA bit, oops. This reverts commit ef1e87e6cdbd80e74a8bc6d48b0b174a0812fe69.
* include: Sync Khronos headers for OpenGL 4.6Adam Jackson2017-08-244-16/+136
| | | | | | | | Taken from c21e602b9fda1d3bbaecb08194592f67e6a0649b from OpenGL-Registry. Signed-off-by: Adam Jackson <[email protected]> Acked-by: Ilia Mirkin <[email protected]>
* dri: fix typoEric Engestrom2017-08-241-1/+1
| | | | Signed-off-by: Eric Engestrom <[email protected]>
* egl: Fix inclusion of egl.h+mesa_glinterop.hMatt Turner2017-08-211-0/+4
| | | | | | | | Previously clang would warn about redefinition of typedef EGLDisplay. Avoid this by adding preprocessor guards to mesa_glinterop.h and including it after EGL.h is indirectly included. Reviewed-by: Jordan Justen <[email protected]>
* vulkan: import 1.0.59 headers and xml.Dave Airlie2017-08-221-4/+15
| | | | Acked-by: Jason Ekstrand <[email protected]>
* dri: fix typo in commentGwan-gyeong Mun2017-08-171-1/+1
| | | | | Signed-off-by: Mun Gwan-gyeong <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* intel/drm: Pull in the i915 fence array APIJason Ekstrand2017-08-151-2/+28
| | | | Reviewed-by: Lionel Landwerlin <[email protected]>
* drm-uapi/forcc: Pull in new modifiersJason Ekstrand2017-08-141-0/+31
| | | | Reviewed-by: Ben Widawsky <[email protected]>
* egl: Update headers from KhronosDaniel Stone2017-08-113-13/+76
| | | | | | Taken from egl-registry 7d68647c4dab. Signed-off-by: Daniel Stone <[email protected]>
* dri: Introduce SWAP_METHOD tokensThomas Hellstrom2017-08-101-0/+12
| | | | | | | | | | | | We shouldn't be using GLX tokens in the dri subsystem, so define dri SWAP_METHOD tokens and translate when necessary. Unfortunately the X server uses the dri swap method value untranslated as the GLX fbconfig swapMethod, so we can't enumerate these tokens arbitrarily, but rather need to make them have the same values as the corresponding GLX tokens. Signed-off-by: Thomas Hellstrom <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* dri: Fix __DRIconfig reporting of __DRI_ATTRIB_SWAP_METHODThomas Hellstrom2017-08-101-1/+4
| | | | | | | | | | | | | | The attribMap had two entries for this attribute, and driGetConfigAttribIndex didn't return a proper value for this attribute. Fix this, and also make sure we return SWAP_UNDEFINED for single-buffer configs as required by the GLX_OML_swap_method spec. Finally bump the dri core extension version to 2, indicating that we correctly report __DRI_ATTRIB_SWAP_METHOD. Signed-off-by: Thomas Hellstrom <[email protected]> Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Michel Dänzer <[email protected]>
* include: update GLES gl2ext header to no longer reference bad functionIlia Mirkin2017-08-071-5/+52
| | | | | | | | | | | There was a previous error in the gl.xml and generated files that referenced glMultiDrawElementsBaseVertexOES. This function should not exist, only the EXT-suffixed version should. Leaving the other headers alone to avoid conflicts with GL 4.6 work. Signed-off-by: Ilia Mirkin <[email protected]> Acked-by: Samuel Pitoiset <[email protected]>
* dri: Add a flushSwapBuffers method to the image loader extensionThomas Hellstrom2017-08-031-1/+15
| | | | | | | | | This method may be used by dri drivers to make sure all outstanding buffer swaps have been flushed to hardware. Signed-off-by: Thomas Hellstrom <[email protected]> Reviewed-by: Sinclair Yeh <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* dri: define a version 2 of the DRI_ConfigOptions extensionNicolai Hähnle2017-08-021-2/+18
| | | | | | | | | | The new function is defined to return a malloc'ed pointer. In the following patches, this helps avoid leaking library handles when pipe drivers are linked dynamically. It also allows us to generate the XML string on the fly in the future. Reviewed-by: Marek Olšák <[email protected]>
* vulkan: Import in the latest 1.0.57 header and XML from KhronosJason Ekstrand2017-08-011-36/+55
| | | | Acked-by: Dave Airlie <[email protected]>
* gles: Restore some lost typedefsScott D Phillips2017-08-012-4/+14
| | | | | | | | | | | | | GLES/gl.h has historically provided some typedefs that are not used in the API itself. Restore these typedefs that were lost to avoid breaking applications. These seem to be the only typedefs removed in the update. Fixes: 7fd0817 "Update Khronos-supplied headers" [Eric: added a big warning to revert this patch when pulling the updated header] Signed-off-by: Eric Engestrom <[email protected]>
* dri_interface: document loaderPrivate for getCapabilityMarek Olšák2017-07-311-0/+4
| | | | Reviewed-by: Emil Velikov <[email protected]>
* dri_interface,egl,gallium: only expose RGBA visuals on AndroidMarek Olšák2017-07-311-2/+26
| | | | | | | | | | | | | | X/GLX can't handle them. This removes almost 500 GLX visuals that were incorrectly exposed. Add an optional getCapability callback for querying what the loader can do. I'm not splitting this patch, because it's already too small. v2: also add the callback to __DRIimageLoaderExtension Reviewed-by: Nicolai Hähnle <[email protected]> Cc: 17.2 <[email protected]>
* vulkan: Update to the new 1.0.54 spec XML and headersJason Ekstrand2017-07-151-391/+893
| | | | | | | | | There is one small ANV change here because we used the VK_ERROR_INVALID_EXTERNAL_HANDLE_KHX enum in the BO cache and that had to be updated to have the _KHR suffix. Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]> Reviewed-by: Lionel Landwerlin <[email protected]>
* dri: Add KHR_no_error DRI extensionGrigori Goronzy2017-07-141-0/+19
| | | | | | | | | | This basic extension allows usage of the __DRI_CTX_FLAG_NO_ERROR flag. This includes support code for classic Mesa drivers to switch on the no-error mode if the flag is set. v2: Move to common DRI code. Reviewed-by: Marek Olšák <[email protected]>
* vc4: Switch back to using a local copy of vc4_drm.h.Eric Anholt2017-07-121-0/+318
| | | | | | | | | | | Needing to get our uapi header from libdrm has only complicated things. Follow intel's lead and drop our requirement for it. Generated from the same commit mentioned in the README. v2: Update Android.mk as well, move vc4_drm.h reference for distcheck. Reviewed-by: Daniel Stone <[email protected]>
* intel: Move the DRM uapi headers to a non-Intel location.Eric Anholt2017-07-125-0/+3535
| | | | | | | | | | | | I want to remove vc4's dependency on headers from libdrm as well, but storing multiple copies of drm_fourcc.h in our tree would be silly. v2: Update Android.mk as well, move distcheck drm*.h references to top-level noinst_HEADERS. Reviewed-by: Lionel Landwerlin <[email protected]> (v1) Reviewed-by: Daniel Stone <[email protected]> (v1) Reviewed-by: Rob Herring <[email protected]>
* gallium: use "ull" number suffix to keep the QtCreator parser happyMarek Olšák2017-07-101-1/+1
| | | | | | | It can't parse "llu". Reviewed-by: Thomas Helland <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* Update Khronos-supplied headersNicolai Hähnle2017-06-3015-1431/+3486
| | | | | | | | | | | Taken from commit 676834dd529d620ee25090e738d2607dfde003d8 of https://github.com/KhronosGroup/OpenGL-Registry.git v2: - keep the BUILDING_MESA bits (Matt) Reviewed-by: Matt Turner <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* dri: Add UYVY as available formatJohnson Lin2017-06-301-1/+3
| | | | | | | | | UYVY is diffrent with YUYV in byte order. YUYV is already declared in dri_interface.h, this CL add the difinitions for UYVY. Drivers can add UYVY as supported format Reviewed-by: Kristian H. Kristensen <[email protected]>
* i965/CFL: Add PCI Ids for Coffee Lake.Anusha Srivatsa2017-06-221-0/+11
| | | | | | | | | | | | | | Coffee Lake has a gen9 graphics following KBL. From 3D perspective, CFL is a clone of KBL/SKL features. v2: Change commit message, correct alignment <Anuj Phogat> v3: Update IDs. v4: Initialize l3_banks, correct nomenclature <Anuj> Cc: Rodrigo Vivi <[email protected]> Signed-off-by: Anusha Srivatsa <[email protected]> Acked-by: Benjamin Widawsky <[email protected]> Reviewed-by: Anuj Phogat <[email protected]>
* radeonsi: add new polaris12 pci idAlex Deucher2017-06-161-0/+1
| | | | | | Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: 17.0 17.1 <[email protected]>
* i965/cnl: Add a preliminary device for CannonlakeBen Widawsky2017-06-091-0/+12
| | | | | | | | | | | | | | | | v2 (Anuj): Rebased on master and updated pci ids Remove redundant initialization of max_wm_threads to 64 * 12. For gen9+ max_wm_threads are initialized in gen_get_device_info(). v3 (Anuj): Move the patch to end of series. Remove unused gt1, gt2, gt3 functions. Remove l3_banks variable. Variable is now available on master. Signed-off-by: Anuj Phogat <[email protected]> Signed-off-by: Ben Widawsky <[email protected]> Reviewed-by: Anuj Phogat <[email protected]>
* dri: introduce dmabuf format modifier related handlesVarad Gautam2017-05-301-1/+62
| | | | | | | | | | | | | | | | | | these allow dmabuf import with modifiers, and supported format and modifier queries, which are used to implement EGL_EXT_image_dma_buf_import_modifiers. v2: - squash dmabuf queries into DRIimage version 15 (Jason Ekstrand). - add external_only param to queryDmaBufModifiers (Emil, Daniel Stone) - pass a single modifier form createImageFromDmaBufs2 since all planes have the same modifier (Jason Ekstrand) Signed-off-by: Pekka Paalanen <[email protected]> Signed-off-by: Varad Gautam <[email protected]> Reviewed-by: Daniel Stone <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Eric Engestrom <[email protected]>
* dri: Extend __DRIbackgroundCallableExtensionRec to include a callback that ↵Gregory Hainaut2017-05-291-0/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | checks for thread safety DRI-drivers could call Xlib functions, for example to allocate a new back buffer. When glthread is enabled, the driver runs mostly on a separate thread. Therefore we need to guarantee the thread safety between libX11 calls from the applications (not aware of the extra thread) and the ones from the driver. See discussion thread: https://lists.freedesktop.org/archives/mesa-dev/2017-April/152547.html Fortunately, Xlib allows to lock display to ensure thread safety but XInitThreads must be called first by the application to initialize the lock function pointer. This patch will allow to check XInitThreads was called to allow glthread on GLX or EGL platform. Note: a tentative was done to port libX11 code to XCB but it didn't solve fully thread safety. See discussion thread: https://lists.freedesktop.org/archives/mesa-dev/2017-April/153137.html Note: Nvidia forces the driver to call XInitThreads. Quoting their manpage: "The NVIDIA OpenGL driver will automatically attempt to enable Xlib thread-safe mode if needed. However, it might not be possible in some situations, such as when the NVIDIA OpenGL driver library is dynamically loaded after Xlib has been loaded and initialized. If that is the case, threaded optimizations will stay disabled unless the application is modified to call XInitThreads() before initializing Xlib or to link directly against the NVIDIA OpenGL driver library. Alternatively, using the LD_PRELOAD environment variable to include the NVIDIA OpenGL driver library should also achieve the desired result." v2: based on Nicolai and Matt feedback Use C style comment v3: based on Emil feedback split the patch in 3 s/isGlThreadSafe/isThreadSafe/ v5: based on Marek comment Add a comment that isThreadSafe is supported by extension v2 Signed-off-by: Gregory Hainaut <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* vulkan: Update registry and headers to 1.0.49Jason Ekstrand2017-05-161-4/+107
| | | | Reviewed-by: Samuel Iglesias Gonsálvez <[email protected]>