From patchwork Thu Sep 7 18:42:22 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Gustavo Padovan X-Patchwork-Id: 9942699 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 95325602CC for ; Thu, 7 Sep 2017 18:45:02 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 915AC287FB for ; Thu, 7 Sep 2017 18:45:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 85F48287FF; Thu, 7 Sep 2017 18:45:02 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.4 required=2.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM autolearn=unavailable version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 06186287FB for ; Thu, 7 Sep 2017 18:45:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755552AbdIGSnT (ORCPT ); Thu, 7 Sep 2017 14:43:19 -0400 Received: from mail-qk0-f196.google.com ([209.85.220.196]:33771 "EHLO mail-qk0-f196.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754650AbdIGSnQ (ORCPT ); Thu, 7 Sep 2017 14:43:16 -0400 Received: by mail-qk0-f196.google.com with SMTP id g128so318202qke.0; Thu, 07 Sep 2017 11:43:15 -0700 (PDT) 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=gB+eSqx115DcMJD8eDCFais9OlpHtq619fqlwr9gSvc=; b=sTONR2MBlXex9t02fyTtDMQ91tRQ8vv3PlkNMIgrcYpx+fT/oUjNB/ygeCV9yOsTO5 EHHLlVil+Y4vcy+3wNHkYVCjxSbecpH/ESrsfGBKno97ioZB9qe5RULXyRKs2GaXheio faVZ5b+gZ4v4P4CBvrUVwPYvYRjHaTm5R9oUZqGJGvfDFnGQFHseMfhCcwMe8ZrXKR/9 T8wUWqbNFEgclLAIiVdnl8qY+yKeoN37Legi2UFL7bMBP1FPVadTCd3wfa74SUm4Hk9x FMWNkKcEuuh8H+qwZ//Cu+6f4UIqKZuqpxNh0kBcaOCYm32r5l47U3lzKSmDoI+gbNfi UmVg== X-Gm-Message-State: AHPjjUixFj6eilgM49MBEZtIiKDiJBxkAkfQ+okfXuR4N21biIGWYYsh VBzskjxJnMFyZs+92jE= X-Google-Smtp-Source: ADKCNb5xqQ9iSK0WL9rjoelxgAJkAXsJCOpXVx1DonkDNDt/cTkTQvgmq2b+9lzMUQYISbnucofGqw== X-Received: by 10.55.23.13 with SMTP id i13mr359651qkh.237.1504809795266; Thu, 07 Sep 2017 11:43:15 -0700 (PDT) Received: from localhost.localdomain ([187.10.21.246]) by smtp.gmail.com with ESMTPSA id v30sm213216qtg.70.2017.09.07.11.43.07 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Thu, 07 Sep 2017 11:43:09 -0700 (PDT) From: Gustavo Padovan To: linux-media@vger.kernel.org Cc: Hans Verkuil , Mauro Carvalho Chehab , Shuah Khan , linux-kernel@vger.kernel.org, Gustavo Padovan Subject: [PATCH v3 11/15] [media] vivid: mark vivid queues as ordered Date: Thu, 7 Sep 2017 15:42:22 -0300 Message-Id: <20170907184226.27482-12-gustavo@padovan.org> X-Mailer: git-send-email 2.13.5 In-Reply-To: <20170907184226.27482-1-gustavo@padovan.org> References: <20170907184226.27482-1-gustavo@padovan.org> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Gustavo Padovan To enable vivid to be used with explicit synchronization we need to mark its queues as ordered. vivid queues are already ordered by default so we no changes are needed. Signed-off-by: Gustavo Padovan Acked-by: Hans Verkuil --- drivers/media/platform/vivid/vivid-core.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/drivers/media/platform/vivid/vivid-core.c b/drivers/media/platform/vivid/vivid-core.c index 608bcceed463..239790e8ccc6 100644 --- a/drivers/media/platform/vivid/vivid-core.c +++ b/drivers/media/platform/vivid/vivid-core.c @@ -1063,6 +1063,7 @@ static int vivid_create_instance(struct platform_device *pdev, int inst) q->type = dev->multiplanar ? V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE : V4L2_BUF_TYPE_VIDEO_CAPTURE; q->io_modes = VB2_MMAP | VB2_USERPTR | VB2_DMABUF | VB2_READ; + q->ordered = 1; q->drv_priv = dev; q->buf_struct_size = sizeof(struct vivid_buffer); q->ops = &vivid_vid_cap_qops; @@ -1083,6 +1084,7 @@ static int vivid_create_instance(struct platform_device *pdev, int inst) q->type = dev->multiplanar ? V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE : V4L2_BUF_TYPE_VIDEO_OUTPUT; q->io_modes = VB2_MMAP | VB2_USERPTR | VB2_DMABUF | VB2_WRITE; + q->ordered = 1; q->drv_priv = dev; q->buf_struct_size = sizeof(struct vivid_buffer); q->ops = &vivid_vid_out_qops; @@ -1103,6 +1105,7 @@ static int vivid_create_instance(struct platform_device *pdev, int inst) q->type = dev->has_raw_vbi_cap ? V4L2_BUF_TYPE_VBI_CAPTURE : V4L2_BUF_TYPE_SLICED_VBI_CAPTURE; q->io_modes = VB2_MMAP | VB2_USERPTR | VB2_DMABUF | VB2_READ; + q->ordered = 1; q->drv_priv = dev; q->buf_struct_size = sizeof(struct vivid_buffer); q->ops = &vivid_vbi_cap_qops; @@ -1123,6 +1126,7 @@ static int vivid_create_instance(struct platform_device *pdev, int inst) q->type = dev->has_raw_vbi_out ? V4L2_BUF_TYPE_VBI_OUTPUT : V4L2_BUF_TYPE_SLICED_VBI_OUTPUT; q->io_modes = VB2_MMAP | VB2_USERPTR | VB2_DMABUF | VB2_WRITE; + q->ordered = 1; q->drv_priv = dev; q->buf_struct_size = sizeof(struct vivid_buffer); q->ops = &vivid_vbi_out_qops; @@ -1142,6 +1146,7 @@ static int vivid_create_instance(struct platform_device *pdev, int inst) q = &dev->vb_sdr_cap_q; q->type = V4L2_BUF_TYPE_SDR_CAPTURE; q->io_modes = VB2_MMAP | VB2_USERPTR | VB2_DMABUF | VB2_READ; + q->ordered = 1; q->drv_priv = dev; q->buf_struct_size = sizeof(struct vivid_buffer); q->ops = &vivid_sdr_cap_qops;