From patchwork Thu Sep 8 18:48:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Xavier Roumegue X-Patchwork-Id: 17349 Return-Path: X-Original-To: parsemail@patchwork.libcamera.org Delivered-To: parsemail@patchwork.libcamera.org Received: from lancelot.ideasonboard.com (lancelot.ideasonboard.com [92.243.16.209]) by patchwork.libcamera.org (Postfix) with ESMTPS id 5B819C327F for ; Thu, 8 Sep 2022 18:49:27 +0000 (UTC) Received: from lancelot.ideasonboard.com (localhost [IPv6:::1]) by lancelot.ideasonboard.com (Postfix) with ESMTP id C855E620B1; Thu, 8 Sep 2022 20:49:25 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=libcamera.org; s=mail; t=1662662965; bh=wF5EBF++35Sl5Dk+u90PDywpcgoPQN/maOAX/112ZB8=; h=To:Date:In-Reply-To:References:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=m9LeZi4na8mDBECF8uXKT8HmugJIzdWHwGmIJsklLlshB914DiHhQjw2qwRsqEkr1 9Lff8xwLl9yAwBvWF3Fa1Ki+XahTGzKJEaNa+0qJlNzovrXjHB9E66MRHsIKzQdxeG jMqRUOxIhQtHePkSge0AS7cP4L1VHNgljQIS2ZeKlTiRtlB05/jI8fgPycg/mabTpN f1YKqfeNEsWaHBJEMS8bH6asClFa76Fi1IwPp3SFuscZVn/etoqmc6puu1vyQDIp7/ DC0zkRsQcevlUCX6aZogES2Bu5cjqmWY9c2h194uwWt5vCmAypIzJb/EanWoZR266O xwpDc8TFu6Faw== Received: from EUR04-DB3-obe.outbound.protection.outlook.com (mail-eopbgr60040.outbound.protection.outlook.com [40.107.6.40]) by lancelot.ideasonboard.com (Postfix) with ESMTPS id 4C3EF620B9 for ; Thu, 8 Sep 2022 20:49:21 +0200 (CEST) Authentication-Results: lancelot.ideasonboard.com; dkim=pass (1024-bit key; unprotected) header.d=NXP1.onmicrosoft.com header.i=@NXP1.onmicrosoft.com header.b="jbkBvnvk"; dkim-atps=neutral ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=TQGfJ2Ry06AuVSYKof917raJ6abAzO+TNZMty3XeC+4sGX5IKybXENJvkqlYLEAvWIfSxsSUVDoOdE6XRNXDtU3HsFDRUMtNeFO0JPV5hEHFpgwQuCjSYWNmqssyuAgvvEXfm6CZd2J/WiZrh4Ow70ngBUU5X5CJmZ9dgiEwRUUbKaw004KHx0EQA2/Cng1UxRzmquzBBn1/JIqLDGn69asWeJfHP5wV9AClhdASKP6QU2Eh45CnUBnu3GkpIRVzN8tYe+2L7sJdIsu9j1J3GMXrz2fRB0Z3uSfV10UAFyVIhvnwaqOY5cndihCGQ4ki7SekQaISGVLb0FTzskza4w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-AntiSpam-MessageData-ChunkCount:X-MS-Exchange-AntiSpam-MessageData-0:X-MS-Exchange-AntiSpam-MessageData-1; bh=NHcZzGNN1W3/NowGWn0tjFK00mRQtCxeCxAIMil8EAQ=; b=n5bIAGXBOlE3nwDZQXiil1Jk/RDxjD3MT8ba1wX8ahHV+rmWrjwtQrfc8/eMEHSY/xSU86Uf+0QrZniRj+4uvjT5UNSEt3hqhayGaMT/INJ0dvW3mkSkXCLoMYuFc/sH6ay3okXO1hE3ePYK7sXA+GiWGIrg6Jtsjcs/XBCvaOIGI0zh7LLxYZyTAtLKqDU0AvrvWQboHiiJ5vlDsNFtNjGZRzem6BgXVvocXt85+6jCL+F+o5exZ6EyLTAA+NEmBlCtbJfuGse+ewPrQqqCeqnTlJw/UhgcoR/n6gN0GKE7lBCQrxEcAABRUcCL8+axzQIN7FmijHc1O3RllwB27g== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oss.nxp.com; dmarc=pass action=none header.from=oss.nxp.com; dkim=pass header.d=oss.nxp.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=NXP1.onmicrosoft.com; s=selector2-NXP1-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=NHcZzGNN1W3/NowGWn0tjFK00mRQtCxeCxAIMil8EAQ=; b=jbkBvnvk5iDfPlpAxTb7VQygZ/DfnDaqLhmwIn56rBbZnCUilI8VgDPqMeRhXT2AoO6XKiWIM1y3V1e4R+PEXuuR1Qnu18Bx+y+mK8ND16ZVNnxgUoCIbK//EhmoWUiDWMnvs30B6mv4i1v84yH0CiQNEYNYSgBJHOf3BXWm9ak= Authentication-Results: dkim=none (message not signed) header.d=none;dmarc=none action=none header.from=oss.nxp.com; Received: from PAXPR04MB8703.eurprd04.prod.outlook.com (2603:10a6:102:21e::22) by AS8PR04MB8852.eurprd04.prod.outlook.com (2603:10a6:20b:42f::14) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.5612.19; Thu, 8 Sep 2022 18:49:19 +0000 Received: from PAXPR04MB8703.eurprd04.prod.outlook.com ([fe80::485:adba:7081:715a]) by PAXPR04MB8703.eurprd04.prod.outlook.com ([fe80::485:adba:7081:715a%3]) with mapi id 15.20.5612.019; Thu, 8 Sep 2022 18:49:19 +0000 To: libcamera-devel@lists.libcamera.org Date: Thu, 8 Sep 2022 20:48:43 +0200 Message-Id: <20220908184850.1874303-8-xavier.roumegue@oss.nxp.com> X-Mailer: git-send-email 2.37.3 In-Reply-To: <20220908184850.1874303-1-xavier.roumegue@oss.nxp.com> References: <20220908184850.1874303-1-xavier.roumegue@oss.nxp.com> X-ClientProxiedBy: PR3P250CA0001.EURP250.PROD.OUTLOOK.COM (2603:10a6:102:57::6) To PAXPR04MB8703.eurprd04.prod.outlook.com (2603:10a6:102:21e::22) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 X-MS-PublicTrafficType: Email X-MS-TrafficTypeDiagnostic: PAXPR04MB8703:EE_|AS8PR04MB8852:EE_ X-MS-Office365-Filtering-Correlation-Id: cb9dc2f6-0951-4e5b-e0d0-08da91cad6af X-MS-Exchange-SharedMailbox-RoutingAgent-Processed: True X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: iwzWZK/D/AzMN5ciiHzjYOH2JaFVXv8U+9ztdlVP5e73szPabyO8UdVxLCzIvkcF3fNHgRtenOVCRm+qVDgsqI+HnNcYPqGVO6Zh+fHGO1TsgpmNqe7usuIQalaZj3gV57v+TmmmLx71QbKocGzkMoou3ntdigxgUW8DbD4I3q6VXStcDFYl8HW18oGhmji/5jhRtB8dWYNVFUk3hDng1AnheD9NecH9V1rYtqPSzjKxfeybGXK+KvAwQDowmcOdzWZoAPiY/PpmPwomozaDBcsNTEgixzliCMiYxcjA5c7uTAapIpTSNSfyBegjh6TN+9d4ON4wm4UNBLPyFE9BNr7ZyvtrXWqrVFZNyrxcnLbEjcU1muYQDqc416PtQSXktz/9fVOlschaPI2E1cfu5CkoWlGwXVAHba3ajcirpSwl7MO9999oE6DWcFi19Wd18UrKJnLojrA/3if69yyY5O7esaHA6xqf8DVJFirdTngZ5iARdjGyMgnSiPgH2dqNjWaVJuBgdLcSRSRBZNK5eHPlplFlrtPqcJTWjAlzzl0NkGdsaTKpqdVbvj1EQHKV57l5R2Q5ccLD/oOyoYl7Pq+kKIndmIDxIH5bCuPnczm6xJuEb2xf5yxm6xGDgcd3cEP9YBnKFPNFi3+WEG/0Na8OhPxyQfMdgnjA+VC/yjiq8NoD1EGGkAFZ1GkJN9TA2t/jOeLP4ARSc8XXzsFiBw== X-Forefront-Antispam-Report: CIP:255.255.255.255; CTRY:; LANG:en; SCL:1; SRV:; IPV:NLI; SFV:NSPM; H:PAXPR04MB8703.eurprd04.prod.outlook.com; PTR:; CAT:NONE; SFS:(13230016)(4636009)(39860400002)(346002)(376002)(396003)(136003)(366004)(38100700002)(66556008)(66476007)(66946007)(8936002)(44832011)(5660300002)(4326008)(8676002)(6916009)(316002)(41300700001)(186003)(1076003)(2616005)(2906002)(478600001)(6666004)(86362001)(6512007)(52116002)(6506007)(6486002); DIR:OUT; SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: +S2UL0Tc6njXWw/Jmq6FitVQT4EHzs/NTF7U5SjBRggLr7USDDq9xBAghVx3nSUg/fYP1ELbrj3dkdfPdntJth+Zlh/ema7jiPaM5OCubmIsa4o7+Q9DsClq5qhsl8feZQ7Ch2SHbp4E9GLJhM2E11+D8dl/sdIcFNueRbZhNDZpnMVpCI7Jp7cJHMoB4YmXMo5QPaVbbwI0nrEm7PK3PIUEF8Opt+Vn+qlXA/eobkpZbTovVcImbI5+LxOYYjLAyA4h0ugzIEbYQdmAbIm+By5lN3BnHWXd8A1BKWaHjfUoJ+s/ZpDcnL24qx4I4HKVUI8YBeb8aLomUckgR6DRXmQV3yVar5To5QefhL2Tk77TjvTzn3aRYnOiHsLflzkp0ggbSAp/euC5kG2C9HYbkIglHwDybaYWOyCiJUfYuXCdyhUNqt7NLeVIteJS+0MePzQP5bTpquB9umFBwYcE1ofL0nn7q0tAt+NqPaSljwWpk4sAGsDYYP5oI2PP2p7NE7pWH3/e3j0AhkOhgH65/4FA2HndjqKSKL8o85BfDcgmtJL6LlazVEEuCSwUIob27G/yy5Bj2Z/+/z4lHIWBoGmW0XSZpamciieeT+k0XwULDx7AFnLncnAQdvB5dgOMov65Yu0CNDhRrewXyrCvFKuDUYi7x5Uv7hlrF3O8RtfeWuIhfMDFVy/nBniKLTOIlQeS5Sykf+8g2QnRUUKyW72ZowJx2c+gAurLsteyEcBbpBJIOy9MgTCkWwW4jP5uFmF3oeu40o1cnAYNQRRiuxUNNuFz76xV2FNAg97RvmD9zDhivKw98cUOn+d5oIm5zO33wv2Dnx1zKsHe4FSzT6YtHtkTOmjznq8xFgfQZXHwSX4Wsn5i39d5YV4IkaeG+bJMXVMZJqTZVfLyW1EdcSM7Mj9Fc8V5OvNZoYNZWmIkZKlJhR00U8UxogKzfnLK7yNuLs1lr961l0SumkL9BuDcxAZeBWV9DniyarwXhG1u36E03yKoEnDucED8qd94Wd/GfbiNzA6meIPsOS/j/y3bsFZBJP7gRzjSHJFEe8F4JxlHcw3ffUu5+wtGOLfvUVL37JaAljffKLCQnk1Kd9fuZ5HvOAtVfMQ21GKSobLanr3vn7caiV3b67ACaIWpYDzpYwM+ZIvFl/lEuOu6OJCSaIXDPj/TCzbzuWjUkH4/i37jhfEzduQAN2jt50uRzOyZ9gdZEvNoyvHWJl/GCWJ0/HoSaJJ9SFCkopu5ff4eDo2rKEaoAxKluEUEamaqnrHa8u8Q4h9Kx8/zx1xf9s8wos2o9g9/+wuMzHZP7TQ0AcdGueLdFJPKm/V18pr7WQVU6vvHnNZvmJXJdlF6d0hXZFxLzyNOnXjFiuc02+Ai+PH9jvs4+5YHriF5FI9OCeP3A+T7Wet6O+xUprOjy/bTcvkeXmIZKGUbCRH8FwxPibmIg8kPSpHj5h9sYfEb1ZDm/hg84QUKTqVef2PmqoAdLrotEWym/uzDW21V4nwW5prsWD0qswBaVtYGyDqh86Fbsh/L7v9j/kNU6nikanNxO2HmBziXwTYuZrB4DzFo8CvWhnB5AgiOYkE4Zv22tmqlqw2qVHIj0d1LposjWtTPP4U7xoTbxfKV/d/m+qDyryzK/DifdgJ3mrcjwzObbmNrKD7KHFCnJr5Mrxa8LQ== X-OriginatorOrg: oss.nxp.com X-MS-Exchange-CrossTenant-Network-Message-Id: cb9dc2f6-0951-4e5b-e0d0-08da91cad6af X-MS-Exchange-CrossTenant-AuthSource: PAXPR04MB8703.eurprd04.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 08 Sep 2022 18:49:19.9024 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 686ea1d3-bc2b-4c6f-a92c-d99c5c301635 X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: 9+hHrmW6CtxE9Pp1cs9Fvkf2N8WDRjgLSyb18V/L0oe8lCFeXxtP65evBVZJu/Ds7HjENa/qCoICJqqJPQNrkQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: AS8PR04MB8852 Subject: [libcamera-devel] [PATCH 07/14] include: linux: Update headers for dw100/dynamic array support X-BeenThere: libcamera-devel@lists.libcamera.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-Patchwork-Original-From: Xavier Roumegue via libcamera-devel From: Xavier Roumegue Reply-To: Xavier Roumegue Errors-To: libcamera-devel-bounces@lists.libcamera.org Sender: "libcamera-devel" This is merged in media_tree/master linux kernel: - 9d5c3c069805 - media: uapi: Add a control for DW100 driver - a41c4088cf43 - media: v4l: uapi: Add user control base for DW100 controls - 43cc0ec38131 - media: v4l2-ctrls: add change flag for when dimensions change Signed-off-by: Xavier Roumegue Reviewed-by: Laurent Pinchart --- include/linux/dw100.h | 14 ++++++++++++++ include/linux/v4l2-controls.h | 6 ++++++ include/linux/videodev2.h | 2 ++ 3 files changed, 22 insertions(+) create mode 100644 include/linux/dw100.h diff --git a/include/linux/dw100.h b/include/linux/dw100.h new file mode 100644 index 00000000..3356496e --- /dev/null +++ b/include/linux/dw100.h @@ -0,0 +1,14 @@ +/* SPDX-License-Identifier: GPL-2.0-only WITH Linux-syscall-note */ +/* Copyright 2022 NXP */ + +#ifndef __UAPI_DW100_H__ +#define __UAPI_DW100_H__ + +#include + +/* + * Check Documentation/userspace-api/media/drivers/dw100.rst for control details. + */ +#define V4L2_CID_DW100_DEWARPING_16x16_VERTEX_MAP (V4L2_CID_USER_DW100_BASE + 1) + +#endif diff --git a/include/linux/v4l2-controls.h b/include/linux/v4l2-controls.h index 9d2a8237..047f8965 100644 --- a/include/linux/v4l2-controls.h +++ b/include/linux/v4l2-controls.h @@ -229,6 +229,12 @@ enum v4l2_colorfx { */ #define V4L2_CID_USER_ISL7998X_BASE (V4L2_CID_USER_BASE + 0x1180) +/* + * The base for DW100 driver controls. + * We reserve 16 controls for this driver. + */ +#define V4L2_CID_USER_DW100_BASE (V4L2_CID_USER_BASE + 0x1190) + /* MPEG-class control IDs */ /* The MPEG controls are applicable to all codec controls * and the 'MPEG' part of the define is historical */ diff --git a/include/linux/videodev2.h b/include/linux/videodev2.h index bfb315d6..f502114f 100644 --- a/include/linux/videodev2.h +++ b/include/linux/videodev2.h @@ -1860,6 +1860,7 @@ struct v4l2_querymenu { #define V4L2_CTRL_FLAG_HAS_PAYLOAD 0x0100 #define V4L2_CTRL_FLAG_EXECUTE_ON_WRITE 0x0200 #define V4L2_CTRL_FLAG_MODIFY_LAYOUT 0x0400 +#define V4L2_CTRL_FLAG_DYNAMIC_ARRAY 0x0800 /* Query flags, to be ORed with the control ID */ #define V4L2_CTRL_FLAG_NEXT_CTRL 0x80000000 @@ -2367,6 +2368,7 @@ struct v4l2_event_vsync { #define V4L2_EVENT_CTRL_CH_VALUE (1 << 0) #define V4L2_EVENT_CTRL_CH_FLAGS (1 << 1) #define V4L2_EVENT_CTRL_CH_RANGE (1 << 2) +#define V4L2_EVENT_CTRL_CH_DIMENSIONS (1 << 3) struct v4l2_event_ctrl { __u32 changes;