aboutsummaryrefslogtreecommitdiffstats
path: root/include
Commit message (Collapse)AuthorAgeFilesLines
* i965/skl: PCI ID cleanup and brand stringsBen Widawsky2015-11-031-15/+19
| | | | | | | | | | | | A few new PCI ids are added here, and one is removed (0x190B) because it no longer seems to exist anywhere. v2-4: Only use ascii characters (Ilia) 0x1921 is no longer marked as f Reviewed-by: Jordan Justen <[email protected]> Signed-off-by: Ben Widawsky <[email protected]>
* i965/skl: Add GT4 PCI IDsBen Widawsky2015-11-031-0/+4
| | | | | | | | | | | | | | | | | | | | Like other gen8+ hardware, the hardware automatically scales up thread counts. We must be careful about the URB sizes since GT4 adds another slice. One of the existing PCI IDs is actually mislabeled as GT3. Arguably this is a real bug since the URB size will be wrong. Because this patch is simply meant to add the missing IDs, that will be fixed in a later patch. v2: No longer relevant. v3: Update the wm thread count to support GT4. The WM thread count is used to determine the maximum scratch space required. Currently the code always allocates the maximum amount even though lower GT SKUs require less. The formula is threads_per_psd * subslices_per_slice * slices Cc: [email protected] Reviewed-by: Jordan Justen <[email protected]> Signed-off-by: Ben Widawsky <[email protected]>
* gallium/swrast: fix front buffer blitting. (v2)Dave Airlie2015-10-311-1/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | So I've known this was broken before, cogl has a workaround for it from what I know, but with the gallium based swrast drivers BlitFramebuffer from back to front or vice-versa was pretty broken. The legacy swrast driver tracks when a front buffer is used and does the get/put images when it is mapped/unmapped, so this patch attempts to add the same functionality to the gallium drivers. It creates a new context interface to denote when a front buffer is being created, and passes a private pointer to it, this pointer is then used to decide on map/unmap if the contents should be updated from the real frontbuffer using get/put image. This is primarily to make gtk's gl code work, the only thing I've tested so far is the glarea test from https://github.com/ebassi/glarea-example.git v2: bump extension version, check extension version before calling get image. (Ian) Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=91930 Cc: <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* radeonsi: add Stoney pci idsSamuel Li2015-10-231-0/+2
| | | | | | | Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> Signed-off-by: Samuel Li <[email protected]> Cc: [email protected]
* c11/threads: initialize timeout structureJan Vesely2015-10-081-0/+6
| | | | | Signed-off-by: Jan Vesely <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* c11/threads: Assert that mtx is non-NULL and check return values.Matt Turner2015-09-251-25/+23
| | | | | | | | | | | | Passing NULL to C11 threads functions isn't safe, so there's no need for our implementation to handle it. Cuts about 1k of .text. text data bss dec hex filename 5009514 198440 26328 5234282 4fde6a i965_dri.so before 5008346 198440 26328 5233114 4fd9da i965_dri.so after Reviewed-by: Timothy Arceri <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* GL: update glext to svn 31811Dave Airlie2015-08-201-9/+285
| | | | | | | This brings in the new ARB extensions. Acked-by: Chris Forbes <[email protected]> Signed-off-by: Dave Airlie <[email protected]>
* radeonsi: add all new VI PCI IDs including FijiMarek Olšák2015-08-141-0/+24
|
* radeonsi: add new OLAND pci idAlex Deucher2015-08-101-0/+1
| | | | | | | Reviewed-by: Edward O'Callaghan <[email protected]> Reviewed-by: Michel Dänzer <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
* egl/dri: Add error info needed for EGL_EXT_image_dma_buf_import extensionFrank Binns2015-08-041-2/+6
| | | | | | | | | | | | | Update the DRI image interface error codes to reflect the needs of the EGL_EXT_image_dma_buf_import extension. This means updating the existing error code documentation and adding a new __DRI_IMAGE_ERROR_BAD_ACCESS error code so that drivers can correctly reject unsupported pitches and offsets. Hook the new error code up in EGL to return EGL_BAD_ACCESS. Cc: <[email protected]> Signed-off-by: Frank Binns <[email protected]> Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Eric Anholt <[email protected]>
* includes/GL: remove duplicated extension declarations from glx.hEmil Velikov2015-08-011-92/+0
| | | | | | | | | | | | All three of GLX_NV_float_buffer, GLX_EXT_texture_from_pixmap and GLX_MESA_query_renderer have been in glxext.h for a while now. As such we can drop this workaround/hack from the header. v2: Remove the comment about GLX_NV_float_buffer. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Brian Paul <[email protected]> (v1)
* c99_math: (trivial) implement exp2 for MSVC tooRoland Scheidegger2015-07-291-0/+6
| | | | Unsurprisingly doesn't build otherwise with old msvc.
* c99_math: Implement exp2f for MSVC.Matt Turner2015-07-291-0/+6
| | | | Reviewed-by: Jose Fonseca <[email protected]>
* i965: Support importing R8 and GR88 dma_bufsChad Versace2015-07-281-2/+7
| | | | | | | | | | | EGL_EXT_image_dma_buf_import now supports those formats. Tests: - Tested by Piglit ext_image_dma_buf_import-transcode-nv12-as-r8-gr88. - Tested by Peter in Kodi/XBMC to obtain 60fps NV12 transcode at 4K. Tested-by: Peter Frühberger <[email protected]> Signed-off-by: Chad Versace <[email protected]>
* egl,dri_interface: use DRI2rendererQueryExtension to enable 3D textures & sRGBMarek Olšák2015-07-221-0/+5
| | | | Reviewed-by: Emil Velikov <[email protected]>
* dri_interface: drop __NOT_HAVE_DRM_H magicEmil Velikov2015-07-221-8/+1
| | | | | | | v2: use HAVE_LIBDRM macro. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Ian Romanick <[email protected]>
* egl: use unix defines on osx with clangJulien Isorce2015-07-081-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I also created an bug in Khronos 's bugzilla as you suggested: https://www.khronos.org/bugzilla/show_bug.cgi?id=1356 I'll let you know if I get feedback from this bug or else where. Patch with updated error messages: [PATCH] eglplatform: treat __APPLE__ the same way as __unix__ to handle X11 types CC eglapi.lo ./egldisplay.h:258:19: error: unknown type name 'Display' _eglGetX11Display(Display *native_display, const EGLint *attrib_list); eglapi.c:290:4: error: array size is negative STATIC_ASSERT(sizeof(void*) == sizeof(nativeDisplay)); eglapi.c:291:25: warning: cast to 'void *' from smaller integer type 'EGLNativeDisplayType' (aka 'int') [-Wint-to-void-pointer-cast] native_display_ptr = (void*) nativeDisplay; eglapi.c:307:32: error: use of undeclared identifier 'Display' dpy = _eglGetX11Display((Display*) native_display, attrib_list); eglapi.c:776:35: error: use of undeclared identifier 'Window' native_window = (void*) (* (Window*) native_window); eglapi.c:847:35: error: use of undeclared identifier 'Pixmap' native_pixmap = (void*) (* (Pixmap*) native_pixmap); Bugzilla Mesa: https://bugs.freedesktop.org/show_bug.cgi?id=90249 Bugzilla Khronos: https://www.khronos.org/bugzilla/show_bug.cgi?id=1356 Signed-off-by: Julien Isorce <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* darwin: Suppress type conversion warnings for GLhandleARBJulien Isorce2015-07-081-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch and its description are inspired from Jose Fonseca explanations and suggestions. With this patch the following logic applies and only if __APPLE__: When building mesa, GLhandleARB is defined as unsigned long and at some point casted to GLuint in gl fuction implementations. These exact points are where these errors and warnings appear. When building an application GLhandleARB is defined as void*. Later when calling a gl function, for example glBindAttribLocationARB, it will be dispatched to _mesa_BindAttribLocation. So internally void* will be treated as unsigned long which has the same size. So the same truncation happens when casting it to GLuint. Same when GLhandleARB appears as return value. For mesa it will be GLuint -> unsigned long. For an application it will be GLuint -> unsigned long -> void*. Note that the value will be preserved when casting back to GLuint. When GLhandleARB appears as a pointer there are also separate entry-points, i.e. _mesa_FuncNameARB. So the same logic can be applied. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=66346 Signed-off-by: Julien Isorce <[email protected]> Reviewed-by: Jose Fonseca <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* i965/bxt: Add basic Broxton infrastructureBen Widawsky2015-06-241-0/+3
| | | | | | | | | | | | | | | | | The thread counts and URB information are all speculative numbers that were based on some CHV numbers at the time. v2: Originally this patch had PCI IDs. I've moved that to a new patch at the end of the series. Remove is_cherryview hack. Add PCI ids. These match the ones defined in the kernel. The only one tested by us is 0x0a84. Capitalize the hex string (Mark) Signed-off-by: Ben Widawsky <[email protected]> Tested-by: "Lecluse, Philippe" <[email protected]> Reviewed-by: Mark Janes <[email protected]>
* egl: import platform headers from registry (v2)Marek Olšák2015-06-052-13/+25
| | | | | | | v2: don't remove local Mesa changes Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: import eglext.h from registry and cleanup eglmesaext.h (v2)Marek Olšák2015-06-052-44/+247
| | | | | | | | | v2: include mesa and chromium extensions in eglext.h so as not to break existing users v3: keep PFNEGLSWAPBUFFERSREGIONNOK because piglit uses it Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: import egl.h from registry (v2)Marek Olšák2015-06-051-294/+268
| | | | | | | v2: split the commit into 3 patches Reviewed-by: Emil Velikov <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* egl: remove remaining EGL_MESA_copy_context skeletonEmil Velikov2015-05-141-11/+0
| | | | | | | | | | With earlier commit (7a58262e58d egl: Remove skeleton implementation of EGL_MESA_screen_surface) we've removed the skeleton implementation of eglCopyContextMESA(). Just like EGL_MESA_screen_surface this extension was never implemented in mesa. Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Adam Jackson <[email protected]>
* egl: fix the EGL_MESA_image_dma_buf_export header declarationsEmil Velikov2015-05-141-0/+6
| | | | | | | | | | | | | | | Similar to other EGL extensions - guard the function prototypes by EGL_EGLEXT_PROTOTYPES as the libEGL library does (should) not provide the symbols statically. Instead users should call eglGetProcAddress, which returns the function pointer. The latter of which was missing the type declaration (typedef). Cc: Dave Airlie <[email protected]> Cc: Marc-André Lureau <[email protected]> Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Marek Olšák <[email protected]> Reviewed-by: Chad Versace <[email protected]>
* radeonsi: add new bonaire pci idAlex Deucher2015-05-121-0/+1
| | | | | | Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Alex Deucher <[email protected]> Cc: [email protected]
* egl: Remove skeleton implementation of EGL_MESA_screen_surfaceAdam Jackson2015-05-111-46/+0
| | | | | | | | No backend wires this up to anything, and the extension spec has been marked obsolete for 4+ years. Reviewed-by: Marek Olšák <[email protected]> Signed-off-by: Adam Jackson <[email protected]>
* egl: image_dma_buf_export - use KHR 64-bit typeDave Airlie2015-05-051-2/+1
| | | | | | | | After talking to Jon Leech he suggested this should be fine. update spec to the version in the registry. Signed-off-by: Dave Airlie <[email protected]>
* dri_interface: add an interface for fencesMarek Olšák2015-04-301-0/+60
|
* i965: Add marketing names for CHVVille Syrjälä2015-04-161-4/+4
| | | | | | | All CHV devices will be branded as "Intel(r) HD Graphics". Reviewed-by: Kenneth Graunke <[email protected]> Signed-off-by: Ville Syrjälä <[email protected]>
* gallium: fix gcc compile errors when using _XOPEN_SOURCE=600 but not std=c99Jose Fonseca2015-04-031-1/+6
| | | | | | The fpclassify stuff either needs std=c99 or _XOPEN_SOURCE=600 passed to gcc, but when using the latter the lrint family of function will be defined too.
* configure: nuke --with-max-{width,height}Emil Velikov2015-04-011-4/+2
| | | | | | | | | | Unused as of commit 630ab0d27ba(mesa: remove last of MAX_WIDTH, MAX_HEIGHT). Update all the remaining references to the defines. v2: Use the correct variable name in the comments Signed-off-by: Emil Velikov <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* egl: add initial EGL_MESA_image_dma_buf_export v2.4Dave Airlie2015-04-012-1/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | At the moment to get an EGL image to a dma-buf file descriptor, you have to use EGL_MESA_drm_image, and then use libdrm to convert this to a file descriptor. This extension just provides an API modelled on EGL_MESA_drm_image, to return a dma-buf file descriptor. v2: update spec for new API proposal add internal queries to get the fourcc back from intel driver. v2.1: add gallium pieces. v2.2: add offsets to spec and API, rename fd->fds, stride->strides in API. rewrite spec a bit more, add some q/a v2.3: add modifiers to query interface and 64-bit type for that (Daniel Stone) specifiy what happens to num fds vs num planes differences. (Chad Versace) v2.4: fix grammar (Daniel Stone) Signed-off-by: Dave Airlie <[email protected]>
* c99_math: Don't reimplement lrint and friends on MSVC 2013.Jose Fonseca2015-03-251-1/+2
| | | | | | | | MSVC 2013 declares these functions, both for C and C++ source files. This was caught with MSVC in analyze mode. Reviewed-by: Brian Paul <[email protected]>
* include: Ensure float.h is included for DBL_MAX.Jose Fonseca2015-03-221-0/+1
| | | | | | | I didn't actually hit the issue in practice, but just happen to notice while looking at the code. Reviewed-by: Brian Paul <[email protected]>
* c11/threads: Use PTHREAD_MUTEX_RECURSIVE by defaultFelix Janda2015-03-161-6/+1
| | | | | | | | | | | | Previously PTHREAD_MUTEX_RECURSIVE_NP had been used on linux for compatibility with old glibc. Since mesa defines __GNU_SOURCE__ on linux PTHREAD_MUTEX_RECURSIVE is also available since at least 1998. So we can unconditionally use the portable version PTHREAD_MUTEX_RECURSIVE. Cc: "10.5" <[email protected]> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=88534 Reviewed-by: Emil Velikov <[email protected]>
* mesa: move fpclassify work-arounds into c99_math.hBrian Paul2015-03-121-0/+44
| | | | | | v2: Use #error in the #else clause, per Jose. Reviewed-by: Jose Fonseca <[email protected]>
* c99_alloca.h: Also use <alloca.h> for cygwinJon TURNEY2015-03-071-1/+1
| | | | | Signed-off-by: Jon TURNEY <[email protected]> Reviewed-by: Brian Paul <[email protected]>
* include: Add helper header to help trap includes inside extern C.José Fonseca2015-03-062-0/+50
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is just to help repro and fixing these issues with any C++ compiler -- Commiting this will of course wait until all issues are addressed. $ scons src/glsl/ scons: Reading SConscript files ... Checking for GCC ... yes Checking for Clang ... no Checking for X11 (x11 xext xdamage xfixes glproto >= 1.4.13)... yes Checking for XCB (x11-xcb xcb-glx >= 1.8.1 xcb-dri2 >= 1.8)... yes Checking for XF86VIDMODE (xxf86vm)... yes Checking for DRM (libdrm >= 2.4.38)... yes Checking for UDEV (libudev >= 151)... yes warning: LLVM disabled: not building llvmpipe scons: done reading SConscript files. scons: Building targets ... scons: building associated VariantDir targets: build/linux-x86_64-debug/glsl Compiling src/glsl/ast_array_index.cpp ... Compiling src/glsl/ast_expr.cpp ... Compiling src/glsl/ast_function.cpp ... Compiling src/glsl/ast_to_hir.cpp ... Compiling src/glsl/ast_type.cpp ... Compiling src/glsl/builtin_functions.cpp ... In file included from include/c99_compat.h:28:0, from src/mapi/u_compiler.h:4, from src/mapi/u_thread.h:47, from src/mapi/glapi/glapi.h:47, from src/mesa/main/mtypes.h:42, from src/mesa/main/errors.h:47, from src/mesa/main/imports.h:41, from src/mesa/main/core.h:44, from src/glsl/builtin_functions.cpp:58: include/no_extern_c.h:48:1: error: template with C linkage template<class T> class _IncludeInsideExternCNotPortable; ^ In file included from include/c99_compat.h:28:0, from include/c11/threads.h:38, from src/mapi/u_thread.h:49, from src/mapi/glapi/glapi.h:47, from src/mesa/main/mtypes.h:42, from src/mesa/main/errors.h:47, from src/mesa/main/imports.h:41, from src/mesa/main/core.h:44, from src/glsl/builtin_functions.cpp:58: include/no_extern_c.h:48:1: error: template with C linkage template<class T> class _IncludeInsideExternCNotPortable; ^ Compiling src/glsl/builtin_types.cpp ... Compiling src/glsl/builtin_variables.cpp ... scons: *** [build/linux-x86_64-debug/glsl/builtin_functions.os] Error 1 scons: building terminated because of errors. Reviewed-by: Mark Janes <[email protected]>
* st/vega: Remove.Jose Fonseca2015-03-044-1202/+0
| | | | | | | | | | | | | OpenVG API seems to have dwindled away. The code would still be interesting if we wanted to implement NV_path_rendering but given the trend of the next gen graphics APIs, it seems unlikely that this becomes ARB or core. v2: Remove a few "openvg" references left, per Emil Velikov. Reviewed-by: Emil Velikov <[email protected]> v3: Update release notes.
* windows/gdi: Remove.Jose Fonseca2015-03-041-140/+0
| | | | | | | | | | | | This classic driver is so far behind Gallium softpipe/llvmpipe based one, that's hard to imagine ever being useful. v2: Drop drivers/windows from src/mesa/Makefile.am:EXTRA_DIST per Emil Velikov. Reviewed-by: Emil Velikov <[email protected]> v3: Update release notes.
* c99_alloca.h: add case for __sunBrian Paul2015-03-031-0/+4
| | | | Reviewed-by: Alan Coopersmith <[email protected]>
* c99_alloca.h: Include stdlib.h on all non-Windows.Vinson Lee2015-03-021-5/+1
| | | | | | | | Fix build on FreeBSD. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89364 Signed-off-by: Vinson Lee <[email protected]> Tested-by: Brian Paul <[email protected]>
* mesa: move FLT_MAX_EXP to c99_math.hBrian Paul2015-02-281-0/+4
| | | | Reviewed-by: Ian Romanick <[email protected]>
* c99_alloca.h: fix #include for MinGWBrian Paul2015-02-271-0/+4
| | | | | | | As with MSVC, include malloc.h but don't redefine alloca. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89364 Reviewed-by: José Fonseca <[email protected]>
* nir: Use alloca instead of variable length arrays.Jose Fonseca2015-02-271-0/+45
| | | | | | | | This is to enable the code to build with -Werror=vla in the short term, and enable the code to build with MSVC2013 soon after. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
* c99_math.h: add defines for M_PI, M_E, M_LOG2EBrian Paul2015-02-271-0/+13
| | | | | Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89342 Signed-off-by: Brian Paul <[email protected]>
* c99: in c99_math.h check that _USE_MATH_DEFINES is defined with MSVCBrian Paul2015-02-261-0/+5
| | | | Reviewed-by: Jose Fonseca <[email protected]>
* include,auxiliary: Remove support for MSVC older then 2008.Jose Fonseca2015-02-262-76/+6
| | | | | | | | | | MSVC 2008 (shipped with Windows SDK 7.0.7600) is the oldest we need to support. At least on llvmpipe, gallium/auxiliary, and util modules. For the remaining modules (particular all OpenGL specific code) can be built with MSVC 2013. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Emil Velikov <[email protected]>
* mesa: move signbit() macro to c99_math.hBrian Paul2015-02-241-0/+8
| | | | Reviewed-by: Matt Turner <[email protected]>
* mesa: replace LOGF, EXPF with logf, expfBrian Paul2015-02-241-0/+10
| | | | Reviewed-by: Matt Turner <[email protected]>