From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D4CCFC43334 for ; Tue, 5 Jul 2022 15:20:16 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=MqRsoWXRzOa0GjGO4F9FOU0/ybv2sa6/s8xKMBa3PYU=; b=tQcPDc/QV/2G9a dyRWktdJCmVktBWtQZTsSAI2kDxtIDwW+dEj7j7bitpvEj7G/ZWjKk18gVnEnj5ljTukX1RLEW42G 6i5lKgOSlNjkXeOE5xMMoTUBLs4YNNMlinv5YNF6dzmUJ8x6Fs1WEjZwO5XDM68dPH+Q+blWzIZzn z/ivD+DIqTcyd+xupkcgzLd510WIcPGeVVRbr2wwR8bC1cB97/wPnRael2L0KTrQyf8BVgl32qJz2 OvHmwOV36Qix4UBeWjPoB4qHxaMj3BMFAMmftuVkfsNXO1kRUIs/VSh5i9Zy4KNkdk+tGtC+kF3i4 PBXd1PXFXFVk9JafQzcQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1o8kLH-0015wd-56; Tue, 05 Jul 2022 15:19:59 +0000 Received: from mail-vs1-xe2a.google.com ([2607:f8b0:4864:20::e2a]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1o8kLD-0015sj-PW for linux-rockchip@lists.infradead.org; Tue, 05 Jul 2022 15:19:57 +0000 Received: by mail-vs1-xe2a.google.com with SMTP id j6so12280554vsi.0 for ; Tue, 05 Jul 2022 08:19:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=vanguardiasur-com-ar.20210112.gappssmtp.com; s=20210112; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to; bh=SKPvviyPL26CyA8l9iar2MIM4Wl98vso25xZ3nSjowU=; b=c0XNEbkP56Uqlf4jbginpW0oHEPYA0t7AvZsiEserqczx9y1nIzJpBNsL8Sc6nrkj/ q2T/YS82/7XzUAAoKEyCWX539afsddUI2xsSnt4prcm+mjMFdB32eOuzeB/EZ8vX30kY bO58EClJSlDOewXEm7SqHBVP309Srux5rkhUkTWEs/pYyCk3AqY9lrqtJetO8Z3ofaun i8OVgiYO/LzH9Igm+AMI5uxUw8y8ljzUSEEYe2E3RO31MCWc39KO5uc6saJfMtQnpPuF rpxBWGIQYgfm4LUJSsPfHkADD/CwTH4HT3F1UUDv7UogtFBxSYJzExYvvgyVWz2CU6kS Io4A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to; bh=SKPvviyPL26CyA8l9iar2MIM4Wl98vso25xZ3nSjowU=; b=C7wdG3zxAXN0VlRqBKLWeREz2myd1RhSFW6FJ7IcrBwOtHE0YWtLlZLMKzxQ4ZIfN5 ++0t65hEfL3lE6IOwjRF8DWPtbD0TMFHGgBejMFyVo5iZyVQYMhl1lO0I3QoM2yuowt0 /SCsc0FvVl7p0HZVWIuLVKXaeTdWOr70WkzurdsN94LRLLUJ5vTOnFNXGpz4M26amtvL cD6JdtRxpJoxF1aHmU9gzwQ/Ovt1ypxNb9BSTC9KfUUzf3MU48EW3dszo+RxfHvlkIiF Vre0gC5Yvjx6LA3lLByQmZ2tlltHQa8wuWrP3Ln2CVwyuk+7I5RjJGNdR5sMuYqvCbvY ATPw== X-Gm-Message-State: AJIora9Ov+0o/mhbDmT/tRD9bBHRwNrdBXd6WDSvKd5ZRQIH/dGAOQnO vyoeIbU8CaLmcHTYm4N4vbIx7Q== X-Google-Smtp-Source: AGRyM1tMBtr7MaG5fInbc7HrIJPJwBQ3Wz4TiiPGLX6OFZzB9OSAQ2Kvd7GK6x+gf0OnNgXpAqo5AA== X-Received: by 2002:a67:b207:0:b0:356:51a5:993e with SMTP id b7-20020a67b207000000b0035651a5993emr19609454vsf.12.1657034390773; Tue, 05 Jul 2022 08:19:50 -0700 (PDT) Received: from eze-laptop ([190.190.187.68]) by smtp.gmail.com with ESMTPSA id b5-20020ab00b05000000b00382a8b1e590sm2980986uak.20.2022.07.05.08.19.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Jul 2022 08:19:49 -0700 (PDT) Date: Tue, 5 Jul 2022 12:19:44 -0300 From: Ezequiel Garcia To: Benjamin Gaignard Cc: mchehab@kernel.org, hverkuil@xs4all.nl, p.zabel@pengutronix.de, gregkh@linuxfoundation.org, mripard@kernel.org, paul.kocialkowski@bootlin.com, wens@csie.org, jernej.skrabec@gmail.com, samuel@sholland.org, nicolas.dufresne@collabora.com, andrzej.p@collabora.com, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-rockchip@lists.infradead.org, linux-staging@lists.linux.dev, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, kernel@collabora.com Subject: Re: [PATCH v10 04/17] media: uapi: HEVC: Add missing fields in HEVC controls Message-ID: References: <20220705085420.272912-1-benjamin.gaignard@collabora.com> <20220705085420.272912-5-benjamin.gaignard@collabora.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <20220705085420.272912-5-benjamin.gaignard@collabora.com> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220705_081955_876024_C83FA941 X-CRM114-Status: GOOD ( 23.25 ) X-BeenThere: linux-rockchip@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Upstream kernel work for Rockchip platforms List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "Linux-rockchip" Errors-To: linux-rockchip-bounces+linux-rockchip=archiver.kernel.org@lists.infradead.org On Tue, Jul 05, 2022 at 10:54:07AM +0200, Benjamin Gaignard wrote: > Complete the HEVC controls with missing fields from H.265 specifications. > Even if these fields aren't used by the current mainlined drivers > they will be required for (at least) the rkvdec driver. > > Signed-off-by: Benjamin Gaignard > Acked-by: Nicolas Dufresne > Tested-by: Jernej Skrabec Reviewed-by: Ezequiel Garcia > --- > version 9: > - fix typo > > .../media/v4l/ext-ctrls-codec.rst | 32 +++++++++++++++++++ > include/media/hevc-ctrls.h | 8 ++++- > 2 files changed, 39 insertions(+), 1 deletion(-) > > diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst > index 6183f43f4d73..cff742142a55 100644 > --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst > +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst > @@ -2683,6 +2683,16 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - > :stub-columns: 0 > :widths: 1 1 2 > > + * - __u8 > + - ``video_parameter_set_id`` > + - Specifies the value of the vps_video_parameter_set_id of the active VPS > + as described in section "7.4.3.2.1 General sequence parameter set RBSP semantics" > + of H.265 specifications. > + * - __u8 > + - ``seq_parameter_set_id`` > + - Provides an identifier for the SPS for reference by other syntax elements > + as described in section "7.4.3.2.1 General sequence parameter set RBSP semantics" > + of H.265 specifications. > * - __u16 > - ``pic_width_in_luma_samples`` > - > @@ -2822,6 +2832,9 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - > :stub-columns: 0 > :widths: 1 1 2 > > + * - __u8 > + - ``pic_parameter_set_id`` > + - Identifies the PPS for reference by other syntax elements. > * - __u8 > - ``num_extra_slice_header_bits`` > - > @@ -3048,6 +3061,15 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - > * - __u8 > - ``ref_idx_l1[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]`` > - The list of L1 reference elements as indices in the DPB. > + * - __u16 > + - ``short_term_ref_pic_set_size`` > + - Specifies the size, in bits, of the short-term reference picture set, described as st_ref_pic_set() > + in the specification, included in the slice header or SPS (section 7.3.6.1). > + * - __u16 > + - ``long_term_ref_pic_set_size`` > + - Specifies the size, in bits, of the long-term reference picture set include in the slice header > + or SPS. It is the number of bits in the conditional block if(long_term_ref_pics_present_flag) > + in section 7.3.6.1 of the specification. > * - __u8 > - ``padding`` > - Applications and drivers must set this to zero. > @@ -3385,6 +3407,16 @@ enum v4l2_mpeg_video_hevc_size_of_length_field - > - ``pic_order_cnt_val`` > - PicOrderCntVal as described in section 8.3.1 "Decoding process > for picture order count" of the specification. > + * - __u16 > + - ``short_term_ref_pic_set_size`` > + - Specifies the size, in bits, of the short-term reference picture set, of the first slice > + described as st_ref_pic_set() in the specification, included in the slice header > + or SPS (section 7.3.6.1). > + * - __u16 > + - ``long_term_ref_pic_set_size`` > + - Specifies the size, in bits, of the long-term reference picture set, of the first slice > + included in the slice header or SPS. It is the number of bits in the conditional block > + if(long_term_ref_pics_present_flag) in section 7.3.6.1 of the specification. > * - __u8 > - ``num_active_dpb_entries`` > - The number of entries in ``dpb``. > diff --git a/include/media/hevc-ctrls.h b/include/media/hevc-ctrls.h > index 01ccda48d8c5..752a8d10782c 100644 > --- a/include/media/hevc-ctrls.h > +++ b/include/media/hevc-ctrls.h > @@ -58,6 +58,8 @@ enum v4l2_mpeg_video_hevc_start_code { > /* The controls are not stable at the moment and will likely be reworked. */ > struct v4l2_ctrl_hevc_sps { > /* ISO/IEC 23008-2, ITU-T Rec. H.265: Sequence parameter set */ > + __u8 video_parameter_set_id; > + __u8 seq_parameter_set_id; > __u16 pic_width_in_luma_samples; > __u16 pic_height_in_luma_samples; > __u8 bit_depth_luma_minus8; > @@ -108,6 +110,7 @@ struct v4l2_ctrl_hevc_sps { > > struct v4l2_ctrl_hevc_pps { > /* ISO/IEC 23008-2, ITU-T Rec. H.265: Picture parameter set */ > + __u8 pic_parameter_set_id; > __u8 num_extra_slice_header_bits; > __u8 num_ref_idx_l0_default_active_minus1; > __u8 num_ref_idx_l1_default_active_minus1; > @@ -199,7 +202,8 @@ struct v4l2_ctrl_hevc_slice_params { > __u32 slice_segment_addr; > __u8 ref_idx_l0[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]; > __u8 ref_idx_l1[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]; > - > + __u16 short_term_ref_pic_set_size; > + __u16 long_term_ref_pic_set_size; > __u8 padding; > > /* ISO/IEC 23008-2, ITU-T Rec. H.265: Weighted prediction parameter */ > @@ -214,6 +218,8 @@ struct v4l2_ctrl_hevc_slice_params { > > struct v4l2_ctrl_hevc_decode_params { > __s32 pic_order_cnt_val; > + __u16 short_term_ref_pic_set_size; > + __u16 long_term_ref_pic_set_size; > __u8 num_active_dpb_entries; > struct v4l2_hevc_dpb_entry dpb[V4L2_HEVC_DPB_ENTRIES_NUM_MAX]; > __u8 num_poc_st_curr_before; > -- > 2.32.0 > _______________________________________________ Linux-rockchip mailing list Linux-rockchip@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-rockchip