Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp4544097imm; Tue, 9 Oct 2018 00:59:46 -0700 (PDT) X-Google-Smtp-Source: ACcGV61jQX2PIG45dw13hxxn73lJUOlPv9UkEHpAWWTyRA2U6ZrPGLVjB9MzcESqVzaxiroxTpCQ X-Received: by 2002:a62:210:: with SMTP id 16-v6mr29785508pfc.100.1539071986473; Tue, 09 Oct 2018 00:59:46 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539071986; cv=none; d=google.com; s=arc-20160816; b=aHvFrOZBdoqEqhp2uqAY+dVKPeK5JtU2Yz77jlKepvG7cOsxY3t5RxuFlitrrEgym6 g0h35n9/8YL5Nmz9cjlagiIwGKTM7VjL7IRwD4d8mRPbhSIv7KLtuHw0ihWE+vB7zDfN 3KC4ctpv79n/de99RAb0fWnZFXE4hUTPXA9NCETUG17r0yRi7V3DJGW2h4CQL0awUK7l nkUB6cG24gQy9KMt67L88PDy8TBmPd9CFs2R9uef4iCbl/F0J4kxEg81nYrf2ek0R7cq M6E1CUK/4fIro+BFxZaW8m4nCUJeiYKvPtKevfyyYOku9EwfyZ7qJZ3vs6YqUTKkNTyp 8/Kg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:message-id:date:subject:cc:to:from; bh=UkagnjyPGxEaXuCV2FbB/zMkkHwLBw4XoZz9AaxZsUg=; b=jP6j1g4RusE7eHrYzwul3BPOF/PbomJHoGg/O+p3AhDy2PfF0la9T9Dma+h8XfN1L3 BAKndms8eF5LKv4iZp/xBHDD8YBL9V2RWYROgjb8yUB9u2ywVN4T40COruRyUdYMGOpB fO57AmR2Ol4gL5SQSTQu71U3z1luw190Bj6lZxWnmM5NaRcAXAam6hBIfoZOXc4dyZ9d jVKNSkaeYh7BIiOKSiySO8s+inLbbzR59J1MPhfsLKwCEMGVPcZ2pR2NrQQk5wp9v8Kp 8ujDxK+JdPFCcQ18UTuyeKW1L3OXz3fbEHmxyLLhwVI9rQWZ5EqQ+SOtBfuwHcExXabK 891g== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 33-v6si21943254plt.65.2018.10.09.00.59.32; Tue, 09 Oct 2018 00:59:46 -0700 (PDT) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726827AbeJIPOj (ORCPT + 99 others); Tue, 9 Oct 2018 11:14:39 -0400 Received: from alexa-out-blr-01.qualcomm.com ([103.229.18.197]:6137 "EHLO alexa-out-blr-01.qualcomm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726488AbeJIPOj (ORCPT ); Tue, 9 Oct 2018 11:14:39 -0400 X-IronPort-AV: E=Sophos;i="5.54,359,1534789800"; d="scan'208";a="240330" Received: from ironmsg03-blr.qualcomm.com ([10.86.208.132]) by alexa-out-blr-01.qualcomm.com with ESMTP/TLS/AES256-SHA; 09 Oct 2018 13:22:42 +0530 X-IronPort-AV: E=McAfee;i="5900,7806,9040"; a="1605179" Received: from mgottam-linux.qualcomm.com ([10.204.66.66]) by ironmsg03-blr.qualcomm.com with ESMTP; 09 Oct 2018 13:22:40 +0530 Received: by mgottam-linux.qualcomm.com (Postfix, from userid 2305155) id DB3DD2E3C; Tue, 9 Oct 2018 13:22:39 +0530 (IST) From: Malathi Gottam To: stanimir.varbanov@linaro.org, hverkuil@xs4all.nl, mchehab@kernel.org Cc: linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, acourbot@chromium.org, vgarodia@codeaurora.org, mgottam@codeaurora.org Subject: [PATCH] media: venus: add support for USERPTR to queue Date: Tue, 9 Oct 2018 13:22:37 +0530 Message-Id: <1539071557-1500-1-git-send-email-mgottam@codeaurora.org> X-Mailer: git-send-email 1.9.1 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add USERPTR to queue access methods by adding this support to io_modes on both the planes. Signed-off-by: Malathi Gottam --- drivers/media/platform/qcom/venus/venc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/media/platform/qcom/venus/venc.c b/drivers/media/platform/qcom/venus/venc.c index 754c19a..b86994c 100644 --- a/drivers/media/platform/qcom/venus/venc.c +++ b/drivers/media/platform/qcom/venus/venc.c @@ -1096,7 +1096,7 @@ static int m2m_queue_init(void *priv, struct vb2_queue *src_vq, int ret; src_vq->type = V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE; - src_vq->io_modes = VB2_MMAP | VB2_DMABUF; + src_vq->io_modes = VB2_MMAP | VB2_USERPTR | VB2_DMABUF; src_vq->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_COPY; src_vq->ops = &venc_vb2_ops; src_vq->mem_ops = &vb2_dma_sg_memops; @@ -1112,7 +1112,7 @@ static int m2m_queue_init(void *priv, struct vb2_queue *src_vq, return ret; dst_vq->type = V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE; - dst_vq->io_modes = VB2_MMAP | VB2_DMABUF; + dst_vq->io_modes = VB2_MMAP | VB2_USERPTR | VB2_DMABUF; dst_vq->timestamp_flags = V4L2_BUF_FLAG_TIMESTAMP_COPY; dst_vq->ops = &venc_vb2_ops; dst_vq->mem_ops = &vb2_dma_sg_memops; -- 1.9.1