From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 40EB9C2BB1D for ; Fri, 13 Mar 2020 10:26:16 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 4A8C62073E for ; Fri, 13 Mar 2020 10:26:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726632AbgCMK0P (ORCPT ); Fri, 13 Mar 2020 06:26:15 -0400 Received: from mout.kundenserver.de ([217.72.192.74]:43193 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726423AbgCMK0P (ORCPT ); Fri, 13 Mar 2020 06:26:15 -0400 Received: from mail.cetitecgmbh.com ([87.190.42.90]) by mrelayeu.kundenserver.de (mreue107 [212.227.15.183]) with ESMTPSA (Nemesis) id 1MkYsS-1jbbb229de-00m1eV; Fri, 13 Mar 2020 11:26:02 +0100 Received: from pflvmailgateway.corp.cetitec.com (unknown [127.0.0.1]) by mail.cetitecgmbh.com (Postfix) with ESMTP id 67EE36501F5; Fri, 13 Mar 2020 10:26:01 +0000 (UTC) X-Virus-Scanned: amavisd-new at cetitec.com Received: from mail.cetitecgmbh.com ([127.0.0.1]) by pflvmailgateway.corp.cetitec.com (pflvmailgateway.corp.cetitec.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tXMM2uOgK3Nx; Fri, 13 Mar 2020 11:26:01 +0100 (CET) Received: from pfwsexchange.corp.cetitec.com (unknown [10.10.1.99]) by mail.cetitecgmbh.com (Postfix) with ESMTPS id EB9EA64FEE5; Fri, 13 Mar 2020 11:26:00 +0100 (CET) Received: from pflmari.corp.cetitec.com (10.10.2.141) by PFWSEXCHANGE.corp.cetitec.com (10.10.1.99) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 13 Mar 2020 11:26:01 +0100 Received: by pflmari.corp.cetitec.com (Postfix, from userid 1000) id 9500F804F8; Fri, 13 Mar 2020 11:26:00 +0100 (CET) Date: Fri, 13 Mar 2020 11:26:00 +0100 From: Alex Riesen To: Hans Verkuil CC: Kieran Bingham , Mauro Carvalho Chehab , Laurent Pinchart , Rob Herring , Mark Rutland , , , , , Subject: Re: [PATCH 2/8] media: adv748x: add audio mute control and output selection ioctls Message-ID: <20200313102600.GF3832@pflmari> Mail-Followup-To: Alex Riesen , Hans Verkuil , Kieran Bingham , Mauro Carvalho Chehab , Laurent Pinchart , Rob Herring , Mark Rutland , devel@driverdev.osuosl.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-renesas-soc@vger.kernel.org References: <20200113141521.GC3606@pflmari> MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Disposition: inline In-Reply-To: X-Originating-IP: [10.10.2.141] X-ClientProxiedBy: PFWSEXCHANGE.corp.cetitec.com (10.10.1.99) To PFWSEXCHANGE.corp.cetitec.com (10.10.1.99) X-EsetResult: clean, is OK X-EsetId: 37303A290D7F536A627061 X-Provags-ID: V03:K1:pmRc/dG1ku1hUco+cU0pJmJkIsZimoq3eyRDNsQtuHdsIPbBkC0 4FCaHFoQiKJCY0LxHdfYTK1gYRbqBfebjsEZ1NWa81AK/HJcPe3lDMnxRIBZQXl11KLhx7z SD0etOc+nneciAeV9I24SK6kUDjeCXMy8a9P6dTWq9DppjM3ma11hS3SENmDP6Jm1padRlH Ka0SLqEinwp4UtQcH/BlQ== X-UI-Out-Filterresults: notjunk:1;V03:K0:ZaxZ+24ibLo=:c1xj2HmOiiT7P0OF2k8DOW XaX2A2wFTELxyxbYE1tVYCvlNEsu3ed81azir53chhnbQyrwPWu5utikSlnKeHf4xu2cMRTxy Oyjj18HpP+dB8eW6QCm6iweyWKVcP1NTLMtJOTx8h4FPKaCgajswc03QZRxLJRwNoJGWCgtIn KVpNLJ9p1yCq9l4ZWbLGKwVhdOjyCWvRDnlSDlKtxxHugKbRLJv7Mvt/ec5NYwoXE5qOOuP4L 0MQAn1IUf6HQyqDmlRW8zOwOl/dxSHL+4zFp1GvsNieo5BDRGo/UjEvSlGbSPIcPo7K+c7eqI IpFTCFMnVlmoFJopsAyUQye3GapWvVGshe7cIwbR54q8DiJB1tUQWtn996S2Mnd4j0C8CMDek 0wRgcsXVYDO1bZqAa0WwkhfZzqXRAUFona7kUzUajvBZ8xbqCklN+c5ES+r7kzGyleoE2pbP5 QfjdKLmYzC1XUDAuoFLma8D2OxvFrxJFEjXLAteYUVp0cklq10g0HceJuNlQtTeFY61gbDUJd 7eCb4qAE137EfA+jIarEcDvJcS3UDDwq7UZRiTENCv3eUdT/0sJln8DwR/ZhWiOvxaSA8Of3q 0piztpK/tcpiZ1f+5nZ+FHIGjGIGvso2/JxpBANut6UwCu2Xdf0A6G9JezUhgc1KTbhEhwrTo hR1OmvSD+dqV2M/KyJH4hmC0W2rW3ViyLNLWUUfUIRTsmqzaUQ0cVgsv9oTumkbLOyGXm+B8k HTn+D6XWixhHB1gDESYUKWk36vLSQhXBNifaYJckd/U6y4HXEPIlhDzLNa4mhZXRkRqXZP0mK 7etH9sAqT59s35QgmTdHzUaYFHAVWZ3OWakuGbIvXImobhwMIMd4BH6b8nD/9jQYXAVD/a/ Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Hans, Hans Verkuil, Fri, Mar 13, 2020 09:16:11 +0100: > On 1/13/20 3:15 PM, Alex Riesen wrote: > > This change implements audio-related V4L2 ioctls for the HDMI subdevice. > > This is really where things go wrong. These V4L2 audio ioctls are meant for > old PCI TV tuner devices where the audio was implemented as audio jack outputs > that are typically looped back to audio inputs on a (PCI) soundcard. And when > these ioctls were designed ALSA didn't even exist. I see. That was before my time :) > Generally an hdmi driver will configure the i2s audio automatically, which is > typically connected to the SoC and controlled by the ALSA driver of the SoC, > but there may well be missing features (audio never got a lot of attention in > hdmi receivers). So what I would like to know is: what features are missing? Well, the audio is missing. The current adv748x driver does not export the audio features of the device at all. There is no code to enable the I2S audio output and it is disabled (all clock and the data lines) by default. But, by now it seems to be clear that implementation of ALSA SoC DAI interfaces is the way to support the audio. And I am already slowly working on it. > Anything missing can likely be resolved by adding HDMI audio specific V4L2 controls, > which would be the right approach for this. > > So I would expect to see a proposal for V4L2_CID_DV_RX_AUDIO_ controls to be > added here: > > https://linuxtv.org/downloads/v4l-dvb-apis-new/uapi/v4l/ext-ctrls-dv.html This seems to be an explicitly "digital video" control class. And it has no control option for mute. Or did you mean a similarly structured new class for "digital audio"? This feels like an overkill for this particular driver... Regards, Alex From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-0.8 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C8D62C10DCE for ; Fri, 13 Mar 2020 10:26:21 +0000 (UTC) Received: from whitealder.osuosl.org (smtp1.osuosl.org [140.211.166.138]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id CDBFA2073E for ; Fri, 13 Mar 2020 10:26:21 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org CDBFA2073E Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=cetitec.com Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=driverdev-devel-bounces@linuxdriverproject.org Received: from localhost (localhost [127.0.0.1]) by whitealder.osuosl.org (Postfix) with ESMTP id 89BEA88B09; Fri, 13 Mar 2020 10:26:21 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from whitealder.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id RPYL-ltxmt-6; Fri, 13 Mar 2020 10:26:19 +0000 (UTC) Received: from ash.osuosl.org (ash.osuosl.org [140.211.166.34]) by whitealder.osuosl.org (Postfix) with ESMTP id AA36488AF1; Fri, 13 Mar 2020 10:26:19 +0000 (UTC) Received: from fraxinus.osuosl.org (smtp4.osuosl.org [140.211.166.137]) by ash.osuosl.org (Postfix) with ESMTP id 56C041BF349 for ; Fri, 13 Mar 2020 10:26:18 +0000 (UTC) Received: from localhost (localhost [127.0.0.1]) by fraxinus.osuosl.org (Postfix) with ESMTP id 500FE874C1 for ; Fri, 13 Mar 2020 10:26:18 +0000 (UTC) X-Virus-Scanned: amavisd-new at osuosl.org Received: from fraxinus.osuosl.org ([127.0.0.1]) by localhost (.osuosl.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id aXoVP_pTaoNs for ; Fri, 13 Mar 2020 10:26:17 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from mout.kundenserver.de (mout.kundenserver.de [217.72.192.74]) by fraxinus.osuosl.org (Postfix) with ESMTPS id 1BB2F874A6 for ; Fri, 13 Mar 2020 10:26:16 +0000 (UTC) Received: from mail.cetitecgmbh.com ([87.190.42.90]) by mrelayeu.kundenserver.de (mreue107 [212.227.15.183]) with ESMTPSA (Nemesis) id 1MkYsS-1jbbb229de-00m1eV; Fri, 13 Mar 2020 11:26:02 +0100 Received: from pflvmailgateway.corp.cetitec.com (unknown [127.0.0.1]) by mail.cetitecgmbh.com (Postfix) with ESMTP id 67EE36501F5; Fri, 13 Mar 2020 10:26:01 +0000 (UTC) X-Virus-Scanned: amavisd-new at cetitec.com Received: from mail.cetitecgmbh.com ([127.0.0.1]) by pflvmailgateway.corp.cetitec.com (pflvmailgateway.corp.cetitec.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id tXMM2uOgK3Nx; Fri, 13 Mar 2020 11:26:01 +0100 (CET) Received: from pfwsexchange.corp.cetitec.com (unknown [10.10.1.99]) by mail.cetitecgmbh.com (Postfix) with ESMTPS id EB9EA64FEE5; Fri, 13 Mar 2020 11:26:00 +0100 (CET) Received: from pflmari.corp.cetitec.com (10.10.2.141) by PFWSEXCHANGE.corp.cetitec.com (10.10.1.99) with Microsoft SMTP Server (TLS) id 15.0.1497.2; Fri, 13 Mar 2020 11:26:01 +0100 Received: by pflmari.corp.cetitec.com (Postfix, from userid 1000) id 9500F804F8; Fri, 13 Mar 2020 11:26:00 +0100 (CET) Date: Fri, 13 Mar 2020 11:26:00 +0100 From: Alex Riesen To: Hans Verkuil Subject: Re: [PATCH 2/8] media: adv748x: add audio mute control and output selection ioctls Message-ID: <20200313102600.GF3832@pflmari> Mail-Followup-To: Alex Riesen , Hans Verkuil , Kieran Bingham , Mauro Carvalho Chehab , Laurent Pinchart , Rob Herring , Mark Rutland , devel@driverdev.osuosl.org, linux-media@vger.kernel.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, linux-renesas-soc@vger.kernel.org References: <20200113141521.GC3606@pflmari> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: X-Originating-IP: [10.10.2.141] X-ClientProxiedBy: PFWSEXCHANGE.corp.cetitec.com (10.10.1.99) To PFWSEXCHANGE.corp.cetitec.com (10.10.1.99) X-EsetResult: clean, is OK X-EsetId: 37303A290D7F536A627061 X-Provags-ID: V03:K1:pmRc/dG1ku1hUco+cU0pJmJkIsZimoq3eyRDNsQtuHdsIPbBkC0 4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ImobhwMIMd4BH6b8nD/9jQYXAVD/a/ X-BeenThere: driverdev-devel@linuxdriverproject.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Linux Driver Project Developer List List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: Mark Rutland , devel@driverdev.osuosl.org, devicetree@vger.kernel.org, Kieran Bingham , linux-kernel@vger.kernel.org, linux-renesas-soc@vger.kernel.org, Rob Herring , Laurent Pinchart , Mauro Carvalho Chehab , linux-media@vger.kernel.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Errors-To: driverdev-devel-bounces@linuxdriverproject.org Sender: "devel" Hi Hans, Hans Verkuil, Fri, Mar 13, 2020 09:16:11 +0100: > On 1/13/20 3:15 PM, Alex Riesen wrote: > > This change implements audio-related V4L2 ioctls for the HDMI subdevice. > > This is really where things go wrong. These V4L2 audio ioctls are meant for > old PCI TV tuner devices where the audio was implemented as audio jack outputs > that are typically looped back to audio inputs on a (PCI) soundcard. And when > these ioctls were designed ALSA didn't even exist. I see. That was before my time :) > Generally an hdmi driver will configure the i2s audio automatically, which is > typically connected to the SoC and controlled by the ALSA driver of the SoC, > but there may well be missing features (audio never got a lot of attention in > hdmi receivers). So what I would like to know is: what features are missing? Well, the audio is missing. The current adv748x driver does not export the audio features of the device at all. There is no code to enable the I2S audio output and it is disabled (all clock and the data lines) by default. But, by now it seems to be clear that implementation of ALSA SoC DAI interfaces is the way to support the audio. And I am already slowly working on it. > Anything missing can likely be resolved by adding HDMI audio specific V4L2 controls, > which would be the right approach for this. > > So I would expect to see a proposal for V4L2_CID_DV_RX_AUDIO_ controls to be > added here: > > https://linuxtv.org/downloads/v4l-dvb-apis-new/uapi/v4l/ext-ctrls-dv.html This seems to be an explicitly "digital video" control class. And it has no control option for mute. Or did you mean a similarly structured new class for "digital audio"? This feels like an overkill for this particular driver... Regards, Alex _______________________________________________ devel mailing list devel@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel