From patchwork Wed Sep 20 09:32:45 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shengjiu Wang X-Patchwork-Id: 142325 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:612c:172:b0:3f2:4152:657d with SMTP id h50csp4022934vqi; Wed, 20 Sep 2023 03:19:14 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH4MfY5DGqOm2SMHpLCllIWwUoA5QKPJS28fyMaoMURvX9gdxkUWh94D9rOWCqITlRubTmc X-Received: by 2002:a05:6a20:8f0c:b0:14d:2b8d:d62f with SMTP id b12-20020a056a208f0c00b0014d2b8dd62fmr2714152pzk.47.1695205153701; Wed, 20 Sep 2023 03:19:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1695205153; cv=none; d=google.com; s=arc-20160816; b=kTsn+CgbGflqlCuggjNHLhRkgRmwXXi2g/pZ2sz9MCxGqNFDrq2N23URA05lWeWjaR 1JquV4rXMExReBEosOnk328NsbCU4QEUqHAdgf0ivyQ8b6szvhhitpVZ2oGEZLX/E4lF JcWrr/ZlvlFrqxmQ/jmkjZy6e6bHZdHMs87Yq3fVqTvqsjJaArXa/cTCDUvMWv6+im4f tOimBXDkJgCJXVb5Tck8bsO4YUsYqP9iQQSXo4leZ2rdnNMStjTNpXWp1XPqoSQfl8Gj 41UADqqQm+s784xhO3/+H8izoXSQ9AgUUzhufnZt2zJy2xmBluwQ7SytNpczI7OBUtHI 0ojg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:references:in-reply-to:message-id:date:subject :to:from; bh=f3QFll8sKbIOGfOGZtI1aM9XK4BlmjBoT772U7GVlkM=; fh=ufiESpW7Hvn5oNmN0l6/qCUiQrKfLLrOwb5uR1Dftds=; b=z64Z+Ej2ZEM5Ykb9hjGtK81yryPmZ9A0VaEoK2y3bv+dJel6cQEIEEbgSkygNosDwp G8vDeZbNl6nU5AESHolXFn43eV6IRJWMJBzxIWlndYiPr5tT80eK0UoJxGKVltfxInF6 7VUpcteRsWpiNWs+WcM6tKeXPqCjRs1YoLiEUoMpgzqGprGgS1hIbqF1FmntrdxjVp3L rf9Cdc0FSRJAXs4I76LKfzFB2txaH6TCYbl2B0y2uFZYuA+BPDVCdOTe+A/1OpDBOuDQ f61TP5HGVlkEiSkil7jak3Z18camNdnSTFC3m/AdhIG8rLIiDyZ6aqQs+88tHXyBBxJm E+9Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from pete.vger.email (pete.vger.email. [23.128.96.36]) by mx.google.com with ESMTPS id n10-20020a17090a670a00b00273ec8dfff8si1288258pjj.80.2023.09.20.03.19.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 20 Sep 2023 03:19:13 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) client-ip=23.128.96.36; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.36 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by pete.vger.email (Postfix) with ESMTP id E0213829AA33; Wed, 20 Sep 2023 03:10:54 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at pete.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234311AbjITKKR (ORCPT + 26 others); Wed, 20 Sep 2023 06:10:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41518 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234262AbjITKKD (ORCPT ); Wed, 20 Sep 2023 06:10:03 -0400 Received: from inva021.nxp.com (inva021.nxp.com [92.121.34.21]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 129E6CA; Wed, 20 Sep 2023 03:09:57 -0700 (PDT) Received: from inva021.nxp.com (localhost [127.0.0.1]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 9B37F200B9B; Wed, 20 Sep 2023 12:09:56 +0200 (CEST) Received: from aprdc01srsp001v.ap-rdc01.nxp.com (aprdc01srsp001v.ap-rdc01.nxp.com [165.114.16.16]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id 62489200B96; Wed, 20 Sep 2023 12:09:56 +0200 (CEST) Received: from localhost.localdomain (shlinux2.ap.freescale.net [10.192.224.44]) by aprdc01srsp001v.ap-rdc01.nxp.com (Postfix) with ESMTP id 7B1581820F59; Wed, 20 Sep 2023 18:09:54 +0800 (+08) From: Shengjiu Wang To: hverkuil@xs4all.nl, sakari.ailus@iki.fi, tfiga@chromium.org, m.szyprowski@samsung.com, mchehab@kernel.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, shengjiu.wang@gmail.com, Xiubo.Lee@gmail.com, festevam@gmail.com, nicoleotsuka@gmail.com, lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, alsa-devel@alsa-project.org, linuxppc-dev@lists.ozlabs.org Subject: [RFC PATCH v4 06/11] media: uapi: Add V4L2_CAP_AUDIO_M2M capability flag Date: Wed, 20 Sep 2023 17:32:45 +0800 Message-Id: <1695202370-24678-7-git-send-email-shengjiu.wang@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1695202370-24678-1-git-send-email-shengjiu.wang@nxp.com> References: <1695202370-24678-1-git-send-email-shengjiu.wang@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP X-Spam-Status: No, score=-0.8 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on pete.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (pete.vger.email [0.0.0.0]); Wed, 20 Sep 2023 03:10:55 -0700 (PDT) X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1777551438992564293 X-GMAIL-MSGID: 1777551438992564293 V4L2_CAP_AUDIO_M2M is similar to V4L2_CAP_VIDEO_M2M flag. It is used for audio memory to memory case. Signed-off-by: Shengjiu Wang --- Documentation/userspace-api/media/v4l/vidioc-querycap.rst | 3 +++ Documentation/userspace-api/media/videodev2.h.rst.exceptions | 1 + include/uapi/linux/videodev2.h | 1 + 3 files changed, 5 insertions(+) diff --git a/Documentation/userspace-api/media/v4l/vidioc-querycap.rst b/Documentation/userspace-api/media/v4l/vidioc-querycap.rst index 6c57b8428356..0b3cefefc86b 100644 --- a/Documentation/userspace-api/media/v4l/vidioc-querycap.rst +++ b/Documentation/userspace-api/media/v4l/vidioc-querycap.rst @@ -259,6 +259,9 @@ specification the ioctl returns an ``EINVAL`` error code. video topology configuration, including which I/O entity is routed to the input/output, is configured by userspace via the Media Controller. See :ref:`media_controller`. + * - ``V4L2_CAP_AUDIO_M2M`` + - 0x40000000 + - The device supports the audio Memory-To-Memory interface. * - ``V4L2_CAP_DEVICE_CAPS`` - 0x80000000 - The driver fills the ``device_caps`` field. This capability can diff --git a/Documentation/userspace-api/media/videodev2.h.rst.exceptions b/Documentation/userspace-api/media/videodev2.h.rst.exceptions index 3e58aac4ef0b..da6d0b8e4c2c 100644 --- a/Documentation/userspace-api/media/videodev2.h.rst.exceptions +++ b/Documentation/userspace-api/media/videodev2.h.rst.exceptions @@ -197,6 +197,7 @@ replace define V4L2_CAP_META_OUTPUT device-capabilities replace define V4L2_CAP_DEVICE_CAPS device-capabilities replace define V4L2_CAP_TOUCH device-capabilities replace define V4L2_CAP_IO_MC device-capabilities +replace define V4L2_CAP_AUDIO_M2M device-capabilities # V4L2 pix flags replace define V4L2_PIX_FMT_PRIV_MAGIC :c:type:`v4l2_pix_format` diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h index 78260e5d9985..3decf7d73870 100644 --- a/include/uapi/linux/videodev2.h +++ b/include/uapi/linux/videodev2.h @@ -508,6 +508,7 @@ struct v4l2_capability { #define V4L2_CAP_TOUCH 0x10000000 /* Is a touch device */ #define V4L2_CAP_IO_MC 0x20000000 /* Is input/output controlled by the media controller */ +#define V4L2_CAP_AUDIO_M2M 0x40000000 /* audio memory to memory */ #define V4L2_CAP_DEVICE_CAPS 0x80000000 /* sets device capabilities field */