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 Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 251C1C433FE for ; Fri, 6 May 2022 11:38:21 +0000 (UTC) Received: from alsa1.perex.cz (alsa1.perex.cz [207.180.221.201]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by alsa0.perex.cz (Postfix) with ESMTPS id 55EC317C1; Fri, 6 May 2022 13:37:29 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa0.perex.cz 55EC317C1 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=alsa-project.org; s=default; t=1651837099; bh=CDDh2KSbrnqeeQjBcQ0pCAaNluEpPzLAeE50CYhH0nc=; h=Subject:From:To:Date:In-Reply-To:References:Cc:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=Ulr2XApqDw4KtI/VjstPoD0lOQkF0/yS7ljNrU7KKiPPi6tFXxz6RmmPmGcnBCeJB IaGc3S9qoLMI8LJtqX0P2RTuKqj4uwv9gYNZEabA3mm6LKlOOZnYPWbRDE+GzZyEcm Vi4OGAxPxnEJpYLe3lXWB1ZDFrYpjM6HGr3r00BE= Received: from alsa1.perex.cz (localhost.localdomain [127.0.0.1]) by alsa1.perex.cz (Postfix) with ESMTP id D98A6F8012F; Fri, 6 May 2022 13:37:28 +0200 (CEST) Received: by alsa1.perex.cz (Postfix, from userid 50401) id 9637BF8014B; Fri, 6 May 2022 13:37:26 +0200 (CEST) Received: from mailgw02.mediatek.com (unknown [210.61.82.184]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by alsa1.perex.cz (Postfix) with ESMTPS id EECADF800F0 for ; Fri, 6 May 2022 13:37:19 +0200 (CEST) DKIM-Filter: OpenDKIM Filter v2.11.0 alsa1.perex.cz EECADF800F0 X-UUID: 5038d43519b74feca2815c150857bef6-20220506 X-CID-P-RULE: Release_Ham X-CID-O-INFO: VERSION:1.1.4, REQID:616086b7-229f-4795-9c2d-512db55b2b67, OB:0, LO B:0,IP:0,URL:0,TC:0,Content:0,EDM:0,RT:0,SF:0,FILE:0,RULE:Release_Ham,ACTI ON:release,TS:0 X-CID-META: VersionHash:faefae9, CLOUDID:470ad8b2-56b5-4c9e-8d83-0070b288eb6a, C OID:IGNORED,Recheck:0,SF:nil,TC:nil,Content:0,EDM:-3,File:nil,QS:0,BEC:nil X-UUID: 5038d43519b74feca2815c150857bef6-20220506 Received: from mtkexhb02.mediatek.inc [(172.21.101.103)] by mailgw02.mediatek.com (envelope-from ) (Generic MTA with TLSv1.2 ECDHE-RSA-AES256-SHA384 256/256) with ESMTP id 987445387; Fri, 06 May 2022 19:37:09 +0800 Received: from mtkcas10.mediatek.inc (172.21.101.39) by mtkmbs10n1.mediatek.inc (172.21.101.34) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384) id 15.2.792.15; Fri, 6 May 2022 19:37:07 +0800 Received: from mtksdccf07 (172.21.84.99) by mtkcas10.mediatek.inc (172.21.101.73) with Microsoft SMTP Server id 15.0.1497.2 via Frontend Transport; Fri, 6 May 2022 19:37:07 +0800 Message-ID: Subject: Re: [RESEND PATCH v7 1/1] firmware: mediatek: add adsp ipc protocol interface From: Tinghan Shen To: Greg Kroah-Hartman Date: Fri, 6 May 2022 19:37:07 +0800 In-Reply-To: References: <20220505053048.13804-1-tinghan.shen@mediatek.com> <20220505053048.13804-2-tinghan.shen@mediatek.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.28.5-0ubuntu0.18.04.2 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-MTK: N Cc: alsa-devel@alsa-project.org, Allen-KH Cheng , Daniel Vetter , Javier Martinez Canillas , Pierre-Louis Bossart , Project_Global_Chrome_Upstream_Group@mediatek.com, Tzung-Bi Shih , Cristian Marussi , Michal Suchanek , Arnd Bergmann , Sudeep Holla , Simon Trimmer , Mark Brown , John Stultz , Matthias Brugger , Bjorn Andersson , linux-arm-kernel@lists.infradead.org, AngeloGioacchino Del Regno , Borislav Petkov , linux-kernel@vger.kernel.org, Thomas Zimmermann , YC Hung , linux-mediatek@lists.infradead.org, Curtis Malainey , Etienne Carriere X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: alsa-devel-bounces@alsa-project.org Sender: "Alsa-devel" Hi Greg, Thanks for your review. On Thu, 2022-05-05 at 23:10 +0200, Greg Kroah-Hartman wrote: > On Thu, May 05, 2022 at 01:30:48PM +0800, Tinghan Shen wrote: > > From: TingHan Shen > > > > Some of mediatek processors contain > > the Tensilica HiFix DSP for audio processing. > > > > The communication between Host CPU and DSP firmware is > > taking place using a shared memory area for message passing. > > > > ADSP IPC protocol offers (send/recv) interfaces using > > mediatek-mailbox APIs. > > > > We use two mbox channels to implement a request-reply protocol. > > > > Signed-off-by: Allen-KH Cheng > > Signed-off-by: TingHan Shen > > Reviewed-by: Pierre-Louis Bossart > > Reviewed-by: Curtis Malainey > > Reviewed-by: Tzung-Bi Shih > > Reviewed-by: YC Hung > > Reviewed-by: AngeloGioacchino Del Regno > > --- > > drivers/firmware/Kconfig | 1 + > > drivers/firmware/Makefile | 1 + > > drivers/firmware/mediatek/Kconfig | 9 + > > drivers/firmware/mediatek/Makefile | 2 + > > drivers/firmware/mediatek/mtk-adsp-ipc.c | 161 ++++++++++++++++++ > > .../linux/firmware/mediatek/mtk-adsp-ipc.h | 65 +++++++ > > 6 files changed, 239 insertions(+) > > create mode 100644 drivers/firmware/mediatek/Kconfig > > create mode 100644 drivers/firmware/mediatek/Makefile > > create mode 100644 drivers/firmware/mediatek/mtk-adsp-ipc.c > > create mode 100644 include/linux/firmware/mediatek/mtk-adsp-ipc.h > > Why do you have a .h file, and export symbols in your .c file, yet you > have no user of these symbols or header file? > > Without a user, we can not take this, sorry. MediaTek have adsp client drivers on 2 chips that use symbols from this module. We were planned to upstream them after Linux community accept this module. I will add those client drivers in next version. > > This should just be one single .c file. > > Also, why a whole subdirectory for just one .c file? Ok, I'll move the souce out and remove this subdirectory in next version. Thank you very much. Best regards, TingHan > > thanks, > > greg k-h