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=-12.1 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,INCLUDES_PATCH,MAILING_LIST_MULTI, MENTIONS_GIT_HOSTING,SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED autolearn=ham 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 E0991C4360F for ; Thu, 4 Apr 2019 13:58:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id AFA90214AF for ; Thu, 4 Apr 2019 13:58:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1554386335; bh=zkFqvPtOmbeGU97xqUbQ8LEKDyVCL2579KmZY/R0X5o=; h=From:To:Cc:Subject:In-Reply-To:Date:List-ID:From; b=y0SFWd6YOFmTUIXjR1r2MSRaHXUBS3Zbu1RqN6vKd9NoGQbbLmb53jnqxjbAaiFmv AR+KoqdoL9jJy7+jkn+TDE68dZExw5J1ZuhMcrsuugTWvvDUndsrwmokV998ktEgER dyS5Ys5BWSSwkWWwEaa1+z6cC2cSP0BWtLuo0GSA= Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729575AbfDDN6y (ORCPT ); Thu, 4 Apr 2019 09:58:54 -0400 Received: from heliosphere.sirena.org.uk ([172.104.155.198]:60134 "EHLO heliosphere.sirena.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727441AbfDDN6j (ORCPT ); Thu, 4 Apr 2019 09:58:39 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=o9qc8BULGi8SzKzz3FPvxxn43t/KoOJY1dafcoG2Yo8=; b=l4VWODum7BOp QyyiIPpR0MD0ZyjYzVDUJo0CNw4AbcoRK45+BE3n8fkOc1qEP3qLXRfLHQuCwgn0vVF3umbbsvn4V MRlL81OrmWJXvwnr+4lfszgRcFwXFYMjJ9pA2NMmWQoOSqA8Z3XiY/KTNiuyWZvwqBQFHRvflzB3E 3zZqs=; Received: from [147.50.13.10] (helo=finisterre.ee.mobilebroadband) by heliosphere.sirena.org.uk with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hC2su-0006d1-VW; Thu, 04 Apr 2019 13:58:29 +0000 Received: by finisterre.ee.mobilebroadband (Postfix, from userid 1000) id 22337441D3C; Thu, 4 Apr 2019 20:58:26 +0700 (+07) From: Mark Brown To: Olivier Moysan Cc: Mark Brown , lgirdwood@gmail.com, broonie@kernel.org, perex@perex.cz, tiwai@suse.com, mcoquelin.stm32@gmail.com, alexandre.torgue@st.com, alsa-devel@alsa-project.org, robh@kernel.org, mark.rutland@arm.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, linux-kernel@vger.kernel.org, olivier.moysan@st.com, arnaud.pouliquen@st.com, benjamin.gaignard@st.com, apatard@mandriva.com, alsa-devel@alsa-project.org Subject: Applied "ASoC: cs42l51: add reset management" to the asoc tree In-Reply-To: <1554297817-14154-4-git-send-email-olivier.moysan@st.com> X-Patchwork-Hint: ignore Message-Id: <20190404135826.22337441D3C@finisterre.ee.mobilebroadband> Date: Thu, 4 Apr 2019 20:58:26 +0700 (+07) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The patch ASoC: cs42l51: add reset management has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark >From 11b9cd748e3107df5c5e040a4daa986a3c6d8b75 Mon Sep 17 00:00:00 2001 From: Olivier Moysan Date: Wed, 3 Apr 2019 15:23:33 +0200 Subject: [PATCH] ASoC: cs42l51: add reset management Manage cs42l51 audio codec reset pin. Signed-off-by: Olivier Moysan Signed-off-by: Mark Brown --- sound/soc/codecs/cs42l51.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sound/soc/codecs/cs42l51.c b/sound/soc/codecs/cs42l51.c index f43eb51d2d8d..9b3ffa16b204 100644 --- a/sound/soc/codecs/cs42l51.c +++ b/sound/soc/codecs/cs42l51.c @@ -30,6 +30,7 @@ #include #include #include +#include #include #include @@ -54,6 +55,7 @@ struct cs42l51_private { unsigned int audio_mode; /* The mode (I2S or left-justified) */ enum master_slave_mode func; struct regulator_bulk_data supplies[ARRAY_SIZE(cs42l51_supply_names)]; + struct gpio_desc *reset_gpio; }; #define CS42L51_FORMATS ( \ @@ -595,6 +597,17 @@ int cs42l51_probe(struct device *dev, struct regmap *regmap) return ret; } + cs42l51->reset_gpio = devm_gpiod_get_optional(dev, "reset", + GPIOD_OUT_LOW); + if (IS_ERR(cs42l51->reset_gpio)) + return PTR_ERR(cs42l51->reset_gpio); + + if (cs42l51->reset_gpio) { + dev_dbg(dev, "Release reset gpio\n"); + gpiod_set_value_cansleep(cs42l51->reset_gpio, 0); + mdelay(2); + } + /* Verify that we have a CS42L51 */ ret = regmap_read(regmap, CS42L51_CHIP_REV_ID, &val); if (ret < 0) { @@ -629,6 +642,8 @@ int cs42l51_remove(struct device *dev) { struct cs42l51_private *cs42l51 = dev_get_drvdata(dev); + gpiod_set_value_cansleep(cs42l51->reset_gpio, 1); + return regulator_bulk_disable(ARRAY_SIZE(cs42l51->supplies), cs42l51->supplies); } -- 2.20.1 From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark Brown Subject: Applied "ASoC: cs42l51: add reset management" to the asoc tree Date: Thu, 4 Apr 2019 20:58:26 +0700 (+07) Message-ID: <20190404135826.22337441D3C@finisterre.ee.mobilebroadband> References: <1554297817-14154-4-git-send-email-olivier.moysan@st.com> Return-path: In-Reply-To: <1554297817-14154-4-git-send-email-olivier.moysan@st.com> Sender: linux-kernel-owner@vger.kernel.org Cc: Mark Brown , lgirdwood@gmail.combroonie@kernel.org, perex@perex.cz, tiwai@suse.com, mcoquelin.stm32@gmail.com, alexandre.torgue@st.com, alsa-devel@alsa-project.org, robh@kernel.org, mark.rutland@arm.com, devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-stm32@st-md-mailman.stormreply.com, linux-kernel@vger.kernel.org, olivier.moysan@st.com, arnaud.pouliquen@st.com, benjamin.gaignard@st.com, apatard@mandriva.comalsa-devel@alsa-project.org List-Id: devicetree@vger.kernel.org The patch ASoC: cs42l51: add reset management has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark >>From 11b9cd748e3107df5c5e040a4daa986a3c6d8b75 Mon Sep 17 00:00:00 2001 From: Olivier Moysan Date: Wed, 3 Apr 2019 15:23:33 +0200 Subject: [PATCH] ASoC: cs42l51: add reset management Manage cs42l51 audio codec reset pin. Signed-off-by: Olivier Moysan Signed-off-by: Mark Brown --- sound/soc/codecs/cs42l51.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sound/soc/codecs/cs42l51.c b/sound/soc/codecs/cs42l51.c index f43eb51d2d8d..9b3ffa16b204 100644 --- a/sound/soc/codecs/cs42l51.c +++ b/sound/soc/codecs/cs42l51.c @@ -30,6 +30,7 @@ #include #include #include +#include #include #include @@ -54,6 +55,7 @@ struct cs42l51_private { unsigned int audio_mode; /* The mode (I2S or left-justified) */ enum master_slave_mode func; struct regulator_bulk_data supplies[ARRAY_SIZE(cs42l51_supply_names)]; + struct gpio_desc *reset_gpio; }; #define CS42L51_FORMATS ( \ @@ -595,6 +597,17 @@ int cs42l51_probe(struct device *dev, struct regmap *regmap) return ret; } + cs42l51->reset_gpio = devm_gpiod_get_optional(dev, "reset", + GPIOD_OUT_LOW); + if (IS_ERR(cs42l51->reset_gpio)) + return PTR_ERR(cs42l51->reset_gpio); + + if (cs42l51->reset_gpio) { + dev_dbg(dev, "Release reset gpio\n"); + gpiod_set_value_cansleep(cs42l51->reset_gpio, 0); + mdelay(2); + } + /* Verify that we have a CS42L51 */ ret = regmap_read(regmap, CS42L51_CHIP_REV_ID, &val); if (ret < 0) { @@ -629,6 +642,8 @@ int cs42l51_remove(struct device *dev) { struct cs42l51_private *cs42l51 = dev_get_drvdata(dev); + gpiod_set_value_cansleep(cs42l51->reset_gpio, 1); + return regulator_bulk_disable(ARRAY_SIZE(cs42l51->supplies), cs42l51->supplies); } -- 2.20.1 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=-12.0 required=3.0 tests=DKIMWL_WL_HIGH,DKIM_SIGNED, DKIM_VALID,INCLUDES_PATCH,MAILING_LIST_MULTI,MENTIONS_GIT_HOSTING, SIGNED_OFF_BY,SPF_PASS,URIBL_BLOCKED autolearn=unavailable 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 CE058C4360F for ; Thu, 4 Apr 2019 13:59:15 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 9C3CD20652 for ; Thu, 4 Apr 2019 13:59:15 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="B1Vh/dab"; dkim=fail reason="signature verification failed" (1024-bit key) header.d=sirena.org.uk header.i=@sirena.org.uk header.b="l4VWODum" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 9C3CD20652 Authentication-Results: mail.kernel.org; dmarc=fail (p=none dis=none) header.from=kernel.org Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:MIME-Version:Cc:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Date:Message-Id: In-Reply-To:Subject:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: References:List-Owner; bh=MlvJXn+TsQV+Pr1SanDcbkgbJ9u46JMFDDIZpDXP6FI=; b=B1V h/dabX8cCBP24ifYrkei8dWk+svhH+bYo+qfyhY0QsMhw1Yw8sCTvBVr+PK0WiLko6D9nlzcZrEiq fir8pAgum7HkCC22yaymUaFPSEl6geBK1mv+tRXQxWNm3aFsZLd9tEk0/vI+eOGqyXd6oEwnDRFT1 JEaEvMMeJtLXVcs7hhCftGickCpyxYObe3PhyNEKC3i9oMXuUKSK1aMi3ixXE2j8zYCcn4MRgw45q w58Xtez0ZyxsWYDiEmxwTUOGDwuV308YfgdXWEndGcHlfOcjH2Oad4/aNjN4ua/ZLp+rU6NegaZZ5 2C7lo3zzTG6fm41L3HVJht1y0SLXtYA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1hC2ta-0002b9-B6; Thu, 04 Apr 2019 13:59:10 +0000 Received: from heliosphere.sirena.org.uk ([2a01:7e01::f03c:91ff:fed4:a3b6]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1hC2t0-0001sN-I7 for linux-arm-kernel@lists.infradead.org; Thu, 04 Apr 2019 13:58:36 +0000 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=sirena.org.uk; s=20170815-heliosphere; h=Date:Message-Id:In-Reply-To: Subject:Cc:To:From:Sender:Reply-To:MIME-Version:Content-Type: Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:References: List-Id:List-Help:List-Unsubscribe:List-Subscribe:List-Post:List-Owner: List-Archive; bh=o9qc8BULGi8SzKzz3FPvxxn43t/KoOJY1dafcoG2Yo8=; b=l4VWODum7BOp QyyiIPpR0MD0ZyjYzVDUJo0CNw4AbcoRK45+BE3n8fkOc1qEP3qLXRfLHQuCwgn0vVF3umbbsvn4V MRlL81OrmWJXvwnr+4lfszgRcFwXFYMjJ9pA2NMmWQoOSqA8Z3XiY/KTNiuyWZvwqBQFHRvflzB3E 3zZqs=; Received: from [147.50.13.10] (helo=finisterre.ee.mobilebroadband) by heliosphere.sirena.org.uk with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.89) (envelope-from ) id 1hC2su-0006d1-VW; Thu, 04 Apr 2019 13:58:29 +0000 Received: by finisterre.ee.mobilebroadband (Postfix, from userid 1000) id 22337441D3C; Thu, 4 Apr 2019 20:58:26 +0700 (+07) From: Mark Brown To: Olivier Moysan Subject: Applied "ASoC: cs42l51: add reset management" to the asoc tree In-Reply-To: <1554297817-14154-4-git-send-email-olivier.moysan@st.com> X-Patchwork-Hint: ignore Message-Id: <20190404135826.22337441D3C@finisterre.ee.mobilebroadband> Date: Thu, 4 Apr 2019 20:58:26 +0700 (+07) X-Bad-Reply: In-Reply-To but no 'Re:' in Subject. X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20190404_065834_742248_19D8AC86 X-CRM114-Status: GOOD ( 14.61 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: mark.rutland@arm.com, robh@kernel.org, alsa-devel@alsa-project.org, olivier.moysan@st.com, alexandre.torgue@st.com, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, arnaud.pouliquen@st.com, tiwai@suse.com, lgirdwood@gmail.com, broonie@kernel.org, mcoquelin.stm32@gmail.com, apatard@mandriva.com, perex@perex.cz, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, benjamin.gaignard@st.com MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+infradead-linux-arm-kernel=archiver.kernel.org@lists.infradead.org The patch ASoC: cs42l51: add reset management has been applied to the asoc tree at https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted. You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed. If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced. Please add any relevant lists and maintainers to the CCs when replying to this mail. Thanks, Mark >From 11b9cd748e3107df5c5e040a4daa986a3c6d8b75 Mon Sep 17 00:00:00 2001 From: Olivier Moysan Date: Wed, 3 Apr 2019 15:23:33 +0200 Subject: [PATCH] ASoC: cs42l51: add reset management Manage cs42l51 audio codec reset pin. Signed-off-by: Olivier Moysan Signed-off-by: Mark Brown --- sound/soc/codecs/cs42l51.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/sound/soc/codecs/cs42l51.c b/sound/soc/codecs/cs42l51.c index f43eb51d2d8d..9b3ffa16b204 100644 --- a/sound/soc/codecs/cs42l51.c +++ b/sound/soc/codecs/cs42l51.c @@ -30,6 +30,7 @@ #include #include #include +#include #include #include @@ -54,6 +55,7 @@ struct cs42l51_private { unsigned int audio_mode; /* The mode (I2S or left-justified) */ enum master_slave_mode func; struct regulator_bulk_data supplies[ARRAY_SIZE(cs42l51_supply_names)]; + struct gpio_desc *reset_gpio; }; #define CS42L51_FORMATS ( \ @@ -595,6 +597,17 @@ int cs42l51_probe(struct device *dev, struct regmap *regmap) return ret; } + cs42l51->reset_gpio = devm_gpiod_get_optional(dev, "reset", + GPIOD_OUT_LOW); + if (IS_ERR(cs42l51->reset_gpio)) + return PTR_ERR(cs42l51->reset_gpio); + + if (cs42l51->reset_gpio) { + dev_dbg(dev, "Release reset gpio\n"); + gpiod_set_value_cansleep(cs42l51->reset_gpio, 0); + mdelay(2); + } + /* Verify that we have a CS42L51 */ ret = regmap_read(regmap, CS42L51_CHIP_REV_ID, &val); if (ret < 0) { @@ -629,6 +642,8 @@ int cs42l51_remove(struct device *dev) { struct cs42l51_private *cs42l51 = dev_get_drvdata(dev); + gpiod_set_value_cansleep(cs42l51->reset_gpio, 1); + return regulator_bulk_disable(ARRAY_SIZE(cs42l51->supplies), cs42l51->supplies); } -- 2.20.1 _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel