<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel.git/drivers/gpu/drm/virtio/virtgpu_drv.h, branch linux-5.14.y</title>
<subtitle>Hosts the 0x221E linux distro kernel.
</subtitle>
<id>https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.14.y</id>
<link rel='self' href='https://git.0xinfinity.dev/distro/kernel.git/atom?h=linux-5.14.y'/>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/'/>
<updated>2020-12-02T10:48:14Z</updated>
<entry>
<title>drm/virtio: consider dma-fence context when signaling</title>
<updated>2020-12-02T10:48:14Z</updated>
<author>
<name>Gurchetan Singh</name>
</author>
<published>2020-12-01T02:16:23Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=36549848ed27c22bb2ffd5d1468efc6505b05f97'/>
<id>urn:sha1:36549848ed27c22bb2ffd5d1468efc6505b05f97</id>
<content type='text'>
This an incremental refactor towards multiple dma-fence contexts
in virtio-gpu.  Since all fences are still allocated using
&amp;virtio_gpu_fence_driver.context, nothing should break and every
processed fence will be signaled.

The overall idea is every 3D context can allocate a number of
dma-fence contexts.  Each dma-fence context refers to it's own
timeline.

For example, consider the following case where virgl submits
commands to the GPU (fence ids 1, 3) and does a metadata query with
the CPU (fence id 5).  In a different process, gfxstream submits
commands to the GPU (fence ids 2, 4).

fence_id (&amp;dma_fence.seqno)       | 1 2 3 4 5
----------------------------------|-----------
fence_ctx 0 (virgl gpu)           | 1   3
fence_ctx 1 (virgl metadata query)|         5
fence_ctx 2 (gfxstream gpu)       |   2   4

With multiple fence contexts, we can wait for the metadata query
to finish without waiting for the virgl gpu to finish.  virgl gpu
does not have to wait for gfxstream gpu.  The fence id still is the
monotonically increasing sequence number, but it's only revelant to
the specific dma-fence context.

To fully enable this feature, we'll need to:
  - have each 3d context allocate a number of fence contexts. Not
    too hard with explicit context initialization on the horizon.
  - have guest userspace specify fence context when performing
    ioctls.
  - tag each fence emitted to the host with the fence context
    information.  virtio_gpu_ctrl_hdr has padding + flags available,
    so that should be easy.

This change goes in the direction specified above, by:
  - looking up the virtgpu_fence given a fence_id
  - signalling all prior fences in a given context
  - signalling current fence

v2: fix grammar in comment
v3: add r-b tags

Reviewed-by: Anthoine Bourgeois &lt;anthoine.bourgeois@gmail.com&gt;
Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20201201021623.619-3-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/virtio: rename sync_seq and last_seq</title>
<updated>2020-11-20T09:44:41Z</updated>
<author>
<name>Gurchetan Singh</name>
</author>
<published>2020-11-19T01:08:09Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=65f8453dc69159fd499e0c5b7fafbba771a1dfe2'/>
<id>urn:sha1:65f8453dc69159fd499e0c5b7fafbba771a1dfe2</id>
<content type='text'>
To be clearer about our intentions to associate sequence numbers
and fence IDs, let's rename these variables.

Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Reviewed-by: Anthoine Bourgeois &lt;anthoine.bourgeois@gmail.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20201119010809.528-5-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/virtio: use fence_id when processing fences</title>
<updated>2020-11-20T09:44:41Z</updated>
<author>
<name>Gurchetan Singh</name>
</author>
<published>2020-11-19T01:08:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=bb53a604a74b38e6d71ae12174c8c1d229c2e2b1'/>
<id>urn:sha1:bb53a604a74b38e6d71ae12174c8c1d229c2e2b1</id>
<content type='text'>
Currently, the fence ID, which can be used to identify a
virtgpu fence, is the same as the fence sequence number.

Let's use the fence_id name to clearly signal this.

Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Reviewed-by: Anthoine Bourgeois &lt;anthoine.bourgeois@gmail.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20201119010809.528-4-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/virtio: fix a file name comment reference</title>
<updated>2020-11-20T09:44:41Z</updated>
<author>
<name>Anthoine Bourgeois</name>
</author>
<published>2020-11-19T01:08:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=7efb5f38ac9e9694128e03e949139c78b7829e01'/>
<id>urn:sha1:7efb5f38ac9e9694128e03e949139c78b7829e01</id>
<content type='text'>
Easier to find where declarations are implemented.

Signed-off-by: Anthoine Bourgeois &lt;anthoine.bourgeois@gmail.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20201119010809.528-2-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/virtio: implement blob resources: resource create blob ioctl</title>
<updated>2020-09-29T09:23:51Z</updated>
<author>
<name>Gerd Hoffmann</name>
</author>
<published>2020-09-24T00:32:13Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=897b4d1acaf56314652c6a8e75d9f86b5e45638d'/>
<id>urn:sha1:897b4d1acaf56314652c6a8e75d9f86b5e45638d</id>
<content type='text'>
Implement resource create blob as specified.

Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
Acked-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20200924003214.662-18-gurchetansingh@chromium.org
Co-developed-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
</content>
</entry>
<entry>
<title>drm/virtio: implement blob resources: fix stride discrepancy</title>
<updated>2020-09-29T09:23:47Z</updated>
<author>
<name>Gurchetan Singh</name>
</author>
<published>2020-09-24T00:32:11Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=50c3d1938ee380e2d24714ea7058d2d3fc2662de'/>
<id>urn:sha1:50c3d1938ee380e2d24714ea7058d2d3fc2662de</id>
<content type='text'>
The old transfer ioctls may work on blob resources, and there is no
TRANSFER_BLOB hypercall now for simplicity.

The guest may have a image view on the blob resources such that the
stride is not equal to width * bytes_per_pixel.

For host-only blobs, we can repurpose the transfer ioctls to synchronize
caches as well.  For guest-only blobs, these operations are undefined
for now so leave them out.

Also, with seamless Wayland integration between guest/host looking
increasingly attractive, it also makes sense to keep track of
one value for stride.

Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Acked-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20200924003214.662-16-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/virtio: implement blob resources: refactor UUID code somewhat</title>
<updated>2020-09-29T09:23:45Z</updated>
<author>
<name>Gurchetan Singh</name>
</author>
<published>2020-09-24T00:32:10Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=1e2554f49e41d3f6509c6a633e5e4dd48d93ffb9'/>
<id>urn:sha1:1e2554f49e41d3f6509c6a633e5e4dd48d93ffb9</id>
<content type='text'>
For upcoming blob resources, userspace can specify that the
resource will be used for cross-device sharing. This is mainly
for exportable blobs that will only shared with the virtgpu
display but not across devices.

Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Acked-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20200924003214.662-15-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/virtio: implement blob resources: hypercall interface</title>
<updated>2020-09-29T09:23:40Z</updated>
<author>
<name>Gurchetan Singh</name>
</author>
<published>2020-09-24T00:32:08Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=c7a6ac4f60bc54a0a45de76a3a258685024c9293'/>
<id>urn:sha1:c7a6ac4f60bc54a0a45de76a3a258685024c9293</id>
<content type='text'>
This implements the blob hypercall interface.

Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Acked-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20200924003214.662-13-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
<entry>
<title>drm/virtio: implement blob resources: implement vram object</title>
<updated>2020-09-29T09:23:33Z</updated>
<author>
<name>Gerd Hoffmann</name>
</author>
<published>2020-09-24T00:32:07Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=16845c5d540929d2f4dc845f11fbbb238e69170a'/>
<id>urn:sha1:16845c5d540929d2f4dc845f11fbbb238e69170a</id>
<content type='text'>
A virtio-gpu vram object is based on range-based allocation.
No guest shmemfs backing, so we call drm_gem_private_object_init.

This is for host memory without any guest backing (atleast initially).

Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
Acked-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20200924003214.662-12-gurchetansingh@chromium.org
Co-developed-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
</content>
</entry>
<entry>
<title>drm/virtio: implement blob resources: add new fields to internal structs</title>
<updated>2020-09-29T09:23:31Z</updated>
<author>
<name>Gurchetan Singh</name>
</author>
<published>2020-09-24T00:32:06Z</published>
<link rel='alternate' type='text/html' href='https://git.0xinfinity.dev/distro/kernel.git/commit/?id=5c824604e5601a7150e434931243ee9e820fb473'/>
<id>urn:sha1:5c824604e5601a7150e434931243ee9e820fb473</id>
<content type='text'>
Useful for upcoming blob resources.

Signed-off-by: Gurchetan Singh &lt;gurchetansingh@chromium.org&gt;
Acked-by: Tomeu Vizoso &lt;tomeu.vizoso@collabora.com&gt;
Link: http://patchwork.freedesktop.org/patch/msgid/20200924003214.662-11-gurchetansingh@chromium.org
Signed-off-by: Gerd Hoffmann &lt;kraxel@redhat.com&gt;
</content>
</entry>
</feed>
