Received: by 2002:a25:1506:0:0:0:0:0 with SMTP id 6csp6167764ybv; Tue, 18 Feb 2020 11:14:04 -0800 (PST) X-Google-Smtp-Source: APXvYqy1QLzFn0eeq0TiZpGcX9ueummPrQRwOwU3EKAJoIMY497yFzbhlCPIe+UUhQ1NMdyAzrN6 X-Received: by 2002:a9d:6d1a:: with SMTP id o26mr16182704otp.141.1582053244074; Tue, 18 Feb 2020 11:14:04 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582053244; cv=none; d=google.com; s=arc-20160816; b=imR5NXljE9p9fzjzKnCJ1UhABRqRg6Wvuwbx7/0LlSWYhmxPDq+dxioRvWQ7pDigZy MKiQpH2MXu1+uoDsNAx1cU5UVBhPAqzfF/VXvlhViZEbhafjQax1e/zgh5hr4u8SIp6x u4spdTAoVhGvN2V+nglW+q5bNeRgcBnxsBcwDGoQR7wW86wih0IBBOAdNrx/YHZFS9nh pPIsID/hmTB5I8g3/7eJ9Mn+a2WcfudaiVZifscf538bSfSiKVy78VjXbVtLZtMsKRE2 cBb7xq3HtM7MIvJ/fhWBKjmykuY3hc+TRM4OYxr5drz3cWfPw9XYOqmleS7/Q/91zBVg xE4Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:from:subject:references :mime-version:message-id:in-reply-to:date:dkim-signature; bh=LCLnkWXoXz9OcghUi3epooWnoZGfpAtSgZMaGiJOKu8=; b=rXX0zAnWifb37iirV7khdKKzOrCrWp3btLVOMPRxqtxKLp72GsIMmiO5E2h0DrD0Lq NpV5zvG8erV512CUR3vlQH+M+4dl5wDN+SBIhDi+3P/HE/a4J2qtcAFaHfKtgMMUDX8h XFFIrqiAVG3peyVN+9V56PdynCp0GOZAAYRBpzd4ViVu9N6vtqmUsI//6SLWefBPq6TD f5RGmTUrJ1yeS9hxISk95TIO92+pddb651PAHz/x6sgTvssOHho5OrZuk8CHtZdGXcjg 61myetQvnpEPdAtBZtiywXzO/doJ6xK33Lz9fH4AHDHt5Q63qJAjcN7Ug4viDZG9BIEh beQQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=YIweNER3; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 64si2085344otx.50.2020.02.18.11.13.51; Tue, 18 Feb 2020 11:14:04 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@google.com header.s=20161025 header.b=YIweNER3; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=google.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726477AbgBRTN2 (ORCPT + 99 others); Tue, 18 Feb 2020 14:13:28 -0500 Received: from mail-pl1-f202.google.com ([209.85.214.202]:49009 "EHLO mail-pl1-f202.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726444AbgBRTN1 (ORCPT ); Tue, 18 Feb 2020 14:13:27 -0500 Received: by mail-pl1-f202.google.com with SMTP id d20so10690258pls.15 for ; Tue, 18 Feb 2020 11:13:25 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20161025; h=date:in-reply-to:message-id:mime-version:references:subject:from:to :cc; bh=LCLnkWXoXz9OcghUi3epooWnoZGfpAtSgZMaGiJOKu8=; b=YIweNER3ez6cX4gaq18ciHLsjwesfuzsnzZUVkEWb1usGcYqij6EvEOSioq9vbcNLG uKFvYE3Xk/a7jQig8xL9EBlN9i8+ihe4RKWXgdJ5nKCYgJXND+u2ZetufpqA9KDrCIFv lvjBXDYLfHfGTMQaLOdbQa87yxio9rdG/JGD07S3w7NgAbjgfOYqzYx7GMRbP9D7GG4x bhpfm915Ho/+44e8OjsBgqnCJILJ5MPkaQ2xBqFr7qkEre01WuEZS4SgALakc2fxFPk+ 4xhXijqyKnjj0ycBtuXsCdykIer2P2yWy4PgU1uyxuGZR5QyvRmmRGM1UdoUmBpUDcdD EFhg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:in-reply-to:message-id:mime-version :references:subject:from:to:cc; bh=LCLnkWXoXz9OcghUi3epooWnoZGfpAtSgZMaGiJOKu8=; b=V1bBKWtzXworvrPuG95+Ugp4zB9srHGGn2T1Zkvp0pHXXP1je73J2ylkAijOctc5Nd gg7pXCmxtQIBgY0jS0FKD71bUaeUeoiaV4S6d8vFg/M0UcO8iUwaxkWCDgzb34NFjN77 BpOe0Jepxky78x+PQqVa3frATY1Cme4atF6HptuoqDpfm0n7KoppGGGDZLooVzoWzD+U N4wMtnBeEhjlmRB4iw+/hltRo35CMFoZ1hgpSPTvo0Esj5qstWGgsShf5cCir/2FS+tq zYlz7/gkNm8UDNG0aBO6kuFZdDI0Awn1+Oz0ENJAQd5hwpUbBsXu6XRS/wZeQpktzdXB i6Lw== X-Gm-Message-State: APjAAAX2sJ7Xn/Dxm3WaWzKru0gUo7VXEkuR7phljQv2nY+BAaOwmtZS UkDGOmH72n0NFmxwxIWCgGK1yKbR/ZRQMLw= X-Received: by 2002:a63:2a02:: with SMTP id q2mr23581913pgq.198.1582053205231; Tue, 18 Feb 2020 11:13:25 -0800 (PST) Date: Tue, 18 Feb 2020 11:13:14 -0800 In-Reply-To: <20200213213007.17023-1-jkardatzke@google.com> Message-Id: <20200218191314.157285-1-jkardatzke@google.com> Mime-Version: 1.0 References: <20200213213007.17023-1-jkardatzke@google.com> X-Mailer: git-send-email 2.25.0.265.gbab2e86ba0-goog Subject: [PATCH] media: venus: support frame rate control From: Jeffrey Kardatzke To: linux-media@vger.kernel.org Cc: Stanimir Varbanov , Andy Gross , "Mauro Carvalho Chehab )" , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, Jeffrey Kardatzke Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Frame rate control is always enabled in this driver, so make it silently support the V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE. Signed-off-by: Jeffrey Kardatzke --- drivers/media/platform/qcom/venus/venc_ctrls.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/drivers/media/platform/qcom/venus/venc_ctrls.c b/drivers/media/platform/qcom/venus/venc_ctrls.c index 877c0b3299e9..15852bc26231 100644 --- a/drivers/media/platform/qcom/venus/venc_ctrls.c +++ b/drivers/media/platform/qcom/venus/venc_ctrls.c @@ -199,6 +199,9 @@ static int venc_op_s_ctrl(struct v4l2_ctrl *ctrl) } mutex_unlock(&inst->lock); break; + case V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE: + /* Silently ignore, it's always enabled. */ + break; default: return -EINVAL; } @@ -214,7 +217,7 @@ int venc_ctrl_init(struct venus_inst *inst) { int ret; - ret = v4l2_ctrl_handler_init(&inst->ctrl_handler, 30); + ret = v4l2_ctrl_handler_init(&inst->ctrl_handler, 31); if (ret) return ret; @@ -351,6 +354,9 @@ int venc_ctrl_init(struct venus_inst *inst) v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, V4L2_CID_MPEG_VIDEO_FORCE_KEY_FRAME, 0, 0, 0, 0); + v4l2_ctrl_new_std(&inst->ctrl_handler, &venc_ctrl_ops, + V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE, 0, 1, 1, 1); + ret = inst->ctrl_handler.error; if (ret) goto err; -- 2.25.0.265.gbab2e86ba0-goog