From patchwork Thu Mar 8 12:26:22 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luca Ceresoli X-Patchwork-Id: 10267917 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 80D0C60364 for ; Thu, 8 Mar 2018 12:27:38 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 72D5B28649 for ; Thu, 8 Mar 2018 12:27:38 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 6751828696; Thu, 8 Mar 2018 12:27:38 +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.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI 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 193CD28649 for ; Thu, 8 Mar 2018 12:27:38 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755489AbeCHM0y (ORCPT ); Thu, 8 Mar 2018 07:26:54 -0500 Received: from srv-hp10-72.netsons.net ([94.141.22.72]:37883 "EHLO srv-hp10-72.netsons.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751431AbeCHM0w (ORCPT ); Thu, 8 Mar 2018 07:26:52 -0500 Received: from [109.168.11.45] (port=53502 helo=pc-ceresoli.dev.aim) by srv-hp10.netsons.net with esmtpa (Exim 4.89_1) (envelope-from ) id 1etudE-003XXy-Lb; Thu, 08 Mar 2018 13:26:48 +0100 From: Luca Ceresoli To: linux-media@vger.kernel.org Cc: linux-kernel@vger.kernel.org, Luca Ceresoli , Laurent Pinchart , Pawel Osciak , Marek Szyprowski , Kyungmin Park , Mauro Carvalho Chehab Subject: [PATCH v2 3/3] media: vb2-core: vb2_ops: document non-interrupt-context calling Date: Thu, 8 Mar 2018 13:26:22 +0100 Message-Id: <1520511982-985-3-git-send-email-luca@lucaceresoli.net> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1520511982-985-1-git-send-email-luca@lucaceresoli.net> References: <1520511982-985-1-git-send-email-luca@lucaceresoli.net> X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - srv-hp10.netsons.net X-AntiAbuse: Original Domain - vger.kernel.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - lucaceresoli.net X-Get-Message-Sender-Via: srv-hp10.netsons.net: authenticated_id: luca+lucaceresoli.net/only user confirmed/virtual account not confirmed X-Authenticated-Sender: srv-hp10.netsons.net: luca@lucaceresoli.net X-Source: X-Source-Args: X-Source-Dir: 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 Driver writers can benefit in knowing if/when callbacks are called in interrupt context. But it is not completely obvious here, so document it. Signed-off-by: Luca Ceresoli Cc: Laurent Pinchart Cc: Pawel Osciak Cc: Marek Szyprowski Cc: Kyungmin Park Cc: Mauro Carvalho Chehab --- Changes v1 -> v2: - Fix typo in the title. --- include/media/videobuf2-core.h | 3 +++ 1 file changed, 3 insertions(+) diff --git a/include/media/videobuf2-core.h b/include/media/videobuf2-core.h index f20000887d3c..f6818f732f34 100644 --- a/include/media/videobuf2-core.h +++ b/include/media/videobuf2-core.h @@ -296,6 +296,9 @@ struct vb2_buffer { /** * struct vb2_ops - driver-specific callbacks. * + * These operations are not called from interrupt context except where + * mentioned specifically. + * * @queue_setup: called from VIDIOC_REQBUFS() and VIDIOC_CREATE_BUFS() * handlers before memory allocation. It can be called * twice: if the original number of requested buffers