From patchwork Mon Feb 26 08:28:26 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Shengjiu Wang X-Patchwork-Id: 206491 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:7300:a81b:b0:108:e6aa:91d0 with SMTP id bq27csp1957587dyb; Mon, 26 Feb 2024 01:24:23 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCX34G5gJ4ZDHc6UT5JatxMjow6rc6gcUfUtfPQGlqoWsPYJQ6QewDFAtm/ax+j+89M/sdZrI30w6iOa+8vP3KnEZZUN0Q== X-Google-Smtp-Source: AGHT+IHyyp3qxlz0jFnXHJFy+NFaciGO9/t+uu/1PQanyoyxJfMJFQALzLfgAqBVW0EaqcL04R5O X-Received: by 2002:ad4:5aef:0:b0:690:8b6:26 with SMTP id c15-20020ad45aef000000b0069008b60026mr2524735qvh.46.1708939462841; Mon, 26 Feb 2024 01:24:22 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708939462; cv=pass; d=google.com; s=arc-20160816; b=uRqSemJf3Lx2xTXpoKLafXrk8nZULnBbQLxc/IGO9L3wmifpKune8eUEocg6Yo6EtJ EKrdBTR2+dwSu9pTxggmNssexSN/pjnYB9bUnxlhHQpeiUQtsm04U2a3ODSHNatuKLBB hZnwNdSNeTEJGelMQzCKCZX6dlzayibhD8UZcE6wru1wUzOgtmNDwvQxlgTgq6CSOJAB f0kA+52/cI9YVqPnOs9oy1MvKbbZEAYaLP3nlyuUQYoCErbPMB8pGb99CPZPM+41rMfq tBEOTqhYb2wfNsfrgAXd7B23uplgzS3nmQp4k65jxnUmQM5sAmGeA9jk4rQ119plQvcm esUA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-id:precedence:references :in-reply-to:message-id:date:subject:to:from; bh=qNKZBPhofoQBPfo+NXQbgaUvyUcaTPCPIBCBVsPJYDk=; fh=ufiESpW7Hvn5oNmN0l6/qCUiQrKfLLrOwb5uR1Dftds=; b=StJ3lwCiCZT9iti8SchJmox4g03MrHpbVanj4x2l7XTNvfpeYqtRq6nYs1IL6xhx/q wQFXEEHmNtTDfpUDVP33cx336HY8a1mpFSkZ9xIfU+aO7PRj46gvwRbCW5BTezWsyweQ DxFKxCtAKTSegahEYEX0fnNyFy6e178r9shnQygc8CI4bQeeQUQFPCQNIc9Tga+3Nha9 xOKVuURr1ZJ9oQAcwGFeaDyHwjBEITdRaRWgoz6riRZPw7Im0IHUEOQfslb7F05zc4Dl BOmq10N2hcQZmOXKxa3+EDMVddeUSKMe2nrB22/bBzdMJqn0LNQxXU30SU3/BHWy3hs5 XPhw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel+bounces-80940-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80940-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id jl14-20020ad45e8e000000b0068f632a4411si4728122qvb.457.2024.02.26.01.24.22 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 01:24:22 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-80940-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=nxp.com dmarc=pass fromdomain=nxp.com); spf=pass (google.com: domain of linux-kernel+bounces-80940-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-80940-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=nxp.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 9DBCA1C2393B for ; Mon, 26 Feb 2024 09:24:22 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 4FB3B58AD9; Mon, 26 Feb 2024 08:44:34 +0000 (UTC) Received: from inva021.nxp.com (inva021.nxp.com [92.121.34.21]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0AD4758136; Mon, 26 Feb 2024 08:44:31 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=92.121.34.21 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708937072; cv=none; b=Fv4c32MGWcU1JhTqU6PSdECkLsj9EjWc8NGu2lSQQJpQDLsFCDA5YMBQeArrLFSwZmgh/SbHcmmhauiWhdsZgE2sQEtwhvTMyrdCdophgMcKqr1qv4STSLgLJznp6luZCjlmagEAQquO7SrEpPc+jYTsXbLEL/SdUPTfqoghZhQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708937072; c=relaxed/simple; bh=ODVqP+lwq6xFwMgn2BlGi8UA6y56bCAsF8FKu0VoNGM=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References; b=VdmVI924K/ducScc62d+5/dkUfG6+YUcbzJ0wJ+09xbmWz1uoS2vaDEcouQPiSIMnjH09nFT5aMCsswABFscpziFwNS9r26o5TdTXPDwV9R94xvBEPAiXTjIdLx0YTZr2i25gju5HilqhBWDbDIHQ2XbeJWVvqMVUtrEaaTVla4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com; spf=pass smtp.mailfrom=nxp.com; arc=none smtp.client-ip=92.121.34.21 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=nxp.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=nxp.com Received: from inva021.nxp.com (localhost [127.0.0.1]) by inva021.eu-rdc02.nxp.com (Postfix) with ESMTP id AD4A72010FE; Mon, 26 Feb 2024 09:44:29 +0100 (CET) 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 73DCE200B23; Mon, 26 Feb 2024 09:44:29 +0100 (CET) Received: from localhost.localdomain (shlinux2.ap.freescale.net [10.192.224.44]) by aprdc01srsp001v.ap-rdc01.nxp.com (Postfix) with ESMTP id 135DE1820F56; Mon, 26 Feb 2024 16:44:27 +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: [PATCH v13 13/16] media: uapi: Add an entity type for audio resampler Date: Mon, 26 Feb 2024 16:28:26 +0800 Message-Id: <1708936109-11587-14-git-send-email-shengjiu.wang@nxp.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1708936109-11587-1-git-send-email-shengjiu.wang@nxp.com> References: <1708936109-11587-1-git-send-email-shengjiu.wang@nxp.com> X-Virus-Scanned: ClamAV using ClamSMTP Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1791952906466033926 X-GMAIL-MSGID: 1791952906466033926 Add and document a media entity type for an audio resampler. It is MEDIA_ENT_F_PROC_AUDIO_RESAMPLER. Signed-off-by: Shengjiu Wang --- Documentation/userspace-api/media/mediactl/media-types.rst | 6 ++++++ include/uapi/linux/media.h | 1 + 2 files changed, 7 insertions(+) diff --git a/Documentation/userspace-api/media/mediactl/media-types.rst b/Documentation/userspace-api/media/mediactl/media-types.rst index adfb37430f8e..d353f17c3344 100644 --- a/Documentation/userspace-api/media/mediactl/media-types.rst +++ b/Documentation/userspace-api/media/mediactl/media-types.rst @@ -40,6 +40,7 @@ Types and flags used to represent the media graph elements .. _MEDIA-ENT-F-PROC-VIDEO-ENCODER: .. _MEDIA-ENT-F-PROC-VIDEO-DECODER: .. _MEDIA-ENT-F-PROC-VIDEO-ISP: +.. _MEDIA-ENT-F-PROC-AUDIO-RESAMPLER: .. _MEDIA-ENT-F-VID-MUX: .. _MEDIA-ENT-F-VID-IF-BRIDGE: .. _MEDIA-ENT-F-DV-DECODER: @@ -208,6 +209,11 @@ Types and flags used to represent the media graph elements combination of custom V4L2 controls and IOCTLs, and parameters supplied in a metadata buffer. + * - ``MEDIA_ENT_F_PROC_AUDIO_RESAMPLER`` + - An Audio Resampler device. An entity capable of + resampling an audio stream from one sample rate to another sample + rate. Must have one sink pad and at least one source pad. + * - ``MEDIA_ENT_F_VID_MUX`` - Video multiplexer. An entity capable of multiplexing must have at least two sink pads and one source pad, and must pass the video diff --git a/include/uapi/linux/media.h b/include/uapi/linux/media.h index 9ff6dec7393a..a8266eaa8042 100644 --- a/include/uapi/linux/media.h +++ b/include/uapi/linux/media.h @@ -125,6 +125,7 @@ struct media_device_info { #define MEDIA_ENT_F_PROC_VIDEO_ENCODER (MEDIA_ENT_F_BASE + 0x4007) #define MEDIA_ENT_F_PROC_VIDEO_DECODER (MEDIA_ENT_F_BASE + 0x4008) #define MEDIA_ENT_F_PROC_VIDEO_ISP (MEDIA_ENT_F_BASE + 0x4009) +#define MEDIA_ENT_F_PROC_AUDIO_RESAMPLER (MEDIA_ENT_F_BASE + 0x400a) /* * Switch and bridge entity functions