From patchwork Sun Jul 5 12:11:25 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanimir Varbanov X-Patchwork-Id: 234830 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp3932782ilg; Sun, 5 Jul 2020 05:12:22 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwgxDKf3nyqHY7On4nKSPjwXxIFvaSeDm9xx1FvTgQ8BDTEtUtuR3q5RsCo4OAxA/LvHeVb X-Received: by 2002:a17:906:d9d9:: with SMTP id qk25mr41649312ejb.448.1593951142374; Sun, 05 Jul 2020 05:12:22 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593951142; cv=none; d=google.com; s=arc-20160816; b=Dms6eDx2GisLxuCqd6fPPsO8nPl6POUhIfD6tu9oFbug22ZslvYdTM04QS4xzAOOPX Y2luzLnT3zP/mEQCzIdYF5HrfKUsYf1IsIiAY6+gYOwBHwafUaqe4uIsTS9w7EM5Q2Cc PvUPxEynIPuijN9d41ISAVAEJyILL9dSl79EvmMNhyrxDkMvCCwH7b1zR8Wwip3c2FfL AFbOiCWbLy+HTL5/mpZLrgdbuPLu+RjkUlvD6q0TbRnfWHqCEeaRBIwo/q5Ho6ouWmfA wkMvHK7k+QMqM71noKijoULO41dksWE77+Ph8LKbh3XXHpLsPRW0K3/XOzCTMstzv0+k xauQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=c3pGEpF7DAEXcC0pN3mSKCevTRzMwQB5I1tTMzDxF0M=; b=Q/nxqU9hmUULshPm8cdsUFK/gjWCmoh9GQDGnnpar1McCAvl+uYEsbQt2lXDC2U5Qx OQ1K7rYGBPRkIcf+v7BJcSfxfJFXGizHdlHbhrZNqikgIt2KIEVIV8zSLQLaAl0TJv3U vjNQHWezm0rHQcEZ4B0zTcdOEw+5UiE1zakogHnxbes59D8ZZbQods9N/KIlU92tvklM NixpZY8u5sOyHaVnqOQ0G70NCxkGz+PGrpv3HGYC/w9sBl1qCiSJNLeNj2FfUd/vYh+Q 5Bjr6VwbSYJ2eGXeYR6fKkN1qTZhMiVP8vKwzZKaaFnmqXvO7nXeUuO5psJW4bBnOqO3 s5Zg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vbZMpbtL; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f1si10612706eje.610.2020.07.05.05.12.22; Sun, 05 Jul 2020 05:12:22 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=vbZMpbtL; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726961AbgGEMME (ORCPT + 4 others); Sun, 5 Jul 2020 08:12:04 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39972 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726933AbgGEMME (ORCPT ); Sun, 5 Jul 2020 08:12:04 -0400 Received: from mail-ej1-x641.google.com (mail-ej1-x641.google.com [IPv6:2a00:1450:4864:20::641]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B9546C08C5DF for ; Sun, 5 Jul 2020 05:12:03 -0700 (PDT) Received: by mail-ej1-x641.google.com with SMTP id n26so25598767ejx.0 for ; Sun, 05 Jul 2020 05:12:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=c3pGEpF7DAEXcC0pN3mSKCevTRzMwQB5I1tTMzDxF0M=; b=vbZMpbtLs7CMVmEYX3n7vzrtz2n0vXIVLeeIYUduO9/JCmDVzmpE694X79b/QX8vbk g79hDHalKGmtcUL12AUmRKvMKm1EBXLb1nyJH7sS/R7R/YunYkUlpLDWakrxNIHfvO6m EKYd5Rghwsgo34jU1V8Kk0yV/7jBrcc2tPGQupqn0K7yl83ucAPK/zzudLC2BH4e65tx X6O3YYZ4f1tloPGYPuULuSiNoZMYUuIBy6Osww1D0Bmx0lXeoKn9uByUILggLchm9IKF grffUmDqIbnH+zRGIG70MjEr5QUfwh2NgcV/iWw1zagwRdSt8ZqA9jRqThntJprFW5Ar nqwg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=c3pGEpF7DAEXcC0pN3mSKCevTRzMwQB5I1tTMzDxF0M=; b=lj/i1jEprxzbVlcwEwomcMO6qoNCtEdHL9iLK6EdFA6kvF6B6NTJYAxf+7EKUtMH5v Z/64yo+fbrioWa8CXci13/Hv6cH/MlgBSWhDlJSAl/jPLVvegxz3qsUZ9ZuNJTSkl054 sPddEpc0HVjtnfePp1unfytuvtYNNZGZ7Eft/5CO5C5X2EVQgXyW7XnRtEsmTihDoGer QExpQlN+x2b4mlOdcF2kxI37sViXBSC86W1RivH52rBDcsOotH13Q5WXjqxW2FlyPP+8 b+gUngZGJ5//Ds8bcWTXEHF3bWsh1emTohSkcODGEFY3/GqdCV/+N8OlY9ARY1IDpqTi yhbg== X-Gm-Message-State: AOAM5333l0azaG/AHIY5wc3719DZdx0DUIzYHf0UOWKxAM6GR+7zMc6u pHNi5JOnhZZXBv9y9QL8ZTPY12Qn2EcZKA== X-Received: by 2002:a17:906:8316:: with SMTP id j22mr38504760ejx.97.1593951122243; Sun, 05 Jul 2020 05:12:02 -0700 (PDT) Received: from localhost.localdomain (212-5-158-133.ip.btc-net.bg. [212.5.158.133]) by smtp.gmail.com with ESMTPSA id j64sm1517458edd.61.2020.07.05.05.12.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 05 Jul 2020 05:12:01 -0700 (PDT) From: Stanimir Varbanov To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Kyungmin Park , Kamil Debski , Jeongtae Park , Andrzej Hajda , Hans Verkuil , Maheshwar Ajja , Stanimir Varbanov Subject: [PATCH 1/4] media: v4l2-ctrl: Add frame-skip std encoder control Date: Sun, 5 Jul 2020 15:11:25 +0300 Message-Id: <20200705121128.5250-2-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200705121128.5250-1-stanimir.varbanov@linaro.org> References: <20200705121128.5250-1-stanimir.varbanov@linaro.org> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Adds encoders standard v4l2 control for frame-skip. The control is a copy of a custom encoder control so that other v4l2 encoder drivers can use it. Signed-off-by: Stanimir Varbanov --- .../media/v4l/ext-ctrls-codec.rst | 32 +++++++++++++++++++ drivers/media/v4l2-core/v4l2-ctrls.c | 10 ++++++ include/uapi/linux/v4l2-controls.h | 6 ++++ 3 files changed, 48 insertions(+) -- 2.17.1 diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst index d0d506a444b1..a8b4c0b40747 100644 --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst @@ -592,6 +592,38 @@ enum v4l2_mpeg_video_bitrate_mode - the average video bitrate. It is ignored if the video bitrate mode is set to constant bitrate. +``V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE (enum)`` + +enum v4l2_mpeg_video_frame_skip_mode - + Indicates in what conditions the encoder should skip frames. If + encoding a frame would cause the encoded stream to be larger then a + chosen data limit then the frame will be skipped. Possible values + are: + + +.. tabularcolumns:: |p{9.2cm}|p{8.3cm}| + +.. raw:: latex + + \small + +.. flat-table:: + :header-rows: 0 + :stub-columns: 0 + + * - ``V4L2_MPEG_FRAME_SKIP_MODE_DISABLED`` + - Frame skip mode is disabled. + * - ``V4L2_MPEG_FRAME_SKIP_MODE_LEVEL_LIMIT`` + - Frame skip mode enabled and buffer limit is set by the chosen + level and is defined by the standard. + * - ``V4L2_MPEG_FRAME_SKIP_MODE_BUF_LIMIT`` + - Frame skip mode enabled and buffer limit is set by the VBV + (MPEG1/2/4) or CPB (H264) buffer size control. + +.. raw:: latex + + \normalsize + ``V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION (integer)`` For every captured frame, skip this many subsequent frames (default 0). diff --git a/drivers/media/v4l2-core/v4l2-ctrls.c b/drivers/media/v4l2-core/v4l2-ctrls.c index 3f3fbcd60cc6..d088acfa6dd8 100644 --- a/drivers/media/v4l2-core/v4l2-ctrls.c +++ b/drivers/media/v4l2-core/v4l2-ctrls.c @@ -590,6 +590,12 @@ const char * const *v4l2_ctrl_get_menu(u32 id) "External", NULL, }; + static const char * const mpeg_video_frame_skip[] = { + "Disabled", + "Level Limit", + "VBV/CPB Limit", + NULL, + }; switch (id) { case V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ: @@ -651,6 +657,8 @@ const char * const *v4l2_ctrl_get_menu(u32 id) return flash_strobe_source; case V4L2_CID_MPEG_VIDEO_HEADER_MODE: return header_mode; + case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: + return mpeg_video_frame_skip; case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: return multi_slice; case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: @@ -844,6 +852,7 @@ const char *v4l2_ctrl_get_name(u32 id) case V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE: return "H264 MB Level Rate Control"; case V4L2_CID_MPEG_VIDEO_HEADER_MODE: return "Sequence Header Mode"; case V4L2_CID_MPEG_VIDEO_MAX_REF_PIC: return "Max Number of Reference Pics"; + case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: return "Frame Skip Mode"; case V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP: return "H263 I-Frame QP Value"; case V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP: return "H263 P-Frame QP Value"; case V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP: return "H263 B-Frame QP Value"; @@ -1265,6 +1274,7 @@ void v4l2_ctrl_fill(u32 id, const char **name, enum v4l2_ctrl_type *type, case V4L2_CID_FLASH_LED_MODE: case V4L2_CID_FLASH_STROBE_SOURCE: case V4L2_CID_MPEG_VIDEO_HEADER_MODE: + case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: case V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE: case V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE: case V4L2_CID_MPEG_VIDEO_H264_LEVEL: diff --git a/include/uapi/linux/v4l2-controls.h b/include/uapi/linux/v4l2-controls.h index 62271418c1be..4e1526175a4c 100644 --- a/include/uapi/linux/v4l2-controls.h +++ b/include/uapi/linux/v4l2-controls.h @@ -742,6 +742,12 @@ enum v4l2_cid_mpeg_video_hevc_size_of_length_field { #define V4L2_CID_MPEG_VIDEO_HEVC_HIER_CODING_L6_BR (V4L2_CID_MPEG_BASE + 642) #define V4L2_CID_MPEG_VIDEO_REF_NUMBER_FOR_PFRAMES (V4L2_CID_MPEG_BASE + 643) #define V4L2_CID_MPEG_VIDEO_PREPEND_SPSPPS_TO_IDR (V4L2_CID_MPEG_BASE + 644) +#define V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE (V4L2_CID_MPEG_BASE + 645) +enum v4l2_mpeg_video_frame_skip_mode { + V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED = 0, + V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT = 1, + V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT = 2, +}; /* MPEG-class control IDs specific to the CX2341x driver as defined by V4L2 */ #define V4L2_CID_MPEG_CX2341X_BASE (V4L2_CTRL_CLASS_MPEG | 0x1000) From patchwork Sun Jul 5 12:11:26 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanimir Varbanov X-Patchwork-Id: 234829 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp3932769ilg; Sun, 5 Jul 2020 05:12:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJztSC0foxjWtJjYxoaOTilvdUD02SX5rrS+Wyu3VjL4ApZPyv9aUlmMyRDXLJFZhhjFBtsi X-Received: by 2002:a17:906:3446:: with SMTP id d6mr34397393ejb.323.1593951141607; Sun, 05 Jul 2020 05:12:21 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593951141; cv=none; d=google.com; s=arc-20160816; b=akKGmqaOVxplS/qm7wqVrtl7z4vd3mlWytXSNZt7vJin74msfN/RNpdljmKfvWJWe3 XjUBOn2jv2VrTGzBUoTdBwDx8Y4G7jTk8ZET/cpRxstHWCy3szREEb+fSHAx5McnhE24 8YdYmihBRTiN+fJ2nU7eHHEEB6i5Oo0LbCeNTW8I+iBzTMeDk1Y4mYsxFg4o4Bzy7Ju1 vfQVSb0XGgW/P3j6fqrjNC+K5OHsymc8rmxPCUuwVvH6445cY52uwiKChAUYut9CwV2X aHUBwmEIA1XqXni8iiUs9Psck4Oafr+fJvfP0Ulxw6UBA/9JN1/vWeAm5EAv/9zK2IRJ g6uw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=PVmLU+hVnh8Nuu06hzfy+sP04k3OApAgFHgahioSu+I=; b=zK4YihAvQTXrBMYtDYkEeB1Blv4/x0/6zo1B3RKHst+YE27z0fBHTi0jFzv1oGrDlm sXQ06MYR+N6K8yS31a3X3YOCphmFoY+rwRz2QDJjPdGL01Zeq26S4AGxLx06c7KRUqO7 zKHaJzglNbuP7NGwldY9Ry6n040KPIjlTjNjLoi7RzHCSxlAf3rLSz++qDF+avZoqdnn 9YZaOQOVOR32Z1+9DOsXyz6q6zOnrNv1He9Sqsap2P7alA5Ek8eCN46nME9+skqX4Od7 JmZ2BMXg9b4FbBjIanFaOs8eOekJE3dhCzf3NuDQynvTHQWTsG4wZmbGJPV57bad70qA OEzg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HdJZqMAC; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id f1si10612706eje.610.2020.07.05.05.12.21; Sun, 05 Jul 2020 05:12:21 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=HdJZqMAC; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727043AbgGEMMI (ORCPT + 4 others); Sun, 5 Jul 2020 08:12:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39982 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727028AbgGEMMH (ORCPT ); Sun, 5 Jul 2020 08:12:07 -0400 Received: from mail-ej1-x644.google.com (mail-ej1-x644.google.com [IPv6:2a00:1450:4864:20::644]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 8E50BC08C5DF for ; Sun, 5 Jul 2020 05:12:06 -0700 (PDT) Received: by mail-ej1-x644.google.com with SMTP id w16so39537058ejj.5 for ; Sun, 05 Jul 2020 05:12:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=PVmLU+hVnh8Nuu06hzfy+sP04k3OApAgFHgahioSu+I=; b=HdJZqMAC9vwDwq/2+iB7h9yJXCGAIGf8xNMQ9liFjhLi/fvb1XZzTeWNBYjSiMHKOa 98mdSBS50YvGC0BDVIhjIAFTKcDlIyz92ScwSNbaxLdwW6nf7N6Cj/zKQIe4jq7t2GvX wi+NVJRogKGWybka9wuVMlNXfLtjuhLHL0rZlVSNg//AcGoqJU1V43CPFBxjCSoK6zrB 71KTZXPIyrDe+8RGyBhMaNUxMYCKdwbTc1Ghw6QNClu8AH4nbo72658WQJefPVrbG/51 wDZsc7GMLht95gL3fkIsHaXRHdSFYj3mdO7pfHCvFX2yjFo0NPMC+JiMfVWs7wEH1dte i9+Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=PVmLU+hVnh8Nuu06hzfy+sP04k3OApAgFHgahioSu+I=; b=hL/mpkAbzozWSO7IDXapkgPwOUVjQV7tfg+GLnVVl8LTyfDAxQoUWfVI7yGjn3E4KT q+E6K4y/HRjjhJchC3jOEFXLGHND+lNdsSbX7623KYHYnfidr9CHJqz9gvMCjSQO/Wed 5l5K50MU9IJ1jkonALnmBw89MOD4eLtJFAm7Q3cISr76Qvi2MjLoa6PaMS6PkzT3UMHc PI5s/NwxXFI5CPBqO4sHHHxyNkovcfiyJcUfb5lz1tdGm+kSHsHTN3NQN6yCAVL70tHf QWRerMxGm2LJOPucIjCy72S6zPF1kcysiHC9a1XSmOWTxoxHED8GBnkR9F6ed2BA6FGE mjpQ== X-Gm-Message-State: AOAM532E7F91ONiBAFndbyaOpXWLeGwRRp7N+FhltPdslr9sUgutParV 8Cyyr7jUuVnchajdRFTlaCFRnPAfWSGR/Q== X-Received: by 2002:a17:906:1a59:: with SMTP id j25mr37496895ejf.398.1593951125047; Sun, 05 Jul 2020 05:12:05 -0700 (PDT) Received: from localhost.localdomain (212-5-158-133.ip.btc-net.bg. [212.5.158.133]) by smtp.gmail.com with ESMTPSA id j64sm1517458edd.61.2020.07.05.05.12.03 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 05 Jul 2020 05:12:04 -0700 (PDT) From: Stanimir Varbanov To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Kyungmin Park , Kamil Debski , Jeongtae Park , Andrzej Hajda , Hans Verkuil , Maheshwar Ajja , Stanimir Varbanov Subject: [PATCH 2/4] venus: venc: Add support for frame-skip mode v4l2 control Date: Sun, 5 Jul 2020 15:11:26 +0300 Message-Id: <20200705121128.5250-3-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200705121128.5250-1-stanimir.varbanov@linaro.org> References: <20200705121128.5250-1-stanimir.varbanov@linaro.org> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org This adds support for frame-skip-mode standard v4l2 control in encoder driver. The control is implemented based on the combination of client selected bitrate-mode and frame-skip-mode. Once The client selected bitrate-mode (constant or variable) and the frame-skip-mode is not disabled we set variable framerate for rate controller. Signed-off-by: Stanimir Varbanov --- drivers/media/platform/qcom/venus/core.h | 1 + drivers/media/platform/qcom/venus/venc.c | 6 ++++-- drivers/media/platform/qcom/venus/venc_ctrls.c | 12 +++++++++++- 3 files changed, 16 insertions(+), 3 deletions(-) -- 2.17.1 diff --git a/drivers/media/platform/qcom/venus/core.h b/drivers/media/platform/qcom/venus/core.h index 7118612673c9..5e74d0441592 100644 --- a/drivers/media/platform/qcom/venus/core.h +++ b/drivers/media/platform/qcom/venus/core.h @@ -201,6 +201,7 @@ struct venc_controls { u32 bitrate; u32 bitrate_peak; u32 rc_enable; + u32 frame_skip_mode; u32 h264_i_period; u32 h264_entropy_mode; diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c index 513bbc07f7bc..2279596d4d60 100644 --- a/drivers/media/platform/qcom/venus/venc.c +++ b/drivers/media/platform/qcom/venus/venc.c @@ -739,9 +739,11 @@ static int venc_set_properties(struct venus_inst *inst) if (!ctr->rc_enable) rate_control = HFI_RATE_CONTROL_OFF; else if (ctr->bitrate_mode == V4L2_MPEG_VIDEO_BITRATE_MODE_VBR) - rate_control = HFI_RATE_CONTROL_VBR_CFR; + rate_control = ctr->frame_skip_mode ? HFI_RATE_CONTROL_VBR_VFR : + HFI_RATE_CONTROL_VBR_CFR; else - rate_control = HFI_RATE_CONTROL_CBR_CFR; + rate_control = ctr->frame_skip_mode ? HFI_RATE_CONTROL_CBR_VFR : + HFI_RATE_CONTROL_CBR_CFR; ptype = HFI_PROPERTY_PARAM_VENC_RATE_CONTROL; ret = hfi_session_set_property(inst, ptype, &rate_control); diff --git a/drivers/media/platform/qcom/venus/venc_ctrls.c b/drivers/media/platform/qcom/venus/venc_ctrls.c index 8362dde7949e..a418d7d6db0c 100644 --- a/drivers/media/platform/qcom/venus/venc_ctrls.c +++ b/drivers/media/platform/qcom/venus/venc_ctrls.c @@ -202,6 +202,9 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: ctr->rc_enable = ctrl->val; break; + case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: + ctr->frame_skip_mode = ctrl->val; + break; default: return -EINVAL; } @@ -217,7 +220,7 @@ int venc_ctrl_init(struct venus_inst *inst) { int ret; - ret = v4l2_ctrl_handler_init(&inst->ctrl_handler, 31); + ret = v4l2_ctrl_handler_init(&inst->ctrl_handler, 32); if (ret) return ret; @@ -357,6 +360,13 @@ int venc_ctrl_init(struct venus_inst *inst) v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE, 0, 1, 1, 1); + v4l2_ctrl_new_std_menu(&inst->ctrl_handler, &venc_ctrl_ops, + V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE, + V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, + ~((1 << V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED) | + (1 << V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT)), + V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED); + ret = inst->ctrl_handler.error; if (ret) goto err; From patchwork Sun Jul 5 12:11:27 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanimir Varbanov X-Patchwork-Id: 234827 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp3932620ilg; Sun, 5 Jul 2020 05:12:11 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwFWqPsKRP2DvrTAg2Ago3s/aqoodzCiVYqyEpSW25kwr1w6vUlo2Hd6r4Tw7b2qxFR7MoM X-Received: by 2002:a17:906:8316:: with SMTP id j22mr38505153ejx.97.1593951131800; Sun, 05 Jul 2020 05:12:11 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593951131; cv=none; d=google.com; s=arc-20160816; b=Ir/PpllEIdtYE60zeCJOV0uNLGtR69lyeEXA/DGI1Uz6CAxBIvO2UtpGWRW8Y6rJPY KLqLKRe8GpKKSoeIhnBkERBElY9Zx8x812uMG2CuDWsZXe2VLk79aXm1Igd7VlHa8Rvw 6gLa1swjWx1jxpLcP45dCy6njFYWyj/WVza1qt8tASivs5j8+sZh89K0ZESEm5q5rc64 aUJgJNJBQPAIhPHBpWertsQ1HZ+O41vT10+j2JVezYmx+cTc9GRmOrpLbM0NUfoZHD78 6CTt9UhRakLjBP0qwVn8+1UUDyvt0HLd3huQs9bVsJMGR0tRDceCxwbkmKQxACxcdLtu 667w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=PCNLmGR8sMtBYV74iVoiny++gKyFU6QKve9J6ft8KaU=; b=NJ+XYqh2l2schzl/zzkZAkTfEjZ6Hpsmz1VwghdvMRe1RmwH3iACwTu6GdMDeGAc4f /sEqblyfTEUgkwwbYAlV8MjTYsK+UMeV2rLXqmvTyjjUn96a/2IsGZA/DxFp1PzLr8s5 d0ccZBVtob27PYFBUaeGcbByBwtQtkG5GcX3CMSTIIK+U8Thr4wBlhzHaC7iwZFRzNRv 5MXvUimwb4j224mkk4kgLr59tFWmCtlTp51e1P6DZO71qzEdnMG5eKWMx1MBQQfK2XF5 MDO/I508g3B5njEayiKkdukDepKPi4DTPs1B9oc9Cj8tqyiLK/OSXVwamqR86sGR2SJ/ E6Vg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="K/7rA4K4"; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id r22si11728725edq.411.2020.07.05.05.12.11; Sun, 05 Jul 2020 05:12:11 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="K/7rA4K4"; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727062AbgGEMMJ (ORCPT + 4 others); Sun, 5 Jul 2020 08:12:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:39994 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727052AbgGEMMJ (ORCPT ); Sun, 5 Jul 2020 08:12:09 -0400 Received: from mail-ed1-x542.google.com (mail-ed1-x542.google.com [IPv6:2a00:1450:4864:20::542]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C891CC08C5DF for ; Sun, 5 Jul 2020 05:12:08 -0700 (PDT) Received: by mail-ed1-x542.google.com with SMTP id by13so22272376edb.11 for ; Sun, 05 Jul 2020 05:12:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=PCNLmGR8sMtBYV74iVoiny++gKyFU6QKve9J6ft8KaU=; b=K/7rA4K4EI8hH3WgLD9Nf1fvOjaQ2N3MAe9A9/Q+DJx/2ssL1Qe4HiABlOUCSkqgWw JAlYHMnQbaZkFA1GCxToq1heUQvMw4zBb1asjEsuCMT7CyN/hpN4eFNbkGR3uMO6NVyV KmSWfYWLxCVEipYByTksOCBLMyMtwvaLO1xmibJFqSdDo45h5/2bNFh7mE8epKXLn5M1 UX7W4uTFx38idvXGt1L1olIZTTv3YXLtyeqTNxrJ8rbQseZwicHF6JvvrMkldIazkioa +UObmDI13lhx1SB+NXQBsWu/Qh7Wqe2DblVQ2aOiUw5R3qu1kb/QSyoQMo42cXONv2Oz A1yw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=PCNLmGR8sMtBYV74iVoiny++gKyFU6QKve9J6ft8KaU=; b=rZJbT5d6mh+1Bm66hyndTZYK7uJ3nVJZYQXyBGsl0nfhH34VXhWex0W1Bzab41i8/R cGXJb4f1nKLoLlJe3uS3XsW9pM1otm5xj1X8dgzplhLuj9kTPr92xkSfbbQuVNy+uMMi JwOoOB55BH1uUWEZJ2PPQHVzl6Q+3zQkadOr2n6BIxKRAwd5RjF+aeZfJX/6c9SERhF9 HidXUeWV3OaupIrLUZvBnyhrVgsDHdXgD3fDhIeHpjVONHbzfKInpOBzlFPtVrSheseO YnWL2LiV3G5ZJXh0LWTt/+nkzUoCvWzASkdnItl/WOBcoBVbp4eecy3Eu2/liymCKOko n8MA== X-Gm-Message-State: AOAM532Jl1MF2qF5xJfMpOVtOmxc0qwpkFMVrzgKy9PIxJivk3J2xikE FsoXeee2HRTZGsy2W9KsaFCT9H3IaibogQ== X-Received: by 2002:aa7:c2cf:: with SMTP id m15mr25321916edp.27.1593951127381; Sun, 05 Jul 2020 05:12:07 -0700 (PDT) Received: from localhost.localdomain (212-5-158-133.ip.btc-net.bg. [212.5.158.133]) by smtp.gmail.com with ESMTPSA id j64sm1517458edd.61.2020.07.05.05.12.05 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 05 Jul 2020 05:12:06 -0700 (PDT) From: Stanimir Varbanov To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Kyungmin Park , Kamil Debski , Jeongtae Park , Andrzej Hajda , Hans Verkuil , Maheshwar Ajja , Stanimir Varbanov Subject: [PATCH 3/4] media: s5p-mfc: Use standard frame skip mode control Date: Sun, 5 Jul 2020 15:11:27 +0300 Message-Id: <20200705121128.5250-4-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200705121128.5250-1-stanimir.varbanov@linaro.org> References: <20200705121128.5250-1-stanimir.varbanov@linaro.org> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Use the standard menu control for frame skip mode in the MFC driver. The legacy private menu control is kept for backward compatibility. Signed-off-by: Stanimir Varbanov --- drivers/media/platform/s5p-mfc/s5p_mfc_enc.c | 6 ++++++ 1 file changed, 6 insertions(+) -- 2.17.1 diff --git a/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c b/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c index 912fe0c5ab18..3092eb6777a5 100644 --- a/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c +++ b/drivers/media/platform/s5p-mfc/s5p_mfc_enc.c @@ -261,6 +261,11 @@ static struct mfc_control controls[] = { .menu_skip_mask = 0, .default_value = V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED, }, + { + .id = V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE, + .maximum = V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT, + .default_value = V4L2_MPEG_VIDEO_FRAME_SKIP_MODE_DISABLED, + }, { .id = V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT, .type = V4L2_CTRL_TYPE_BOOLEAN, @@ -1849,6 +1854,7 @@ static int s5p_mfc_enc_s_ctrl(struct v4l2_ctrl *ctrl) p->seq_hdr_mode = ctrl->val; break; case V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE: + case V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE: p->frame_skip_mode = ctrl->val; break; case V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT: From patchwork Sun Jul 5 12:11:28 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stanimir Varbanov X-Patchwork-Id: 234828 Delivered-To: patch@linaro.org Received: by 2002:a92:d244:0:0:0:0:0 with SMTP id v4csp3932686ilg; Sun, 5 Jul 2020 05:12:15 -0700 (PDT) X-Google-Smtp-Source: ABdhPJznoMs+RCD1MH4l1+x1GDjSSlMlt4UfyC0oktycUTStxbPzio8dkOWkwtzcsozkUo/fEmVI X-Received: by 2002:a05:6402:30b2:: with SMTP id df18mr50656412edb.229.1593951135819; Sun, 05 Jul 2020 05:12:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1593951135; cv=none; d=google.com; s=arc-20160816; b=qh88LywqZgTMHjQ6nncEGxjgOkAckOLbsjELY0EJwhaY3dL0TiTKVg0uunjksUjZLS aggt9Aru49eJup8rnn7fICOD9wecVr2Ywc+j6M1GlZDmWz+4OqelaDGam6B/CuBCC1zT sj135+F8tj1QO3OBNZn12GTxLcD+K0sLAayMSboDTtgz53pLKYlOp8O6wPSuQ2Or+o3e m6DfvsdNGk8shm9Yi0dxisGknp5r94WhN/MvH0NeJWFl9Dn5zjzVePnELFmcCoXeAKSv C459lQdG7oaY4M3n2tCzGXWgRKw4+VEf1WLCaZqsqTeSwsgnUj4G+l6gRVxMc6XLz/l9 s2Xg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature; bh=7mX8hu/WWjnwnEyPTlU3MGnHpJuzqdu2Apw48vMC6z4=; b=LXGX5aHt+kZd8hwAHQvv35UbkRxZgYkC8r7gxn4SeD/G/HnrxYQwLLMIuNUeDsGvjR p6pYpZQBIQtj1UKoTcAtFrBn+dcrYzoA6pld9A5RCbF2c3C00bOUGl4PlIkCgqXqIYdV dd3pT+vqW7wqSAAsYNSN8H2gmsVMOrYuy3uOTBqfXrnB7a35KvlfUvXWVyhZ0nqxXPHR aTJVnKE3jcKPBhERCw0OXiABhDThZj1azuth62DQqazVnD7XC1oRLTs01u0jBSnjFmvx B1zhDVT/tjh87YDnrB1L+pV2GyehEmEbOME/HU6nSeD0MP2GcUEbDLRlGfpgFX3/vck0 IYVw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FynBPSjD; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id jp14si11462033ejb.93.2020.07.05.05.12.15; Sun, 05 Jul 2020 05:12:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FynBPSjD; spf=pass (google.com: domain of linux-media-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-media-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727064AbgGEMMM (ORCPT + 4 others); Sun, 5 Jul 2020 08:12:12 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40006 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727063AbgGEMML (ORCPT ); Sun, 5 Jul 2020 08:12:11 -0400 Received: from mail-ej1-x642.google.com (mail-ej1-x642.google.com [IPv6:2a00:1450:4864:20::642]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 08A74C08C5DF for ; Sun, 5 Jul 2020 05:12:11 -0700 (PDT) Received: by mail-ej1-x642.google.com with SMTP id lx13so20879957ejb.4 for ; Sun, 05 Jul 2020 05:12:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=7mX8hu/WWjnwnEyPTlU3MGnHpJuzqdu2Apw48vMC6z4=; b=FynBPSjDhveS96iN5Y0RalC1idg3UpwKXyEYfOeZzLo2ogVhqEy87dxLuAgtsox3SM 0whLGGo62pu83HJdLhY3CrWldzxYFN460mOqGomto6LXz36fymnmJfA5Mufh+qQx9M/W ao69skQFA9ywZgRdnrpEF6yM9wnsf97mBvIohYf4H8h/2UmxfVy6d2dv+9Zl4T/ysM8E S4LCilQdYEyxH4J8KMn/ILcOUrCmy9HSb+B6nLw+zXb8sywWxFkWREcJul+F5CNwIMmW B7xIeo2WhAv5C0/kge5WGslynFQ1q32Ve9xBUaGvTvhJTtG61gKKXs1wvOeX+de/Shzy w+pA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=7mX8hu/WWjnwnEyPTlU3MGnHpJuzqdu2Apw48vMC6z4=; b=ki3We/OTFV8m5/MVy3bYqvk/z5+DjT56LXZzKVDcY8hdbaaY5+CBREeL225E+YAseW 2/FYWmh1U51TnqTtSI73sfXeAJCmEUjqv/ypD/AgTzyODii3dz1781mL9gquPyd/jUMv 59qAZowc2PlAGAkqSf9fY9yXJrBtAjAq/x9mMKjKP7TFA2IeokMd2/sdiqzVuE5T7LYq rs/J5lZr6SajsBMxkm5ONCGkz4NyuwBUoOoZHQmt0aHZ/CMEy+Q+/srgr2eOUaPGGjlq i3R10gvyMTza9FsZeaRgPZM/pGEUO5VRGj/GtULOYSde+9Y3W7Z0VfIgImPhS2Xeuxzj 2CTg== X-Gm-Message-State: AOAM5334vsxSOsR80GYoFutQdMk+L8VmuDv6sfhIHJQJKmVMxYF2iMGt Or7qkuhejJuFKU+O+6qGiywLpaboWhZ6ww== X-Received: by 2002:a17:906:5006:: with SMTP id s6mr38495933ejj.294.1593951129593; Sun, 05 Jul 2020 05:12:09 -0700 (PDT) Received: from localhost.localdomain (212-5-158-133.ip.btc-net.bg. [212.5.158.133]) by smtp.gmail.com with ESMTPSA id j64sm1517458edd.61.2020.07.05.05.12.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 05 Jul 2020 05:12:09 -0700 (PDT) From: Stanimir Varbanov To: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, linux-arm-kernel@lists.infradead.org Cc: Kyungmin Park , Kamil Debski , Jeongtae Park , Andrzej Hajda , Hans Verkuil , Maheshwar Ajja , Stanimir Varbanov Subject: [PATCH 4/4] media: docs: Depricate mfc frame skip control Date: Sun, 5 Jul 2020 15:11:28 +0300 Message-Id: <20200705121128.5250-5-stanimir.varbanov@linaro.org> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20200705121128.5250-1-stanimir.varbanov@linaro.org> References: <20200705121128.5250-1-stanimir.varbanov@linaro.org> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Depricate mfc private frame skip mode control for new clients and use the standard one instead. Signed-off-by: Stanimir Varbanov --- Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst | 5 +++++ 1 file changed, 5 insertions(+) -- 2.17.1 diff --git a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst index a8b4c0b40747..c0760bfc54d4 100644 --- a/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst +++ b/Documentation/userspace-api/media/v4l/ext-ctrls-codec.rst @@ -2805,6 +2805,11 @@ MFC 5.1 Control IDs ``V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE`` (enum) + .. note:: + + This control is depricated. Use the standard one + ``V4L2_CID_MPEG_VIDEO_FRAME_SKIP_MODE`` instead. + enum v4l2_mpeg_mfc51_video_frame_skip_mode - Indicates in what conditions the encoder should skip frames. If encoding a frame would cause the encoded stream to be larger then a