Re: [PATCH] media: uapi: h264: clarify num_ref_idx_l[01]_(default_)active fields

2019-10-16 Thread Paul Kocialkowski
Hi, I thought I had answered here already, but looks I never sent the email. On Sat 05 Oct 19, 23:21, Tomasz Figa wrote: > On Sat, Oct 5, 2019 at 11:12 PM Paul Kocialkowski > wrote: > > > > On Sat 05 Oct 19, 22:54, Tomasz Figa wrote: > > > On Sat, Oct 5, 2019 at

Re: [PATCH] media: uapi: h264: clarify num_ref_idx_l[01]_(default_)active fields

2019-10-05 Thread Paul Kocialkowski
On Sat 05 Oct 19, 23:21, Tomasz Figa wrote: > On Sat, Oct 5, 2019 at 11:12 PM Paul Kocialkowski > wrote: > > > > On Sat 05 Oct 19, 22:54, Tomasz Figa wrote: > > > On Sat, Oct 5, 2019 at 10:39 PM Paul Kocialkowski > > > wrote: > > > > > > &

Re: [PATCH] media: uapi: h264: clarify num_ref_idx_l[01]_(default_)active fields

2019-10-05 Thread Paul Kocialkowski
On Sat 05 Oct 19, 22:54, Tomasz Figa wrote: > On Sat, Oct 5, 2019 at 10:39 PM Paul Kocialkowski > wrote: > > > > Hi, > > > > On Sat 05 Oct 19, 17:22, Tomasz Figa wrote: > > > On Fri, Oct 4, 2019 at 6:12 AM Paul Kocialkowski > > > wrote: > > &

Re: [PATCH] media: uapi: h264: clarify num_ref_idx_l[01]_(default_)active fields

2019-10-05 Thread Paul Kocialkowski
Hi, On Sat 05 Oct 19, 17:22, Tomasz Figa wrote: > On Fri, Oct 4, 2019 at 6:12 AM Paul Kocialkowski > wrote: > > > > Hi, > > > > On Thu 05 Sep 19, 13:42, Philipp Zabel wrote: > > > To explain why num_ref_idx_active_override_flag is not part of the API,

Re: [PATCH] media: uapi: h264: clarify num_ref_idx_l[01]_(default_)active fields

2019-10-03 Thread Paul Kocialkowski
nd it doesn't do slice parsing itself), we could always check the flag in the driver and use either the default PPS values or the slice-specific values there. What do you think? Cheers, Paul > Signed-off-by: Philipp Zabel > --- > Documentation/media/uapi/v4l/ext-ctrls-codec.rst

Re: [PATCH 1/2] media: uapi: h264: Add num_ref_idx_active_override_flag

2019-10-03 Thread Paul Kocialkowski
Hi, On Thu 05 Sep 19, 12:15, Philipp Zabel wrote: > This flag tells the kernel whether the slice header contained the > num_ref_idx_l[01]_active_minus1 syntax elements, or whether the > num_ref_idx_l[01]_default_active_minus1 from PPS should be used > instead. Looks good to me: Revie

Re: [PATCH 1/2] media: uapi: h264: Add num_ref_idx_active_override_flag

2019-10-03 Thread Paul Kocialkowski
us no need to have the flag in the uapi), if userspace > > fills the default into the override fields as a fallback. Such a decoder > > does need the num_ref_idx_l[01]_active_minus1 override, but doesn't need > > the num_ref_idx_l[01]_default_active_minus1 field nor the flag. > > > > That is my current understanding of the intention behind this interface, > > I hope this is accurate. > > I've tried to make the docs reflect this in ("media: uapi: h264: clarify > > num_ref_idx_l[01]_(default_)active fields") [1]. > > > > [1] > > https://lore.kernel.org/linux-media/20190905114210.9232-1-p.za...@pengutronix.de/T/#u > > Yes, makes sense for me. Sorry for being late to the party and catching up with this just now. It looks like the conclusion is that we need to keep both the PPS default and slice-specific set of fields to cover both hardware that parses the slice header and hardware that doesn't. In H265, I had evicted the PPS default value and the flag in favor of only providing a slice-specific value, but I should certainly revise this to have the two sets of values and the flag. This should allow covering hardware that does slice header parsing itself. Cheers, Paul -- Paul Kocialkowski, Bootlin Embedded Linux and kernel engineering https://bootlin.com signature.asc Description: PGP signature

Re: [PATCHv2 08/12] pixfmt-compressed.rst: improve H264/HEVC/MPEG1+2/VP8+9 documentation

2019-08-14 Thread Paul Kocialkowski
has no requirements since it can parse all the > + information from the raw bytestream. Maybe it would be clearer to mention that "no requirements" concerns the lack of frame/field boundary requirement? Otherwise it feels a bit unclear what userspace

Re: [PATCHv2 06/12] media: vicodec: set flags for vdec/stateful OUTPUT coded formats

2019-08-14 Thread Paul Kocialkowski
Hi, On Mon 12 Aug 19, 13:05, Hans Verkuil wrote: > From: Maxime Jourdan > > Tag all the coded formats where the vicodec stateful decoder supports > dynamic resolution switching and bytestream parsing. Looks good to me: Reviewed-by: Paul Kocialkowski Cheers, Paul > Signed

Re: [PATCHv2 05/12] media: mtk-vcodec: flag OUTPUT formats with V4L2_FMT_FLAG_DYN_RESOLUTION

2019-08-14 Thread Paul Kocialkowski
Hi, On Mon 12 Aug 19, 13:05, Hans Verkuil wrote: > From: Maxime Jourdan > > Tag all the coded formats where the mtk-vcodec decoder supports dynamic > resolution switching. Looks good to me despite lack of knowledge about the hardware. Reviewed-by: Paul Kocialkowski Cheers, Pa

Re: [PATCHv2 04/12] media: s5p_mfc_dec: set flags for OUTPUT coded formats

2019-08-14 Thread Paul Kocialkowski
dware really supports. Reviewed-by: Paul Kocialkowski Cheers, Paul > Signed-off-by: Maxime Jourdan > Signed-off-by: Hans Verkuil > [hverkuil-ci...@xs4all.nl: added CONTINUOUS_BYTESTREAM] > --- > .../media/platform/s5p-mfc/s5p_mfc_common.h| 1 + > drivers/media/platfor

Re: [PATCHv2 03/12] media: venus: vdec: flag OUTPUT formats with V4L2_FMT_FLAG_DYN_RESOLUTION

2019-08-14 Thread Paul Kocialkowski
Hi, On Mon 12 Aug 19, 13:05, Hans Verkuil wrote: > From: Maxime Jourdan > > Tag all the coded formats where the venus vdec supports dynamic > resolution switching. Looks good to me. Reviewed-by: Paul Kocialkowski Cheers, Paul > Signed-off-by: Maxime Jourdan > Signed-of

Re: [PATCHv2 01/12] videodev2.h: add V4L2_FMT_FLAG_CONTINUOUS_BYTESTREAM

2019-08-14 Thread Paul Kocialkowski
pre-parses the bytestream into > frames or fields (see the corresponding pixelformat descriptions > for details). > > If this flag is set, then this pre-parsing step is not required > (but still possible, of course). Although I wasn't involved with the initial issue, l

Re: [PATCHv2 02/12] videodev2.h: add V4L2_FMT_FLAG_DYN_RESOLUTION

2019-08-14 Thread Paul Kocialkowski
resolution switching for one or more of their listed coded formats. It > allows userspace to know whether it should extract the video parameters > itself, or if it can rely on the device to send V4L2_EVENT_SOURCE_CHANGE > when such changes are detected. Makes sense and looks good to me:

Re: [PATCH v3 1/3] media: uapi: h264: Clarify our expectations regarding NAL header format

2019-07-29 Thread Paul Kocialkowski
ng one pixel format per hardware implementation and I believe it makes no sense. I really don't find it to be an elegant or scalable way to expose the differences between decoder implementations. So the approach I currently like best is to have as much information as possible passed to the d

Re: [PATCH v3 1/3] media: uapi: h264: Clarify our expectations regarding NAL header format

2019-07-29 Thread Paul Kocialkowski
Hi, On Sat 27 Jul 19, 11:46, Boris Brezillon wrote: > On Sat, 27 Jul 2019 11:27:43 +0200 > Paul Kocialkowski wrote: > > > Hi, > > > > On Fri 26 Jul 19, 10:53, Hans Verkuil wrote: > > > On 7/26/19 9:30 AM, Boris Brezillon wrote: > > > >

Re: [PATCH 02/14] videodev2.h: add V4L2_FMT_FLAG_HAS_BITSTREAM_PARSER

2019-07-29 Thread Paul Kocialkowski
Hi, On Sun 28 Jul 19, 23:05, Tomasz Figa wrote: > On Sat, Jul 27, 2019 at 6:37 PM Paul Kocialkowski > wrote: > > > > Hi, > > > > On Wed 24 Jul 19, 13:05, Hans Verkuil wrote: > > > Add an enum_fmt format flag to specifically tag coded formats where > >

Re: [PATCH 04/14] videodev2.h.rst.exceptions: tymecode -> timecode

2019-07-27 Thread Paul Kocialkowski
Hi, On Wed 24 Jul 19, 13:05, Hans Verkuil wrote: > Fix typo. > > Signed-off-by: Hans Verkuil Looks good! Reviewed-by: Paul Kocialkowski Cheers, Paul > --- > Documentation/media/videodev2.h.rst.exceptions | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-)

Re: [PATCH 02/14] videodev2.h: add V4L2_FMT_FLAG_HAS_BITSTREAM_PARSER

2019-07-27 Thread Paul Kocialkowski
COMPRESSED`` flag, since this applies to compressed > + formats only. Should this flag be set for stateless codecs as well? It seems a bit over-kill for this case. I am not sure whether "compressed bitstream format" clearly only covers the formats used by stateful decoders and no

Re: [PATCH v3 1/3] media: uapi: h264: Clarify our expectations regarding NAL header format

2019-07-27 Thread Paul Kocialkowski
Hi, On Fri 26 Jul 19, 10:53, Hans Verkuil wrote: > On 7/26/19 9:30 AM, Boris Brezillon wrote: > > On Fri, 26 Jul 2019 08:28:28 +0200 > > Boris Brezillon wrote: > > > >> On Thu, 25 Jul 2019 23:39:11 -0300 > >> Ezequiel Garcia wrote: > >&g

Re: [PATCH v3 3/3] media: uapi: h264: Get rid of the p0/b0/b1 ref-lists

2019-07-25 Thread Paul Kocialkowski
am order > > > -* - __u8 > > > - - ``ref_pic_list_b1[32]`` > > > - - Forward reference list used by B-frames in the original > > > bitstream order > > > * - __s32 > > >- ``top_field_order_cnt`` > > >- Picture Order Count for the coded top field > > > > Thanks for the patch. > > > > Don't we also need to remove these fields from the UAPI structs? > > Oops, indeed. I'll drop them in the next version. With that change, feel free to add my: Reviewed-by: Paul Kocialkowski Cheers and thanks! Paul -- Paul Kocialkowski, Bootlin Embedded Linux and kernel engineering https://bootlin.com

Re: [PATCH v3 1/3] media: uapi: h264: Clarify our expectations regarding NAL header format

2019-07-25 Thread Paul Kocialkowski
Hi, On Thu 25 Jul 19, 08:42, Boris Brezillon wrote: > On Fri, 5 Jul 2019 19:16:18 +0200 > Boris Brezillon wrote: > > > On Fri, 05 Jul 2019 13:40:03 -0300 > > Ezequiel Garcia wrote: > > > > > Hi Boris, Paul, > > > > > > On Wed, 2019-07-03

Re: [PATCH v3 1/3] media: uapi: h264: Clarify our expectations regarding NAL header format

2019-07-25 Thread Paul Kocialkowski
t; to select the type of NAL header to use. After thinking a bit about this, I'd rather be in favor of having offsets in the control structures rather than forcing the start code type or having a dedicated control for that, as I've mentionned on the other patch. What do you think? Ch

Re: [PATCH v3 2/3] media: uapi: h264: Add the concept of decoding mode

2019-07-25 Thread Paul Kocialkowski
ainly be done as a subsequent patch/series, and definitely not necessarily by you (don't want to add more on your shoulders at this point)! Cheers, Paul > /* Offset in bits to slice_data() from the beginning of this slice. */ > __u32 header_bit_size; > > -- > 2.21.0

Re: [PATCH v2] staging: media: sunxi: Add bool cast to value

2019-07-23 Thread Paul Kocialkowski
Hi, On Mon 22 Jul 19, 18:58, Sakari Ailus wrote: > On Mon, Jul 22, 2019 at 07:14:08PM +0530, Nishka Dasgupta wrote: > > On 22/07/19 5:54 PM, Paul Kocialkowski wrote: > > > Hi, > > > > > > On Mon 22 Jul 19, 12:12, Jeremy Sowden wrote: > > > > O

Re: [PATCH v2] staging: media: sunxi: Add bool cast to value

2019-07-22 Thread Paul Kocialkowski
Hi, On Mon 22 Jul 19, 19:14, Nishka Dasgupta wrote: > On 22/07/19 5:54 PM, Paul Kocialkowski wrote: > > Hi, > > > > On Mon 22 Jul 19, 12:12, Jeremy Sowden wrote: > > > On 2019-07-22, at 11:36:51 +0530, Nishka Dasgupta wrote: > > > > Typecast as bool

Re: [PATCH v2] staging: media: sunxi: Add bool cast to value

2019-07-22 Thread Paul Kocialkowski
hey are non-zero. As a result, I think it's best to be careful. However, I'm not sure I really see what cocinelle was unhappy about. You mentionned single-line functions, but I don't see how that can be a problem. So in the end, I think we should keep the !! and drop the (bool) cast if there's no particular warning about it. What do you think? Cheers, Paul > > static void cedrus_prepare_format(struct v4l2_pix_format *pix_fmt) > > -- > > 2.19.1 -- Paul Kocialkowski, Bootlin Embedded Linux and kernel engineering https://bootlin.com

Re: [PATCH] staging: media: sunxi: Add bool cast to value

2019-07-18 Thread Paul Kocialkowski
r so that we are sure that the function returns either false or true, but never a non-zero value that is not true? Cheers, Paul > Signed-off-by: Nishka Dasgupta > --- > drivers/staging/media/sunxi/cedrus/cedrus_video.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) >

Re: [PATCH 2/2] staging: media: sunxi: Replace function cedrus_check_format()

2019-07-17 Thread Paul Kocialkowski
Hi, On Fri 05 Jul 19, 17:43, Nishka Dasgupta wrote: > On 05/07/19 3:56 PM, Paul Kocialkowski wrote: > > Hi, > > > > On Wed 03 Jul 19, 13:43, Nishka Dasgupta wrote: > > > Remove function cedrus_check_format as all it does is call > > > cedrus_find_for

Re: Single- vs Multi-planar APIs for mem2mem devices

2019-07-12 Thread Paul Kocialkowski
Hi, On Fri 12 Jul 19, 12:26, wens Tsai wrote: > On Thu, Jul 11, 2019 at 8:19 PM Paul Kocialkowski > wrote: > > > > On Thu 11 Jul 19, 19:51, wens Tsai wrote: > > > On Thu, Jul 11, 2019 at 5:39 PM Paul Kocialkowski > > > wrote: > > > > > >

Re: Single- vs Multi-planar APIs for mem2mem devices

2019-07-11 Thread Paul Kocialkowski
On Thu 11 Jul 19, 19:51, wens Tsai wrote: > On Thu, Jul 11, 2019 at 5:39 PM Paul Kocialkowski > wrote: > > > > Hi, > > > > On Thu 11 Jul 19, 17:21, wens Tsai wrote: > > > I noticed that recent codec driver additions, such as hantro, meson/vdec, >

Re: Single- vs Multi-planar APIs for mem2mem devices

2019-07-11 Thread Paul Kocialkowski
ated in a single chunk (the single-plane V4L2 API). I don't have any better answer than "userspace should cope with both APIs as it reflects a hardware constraint", which is indeed what ffmpeg is already doing. Cheers, Paul > Also I noticed that v4l-utils has a plugin that se

Re: [PATCH 2/2] staging: media: sunxi: Replace function cedrus_check_format()

2019-07-05 Thread Paul Kocialkowski
a !! or a bool cast to make coccinelle happy here? Cheers, Paul > Signed-off-by: Nishka Dasgupta > --- > drivers/staging/media/sunxi/cedrus/cedrus_video.c | 10 ++ > 1 file changed, 2 insertions(+), 8 deletions(-) > > diff --git a/drivers/staging/media/sunxi/c

Re: [PATCH 1/2] staging: media: sunxi: Change return type of cedrus_find_format()

2019-07-05 Thread Paul Kocialkowski
icial, sorry. Cheers, Paul > Signed-off-by: Nishka Dasgupta > --- > drivers/staging/media/sunxi/cedrus/cedrus_video.c | 11 --- > 1 file changed, 4 insertions(+), 7 deletions(-) > > diff --git a/drivers/staging/media/sunxi/cedrus/cedrus_video.c > b/d

Re: [RFC] media: uapi: Add VP8 low-level decoder API compound controls.

2019-06-27 Thread Paul Kocialkowski
> + > + __u8 num_dct_parts; > + __u32 dct_part_sizes[8]; > + > + __u8 bool_dec_range; > + __u8 bool_dec_value; > + __u8 bool_dec_count; > + > + __u64 last_frame_ts; > + __u64 golden_frame_ts; > + __u64 alt_frame_ts; > + > + __

Re: [PATCH v2 3/3] media: uapi: h264: Get rid of the p0/b0/b1 ref-lists

2019-06-26 Thread Paul Kocialkowski
removing the DPB or at least renaming it, but I don't have a clear idea of the outcome as well. Cheers, Paul > Signed-off-by: Boris Brezillon > --- > Changes in v2: > * None > --- > Documentation/media/uapi/v4l/ext-ctrls-codec.rst | 9 - > 1 file changed, 9

Re: [PATCH v2 2/3] media: uapi: h264: Add the concept of decoding mode

2019-06-26 Thread Paul Kocialkowski
ssed at a time. About that, I'm wondering how we could handle that in our drivers. It will probably be something like: device_run -+-> decode slice i -> IRQ -+-> job_finish `--- i++ --' And I'm wondering if there could be common helpers to hel

Re: [PATCH v2 1/3] media: uapi: h264: Clarify our expectations regarding NAL header format

2019-06-26 Thread Paul Kocialkowski
control > to select the type of NAL header to use. > > Signed-off-by: Boris Brezillon Looks good to me: Reviewed-by: Paul Kocialkowski Cheers, Paul > --- > Changes in v2: > * None > > Note: we might want to add a nal_header_size field to allow drivers to > quickly

Re: [PATCH RFC 5/6] media: cedrus: Make the slice_params array size limitation more explicit

2019-06-05 Thread Paul Kocialkowski
uld give us enough information to achieve both. A > > slice with index 0 is obviously going to be the first slice in a frame. > > We do this in per-frame mode only. The offset of the slice in the > bitstream is always 0 in per-slice mode, since each v4l2 input buffer > is a slice. I don't think we need a slice index either, we most likely already have enough information to know where we're at regarding slices position. But how about allowing an arbitrary number of slices within frame boundary in per-slice decoding mode? Cheers, Paul

Re: [PATCH RFC 4/6] media: cedrus: Prepare things to support !compound controls

2019-06-05 Thread Paul Kocialkowski
Hi, Le lundi 03 juin 2019 à 13:09 +0200, Boris Brezillon a écrit : > We are about to add a menu control, so let's make the code more generic > to support other control types. Did you have a chance to test this or should I better give it a spin before adding my Reviewed-By? Ch

Re: [PATCH RFC 2/6] media: uapi: h264: Add the concept of decoding mode

2019-06-05 Thread Paul Kocialkowski
LAG 0x01 > #define V4L2_H264_SPS_CONSTRAINT_SET1_FLAG 0x02 > @@ -111,6 +118,8 @@ struct v4l2_h264_pred_weight_table { > struct v4l2_h264_weight_factors weight_factors[2]; > }; > > +#define V4L2_H264_MAX_SLICES_PER_FRAME

Re: [PATCH RFC 2/6] media: uapi: h264: Add the concept of decoding mode

2019-06-05 Thread Paul Kocialkowski
> +:widths: 1 1 2 > > > > > > + > > > > > > +* - ``V4L2_MPEG_VIDEO_H264_DECODING_PER_SLICE`` > > > > > > + - 0 > > > > > > + - The decoding is done per slice. > > > > > > v4l2_ctrl_h26

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-06-04 Thread Paul Kocialkowski
all the time out of simplicity. I mean drivers that don't need it will > > > > already ignore it (i.e. they must not break if they get the extra data) > > > > so other than the potential runtime savings on some hardware, there are > > > > no advantages. > >

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-06-04 Thread Paul Kocialkowski
pace side by having these decoder-specific details handled by the kernel. It also brings us closer to bitstream format (where the modifications are coded) and leaves DPB management to the decoder/driver, which IMO makes a lot of sense. Cheers, Paul -- Paul Kocialkowski, Bootlin Embedded Linux and kernel engineering https://bootlin.com

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-22 Thread Paul Kocialkowski
m where we group controls (parsed bitstream meta-data) and source (OUTPUT) buffers together and submit them tied. When each request gets processed its buffer enters the OUTPUT queue, which gets picked up by the driver and associated with the first destination (CAPTURE) buffer available. Then the driver grabs the buffers and applies the controls matching the source buffer's request before starting decoding with M2M. We have already worked on handling the case of requiring a single destination buffer for the different slices, by having a flag to indicate whether the destination buffer should be held. Cheers, Paul

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-22 Thread Paul Kocialkowski
Hi, Le mercredi 22 mai 2019 à 15:48 +0900, Tomasz Figa a écrit : > On Sat, May 18, 2019 at 11:09 PM Nicolas Dufresne > wrote: > > Le samedi 18 mai 2019 à 12:29 +0200, Paul Kocialkowski a écrit : > > > Hi, > > > > > > Le samedi 18 mai 2019 à 12:04 +020

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-21 Thread Paul Kocialkowski
Hi, On Tue, 2019-05-21 at 19:27 +0900, Tomasz Figa wrote: > On Thu, May 16, 2019 at 2:43 AM Paul Kocialkowski > wrote: > > Hi, > > > > Le mercredi 15 mai 2019 à 10:42 -0400, Nicolas Dufresne a écrit : > > > Le mercredi 15 mai 2019 à 12:09 +0200, Paul

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-18 Thread Paul Kocialkowski
Hi, Le samedi 18 mai 2019 à 12:04 +0200, Jernej Škrabec a écrit : > Dne sobota, 18. maj 2019 ob 11:50:37 CEST je Paul Kocialkowski napisal(a): > > Hi, > > > > On Fri, 2019-05-17 at 16:43 -0400, Nicolas Dufresne wrote: > > > Le jeudi 16 mai 2019 à 20:45 +0

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-18 Thread Paul Kocialkowski
Hi, On Fri, 2019-05-17 at 16:43 -0400, Nicolas Dufresne wrote: > Le jeudi 16 mai 2019 à 20:45 +0200, Paul Kocialkowski a écrit : > > Hi, > > > > Le jeudi 16 mai 2019 à 14:24 -0400, Nicolas Dufresne a écrit : > > > Le mercredi 15 mai 2019 à 22:59 +0200, Paul Koc

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-16 Thread Paul Kocialkowski
Hi, Le jeudi 16 mai 2019 à 14:24 -0400, Nicolas Dufresne a écrit : > Le mercredi 15 mai 2019 à 22:59 +0200, Paul Kocialkowski a écrit : > > Hi, > > > > Le mercredi 15 mai 2019 à 14:54 -0400, Nicolas Dufresne a écrit : > > > Le mercredi 15 mai 2019 à 19:42 +0

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-15 Thread Paul Kocialkowski
Hi, Le mercredi 15 mai 2019 à 14:54 -0400, Nicolas Dufresne a écrit : > Le mercredi 15 mai 2019 à 19:42 +0200, Paul Kocialkowski a écrit : > > Hi, > > > > Le mercredi 15 mai 2019 à 10:42 -0400, Nicolas Dufresne a écrit : > > > Le mercredi 15 mai 2019 à 12:09 +0

Re: Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-15 Thread Paul Kocialkowski
Hi, Le mercredi 15 mai 2019 à 10:42 -0400, Nicolas Dufresne a écrit : > Le mercredi 15 mai 2019 à 12:09 +0200, Paul Kocialkowski a écrit : > > Hi, > > > > With the Rockchip stateless VPU driver in the works, we now have a > > better idea of what the situation is l

Proposed updates and guidelines for MPEG-2, H.264 and H.265 stateless support

2019-05-15 Thread Paul Kocialkowski
er; I'm up for preparing and submitting these control changes and updating cedrus if they seem agreeable. What do you think? Cheers, Paul [0]: https://lkml.org/lkml/2019/3/6/82 [1]: https://patchwork.linuxtv.org/patch/55947/ [2]: https://chromium.googlesource.com/chromiumos/third_party/k

Re: Support for 2D engines/blitters in V4L2 and DRM

2019-05-09 Thread Paul Kocialkowski
U horsepower and RAM bandwidth may be scarce > (though not as a rule), X11 is not mandatory and HW blitting may > actually matter... It sure does, indeed! The situation you are describing for non-x86 is exactly the problem I want to help tackle with this :) Cheers and thanks for your interest, Paul -- Paul Kocialkowski, Bootlin Embedded Linux and kernel engineering https://bootlin.com

Re: [PATCH v5 06/23] media: v4l2-ctrl: v4l2_ctrl_request_setup returns with error upon failure

2019-03-12 Thread Paul Kocialkowski
r to take this into account, marking both src/dst buffers as error (as suggested by Hans on IRC). > Signed-off-by: Dafna Hirschfeld Reviewed-by: Paul Kocialkowski Cheers, Paul > --- > drivers/media/v4l2-core/v4l2-ctrls.c | 18 +++--- > include/media/v4l2-ctrls.h

Re: [PATCH v5 03/23] cedrus: set requires_requests

2019-03-12 Thread Paul Kocialkowski
ht need to get rid of the flag when adding support for decoding JPEG, which may not require the request API. Acked-by: Paul Kocialkowski Cheers, Paul > --- > drivers/staging/media/sunxi/cedrus/cedrus_video.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/d

Re: [PATCH v5 02/23] videodev2.h: add V4L2_BUF_CAP_REQUIRES_REQUESTS

2019-03-12 Thread Paul Kocialkowski
Hi, On Wed, 2019-03-06 at 13:13 -0800, Dafna Hirschfeld wrote: > From: Hans Verkuil > > Add capability to indicate that requests are required instead of > merely supported. > > Signed-off-by: Hans Verkuil Reviewed-by: Paul Kocialkowski Cheers, Paul > --- > Docu

Re: [PATCH v5 01/23] vb2: add requires_requests bit for stateless codecs

2019-03-12 Thread Paul Kocialkowski
Hi, On Wed, 2019-03-06 at 13:13 -0800, Dafna Hirschfeld wrote: > From: Hans Verkuil > > Stateless codecs require the use of the Request API as opposed of it > being optional. > > So add a bit to indicate this and let vb2 check for this. > > Signed-off-by: Hans Ver

[no subject]

2019-03-01 Thread Paul Thomas
unsubscribe linux-wireless

[PATCH v3 1/2] media: v4l: Add definitions for the HEVC slice format and controls

2019-02-14 Thread Paul Kocialkowski
, 4 bits. Signed-off-by: Paul Kocialkowski --- Documentation/media/uapi/v4l/biblio.rst | 9 + .../media/uapi/v4l/ext-ctrls-codec.rst| 418 ++ .../media/uapi/v4l/pixfmt-compressed.rst | 15 + .../media/uapi/v4l/vidioc-queryctrl.rst | 18 + .../media

[PATCH v3 0/2] HEVC/H.265 stateless support for V4L2 and Cedrus

2019-02-14 Thread Paul Kocialkowski
indices in the DPB * Declared variable in their reduced scope as suggested; * Added the H.265/HEVC spec to the biblio; * Used in-doc references to the spec and the required APIs; * Removed debugging leftovers. Cheers! Paul Kocialkowski (2): media: v4l: Add definitions for the HEVC slice format

[PATCH v3 2/2] media: cedrus: Add HEVC/H.265 decoding support

2019-02-14 Thread Paul Kocialkowski
This introduces support for HEVC/H.265 to the Cedrus VPU driver, with both uni-directional and bi-directional prediction modes supported. Field-coded (interlaced) pictures, custom quantization matrices and 10-bit output are not supported at this point. Signed-off-by: Paul Kocialkowski

[PATCH] media: cedrus: mpeg2: Use v4l2_m2m_get_vq helper for capture queue

2019-02-14 Thread Paul Kocialkowski
Since there's a v4l2_m2m_get_vq helper, use it instead of accessing the queue directly, which slightly increases readability. Also reformat the code using the queue a bit while at it. Signed-off-by: Paul Kocialkowski --- drivers/staging/media/sunxi/cedrus/cedrus_mpeg2.c | 10 +- 1

[PATCH v2] media: cedrus: Forbid setting new formats on busy queues

2019-02-14 Thread Paul Kocialkowski
Check that our queues are not busy before setting the format or return EBUSY if that's the case. This ensures that our format can't change once buffers are allocated for the queue. Signed-off-by: Paul Kocialkowski --- drivers/staging/media/sunxi/cedrus/cedrus_video.c | 10

Re: [PATCH] media: cedrus: Forbid setting new formats on busy queues

2019-02-14 Thread Paul Kocialkowski
Hi, On Thu, 2019-02-14 at 09:59 +0100, Hans Verkuil wrote: > On 2/14/19 9:37 AM, Paul Kocialkowski wrote: > > Check that our queues are not busy before setting the format or return > > EBUSY if that's the case. This ensures that our format can't change > > once buff

[PATCH] media: cedrus: Forbid setting new formats on busy queues

2019-02-14 Thread Paul Kocialkowski
Check that our queues are not busy before setting the format or return EBUSY if that's the case. This ensures that our format can't change once buffers are allocated for the queue. Signed-off-by: Paul Kocialkowski --- drivers/staging/media/sunxi/cedrus/cedrus_video.c | 14

Re: [PATCHv2 3/3] vb2: add 'match' arg to vb2_find_buffer()

2019-02-13 Thread Paul Kocialkowski
On Wed, 2019-02-13 at 10:39 +0100, Hans Verkuil wrote: > On 2/13/19 10:08 AM, Paul Kocialkowski wrote: > > Hi, > > > > On Wed, 2019-02-13 at 09:20 +0100, Hans Verkuil wrote: > > As far as I understand from [0], the capture and output formats can't > > be cha

Re: [PATCH v3] media: docs-rst: Document m2m stateless video decoder interface

2019-02-13 Thread Paul Kocialkowski
Hi, On Wed, 2019-02-13 at 10:57 +0100, Hans Verkuil wrote: > On 2/13/19 10:20 AM, Paul Kocialkowski wrote: > > Hi, > > > > On Wed, 2019-02-13 at 09:59 +0100, Hans Verkuil wrote: > > > On 2/13/19 6:58 AM, Alexandre Courbot wrote: > > > > On Wed,

Re: [PATCHv2 4/6] videodev2.h: add V4L2_CTRL_FLAG_REQUIRES_REQUESTS

2019-02-13 Thread Paul Kocialkowski
ec controls). It also allows setting the control outside of a request for enumerating formats. What do you think? Cheers, Paul > Regards, > > Hans > > > Signed-off-by: Hans Verkuil > > --- > > .../media/uapi/v4l/vidioc-queryctrl.rst

Re: [PATCHv2 2/3] vb2: keep track of timestamp status

2019-02-13 Thread Paul Kocialkowski
e the memory it refers > to is no longer valid. > > So keep track of a 'copied_timestamp' state: it is set when the > timestamp is copied from an output to a capture buffer, and is > cleared when it is no longer valid. Reviewed-by: Paul Kocialkowski Cheers, Paul > Si

Re: [PATCH v3] media: docs-rst: Document m2m stateless video decoder interface

2019-02-13 Thread Paul Kocialkowski
when all frames depending on it have been decoded. So I am leaning > towards not complicating matters and keeping your first sentence > as-is. Yes, I believe it would be much simpler to require userspace to only queue capture buffers once they are no longer needed as references. This also means that the dmabuf fd can't be changed so we are guaranteed that memory will still be there. Cheers, Paul -- Paul Kocialkowski, Bootlin Embedded Linux and kernel engineering https://bootlin.com

Re: [PATCHv2 1/3] vb2: replace bool by bitfield in vb2_buffer

2019-02-13 Thread Paul Kocialkowski
Hi, On Mon, 2019-02-04 at 11:11 +0100, hverkuil-ci...@xs4all.nl wrote: > From: Hans Verkuil > > The bool type is not recommended for use in structs, so replace these > by bitfields. > > Signed-off-by: Hans Verkuil Reviewed-by: Paul Kocialkowski Cheers, Paul > --- &g

Re: [PATCHv2 3/3] vb2: add 'match' arg to vb2_find_buffer()

2019-02-13 Thread Paul Kocialkowski
n't happen today with the cedrus driver AFAIK. Or can it? As far as I understand from [0], the capture and output formats can't be changed once we have allocated buffers so I don't really see how we could end up with mixed resolutions. [0]: https://linuxtv.org/downloads/v4l-dvb

Re: [PATCH v5 6/9] drm/bridge: cdns: Separate DSI and D-PHY configuration

2019-02-07 Thread Paul Kocialkowski
about a silly mistake when refactoring. Looks good otherwise, so with that fixed: Reviewed-by: Paul Kocialkowski > Signed-off-by: Maxime Ripard > --- > drivers/gpu/drm/bridge/cdns-dsi.c | 101 ++- > 1 file changed, 73 insertions(+), 28 deletions(-) > &

Re: [PATCH v5 5/9] phy: Move Allwinner A31 D-PHY driver to drivers/phy/

2019-02-07 Thread Paul Kocialkowski
Hi, On Mon, 2019-01-21 at 16:45 +0100, Maxime Ripard wrote: > Now that our MIPI D-PHY driver has been converted to the phy framework, > let's move it into the drivers/phy directory. > > Signed-off-by: Maxime Ripard Reviewed-by: Paul Kocialkowski Cheers, Paul > --- >

Re: [PATCH v4 4/9] sun6i: dsi: Convert to generic phy handling

2019-02-07 Thread Paul Kocialkowski
Ripard Reviewed-by: Paul Kocialkowski Cheers, Paul > --- > drivers/gpu/drm/sun4i/Kconfig | 11 +- > drivers/gpu/drm/sun4i/Makefile | 6 +- > drivers/gpu/drm/sun4i/sun6i_mipi_dphy.c | 164 ++--- > drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c |

Re: [PATCH v5 4/9] sun6i: dsi: Convert to generic phy handling

2019-02-07 Thread Paul Kocialkowski
Ripard Reviewed-by: Paul Kocialkowski Cheers, Paul > --- > drivers/gpu/drm/sun4i/Kconfig | 11 +- > drivers/gpu/drm/sun4i/Makefile | 6 +- > drivers/gpu/drm/sun4i/sun6i_mipi_dphy.c | 164 ++--- > drivers/gpu/drm/sun4i/sun6i_mipi_dsi.c |

Re: [linux-sunxi] [PATCH v2 1/2] media: v4l: Add definitions for the HEVC slice format and controls

2019-01-25 Thread Paul Kocialkowski
Hi, On Thu, 2019-01-24 at 20:23 +0800, Ayaka wrote: > > Sent from my iPad > > > On Jan 24, 2019, at 6:27 PM, Paul Kocialkowski > > wrote: > > > > Hi, > > > > > On Thu, 2019-01-10 at 21:32 +0800, ayaka wrote: > > > I forget a impo

Re: [PATCH v2 2/2] media: cedrus: Add HEVC/H.265 decoding support

2019-01-24 Thread Paul Kocialkowski
Hi, On Tue, 2018-11-27 at 09:21 +0100, Maxime Ripard wrote: > Hi! > > On Fri, Nov 23, 2018 at 02:02:09PM +0100, Paul Kocialkowski wrote: > > This introduces support for HEVC/H.265 to the Cedrus VPU driver, with > > both uni-directional and bi-directional predi

[PATCH v2] Revert "media: cedrus: Allow using the current dst buffer as reference"

2019-01-24 Thread Paul Kocialkowski
: Paul Kocialkowski --- drivers/staging/media/sunxi/cedrus/cedrus_dec.c | 13 - drivers/staging/media/sunxi/cedrus/cedrus_dec.h | 2 -- drivers/staging/media/sunxi/cedrus/cedrus_mpeg2.c | 10 -- 3 files changed, 4 insertions(+), 21 deletions(-) diff --git a/drivers/staging

Re: [PATCH] Revert "media: cedrus: Allow using the current dst buffer as reference"

2019-01-24 Thread Paul Kocialkowski
Hi, On Thu, 2019-01-24 at 11:32 +0100, Greg KH wrote: > On Thu, Jan 24, 2019 at 10:55:42AM +0100, Paul Kocialkowski wrote: > > This reverts commit cf20ae1535eb690a87c29b9cc7af51881384e967. > > > > The vb2_find_timestamp helper was modified to allow finding buffers > >

Re: [linux-sunxi] [PATCH v2 1/2] media: v4l: Add definitions for the HEVC slice format and controls

2019-01-24 Thread Paul Kocialkowski
Hi, On Tue, 2019-01-08 at 18:00 +0800, Ayaka wrote: > > Sent from my iPad > > > On Jan 8, 2019, at 4:38 PM, Paul Kocialkowski > > wrote: > > > > Hi, > > > > > On Tue, 2019-01-08 at 09:16 +0800, Ayaka wrote: > > > > > >

Re: [linux-sunxi] [PATCH v2 1/2] media: v4l: Add definitions for the HEVC slice format and controls

2019-01-24 Thread Paul Kocialkowski
m2m stateless video decoder interface Can you detail exactly what the rockchip decoder absolutely needs in raw bitstream format? Cheers, Paul > On 1/8/19 6:00 PM, Ayaka wrote: > > Sent from my iPad > > > > > On Jan 8, 2019, at 4:38 PM, Paul Kocialkowski > > > wr

[PATCH] Revert "media: cedrus: Allow using the current dst buffer as reference"

2019-01-24 Thread Paul Kocialkowski
This reverts commit cf20ae1535eb690a87c29b9cc7af51881384e967. The vb2_find_timestamp helper was modified to allow finding buffers regardless of their current state in the queue. This means that we no longer have to take particular care of references to the current capture buffer. --- drivers/stag

[PATCH 2/2] media: cedrus: Remove completed item from TODO list (dma-buf references)

2019-01-24 Thread Paul Kocialkowski
Access to reference frames that were imported from dma-buf was taken care of and is no longer a pending item on the driver's TODO list. Signed-off-by: Paul Kocialkowski --- drivers/staging/media/sunxi/cedrus/TODO | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/staging/

[PATCH 1/2] media: vb2: Keep dma-buf buffers mapped until they are freed

2019-01-24 Thread Paul Kocialkowski
uffer once (when it is first needed when queued) and keep it mapped until it is freed. Signed-off-by: Pawel Osciak Reviewed-on: https://chromium-review.googlesource.com/334103 Signed-off-by: Paul Kocialkowski [Paul: Updated for mainline and changed commit message] --- drivers/media/common/vide

Re: [PATCHv2] vb2: vb2_find_timestamp: drop restriction on buffer state

2019-01-24 Thread Paul Kocialkowski
t copy timestamps. > > This change allows for more efficient pipelining (i.e. you can use > a buffer for a reference frame even when it is queued). > > Signed-off-by: Hans Verkuil Reviewed-by: Paul Kocialkowski I guess I'll prepare a new patch to revert the change I made

Re: [PATCH] media: docs-rst: Document m2m stateless video decoder interface

2019-01-24 Thread Paul Kocialkowski
Hi, On Thu, 2019-01-24 at 17:07 +0900, Tomasz Figa wrote: > On Wed, Jan 23, 2019 at 7:42 PM Paul Kocialkowski > wrote: > > Hi Alex, > > > > On Wed, 2019-01-23 at 18:43 +0900, Alexandre Courbot wrote: > > > On Tue, Jan 22, 2019 at 7:10 PM Paul Koci

Re: [PATCH] media: docs-rst: Document m2m stateless video decoder interface

2019-01-23 Thread Paul Kocialkowski
Hi Alex, On Wed, 2019-01-23 at 18:43 +0900, Alexandre Courbot wrote: > On Tue, Jan 22, 2019 at 7:10 PM Paul Kocialkowski > wrote: > > Hi, > > > > On Tue, 2019-01-22 at 17:19 +0900, Tomasz Figa wrote: > > > Hi Paul, > > > > > > On Fri, De

Re: [PATCH] media: docs-rst: Document m2m stateless video decoder interface

2019-01-22 Thread Paul Kocialkowski
Hi, On Tue, 2019-01-22 at 17:19 +0900, Tomasz Figa wrote: > Hi Paul, > > On Fri, Dec 7, 2018 at 5:30 PM Paul Kocialkowski > wrote: > > Hi, > > > > Thanks for this new version! I only have one comment left, see below. > > > > On Wed, 2018-12-

Re: [PATCH v4 9/9] drm/bridge: cdns: Convert to phy framework

2019-01-17 Thread Sean Paul
ff-by: Maxime Ripard Aside from the wakeup change mentioned in patch 8, Acked-by: Sean Paul > --- > drivers/gpu/drm/bridge/Kconfig| 1 +- > drivers/gpu/drm/bridge/cdns-dsi.c | 485 +++ > drivers/phy/cadence/cdns-dphy.c | 2 +- > 3 files chang

Re: [PATCH v4 8/9] phy: Add Cadence D-PHY support

2019-01-17 Thread Sean Paul
evm_clk_get(&pdev->dev, "pll_ref"); > + if (IS_ERR(dphy->pll_ref_clk)) > + return PTR_ERR(dphy->pll_ref_clk); > + > + if (dphy->ops->probe) { > + ret = dphy->ops->probe(dphy); > + if (ret) >

Re: [PATCH v4 6/9] drm/bridge: cdns: Separate DSI and D-PHY configuration

2019-01-17 Thread Sean Paul
id(struct drm_bridge *bridge, > if ((mode->hdisplay * bpp) % 32) > return MODE_H_ILLEGAL; > > - nlanes = output->dev->lanes; > - > - ret = cdns_dsi_mode2cfg(dsi, mode, &dsi_cfg, &dphy_cfg, true); > + ret = cdns_dsi_check_conf(dsi, mode, &dsi_cfg, &dphy_cfg, true); > if (ret) > - return MODE_CLOCK_RANGE; > + return MODE_BAD; > > return MODE_OK; > } > @@ -990,7 +1030,7 @@ static void cdns_dsi_bridge_enable(struct drm_bridge > *bridge) > bpp = mipi_dsi_pixel_format_to_bpp(output->dev->format); > nlanes = output->dev->lanes; > > - WARN_ON_ONCE(cdns_dsi_mode2cfg(dsi, mode, &dsi_cfg, &dphy_cfg, false)); > + WARN_ON_ONCE(cdns_dsi_check_conf(dsi, mode, &dsi_cfg, &dphy_cfg, > false)); > > cdns_dsi_hs_init(dsi, &dphy_cfg); > cdns_dsi_init_link(dsi); > -- > git-series 0.9.1 -- Sean Paul, Software Engineer, Google / Chromium OS

[PATCH RFC 0/3] media: Ensure access to dma-buf-imported reference buffers

2019-01-14 Thread Paul Kocialkowski
starting with: media: cedrus: Cleanup duplicate declarations from cedrus_dec header Paul Kocialkowski (4): media: vb2: Add helpers to access unselected buffers media: v4l2-mem2mem: Add an optional job_done operation media: cedrus: Request access to reference buffers when decoding media: cedrus

[PATCH RFC 4/4] media: cedrus: Remove completed item from TODO list (dma-buf references)

2019-01-14 Thread Paul Kocialkowski
Access to reference frames that were imported from dma-buf was taken care of and is no longer a pending item on the driver's TODO list. Signed-off-by: Paul Kocialkowski --- drivers/staging/media/sunxi/cedrus/TODO | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/staging/

[PATCH RFC 3/4] media: cedrus: Request access to reference buffers when decoding

2019-01-14 Thread Paul Kocialkowski
Because we need to request and release access to reference buffers that are backed by a dma-buf import, keep track of the buffers used as reference and add the appropriate calls in the device_run and job_done m2m callbacks. The latter is introduced for this purpose. Signed-off-by: Paul

[PATCH RFC 2/4] media: v4l2-mem2mem: Add an optional job_done operation

2019-01-14 Thread Paul Kocialkowski
can be passed to the operation. Delaying the current context clearing should not be a problem since the next call to v4l2_m2m_try_run happens right after that. Signed-off-by: Paul Kocialkowski --- drivers/media/v4l2-core/v4l2-mem2mem.c | 8 ++-- include/media/v4l2-mem2mem.h | 4

[PATCH RFC 1/4] media: vb2: Add helpers to access unselected buffers

2019-01-14 Thread Paul Kocialkowski
-by: Paul Kocialkowski --- .../media/common/videobuf2/videobuf2-core.c | 46 +++ include/media/videobuf2-core.h| 15 ++ 2 files changed, 61 insertions(+) diff --git a/drivers/media/common/videobuf2/videobuf2-core.c b/drivers/media/common/videobuf2/videobuf2

Re: [PATCH 2/2] media: cedrus: Allow using the current dst buffer as reference

2019-01-09 Thread Paul Kocialkowski
Hi, On Wed, 2019-01-09 at 15:29 +0100, Hans Verkuil wrote: > On 01/09/19 15:19, Paul Kocialkowski wrote: > > It was reported that some cases of interleaved video decoding require > > using the current destination buffer as a reference. However, this is > > no longer possi

[PATCH 2/2] media: cedrus: Allow using the current dst buffer as reference

2019-01-09 Thread Paul Kocialkowski
the current destination buffer before resorting to vb2_find_timestamp and use it in MPEG-2. Signed-off-by: Paul Kocialkowski --- drivers/staging/media/sunxi/cedrus/cedrus_dec.c | 13 + drivers/staging/media/sunxi/cedrus/cedrus_dec.h | 2 ++ drivers/staging/media/sunxi/cedrus

  1   2   3   4   5   >