host1x: drm: Remove overly verbose messages

These messages are relics and should never have been commited. Remove
them as they are now useless.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: gr2d: Minor cleanups

Remove some unneeded commands and drop a debugging message that's no
longer useful.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: Parameterize syncpoint increments

The previously hard-coded syncpoint IDs were only valid for L4T kernels
and don't work on upstream kernels where the syncpoint ID assignment is
dynamic.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: gr3d: Cleanup command streams

Remove unneeded SETCL opcodes since we don't switch between classes.
Also drop any syncpoint waits within the stream because they are not
necessary in our case either.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: Add test command streams

In order to test basic functioning of command submission, allow modules
to be tested with a simple command stream that just increments a
syncpoint and waits for it. If that test doesn't pass the module isn't
working properly.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: gr3d: Map attributes buffer object

The attributes buffer object is used to store per-vertex attributes such
as position and color. In order to write data to it it needs to be
mapped into the process' address space.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: gr2d: Add support for simple blits

This new function can be used to copy an area between two framebuffers.
Only 1:1 blits are supported and no color conversion takes place.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: drm: Use XBGR8888 pixel format

This seems to be the default pixel format that the gr3d engine uses to
render. Mark framebuffers as using that format so they will be correctly
scanned-out by the display controller.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
host1x: drm: Assume bottom-up layout for framebuffers

The gr3d engine renders bottom-up, so for now assume that all buffrs are
laid out that way so that the display controller can display them
properly.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
tests: host1x: gr2d-clear: Add on-screen display support

If the host1x backend supports on-screen display of framebuffers, prefer
that over writing out a PNG file.

Signed-off-by: Thierry Reding <thierry@gilfi.de>
tests: host1x: gr3d-triangle: Add new test program

This test program uses the gr3d engine to render a 3-color smooth shaded
triangle. It also performs a blit of the rendered triangle into a second
framebuffer to demonstrate the new gr2d blit functionality.

Signed-off-by: Thierry Reding <thierry@gilfi.de>