summaryrefslogtreecommitdiff
AgeCommit message (Collapse)AuthorFilesLines
2016-07-06WIP working \o/staging/workThierry Reding9-38/+117
2016-07-04tegra: Make more completeThierry Reding6-376/+1334
Signed-off-by: Thierry Reding <thierry.reding@gmail.com>
2016-07-04WIPThierry Reding3-0/+8
2016-07-04fixupsThierry Reding4-16/+23
2016-07-04WIPThierry Reding4-37/+22
2016-07-04Revert "gallium/tegra: Use libdrm_tegra API"Thierry Reding4-37/+10
This reverts commit 6a9da427578503d8df92f91d1dedf6fd3099ba98.
2016-07-04gallium/tegra: Use libdrm_tegra APIThierry Reding4-10/+37
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-07-04Merge branch 'staging/tegra' into staging/masterstaging/masterThierry Reding21-1/+2060
2016-07-04Merge branch 'staging/fixes' into staging/masterThierry Reding1-1/+3
2016-07-04gallium/tegra: Add debugging messagesstaging/tegraThierry Reding4-25/+411
Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-07-04Disable shared pipe drivers againThierry Reding1-1/+1
This is a partial revert of commit "WIP: tegra: Add pipe loader" because for some yet unknown reason the driver won't load properly with shared pipe drivers enabled. Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-07-04WIP: tegra: Add pipe loaderThierry Reding3-1/+58
This doesn't currently work for unknown reasons. I'll get back to this when it becomes more relevant. Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-07-04tegra: Initial supportThierry Reding19-1/+1617
Tegra K1 and later use a GPU that can be driven by the Nouveau driver. But the GPU is a pure render node and has no display engine, hence the scanout needs to happen on the Tegra display hardware. The GPU and the display engine each have a separate DRM device node exposed by the kernel. To make the setup appear as a single device, this driver instantiates a Nouveau screen with each instance of a Tegra screen and forwards GPU requests to the Nouveau screen. For purposes of scanout it will import buffers created on the GPU into the display driver. Handles that userspace requests are those of the display driver so that they can be used to create framebuffers. This has been tested with some GBM test programs, as well as kmscube and weston. All of those run without modifications, but I'm sure there is a lot that can be improved. TODO: - use Nouveau headers to get at the prototype for creating a screen - implement enough support to seamlessly integrate with X - refactor some of the code to be reusable by other drivers Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-07-04kms-swrast: Fix build warningstaging/fixesThierry Reding1-1/+3
drmPrimeHandleToFD() takes a pointer to an int as the last argument. Passing in a pointer to an unsigned int (winsys_handle.handle) causes the compiler to warn about mismatched signedness. Signed-off-by: Thierry Reding <treding@nvidia.com>
2016-07-04i965/blorp: Prepare for more than two vertex attributesstaging/nouveaustaging/baseTopi Pohjolainen4-3/+22
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965/blorp: Tell vertex fetcher about flat inputsTopi Pohjolainen2-8/+30
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965/blorp: Add support for flat input bufferTopi Pohjolainen1-3/+65
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965/blorp: Store input read maskTopi Pohjolainen2-0/+2
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965/blorp: Rename push constants to inputsTopi Pohjolainen5-22/+22
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965/blorp: Use core vertex buffer state setupTopi Pohjolainen1-48/+14
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965/blorp: Split vertex data and element setupTopi Pohjolainen1-21/+25
Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965: Unify vertex buffer setupTopi Pohjolainen2-29/+46
On gen >= 8 one doesn't provide ending address but number of bytes available. This is relative to the given offset. Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-04i965/draw: Expose vertex buffer state setupTopi Pohjolainen2-18/+37
Also change the interface to use start and end offsets. Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net>
2016-07-03freedreno: fix crash on smaller gpus and higher resolutionsRob Clark1-1/+1
Devices with smaller GMEM size need more tiles. On db410c at 2048x1152, glmark2 shadow needed ~330 tiles for fullscreen. Lets bump it up to 512. (Maybe with MRT you could end up needing more, but at that point things are probably going to be painfully slow.) Signed-off-by: Rob Clark <robdclark@gmail.com>
2016-07-02i965: don't drop const initializers in vector splittingRob Clark1-0/+12
Signed-off-by: Rob Clark <robclark@freedesktop.org> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-07-02glsl: add driconf to zero-init unintialized varsRob Clark11-1/+34
Some games are sloppy.. perhaps because it is defined behavior for DX or perhaps because nv blob driver defaults things to zero. So add driconf param to force uninitialized variables to default to zero. This issue was observed with rust, from steam store. But has surfaced elsewhere in the past. Signed-off-by: Rob Clark <robclark@freedesktop.org> Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
2016-07-02freedreno/ir3: support glsl linking for cmdline compilerRob Clark1-24/+47
For .vert/.frag, now multiple can be specified on the cmdline for purposes of linking, and the last one specified is the one that is fed into the ir3 backend (and dumped along the way if --verbose is specified) Without this, varyings in frag shaders would appear as undefined. Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-02glsl/standalone: initialize MaxUserAssignableUniformLocationsRob Clark1-0/+4
Signed-off-by: Rob Clark <robclark@freedesktop.org>
2016-07-02freedreno: update valid_buffer_range for SO buffersRob Clark1-0/+5
Signed-off-by: Rob Clark <robdclark@gmail.com>
2016-07-02freedreno/ir3: support non-user_buffer constsRob Clark2-3/+5
Signed-off-by: Rob Clark <robdclark@gmail.com>
2016-07-02freedreno/a2xx: move setup/restore cmds into binning passRob Clark4-9/+4
Rather than doing a separate submit at context create, move these cmds to before first tile, as is done on a3xx/a4xx. Otherwise state can be overwritten by other contexts. Signed-off-by: Rob Clark <robdclark@gmail.com>
2016-07-02freedreno: pass index buffer as a pipe_resourceRob Clark2-16/+16
This will be useful in a following patch. Signed-off-by: Rob Clark <robdclark@gmail.com>
2016-07-02freedreno: switch emit_const_bo() to take prsc'sRob Clark4-17/+18
We can push the unwrap of pipe_resource down. Signed-off-by: Rob Clark <robdclark@gmail.com>
2016-07-02nv30: Fix "array subscript is below array bounds" compiler warningHans de Goede1-2/+1
gcc6 does not like the trick where we point to one entry before the array start and then start a while with a pre-increment. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-07-02nouveau: Fix a couple of "foo may be used uninitialized' compiler warningsHans de Goede2-3/+3
These are all new false positives with gcc6. In nouveau_compiler.c: gcc6 no longer assumes that passing a pointer to a variable into a function initialises that variable. In nv50_ir_from_tgsi.cpp op and mode are not set if there are 0 enabled dst channels, this never happens, but gcc cannot know this. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Acked-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-07-02nouveau: Fix gcc6 / c++11 auto_ptr deprecation compiler warningsHans de Goede1-0/+4
Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2016-07-02nouveau: Add support for SV_WORK_DIMHans de Goede8-12/+29
Add support for SV_WORK_DIM for nvc0 and nve4. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2016-07-02nvc0: Make NVC0_CB_AUX_GRID_INFO take an index argumentHans de Goede3-4/+4
This brings it inline with the other macros like NVC0_CB_AUX_UBO_INFO and NVC0_CB_AUX_TEX_INFO. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2016-07-02clover: Pass work_dim parameter of clEnqueueNDRangeKernel() to driverHans de Goede2-0/+8
In order to implement get_work_dim() the driver may need to know the clEnqueueNDRangeKernel() work_dim parameter, so pass it to the driver. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2016-07-02tgsi: Add WORK_DIM System ValueHans de Goede3-0/+10
Add a new WORK_DIM SV type, this is will return the grid dimensions (1-4) for compute (opencl) kernels. This is necessary to implement the opencl get_work_dim() function. Signed-off-by: Hans de Goede <hdegoede@redhat.com> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
2016-07-02mesa/main: fix error checking logic on CopyImageSubDataAlejandro Piñeiro1-5/+10
For the case (both src or dst) where we had a texobject, but the texobject target was not the same that the method target, this spec paragraph was appplied: /* Section 18.3.2 (Copying Between Images) of the OpenGL 4.5 Core * Profile spec says: * * "An INVALID_VALUE error is generated if either name does not * correspond to a valid renderbuffer or texture object according * to the corresponding target parameter." */ But for that case, the correct spec paragraph should be: /* Section 18.3.2 (Copying Between Images) of the OpenGL 4.5 Core * Profile spec says: * * "An INVALID_ENUM error is generated if either target is * not RENDERBUFFER or a valid non-proxy texture target; * is TEXTURE_BUFFER or one of the cubemap face selectors * described in table 8.18; or if the target does not * match the type of the object." */ specifically the last sentence: "or if the target does not match the type of the object". This patch fixes the error returned (s/INVALID/ENUM) for that case, and moves up the INVALID_VALUE spec paragraph, as that case (invalid texture object) was handled before. Fixes: GL44-CTS.copy_image.target_miss_match Reviewed-by: Nicolai Hähnle <nicolai.haehnle@amd.com>
2016-07-02st/glsl_to_tgsi: don't increase immediate index by 1.Dave Airlie1-1/+1
Immediates are stored into a separate table, and are consolidated, so if we get an immediate we don't need to offset it as the index it has is correct. Cc: "11.2 12.0" <mesa-stable@lists.freedesktop.org> Signed-off-by: Dave Airlie <airlied@redhat.com>
2016-07-01st/mesa: get max supported number of image samples from driverIlia Mirkin1-1/+5
Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu> Reviewed-by: Marek Olšák <marek.olsak@amd.com>
2016-07-01nvc0: fix up image support for allowing multiple samplesIlia Mirkin7-49/+108
Basically we just have to scale up the coordinates and then add the relevant sample offset. The code to handle this was already largely present from Christoph's earlier attempts to pipe images through back in the dark ages, this just hooks it all up. Signed-off-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-07-01st/mesa: check the texture image level in st_texture_match_imageNicolai Hähnle1-0/+3
Otherwise, 1x1 images of arbitrarily high level are accepted. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96639#add_comment Cc: 11.2 12.0 <mesa-stable@lists.freedesktop.org> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-07-01st/mesa: an incomplete texture may have a zero-size first imageNicolai Hähnle1-0/+3
Fixes a regression introduced by commit 42624ea83 which triggered an assertion in dEQP-GLES2.functional.texture.completeness.cube.not_positive_level_0 While stImage must have a non-zero size as verified by the caller, we also look at the size of the base image in an attempt to make a better guess at the level0 size (this is important when the base image size is odd). However, the base image may have a zero size even when it exists. Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96629 Cc: 12.0 <mesa-stable@lists.freedesktop.org> Reviewed-by: Ilia Mirkin <imirkin@alum.mit.edu>
2016-07-01st/vdpau: use bicubic filter for scaling(v6.1)Nayan Deshmukh3-14/+106
use bicubic filtering as high quality scaling L1. v2: fix a typo and add a newline to code v3: -render the unscaled image on a temporary surface (Christian) -apply noise reduction and sharpness filter on unscaled surface -render the final scaled surface using bicubic interpolation v4: support high quality scaling v5: set dst_area and dst_clip in bicubic filter v6: set buffer layer before setting dst_area v6.1: add PIPE_BIND_LINEAR when creating resource Signed-off-by: Nayan Deshmukh <nayan26deshmukh@gmail.com> Reviewed-by: Christian König <christian.koenig@amd.com>
2016-07-01vl: add a bicubic interpolation filter(v5)Nayan Deshmukh3-0/+528
This is a shader based bicubic interpolater which uses cubic Hermite spline algorithm. v2: set dst_area and dst_clip during scaling (Christian) v3: clear the render target before rendering v4: intialize offsets while initializing shaders use a constant buffer to send dst_size to frag shader small changes to reduce calculation in shader v5: send half pixel offset instead of sending dst_size Signed-off-by: Nayan Deshmukh <nayan26deshmukh@gmail.com> Reviewed-by: Christian König <christian.koenig@amd.com>
2016-07-01mesa/st: Use 'struct nir_shader' instead of 'nir_shader'.Vinson Lee1-6/+6
Fix this build error with GCC 4.4. CC state_tracker/st_nir_lower_builtin.lo In file included from state_tracker/st_nir_lower_builtin.c:61: state_tracker/st_nir.h:34: error: redefinition of typedef ‘nir_shader’ ../../src/compiler/nir/nir.h:1830: note: previous declaration of ‘nir_shader’ was here Suggested-by: Rob Clark <robdclark@gmail.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=96235 Signed-off-by: Vinson Lee <vlee@freedesktop.org> Reviewed-by: Jason Ekstrand <jason@jlekstrand.net> Reviewed-by: Rob Clark <robdclark@gmail.com>
2016-07-01docs: update MESA_DEBUG envvar documentation.Alejandro Piñeiro1-2/+11
silent, flush, incomplete_tex and incomplete_fbo flags were not documented (see src/mesa/main.debug.c for more info). FP is not checked anymore. v2 (Brian Paul): * MESA_DEBUG accepts a comma-separated list of parameters. * Clarify how MESA_DEBUG behaves with mesa debug and release builds. * Updated wording. v3: Better wording for one paragraph (Brian Paul) Reviewed-by: Brian Paul <brianp@vmware.com>