Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-15 Thread Tomasz Figa
On Tue, Jan 14, 2020 at 7:35 PM Dmitry Sepp wrote: > > Hi Keiichi, > > thank you for the update. > > On Dienstag, 14. Januar 2020 08:18:50 CET Keiichi Watanabe wrote: > > Hi, > > > > On Thu, Jan 9, 2020 at 11:21 PM Tomasz Figa wrote: > > > On Wed, Jan 8, 2020 at 10:52 PM Keiichi Watanabe > wrote

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-14 Thread Keiichi Watanabe
Hi, On Tue, Jan 14, 2020 at 7:35 PM Dmitry Sepp wrote: > > Hi Keiichi, > > thank you for the update. > > On Dienstag, 14. Januar 2020 08:18:50 CET Keiichi Watanabe wrote: > > Hi, > > > > On Thu, Jan 9, 2020 at 11:21 PM Tomasz Figa wrote: > > > On Wed, Jan 8, 2020 at 10:52 PM Keiichi Watanabe >

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-14 Thread Dmitry Sepp
Hi Keiichi, thank you for the update. On Dienstag, 14. Januar 2020 08:18:50 CET Keiichi Watanabe wrote: > Hi, > > On Thu, Jan 9, 2020 at 11:21 PM Tomasz Figa wrote: > > On Wed, Jan 8, 2020 at 10:52 PM Keiichi Watanabe wrote: > > > Hi Gerd, > > > > > > On Thu, Dec 19, 2019 at 10:12 PM Gerd Ho

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-13 Thread Keiichi Watanabe
Hi, On Thu, Jan 9, 2020 at 11:21 PM Tomasz Figa wrote: > > On Wed, Jan 8, 2020 at 10:52 PM Keiichi Watanabe > wrote: > > > > Hi Gerd, > > > > On Thu, Dec 19, 2019 at 10:12 PM Gerd Hoffmann wrote: > > > > > > Hi, > > > > > > > > However that still doesn't let the driver know which buffers wil

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-09 Thread Tomasz Figa
On Wed, Jan 8, 2020 at 10:52 PM Keiichi Watanabe wrote: > > Hi Gerd, > > On Thu, Dec 19, 2019 at 10:12 PM Gerd Hoffmann wrote: > > > > Hi, > > > > > > However that still doesn't let the driver know which buffers will be > > > > dequeued when. A simple example of this scenario is when the guest

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-09 Thread Gerd Hoffmann
Hi, > Regarding re-using, the driver can simply re-queue buffers returned by > the device. If the device needs a buffer as reference frame, it must > not return the buffer. Ok, that'll work. > I'll describe this rule in the next version of the patch. Good. You should also add a note about or

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Keiichi Watanabe
Hi Gerd, On Thu, Dec 19, 2019 at 10:12 PM Gerd Hoffmann wrote: > > Hi, > > > > However that still doesn't let the driver know which buffers will be > > > dequeued when. A simple example of this scenario is when the guest is > > > done displaying a frame and requeues the buffer back to the decod

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Keiichi Watanabe
Hi Gerd, Thank you so much for the review. I'm sorry for not replying earlier. On Thu, Dec 19, 2019 at 10:02 PM Gerd Hoffmann wrote: > > Hi, > > > > Not clearly defined in the spec: When is the decoder supposed to send > > > the response for a queue request? When it finished decoding (i.e. fr

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Keiichi Watanabe
On Wed, Jan 8, 2020 at 10:11 PM Dmitry Sepp wrote: > > Hi Tomasz, Keiichi, > > On Mittwoch, 8. Januar 2020 13:46:25 CET Tomasz Figa wrote: > > On Wed, Jan 8, 2020 at 9:15 PM Keiichi Watanabe > wrote: > > > Hi Dmitry, > > > > > > On Wed, Jan 8, 2020 at 7:00 PM Dmitry Sepp > wrote: > > > > Hi Keii

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Dmitry Sepp
Hi Tomasz, Keiichi, On Mittwoch, 8. Januar 2020 13:46:25 CET Tomasz Figa wrote: > On Wed, Jan 8, 2020 at 9:15 PM Keiichi Watanabe wrote: > > Hi Dmitry, > > > > On Wed, Jan 8, 2020 at 7:00 PM Dmitry Sepp wrote: > > > Hi Keiichi, > > > > > > On Mittwoch, 8. Januar 2020 07:59:22 CET Keiichi Wat

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Keiichi Watanabe
On Wed, Jan 8, 2020 at 9:46 PM Tomasz Figa wrote: > > On Wed, Jan 8, 2020 at 9:15 PM Keiichi Watanabe wrote: > > > > Hi Dmitry, > > > > On Wed, Jan 8, 2020 at 7:00 PM Dmitry Sepp > > wrote: > > > > > > Hi Keiichi, > > > > > > On Mittwoch, 8. Januar 2020 07:59:22 CET Keiichi Watanabe wrote: > >

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Tomasz Figa
On Wed, Jan 8, 2020 at 9:15 PM Keiichi Watanabe wrote: > > Hi Dmitry, > > On Wed, Jan 8, 2020 at 7:00 PM Dmitry Sepp > wrote: > > > > Hi Keiichi, > > > > On Mittwoch, 8. Januar 2020 07:59:22 CET Keiichi Watanabe wrote: > > > Hi Dmitry, > > > > > > On Wed, Jan 8, 2020 at 1:50 AM Dmitry Sepp > >

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Keiichi Watanabe
Hi Dmitry, On Wed, Dec 18, 2019 at 10:02 PM Keiichi Watanabe wrote: > > From: Dmitry Sepp > > The virtio video encoder device and decoder device provide functionalities to > encode and decode video stream respectively. > Though video encoder and decoder are provided as different devices, they us

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Keiichi Watanabe
Hi Dmitry, On Wed, Jan 8, 2020 at 7:00 PM Dmitry Sepp wrote: > > Hi Keiichi, > > On Mittwoch, 8. Januar 2020 07:59:22 CET Keiichi Watanabe wrote: > > Hi Dmitry, > > > > On Wed, Jan 8, 2020 at 1:50 AM Dmitry Sepp > wrote: > > > Hi Keiichi, > > > > > > thanks for the updates, please see my comment

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-08 Thread Dmitry Sepp
Hi Keiichi, On Mittwoch, 8. Januar 2020 07:59:22 CET Keiichi Watanabe wrote: > Hi Dmitry, > > On Wed, Jan 8, 2020 at 1:50 AM Dmitry Sepp wrote: > > Hi Keiichi, > > > > thanks for the updates, please see my comments below. > > > > On Dienstag, 7. Januar 2020 14:24:31 CET Keiichi Watanabe wrote

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-07 Thread Keiichi Watanabe
Hi Dmitry, On Wed, Jan 8, 2020 at 1:50 AM Dmitry Sepp wrote: > > Hi Keiichi, > > thanks for the updates, please see my comments below. > > On Dienstag, 7. Januar 2020 14:24:31 CET Keiichi Watanabe wrote: > > Hi Dmitry, > > > > On Mon, Jan 6, 2020 at 11:59 PM Dmitry Sepp > wrote: > > > Hi, > > >

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-07 Thread Dmitry Sepp
Hi Keiichi, thanks for the updates, please see my comments below. On Dienstag, 7. Januar 2020 14:24:31 CET Keiichi Watanabe wrote: > Hi Dmitry, > > On Mon, Jan 6, 2020 at 11:59 PM Dmitry Sepp wrote: > > Hi, > > > > a couple of new comments: > > > > On Mittwoch, 18. Dezember 2019 14:02:14 CET

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-07 Thread Keiichi Watanabe
Hi Dmitry, On Mon, Jan 6, 2020 at 11:59 PM Dmitry Sepp wrote: > > Hi, > > a couple of new comments: > > On Mittwoch, 18. Dezember 2019 14:02:14 CET Keiichi Watanabe wrote: > > From: Dmitry Sepp > > > > The virtio video encoder device and decoder device provide functionalities > > to encode and d

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-06 Thread Dmitry Sepp
Hi, a couple of new comments: On Mittwoch, 18. Dezember 2019 14:02:14 CET Keiichi Watanabe wrote: > From: Dmitry Sepp > > The virtio video encoder device and decoder device provide functionalities > to encode and decode video stream respectively. > Though video encoder and decoder are provided

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-06 Thread Keiichi Watanabe
Hi Dmitry, On Sat, Jan 4, 2020 at 12:47 AM Dmitry Sepp wrote: > > Hi Keiichi, > > On Mittwoch, 18. Dezember 2019 14:02:14 CET Keiichi Watanabe wrote: > > From: Dmitry Sepp > > > > The virtio video encoder device and decoder device provide functionalities > > to encode and decode video stream res

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-06 Thread Dmitry Sepp
Hi, On Montag, 6. Januar 2020 09:33:35 CET Gerd Hoffmann wrote: > Hi, > > > > We also see the need to add a max_streams value to this structure so as > > > to > > > explicitly provide a limit on the number of streams the guest can > > > create. > > > > What would be the advantage over just try

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-06 Thread Gerd Hoffmann
Hi, > How should one deal with multiplanar formats? Do we create one resource per > plane? Otherwise we need a way to send mem entries for each plane in one > request. DRM uses arrays of handles and offsets (see struct drm_framebuffer). A handle references a gem object (roughly the same as a

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-06 Thread Gerd Hoffmann
Hi, > > We also see the need to add a max_streams value to this structure so as to > > explicitly provide a limit on the number of streams the guest can create. > > What would be the advantage over just trying to create one and > failing? The maximum number would be only meaningful for the spec

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-05 Thread Tomasz Figa
On Mon, Dec 30, 2019 at 9:16 PM Dmitry Sepp wrote: > > > On Donnerstag, 19. Dezember 2019 14:28:23 CET Dmitry Sepp wrote: > > Hi Keiichi, > > > > Thank you for the update. Please see some comments below. > > > > Also, we need to bring the virtio_video_control back as it is in fact used > > by the

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2020-01-03 Thread Dmitry Sepp
Hi Keiichi, On Mittwoch, 18. Dezember 2019 14:02:14 CET Keiichi Watanabe wrote: > From: Dmitry Sepp > > The virtio video encoder device and decoder device provide functionalities > to encode and decode video stream respectively. > Though video encoder and decoder are provided as different device

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-30 Thread Dmitry Sepp
On Donnerstag, 19. Dezember 2019 14:28:23 CET Dmitry Sepp wrote: > Hi Keiichi, > > Thank you for the update. Please see some comments below. > > Also, we need to bring the virtio_video_control back as it is in fact used > by the driver to enumerate supported encoder controls. But yes, it still

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-20 Thread Tomasz Figa
On Sat, Dec 21, 2019 at 12:46 AM Dmitry Sepp wrote: > On Freitag, 20. Dezember 2019 16:26:50 CET Keiichi Watanabe wrote: > > On Thu, Dec 19, 2019 at 10:28 PM Dmitry Sepp > > wrote: > > > On Mittwoch, 18. Dezember 2019 14:02:14 CET Keiichi Watanabe wrote: [snip] > > > > +enum virtio_video_format {

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-20 Thread Dmitry Sepp
Hi Keiichi, On Freitag, 20. Dezember 2019 16:26:50 CET Keiichi Watanabe wrote: > Hi Dmitry, > Thanks for the feedback. > > On Thu, Dec 19, 2019 at 10:28 PM Dmitry Sepp > > wrote: > > Hi Keiichi, > > > > Thank you for the update. Please see some comments below. > > > > Also, we need to bring t

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-20 Thread Dmitry Sepp
Hi Keiichi, On Freitag, 20. Dezember 2019 15:05:02 CET Keiichi Watanabe wrote: > Hi Frediano, > Thanks for reviewing! > > On Thu, Dec 19, 2019 at 2:29 AM Frediano Ziglio wrote: > > > From: Dmitry Sepp > > > > > > The virtio video encoder device and decoder device provide > > > functionalities

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-20 Thread Keiichi Watanabe
Hi Dmitry, Thanks for the feedback. On Thu, Dec 19, 2019 at 10:28 PM Dmitry Sepp wrote: > > Hi Keiichi, > > Thank you for the update. Please see some comments below. > > Also, we need to bring the virtio_video_control back as it is in fact used by > the driver to enumerate supported encoder contr

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-20 Thread Keiichi Watanabe
Hi Frediano, Thanks for reviewing! On Thu, Dec 19, 2019 at 2:29 AM Frediano Ziglio wrote: > > > > > From: Dmitry Sepp > > > > The virtio video encoder device and decoder device provide functionalities > > to > > encode and decode video stream respectively. > > Though video encoder and decoder a

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Dmitry Sepp
Hi Keiichi, Thank you for the update. Please see some comments below. Also, we need to bring the virtio_video_control back as it is in fact used by the driver to enumerate supported encoder controls. But yes, it still needs to be documemnted, it's true. On Mittwoch, 18. Dezember 2019 14:02:14

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Gerd Hoffmann
Hi, > > However that still doesn't let the driver know which buffers will be > > dequeued when. A simple example of this scenario is when the guest is > > done displaying a frame and requeues the buffer back to the decoder. > > Then the decoder will not choose it for decoding next frames into as

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Gerd Hoffmann
Hi, > > Not clearly defined in the spec: When is the decoder supposed to send > > the response for a queue request? When it finished decoding (i.e. frame > > is ready for playback), or when it doesn't need the buffer any more for > > decoding (i.e. buffer can be re-queued or pages can be relea

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Gerd Hoffmann
Hi, > > I also can't see why the flag is needed in the first place. The driver > > should know which buffers are queued still and be able to figure > > whenever the drain is complete or not without depending on that flag. > > So I'd suggest to simply drop it. > This flag is used not for drain o

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Tomasz Figa
On Thu, Dec 19, 2019 at 7:55 PM Dmitry Sepp wrote: > > Hi Tomasz, > > On Donnerstag, 19. Dezember 2019 10:59:02 CET Tomasz Figa wrote: > > On Thu, Dec 19, 2019 at 6:48 PM Dmitry Sepp > wrote: > > > Hi, > > > > > > On Donnerstag, 19. Dezember 2019 08:46:39 CET Gerd Hoffmann wrote: > > > > On Wed,

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Dmitry Sepp
Hi Tomasz, On Donnerstag, 19. Dezember 2019 10:59:02 CET Tomasz Figa wrote: > On Thu, Dec 19, 2019 at 6:48 PM Dmitry Sepp wrote: > > Hi, > > > > On Donnerstag, 19. Dezember 2019 08:46:39 CET Gerd Hoffmann wrote: > > > On Wed, Dec 18, 2019 at 11:08:37PM +0900, Tomasz Figa wrote: > > > > On Wed,

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Tomasz Figa
On Thu, Dec 19, 2019 at 6:48 PM Dmitry Sepp wrote: > > Hi, > > On Donnerstag, 19. Dezember 2019 08:46:39 CET Gerd Hoffmann wrote: > > On Wed, Dec 18, 2019 at 11:08:37PM +0900, Tomasz Figa wrote: > > > On Wed, Dec 18, 2019 at 10:40 PM Gerd Hoffmann wrote: > > > > Hi, > > > > > > > > > +The devic

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Tomasz Figa
On Thu, Dec 19, 2019 at 6:26 PM Dmitry Sepp wrote: > > Hi Gerd, > > On Mittwoch, 18. Dezember 2019 14:40:37 CET Gerd Hoffmann wrote: > > Hi, > > > > > +The device MUST mark the last buffer with the > > > +VIRTIO_VIDEO_BUFFER_F_EOS flag to denote completion of the drain > > > +sequence. > > > > N

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Dmitry Sepp
Hi, On Donnerstag, 19. Dezember 2019 08:46:39 CET Gerd Hoffmann wrote: > On Wed, Dec 18, 2019 at 11:08:37PM +0900, Tomasz Figa wrote: > > On Wed, Dec 18, 2019 at 10:40 PM Gerd Hoffmann wrote: > > > Hi, > > > > > > > +The device MUST mark the last buffer with the > > > > +VIRTIO_VIDEO_BUFFER_

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-19 Thread Dmitry Sepp
Hi Gerd, On Mittwoch, 18. Dezember 2019 14:40:37 CET Gerd Hoffmann wrote: > Hi, > > > +The device MUST mark the last buffer with the > > +VIRTIO_VIDEO_BUFFER_F_EOS flag to denote completion of the drain > > +sequence. > > No, that would build a race condition into the protocol. The device > c

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-18 Thread Gerd Hoffmann
On Wed, Dec 18, 2019 at 11:08:37PM +0900, Tomasz Figa wrote: > On Wed, Dec 18, 2019 at 10:40 PM Gerd Hoffmann wrote: > > > > Hi, > > > > > +The device MUST mark the last buffer with the > > > +VIRTIO_VIDEO_BUFFER_F_EOS flag to denote completion of the drain > > > +sequence. > > > > No, that woul

Re: [virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-18 Thread Tomasz Figa
On Wed, Dec 18, 2019 at 10:40 PM Gerd Hoffmann wrote: > > Hi, > > > +The device MUST mark the last buffer with the > > +VIRTIO_VIDEO_BUFFER_F_EOS flag to denote completion of the drain > > +sequence. > > No, that would build a race condition into the protocol. The device > could complete the la

[virtio-dev] Re: [PATCH v2 1/1] virtio-video: Add virtio video device specification

2019-12-18 Thread Gerd Hoffmann
Hi, > +The device MUST mark the last buffer with the > +VIRTIO_VIDEO_BUFFER_F_EOS flag to denote completion of the drain > +sequence. No, that would build a race condition into the protocol. The device could complete the last buffer after the driver has sent the drain command but before the de