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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 9F6D7C54798 for ; Tue, 5 Mar 2024 14:07:40 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender: Content-Transfer-Encoding:Content-Type:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To: Message-ID:Subject:Cc:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=gd0SzkhMXiZ2MBxZiU7xWHNLF4xaE8l/TCEdVbGJDd8=; b=g8llsDpLrDUEwG KOzvAZ3bXeXSVHw0exXLMPhb/2EKYUSHXgP+NclZqYCumdfmMuCC9wLnsVyzIZMG1IQWdPYAwc64E 99h/fPw0304MMEmA1IB1748Md8vzplizu8K8ttjJz60kg8SbNnV34ouQHNyW0Lp/fife8BHmfd2AR Q9d8IHz08iLgt12vMwDBKnI+0BOc5B2UV7ukFPFmQBb9sBUgwU5hy8HXpJPpRdGELOguSbZZzBBMs y+B82mUM+efSw+Oq1gLxkBn4jWIWc+vTMAqVgsSPbQPzTDUCD8Ai5rJYGUSBfmOOq+dpvObnm78wL hxGKfxVkOAyUORUWHa1w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.97.1 #2 (Red Hat Linux)) id 1rhVS0-0000000DwoF-2P00; Tue, 05 Mar 2024 14:07:24 +0000 Received: from relay8-d.mail.gandi.net ([2001:4b98:dc4:8::228]) by bombadil.infradead.org with esmtps (Exim 4.97.1 #2 (Red Hat Linux)) id 1rhVRx-0000000Dwmy-26Zp; Tue, 05 Mar 2024 14:07:23 +0000 Received: by mail.gandi.net (Postfix) with ESMTPSA id 974621BF20A; Tue, 5 Mar 2024 14:07:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1709647639; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=mlSdtS9gPl3MStQDE6pU+wB4e620UH09fdWfMjz3JdY=; b=mKJ/As3NrkbIh4PqASWy22hOM4m+EZHgPI+zhZQrt886iDFGwkdhs8cK5LSEZHlRUbVD7J c7gx2HJ7SrSF1AXWtqe70ZWhjiOFzpE6or4k+k7JaHKoojt9TQzfREwGwIu3Zmm9Tk9p4X 84q8AGfD9BW+fuoqymLP5MswVra4Wa44dcIWDJASp6/tMbEfUurr0NqwX5/Kacul2npFcU gfJndI9ZTkBq924ykcXEhGAoaI1U3t5rdSpaN0U8+aKBa9m1aGxeTuf/pxA4DwRAS+m+sJ 1bkxO0ZxdojAXtO+RHCjuqZIMygma3rFAfi2SyNMjO2uuy5+jEpbdcXkTl4PZg== Date: Tue, 5 Mar 2024 15:07:16 +0100 From: Luca Ceresoli To: Philipp Zabel Cc: Nicolas Frattaroli , Liam Girdwood , Mark Brown , Jaroslav Kysela , Takashi Iwai , Heiko Stuebner , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Thomas Petazzoni , linux-rockchip@lists.infradead.org, linux-sound@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org Subject: Re: [PATCH v3 4/7] ASoC: codecs: Add RK3308 internal audio codec driver Message-ID: <20240305150716.0fca0e33@booty> In-Reply-To: <09c275d0f0a1bf85f37635d9570514e8fc631e72.camel@pengutronix.de> References: <20240221-rk3308-audio-codec-v3-0-dfa34abfcef6@bootlin.com> <20240221-rk3308-audio-codec-v3-4-dfa34abfcef6@bootlin.com> <09c275d0f0a1bf85f37635d9570514e8fc631e72.camel@pengutronix.de> Organization: Bootlin X-Mailer: Claws Mail 4.0.0 (GTK+ 3.24.33; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-GND-Sasl: luca.ceresoli@bootlin.com X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20240305_060721_730781_ADE10126 X-CRM114-Status: GOOD ( 21.53 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Hello Philipp, On Wed, 21 Feb 2024 14:21:23 +0100 Philipp Zabel wrote: > On Mi, 2024-02-21 at 11:22 +0100, Luca Ceresoli wrote: > > Add driver for the internal audio codec of the Rockchip RK3308 SoC. > > > > Initially based on the vendor kernel driver [0], with lots of cleanups, > > fixes, improvements, conversion to DAPM and removal of some features. > > > > [0] https://github.com/rockchip-linux/kernel/blob/develop-4.19/sound/soc/codecs/rk3308_codec.c > > > > Signed-off-by: Luca Ceresoli > > > [...] > > diff --git a/sound/soc/codecs/rk3308_codec.c b/sound/soc/codecs/rk3308_codec.c > > new file mode 100644 > > index 000000000000..61bfb75f92a3 > > --- /dev/null > > +++ b/sound/soc/codecs/rk3308_codec.c > > @@ -0,0 +1,993 @@ > [...] > > +static int rk3308_codec_platform_probe(struct platform_device *pdev) > > +{ > [...] > > + rk3308->reset = devm_reset_control_get(&pdev->dev, "codec"); > > + if (IS_ERR(rk3308->reset)) { > > + err = PTR_ERR(rk3308->reset); > > + if (err != -ENOENT) > > + return err; > > + > > + dev_dbg(&pdev->dev, "No reset control found\n"); > > + rk3308->reset = NULL; > > + } > > Please use devm_reset_control_get_optional_exclusive(). That already > returns NULL instead of -ENOENT if the reset control is not specified > in the device tree. Then dev_err_probe() can be used to report errors. Good point, thanks. Queued for v4. Best regards, Luca -- Luca Ceresoli, Bootlin Embedded Linux and Kernel engineering https://bootlin.com _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel