From patchwork Fri Jan 22 00:57:10 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Laurent Pinchart X-Patchwork-Id: 8086351 X-Patchwork-Delegate: geert@linux-m68k.org Return-Path: X-Original-To: patchwork-linux-renesas-soc@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 5EC099F744 for ; Fri, 22 Jan 2016 00:57:55 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 9036B2034C for ; Fri, 22 Jan 2016 00:57:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 8621020443 for ; Fri, 22 Jan 2016 00:57:53 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751316AbcAVA5w (ORCPT ); Thu, 21 Jan 2016 19:57:52 -0500 Received: from galahad.ideasonboard.com ([185.26.127.97]:58727 "EHLO galahad.ideasonboard.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751310AbcAVA5w (ORCPT ); Thu, 21 Jan 2016 19:57:52 -0500 Received: from avalon.access.network (nblzone-211-213.nblnetworks.fi [83.145.211.213]) by galahad.ideasonboard.com (Postfix) with ESMTPSA id 3A1EA21895 for ; Fri, 22 Jan 2016 01:56:47 +0100 (CET) From: Laurent Pinchart To: linux-renesas-soc@vger.kernel.org Subject: [PATCH/RFC v2 41/56] DocBook: media: Document the V4L2 subdev request API Date: Fri, 22 Jan 2016 02:57:10 +0200 Message-Id: <1453424245-18782-42-git-send-email-laurent.pinchart+renesas@ideasonboard.com> X-Mailer: git-send-email 2.4.10 In-Reply-To: <1453424245-18782-1-git-send-email-laurent.pinchart+renesas@ideasonboard.com> References: <1453424245-18782-1-git-send-email-laurent.pinchart+renesas@ideasonboard.com> Sender: linux-renesas-soc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-renesas-soc@vger.kernel.org X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The V4L2 subdev request API consists in extensions to existing V4L2 subdev ioctls. Document it. Signed-off-by: Laurent Pinchart --- .../DocBook/media/v4l/vidioc-subdev-g-fmt.xml | 33 ++++++++++++++++++++-- .../media/v4l/vidioc-subdev-g-selection.xml | 28 ++++++++++++++++-- 2 files changed, 55 insertions(+), 6 deletions(-) diff --git a/Documentation/DocBook/media/v4l/vidioc-subdev-g-fmt.xml b/Documentation/DocBook/media/v4l/vidioc-subdev-g-fmt.xml index a67cde6f8c54..2623e8f52362 100644 --- a/Documentation/DocBook/media/v4l/vidioc-subdev-g-fmt.xml +++ b/Documentation/DocBook/media/v4l/vidioc-subdev-g-fmt.xml @@ -97,6 +97,13 @@ low-pass noise filter might crop pixels at the frame boundaries, modifying its output frame size. + Applications can get and set formats stored in a request by setting + the which field to + V4L2_SUBDEV_FORMAT_REQUEST and the + request to the request ID. See + for more information about the request + API. + Drivers must not return an error solely because the requested format doesn't match the device capabilities. They must instead modify the format to match what the hardware can provide. The modified format should be as @@ -124,8 +131,22 @@ linkend="v4l2-mbus-framefmt" /> for details. + __u16 + request + Request ID, only valid when the which + field is set to V4L2_SUBDEV_FORMAT_REQUEST. + Applications and drivers must set the field to zero in all other + cases. + + + __u16 + reserved2 + Reserved for future extensions. Applications and drivers must + set the field to zero. + + __u32 - reserved[8] + reserved[7] Reserved for future extensions. Applications and drivers must set the array to zero. @@ -148,6 +169,11 @@ 1 Active formats, applied to the hardware. + + V4L2_SUBDEV_FORMAT_REQUEST + 1 + Request formats, used with the requests API. + @@ -171,8 +197,9 @@ EINVAL The &v4l2-subdev-format; pad - references a non-existing pad, or the which - field references a non-existing format. + references a non-existing pad, the which + field references a non-existing format or the request ID references + a nonexistant request. diff --git a/Documentation/DocBook/media/v4l/vidioc-subdev-g-selection.xml b/Documentation/DocBook/media/v4l/vidioc-subdev-g-selection.xml index 9b59b49db0c3..f1f6a31baa63 100644 --- a/Documentation/DocBook/media/v4l/vidioc-subdev-g-selection.xml +++ b/Documentation/DocBook/media/v4l/vidioc-subdev-g-selection.xml @@ -100,6 +100,13 @@ handle. Two applications querying the same sub-device would thus not interfere with each other. + Applications can get and set selection rectangles stored in a request + by setting the which field to + V4L2_SUBDEV_FORMAT_REQUEST and the + request to the request ID. See + for more information about the request + API. + Drivers must not return an error solely because the requested selection rectangle doesn't match the device capabilities. They must instead modify the rectangle to match what the hardware can provide. The modified @@ -160,8 +167,22 @@ Selection rectangle, in pixels. + __u16 + request + Request ID, only valid when the which + field is set to V4L2_SUBDEV_FORMAT_REQUEST. + Applications and drivers must set the field to zero in all other + cases. + + + __u16 + reserved2 + Reserved for future extensions. Applications and drivers must + set the field to zero. + + __u32 - reserved[8] + reserved[7] Reserved for future extensions. Applications and drivers must set the array to zero. @@ -193,8 +214,9 @@ The &v4l2-subdev-selection; pad references a non-existing pad, the which field references a - non-existing format, or the selection target is not - supported on the given subdev pad. + non-existing format, the selection target is not supported on + the given subdev pad or the request ID references a nonexistant + request.