linux/drivers/gpu/drm/vc4
Eric Anholt 6d45c81d22 drm/vc4: Add support for branching in shader validation.
We're already checking that branch instructions are between the start
of the shader and the proper PROG_END sequence.  The other thing we
need to make branching safe is to verify that the shader doesn't read
past the end of the uniforms stream.

To do that, we require that at any basic block reading uniforms have
the following instructions:

load_imm temp, <next offset within uniform stream>
add unif_addr, temp, unif

The instructions are generated by userspace, and the kernel verifies
that the load_imm is of the expected offset, and that the add adds it
to a uniform.  We track which uniform in the stream that is, and at
draw call time fix up the uniform stream to have the address of the
start of the shader's uniforms at that location.

Signed-off-by: Eric Anholt <eric@anholt.net>
2016-07-15 15:19:50 -07:00
..
Kconfig drm/vc4: Add DPI driver 2016-04-14 12:22:53 -07:00
Makefile drm/vc4: Add DPI driver 2016-04-14 12:22:53 -07:00
vc4_bo.c drm: Remove unused drm_device from drm_gem_object_lookup() 2016-05-17 08:47:30 +02:00
vc4_crtc.c drm/vc4: Implement precise vblank timestamping. 2016-07-11 17:17:34 -07:00
vc4_debugfs.c drm/vc4: Add DPI driver 2016-04-14 12:22:53 -07:00
vc4_dpi.c drm/vc4: clean up error exit path on failed dpi_connector allocation 2016-06-06 14:28:40 -07:00
vc4_drv.c drm/vc4: Add a getparam ioctl for getting the V3D identity regs. 2016-07-14 08:08:35 -07:00
vc4_drv.h drm/vc4: Add support for branching in shader validation. 2016-07-15 15:19:50 -07:00
vc4_gem.c drm: Remove unused drm_device from drm_gem_object_lookup() 2016-05-17 08:47:30 +02:00
vc4_hdmi.c gpu: drm: vc4_hdmi: add missing of_node_put after calling of_parse_phandle 2016-07-07 18:45:11 -07:00
vc4_hvs.c drm/vc4: Add support for scaling of display planes. 2016-02-16 11:24:08 -08:00
vc4_irq.c drm/vc4: improve throughput by pipelining binning and rendering jobs 2016-03-13 17:05:05 -07:00
vc4_kms.c drm/vc4: Return -EBUSY if there's already a pending flip event. 2016-05-31 15:15:55 -07:00
vc4_packet.h drm/vc4: Add support for drawing 3D frames. 2015-12-07 20:05:10 -08:00
vc4_plane.c drm: vc4: enable XBGR8888 and ABGR8888 pixel formats 2016-07-07 18:45:07 -07:00
vc4_qpu_defines.h drm/vc4: Add support for branching in shader validation. 2016-07-15 15:19:50 -07:00
vc4_regs.h drm/vc4: Implement precise vblank timestamping. 2016-07-11 17:17:34 -07:00
vc4_render_cl.c drm/vc4: Return an ERR_PTR from BO creation instead of NULL. 2016-02-16 12:20:58 -08:00
vc4_trace_points.c drm/vc4: Add support for drawing 3D frames. 2015-12-07 20:05:10 -08:00
vc4_trace.h drm/vc4: Add support for drawing 3D frames. 2015-12-07 20:05:10 -08:00
vc4_v3d.c drm/vc4: Recognize a more specific compatible string for V3D. 2016-03-13 18:54:24 -07:00
vc4_validate_shaders.c drm/vc4: Add support for branching in shader validation. 2016-07-15 15:19:50 -07:00
vc4_validate.c drm/vc4: Add support for branching in shader validation. 2016-07-15 15:19:50 -07:00