<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/drivers/gpu/drm/vc4/vc4_v3d.c, branch linux-4.17.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.</subtitle>
<id>https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-4.17.y</id>
<link rel='self' href='https://universe.0xinfinity.dev/distro/kernel/atom?h=linux-4.17.y'/>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/'/>
<updated>2018-02-10T22:23:26Z</updated>
<entry>
<title>drm/vc4: Expose performance counters to userspace</title>
<updated>2018-02-10T22:23:26Z</updated>
<author>
<name>Boris Brezillon</name>
<email>boris.brezillon@free-electrons.com</email>
</author>
<published>2018-01-12T09:09:26Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=65101d8c9108201118efa7e08f4e2c57f438deb9'/>
<id>urn:sha1:65101d8c9108201118efa7e08f4e2c57f438deb9</id>
<content type='text'>
The V3D engine has various hardware counters which might be interesting
to userspace performance analysis tools.

Expose new ioctls to create/destroy a performance monitor object and
query the counter values of this perfmance monitor.

Note that a perfomance monitor is given an ID that is only valid on the
file descriptor it has been allocated from. A performance monitor can be
attached to a CL submission and the driver will enable HW counters for
this request and update the performance monitor values at the end of the
job.

Signed-off-by: Boris Brezillon &lt;boris.brezillon@free-electrons.com&gt;
Reviewed-by: Eric Anholt &lt;eric@anholt.net&gt;
Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20180112090926.12538-1-boris.brezillon@free-electrons.com
</content>
</entry>
<entry>
<title>drm/vc4: Move IRQ enable to PM path</title>
<updated>2018-01-03T23:56:03Z</updated>
<author>
<name>Stefan Schake</name>
<email>stschake@gmail.com</email>
</author>
<published>2017-12-29T16:05:43Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=ce9caf2f79a5aa170a4b6456a03db639eed9c988'/>
<id>urn:sha1:ce9caf2f79a5aa170a4b6456a03db639eed9c988</id>
<content type='text'>
We were calling enable_irq on bind, where it was already enabled previously
by the IRQ helper. Additionally, dev-&gt;irq is not set correctly until after
postinstall and so was always zero here, triggering a warning in 4.15.
Fix both by moving the enable to the power management resume path, where we
know there was a previous disable invocation during suspend.

Fixes: 253696ccd613 ("drm/vc4: Account for interrupts in flight")
Signed-off-by: Stefan Schake &lt;stschake@gmail.com&gt;
Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/1514563543-32511-1-git-send-email-stschake@gmail.com
Tested-by: Stefan Wahren &lt;stefan.wahren@i2se.com&gt;
Reviewed-by: Eric Anholt &lt;eric@anholt.net&gt;
</content>
</entry>
<entry>
<title>drm/vc4: Add an ioctl for labeling GEM BOs for summary stats</title>
<updated>2017-07-28T23:04:53Z</updated>
<author>
<name>Eric Anholt</name>
<email>eric@anholt.net</email>
</author>
<published>2017-07-25T18:27:17Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=f30994622b2bf8e4fa224237ac65304b27a9cb6a'/>
<id>urn:sha1:f30994622b2bf8e4fa224237ac65304b27a9cb6a</id>
<content type='text'>
This has proven immensely useful for debugging memory leaks and
overallocation (which is a rather serious concern on the platform,
given that we typically run at about 256MB of CMA out of up to 1GB
total memory, with framebuffers that are about 8MB ecah).

The state of the art without this is to dump debug logs from every GL
application, guess as to kernel allocations based on bo_stats, and try
to merge that all together into a global picture of memory allocation
state.  With this, you can add a couple of calls to the debug build of
the 3D driver and get a pretty detailed view of GPU memory usage from
/debug/dri/0/bo_stats (or when we debug print to dmesg on allocation
failure).

The Mesa side currently labels at the gallium resource level (so you
see that a 1920x20 pixmap has been created, presumably for the window
system panel), but we could extend that to be even more useful with
glObjectLabel() names being sent all the way down to the kernel.

(partial) example of sorted debugfs output with Mesa labeling all
resources:

               kernel BO cache:  16392kb BOs (3)
       tiling shadow 1920x1080:   8160kb BOs (1)
       resource 1920x1080@32/0:   8160kb BOs (1)
scanout resource 1920x1080@32/0:   8100kb BOs (1)
                        kernel:   8100kb BOs (1)

v2: Use strndup_user(), use lockdep assertion instead of just a
    comment, fix an array[-1] reference, extend comment about name
    freeing.

Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Link: https://patchwork.freedesktop.org/patch/msgid/20170725182718.31468-2-eric@anholt.net
Reviewed-by: Chris Wilson &lt;chris@chris-wilson.co.uk&gt;
</content>
</entry>
<entry>
<title>drm/vc4: Mark the device as active when enabling runtime PM.</title>
<updated>2017-06-02T20:00:47Z</updated>
<author>
<name>Eric Anholt</name>
<email>eric@anholt.net</email>
</author>
<published>2017-05-15T17:16:15Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=7f696942a7e52df2a99410bf23da513f9aad04fb'/>
<id>urn:sha1:7f696942a7e52df2a99410bf23da513f9aad04fb</id>
<content type='text'>
Failing to do so meant that we got a resume() callback on first use of
the device, so we would leak the bin BO that we allocated during
probe.

Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Fixes: 553c942f8b2c ("drm/vc4: Allow using more than 256MB of CMA memory.")
Link: http://patchwork.freedesktop.org/patch/msgid/20170515171615.10168-1-eric@anholt.net
Reviewed-by: Boris Brezillon &lt;boris.brezillon@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>drm/vc4: fix include notation and remove -Iinclude/drm flag</title>
<updated>2017-05-22T07:36:01Z</updated>
<author>
<name>Masahiro Yamada</name>
<email>yamada.masahiro@socionext.com</email>
</author>
<published>2017-05-18T04:29:38Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=b7e8e25b37618070c444083bfb1aedf3317b2a96'/>
<id>urn:sha1:b7e8e25b37618070c444083bfb1aedf3317b2a96</id>
<content type='text'>
Include &lt;drm/*.h&gt; instead of relative path from include/drm, then
remove the -Iinclude/drm compiler flag.

While we are here, use &lt;...&gt; instead of "..." for include/linux/*.h
and include/sound/*.h headers too.

Signed-off-by: Masahiro Yamada &lt;yamada.masahiro@socionext.com&gt;
Signed-off-by: Daniel Vetter &lt;daniel.vetter@ffwll.ch&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/1495081793-9707-2-git-send-email-yamada.masahiro@socionext.com
</content>
</entry>
<entry>
<title>drm/vc4: Add specific compatible strings for Cygnus.</title>
<updated>2017-05-08T19:24:06Z</updated>
<author>
<name>Eric Anholt</name>
<email>eric@anholt.net</email>
</author>
<published>2017-04-28T22:42:23Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=b3f7787b4687b1292e6ac9a3308002adfd9bd394'/>
<id>urn:sha1:b3f7787b4687b1292e6ac9a3308002adfd9bd394</id>
<content type='text'>
Cygnus has V3D 2.6 instead of 2.1, and doesn't use the VC4 display
modules.  The V3D can be uniquely identified by the IDENT[01]
registers, and there's nothing to key off of for the display change
other than the lack of DT nodes for the display components, but it's
convention to have new compatible strings anyway.

Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Acked-by: Rob Herring &lt;robh@kernel.org&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20170428224223.21904-3-eric@anholt.net
</content>
</entry>
<entry>
<title>drm/vc4: Turn the V3D clock on at runtime.</title>
<updated>2017-05-08T19:24:06Z</updated>
<author>
<name>Eric Anholt</name>
<email>eric@anholt.net</email>
</author>
<published>2017-04-28T22:42:21Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=b72a2816e3711474f7a85dee0565dd68eeea2f58'/>
<id>urn:sha1:b72a2816e3711474f7a85dee0565dd68eeea2f58</id>
<content type='text'>
For the Raspberry Pi's bindings, the power domain also implicitly
turns on the clock and deasserts reset, but for the new Cygnus port we
start representing the clock in the devicetree.

v2: Document the clock-names property, check for -ENOENT for no clock
    in DT.
v3: Drop NULL checks around clk calls which embed NULL checks.
v4: Drop clk-names (feedback by Rob Herring)

Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Acked-by: Rob Herring &lt;robh@kernel.org&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20170428224223.21904-1-eric@anholt.net
</content>
</entry>
<entry>
<title>drm/vc4: Allow using more than 256MB of CMA memory.</title>
<updated>2017-04-18T21:32:20Z</updated>
<author>
<name>Eric Anholt</name>
<email>eric@anholt.net</email>
</author>
<published>2017-03-27T23:10:25Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=553c942f8b2cbc7394b4d4fa2f848b23a8f07451'/>
<id>urn:sha1:553c942f8b2cbc7394b4d4fa2f848b23a8f07451</id>
<content type='text'>
Until now, we've had to limit Raspberry Pi to 256MB of CMA memory to
keep from triggering the hardware addressing bug between the tile
binner and the tile alloc memory (where the top 4 bits come from the
tile state data array's address).

To work around that and allow more memory to be reserved for graphics,
allocate a single BO to store tile state data arrays and tile
alloc/overflow memory while the GPU is active, and make sure that that
one BO doesn't happen to cross a 256MB boundary.  With that in place,
we can allocate textures and shaders anywhere in system memory (still
contiguous, of course).

Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20170327231025.19391-1-eric@anholt.net
Reviewed-by: Boris Brezillon &lt;boris.brezillon@free-electrons.com&gt;
</content>
</entry>
<entry>
<title>drm/vc4: Use runtime autosuspend to avoid thrashing V3D power state.</title>
<updated>2016-11-04T23:12:35Z</updated>
<author>
<name>Eric Anholt</name>
<email>eric@anholt.net</email>
</author>
<published>2016-11-04T22:58:38Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=3a62234680d86efa0239665ed8a0e908f1aef147'/>
<id>urn:sha1:3a62234680d86efa0239665ed8a0e908f1aef147</id>
<content type='text'>
The pm_runtime_put() we were using immediately released power on the
device, which meant that we were generally turning the device off and
on once per frame.  In many profiles I've looked at, that added up to
about 1% of CPU time, but this could get worse in the case of frequent
rendering and readback (as may happen in X rendering).  By keeping the
device on until we've been idle for a couple of frames, we drop the
overhead of runtime PM down to sub-.1%.

Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
</content>
</entry>
<entry>
<title>drm/vc4: Recognize a more specific compatible string for V3D.</title>
<updated>2016-03-14T01:54:24Z</updated>
<author>
<name>Eric Anholt</name>
<email>eric@anholt.net</email>
</author>
<published>2016-03-04T20:32:07Z</published>
<link rel='alternate' type='text/html' href='https://universe.0xinfinity.dev/distro/kernel/commit/?id=90d7116061f86c1f8ea460806a0414addea7b58b'/>
<id>urn:sha1:90d7116061f86c1f8ea460806a0414addea7b58b</id>
<content type='text'>
The Raspberry Pi Foundation's firmware updates are shipping device
trees using the old string, so we'll keep recognizing that as this rev
of V3D.  Still, we should use a more specific name in the upstream DT
to clarify which board is being supported, in case we do other revs of
V3D in the future.

Signed-off-by: Eric Anholt &lt;eric@anholt.net&gt;
Acked-by: Stephen Warren &lt;swarren@wwwdotorg.org&gt;
</content>
</entry>
</feed>
