From patchwork Wed Mar 1 11:38:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155869 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 ED49BC64ED6 for ; Wed, 1 Mar 2023 11:39:49 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=y24SQjB/W/r9cvfMe4lzxoUZRbHUXbm+iDF0XFhGfCQ=; b=1oU0p3fSLHfltx 4cSCSErR7PFCZGF9l5ouYtocbz0tcM4ah21rc67wnw1YKjUNL1PoHjYkSIdxbPesmSfSHIq2zFa4C pKfMOVSvhYe9BCRpnhE+3tRTL5ZV/jF7NKtm/GNQdHktC8K2EmmQQ6IWbmX6PX4jXVMhNw/Yp9c7b zfG6pJSH9EdZ1MHvYuv+M+H54J5j8LkhNq5GY3izVRr5unCBQTPzWW0YxEJFZ3OxtJPgjw2v6eH/L 2gbrpBNkc0f1nJDWEN0Gfb36SmZYYaBvHPv7UsJr+s0zleO2fZN56gyu8bzaf0MdZKN+l6yFggDrO Y49PSADnFc1gvf7YEUeA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnJ-00FxCm-BH; Wed, 01 Mar 2023 11:38:49 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKn9-00Fx8u-6D for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:38:41 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670719; x=1709206719; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=kN9zmelvhJBgNAO5EUo3ZIXHZ2yIk12eJ4vuPHyz4Js=; b=ih1mRnHSG+ghFFA1qtAC/rTorDA1Xo/iCCy5INZAm5Vh/G/DOj9UTZSv vUxebUdu9/KQpBYIHVRZ5OmljkfSfB+mnmhYwQ2yZ7jcXfuorBht9ckW4 0opWLqiQgKP+O4Lng5vW2gldquXN1X4tr9qCQkSgPpIM7VYtsGNb3J9JY HVBZOJbcjmgwW1Z7p0t0CPOM/QeVfsERNffg3uFHGOnjHP0TKlXJj8zTz gvaaVsWrVXkvTync2W4Tf1ceTZU741k8EkDezkk6Z5Uvhocihz4Ozhfq+ NsUTNjqvMadsRw45bFs3T/lkRj4lhOymhmnOqQTePG4BDjOy95ipWM5q3 g==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="202995009" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa2.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:38:35 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:38:30 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:27 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 1/8] ASoC: mchp-spdiftx: use FIELD_PREP() where possible Date: Wed, 1 Mar 2023 13:38:00 +0200 Message-ID: <20230301113807.24036-2-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033839_320079_76CB676F X-CRM114-Status: UNSURE ( 9.08 ) X-CRM114-Notice: Please train this message. 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Use directly FIELD_PREP() marco where possible. There is no need for the extra wrappers. Signed-off-by: Claudiu Beznea --- sound/soc/atmel/mchp-spdiftx.c | 21 +++++++++------------ 1 file changed, 9 insertions(+), 12 deletions(-) diff --git a/sound/soc/atmel/mchp-spdiftx.c b/sound/soc/atmel/mchp-spdiftx.c index 20d135c718b0..bf4252412f9f 100644 --- a/sound/soc/atmel/mchp-spdiftx.c +++ b/sound/soc/atmel/mchp-spdiftx.c @@ -72,11 +72,9 @@ /* Valid Bits per Sample */ #define SPDIFTX_MR_VBPS_MASK GENMASK(13, 8) -#define SPDIFTX_MR_VBPS(bps) FIELD_PREP(SPDIFTX_MR_VBPS_MASK, bps) /* Chunk Size */ #define SPDIFTX_MR_CHUNK_MASK GENMASK(19, 16) -#define SPDIFTX_MR_CHUNK(size) FIELD_PREP(SPDIFTX_MR_CHUNK_MASK, size) /* Validity Bits for Channels 1 and 2 */ #define SPDIFTX_MR_VALID1 BIT(24) @@ -89,7 +87,6 @@ /* Bytes per Sample */ #define SPDIFTX_MR_BPS_MASK GENMASK(29, 28) -#define SPDIFTX_MR_BPS(bytes) FIELD_PREP(SPDIFTX_MR_BPS_MASK, (bytes - 1)) /* * ---- Interrupt Enable/Disable/Mask/Status Register (Write/Read-only) ---- @@ -402,47 +399,47 @@ static int mchp_spdiftx_hw_params(struct snd_pcm_substream *substream, params_channels(params)); return -EINVAL; } - mr |= SPDIFTX_MR_CHUNK(dev->playback.maxburst); + mr |= FIELD_PREP(SPDIFTX_MR_CHUNK_MASK, dev->playback.maxburst); switch (params_format(params)) { case SNDRV_PCM_FORMAT_S8: - mr |= SPDIFTX_MR_VBPS(8); + mr |= FIELD_PREP(SPDIFTX_MR_VBPS_MASK, 8); break; case SNDRV_PCM_FORMAT_S16_BE: mr |= SPDIFTX_MR_ENDIAN_BIG; fallthrough; case SNDRV_PCM_FORMAT_S16_LE: - mr |= SPDIFTX_MR_VBPS(16); + mr |= FIELD_PREP(SPDIFTX_MR_VBPS_MASK, 16); break; case SNDRV_PCM_FORMAT_S18_3BE: mr |= SPDIFTX_MR_ENDIAN_BIG; fallthrough; case SNDRV_PCM_FORMAT_S18_3LE: - mr |= SPDIFTX_MR_VBPS(18); + mr |= FIELD_PREP(SPDIFTX_MR_VBPS_MASK, 18); break; case SNDRV_PCM_FORMAT_S20_3BE: mr |= SPDIFTX_MR_ENDIAN_BIG; fallthrough; case SNDRV_PCM_FORMAT_S20_3LE: - mr |= SPDIFTX_MR_VBPS(20); + mr |= FIELD_PREP(SPDIFTX_MR_VBPS_MASK, 20); break; case SNDRV_PCM_FORMAT_S24_3BE: mr |= SPDIFTX_MR_ENDIAN_BIG; fallthrough; case SNDRV_PCM_FORMAT_S24_3LE: - mr |= SPDIFTX_MR_VBPS(24); + mr |= FIELD_PREP(SPDIFTX_MR_VBPS_MASK, 24); break; case SNDRV_PCM_FORMAT_S24_BE: mr |= SPDIFTX_MR_ENDIAN_BIG; fallthrough; case SNDRV_PCM_FORMAT_S24_LE: - mr |= SPDIFTX_MR_VBPS(24); + mr |= FIELD_PREP(SPDIFTX_MR_VBPS_MASK, 24); break; case SNDRV_PCM_FORMAT_S32_BE: mr |= SPDIFTX_MR_ENDIAN_BIG; fallthrough; case SNDRV_PCM_FORMAT_S32_LE: - mr |= SPDIFTX_MR_VBPS(32); + mr |= FIELD_PREP(SPDIFTX_MR_VBPS_MASK, 32); break; default: dev_err(dev->dev, "unsupported PCM format: %d\n", @@ -450,7 +447,7 @@ static int mchp_spdiftx_hw_params(struct snd_pcm_substream *substream, return -EINVAL; } - mr |= SPDIFTX_MR_BPS(bps); + mr |= FIELD_PREP(SPDIFTX_MR_BPS_MASK, bps - 1); switch (params_rate(params)) { case 22050: From patchwork Wed Mar 1 11:38:01 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155870 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 BFAD3C7EE2D for ; Wed, 1 Mar 2023 11:39:57 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=GesAM50KVzWqAqh75PNpTgSG7EbegoKFMS4WY79NE/Q=; b=qSqjn31OC0DDxb UbRzWcd0U2ODswtMhtWpkM2IyTtJokgyBluTV7eiIU7snT8zgzDZXsZuk/VwdmW+ovXPcaiGeoXgq TxQ5kNjYm+XgEllNe9GjumrxHloka2h9hjIQmvnBdSMb/wNln/7XrIWGe92JFbXiTbY2SDBHKZhjA ZjjKa05tqQPKKQl4cQI93MuMsEhHUWKbVUp8atQKnlbpOdgy+R4g/HO7E5gBEU8wOyVCtjKf6N3b9 OBWLlqHW/mywru8dATVzmF7bC+F4YjuCjuJUD+kkdzO8w7Jsn/IfwMozO11Ylg6f2FqwheOar38fW wgtNJUeLTrS08Xd2TkCg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnR-00FxFp-Fw; Wed, 01 Mar 2023 11:38:57 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnE-00Fx8u-J4 for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:38:45 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670724; x=1709206724; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=clQO14yQ+ltRDG+JAi8cfBFkK9rtlbuvlOm22OW9SxU=; b=kvK86nrMrHckJO6XQAfBwQ0yX6yAbYu1OxcjyIkMdZBLeND5pZVFj3eS 1h3kP+LjStrQ6hg3R7OGNDSZTIdVwK2x1f5IJxDxFCsG7wYOHdQDSbbVt m+8aJ5J/Q3835QmPDVYg1MmrhhhYTpiHvnTNSKmrvttAAO8upa9bzuuqh Ory5bDaoic72LSJC1MJAWjUvn94iFATt19GAwJNzw1j+rhmhT3UEJD1ZH X/FjdaJvCFBmWh/A6HSdR4Fov95p04kRChFh+h8MkRk/b3wnymPvDLE1M 8wh4XzTpauyvsMg2tmVcC9cYQtA+SDzETr9OoL44zhJFbetvX9S5fK8rD A==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="202995020" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa2.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:38:44 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex04.mchp-main.com (10.10.85.152) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:38:33 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:30 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 2/8] ASoC: mchp-spdiftx: use regmap_update_bits() Date: Wed, 1 Mar 2023 13:38:01 +0200 Message-ID: <20230301113807.24036-3-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033844_713296_E6B5444F X-CRM114-Status: GOOD ( 11.01 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Use regmap_update_bits() instead of regmap_read(), running variable, regmap_write(). There is no need for extra variables and checks around it as regmap_update_bits() already does this. With this code becomes simpler. Signed-off-by: Claudiu Beznea --- sound/soc/atmel/mchp-spdiftx.c | 22 +++++----------------- 1 file changed, 5 insertions(+), 17 deletions(-) diff --git a/sound/soc/atmel/mchp-spdiftx.c b/sound/soc/atmel/mchp-spdiftx.c index bf4252412f9f..e7241d819748 100644 --- a/sound/soc/atmel/mchp-spdiftx.c +++ b/sound/soc/atmel/mchp-spdiftx.c @@ -306,15 +306,10 @@ static int mchp_spdiftx_trigger(struct snd_pcm_substream *substream, int cmd, { struct mchp_spdiftx_dev *dev = snd_soc_dai_get_drvdata(dai); struct mchp_spdiftx_mixer_control *ctrl = &dev->control; - u32 mr; - int running; int ret; /* do not start/stop while channel status or user data is updated */ spin_lock(&ctrl->lock); - regmap_read(dev->regmap, SPDIFTX_MR, &mr); - running = !!(mr & SPDIFTX_MR_TXEN_ENABLE); - switch (cmd) { case SNDRV_PCM_TRIGGER_RESUME: case SNDRV_PCM_TRIGGER_START: @@ -323,10 +318,8 @@ static int mchp_spdiftx_trigger(struct snd_pcm_substream *substream, int cmd, dev->suspend_irq = 0; fallthrough; case SNDRV_PCM_TRIGGER_PAUSE_RELEASE: - if (!running) { - mr &= ~SPDIFTX_MR_TXEN_MASK; - mr |= SPDIFTX_MR_TXEN_ENABLE; - } + ret = regmap_update_bits(dev->regmap, SPDIFTX_MR, SPDIFTX_MR_TXEN_MASK, + SPDIFTX_MR_TXEN_ENABLE); break; case SNDRV_PCM_TRIGGER_SUSPEND: regmap_read(dev->regmap, SPDIFTX_IMR, &dev->suspend_irq); @@ -336,17 +329,12 @@ static int mchp_spdiftx_trigger(struct snd_pcm_substream *substream, int cmd, SPDIFTX_IR_TXUDR | SPDIFTX_IR_TXOVR); fallthrough; case SNDRV_PCM_TRIGGER_PAUSE_PUSH: - if (running) { - mr &= ~SPDIFTX_MR_TXEN_MASK; - mr |= SPDIFTX_MR_TXEN_DISABLE; - } + ret = regmap_update_bits(dev->regmap, SPDIFTX_MR, SPDIFTX_MR_TXEN_MASK, + SPDIFTX_MR_TXEN_DISABLE); break; default: - spin_unlock(&ctrl->lock); - return -EINVAL; + ret = -EINVAL; } - - ret = regmap_write(dev->regmap, SPDIFTX_MR, mr); spin_unlock(&ctrl->lock); if (ret) dev_err(dev->dev, "unable to disable TX: %d\n", ret); From patchwork Wed Mar 1 11:38:02 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155868 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 9F38CC64ED6 for ; Wed, 1 Mar 2023 11:39:36 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=MQgCakahsWVEpmPtHqg27EBY1l6pffoBgQAeDbw3D00=; b=k8qCTDw9+vE5NY 2rtvThhhcP8HiwwIcnnRMuQbwCNf9Wv1/ME6yGEFUAGyxGzxxQO1Wdb9+okvBg6fJPqmny5OGEBmo DQTjS9NX5+zicujoTCqhINKx/WwbsZ96WNV9pqsQ33naeOOihIm1eHfq+9adDZDswAGFsikdrcDmn Byp9ut0H1zzvz1zZm1rDywDt0tWpS1ahVjLIOZXuKjkpjraGZTdLuFLS+AfzVN7CA3lJw6+2bpdmA vsaK0i0Vl6LQPEza9CFgn8PSjUVDY3VspOOmNpwntXLrXgTenTTRuGSHKioXmsgSQBe7HYY4p6W9U Hk93r9cmazNVcAWjZkMA==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnB-00FxA7-Jn; Wed, 01 Mar 2023 11:38:41 +0000 Received: from esa.microchip.iphmx.com ([68.232.153.233]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKn7-00Fx8z-Vr for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:38:39 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670717; x=1709206717; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=KXEtH9jKkzGjGt3ggsFrpH4RQJqfkFidzUrK69mPhKo=; b=MP7FG9tN8e53KuQ9IqXMfYCJ7yg5YXTZpkyoPL1xNB4t02v/9z89rp6L 8b/Sn+dY/VnRJZ3sLpLgcE0T/vfljdNWcb4suLMByqoG+p9Y94u5ei5k5 Uu5ylfr5sN4BqFIx2pyR/5/s+cAn6cUJGbXj+13/sKOAGAs1TfKVqPyWq Os1NtemS8xcLnAzI2B5D2CU/DpjhE4W7RpW704mSi2w9hJt1tyoWI9HZ7 U238W/X12fErmvkl4GWs06hzHOLZJb1KCQYjz/ga/jdHWGU4KlRe0t9pV 7uOZoydx8G/38Pavb7tT56lFZ2n1Sc7JpEDVrcyPaA6Dct7f7jKa/COzp A==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="202746412" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa3.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:38:37 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:38:37 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:34 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 3/8] ASoC: mchp-spdiftx: update debug message Date: Wed, 1 Mar 2023 13:38:02 +0200 Message-ID: <20230301113807.24036-4-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033838_182630_7DB948E0 X-CRM114-Status: GOOD ( 11.34 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Previous debug message states that there was a failure and tx was not disabled. Which is not true as the TX in this function could also be enabled. Thus improve a bit the debug message by s/disable/start\/stop/. Signed-off-by: Claudiu Beznea --- sound/soc/atmel/mchp-spdiftx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sound/soc/atmel/mchp-spdiftx.c b/sound/soc/atmel/mchp-spdiftx.c index e7241d819748..02a2fa7a42dd 100644 --- a/sound/soc/atmel/mchp-spdiftx.c +++ b/sound/soc/atmel/mchp-spdiftx.c @@ -337,7 +337,7 @@ static int mchp_spdiftx_trigger(struct snd_pcm_substream *substream, int cmd, } spin_unlock(&ctrl->lock); if (ret) - dev_err(dev->dev, "unable to disable TX: %d\n", ret); + dev_err(dev->dev, "unable to start/stop TX: %d\n", ret); return ret; } From patchwork Wed Mar 1 11:38:03 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155872 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 79AFCC64EC7 for ; Wed, 1 Mar 2023 11:40:20 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=37OxPAPZHlogo8tkWeYQfuVfjBPPuMWZoejaQP95dFA=; b=cfF4YIHVxOidKv U7ltOWMnEi6RUcXl6fm5qhI8S7dVwL48b5JIgQ/tsGjLGzGjFxPFArV9Vuewgx/g3d2guIoAOzoHh tICAvIhyoCHSGGF16nwxre0GdPfvLutjWYoiOxlphTMqvaI4kh9PT3SDbe3nUcq6sR/c/IOSV4hod L6i8R4GKumARhi+1grAvBT/u3E23OlEtY+aNeuwjwrjdvC/gxT+701KWszyLr8E5Es4XySzzzXcda kY4SCqtcr1wcahVKQjpILVN4o32rVSH1oP0acyGzLVnyVaTiHoIs1pyEaO3534Cc+RGqjwu41e/XY FDJPG84zxFvRNYzcO12w==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnl-00FxRU-RW; Wed, 01 Mar 2023 11:39:17 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnL-00FxDa-Ie for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:38:52 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670731; x=1709206731; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=5tklInZTjxW7nUOT7xUU9g3nrOpxKYCG1GaGB1k0my8=; b=2GbAd0fY1RigRvxtgc8ZfGhuN+5GLhmlX+dEpur6fCrZqx4XojQsnqLe NKYuKLd/heECPSEZa0XXngaUC+bCGcO09L486QXrfkuuYMy/z61wdtid6 fYLLX7TbQSEkPoXKKYXIaKyQwWmUY6AuPfVsWVFaTD4DJV9grAcVibmHR nllPSA0Q+17H5T4LLDPqzDw8OIZOWmT9PoCIt17JnEj9F0Qcxbc1OAnEZ v5yvpK5mos+GWybFNj4M1ITbfQZBbym1WfE33V1Q6xfq48fHdaf17VhIx 6ZYWSqEIXv5pB0+wSkzluN3QpZAytLOjq3hWafFYeykTm5D6Z1zoF83N6 A==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="139640258" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:38:48 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:38:41 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:37 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 4/8] ASoC: mchp-pdmc: use FIELD_PREP() where possible Date: Wed, 1 Mar 2023 13:38:03 +0200 Message-ID: <20230301113807.24036-5-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033851_708912_BC019B90 X-CRM114-Status: UNSURE ( 9.71 ) X-CRM114-Notice: Please train this message. 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Use FIELD_PREP() macro where possible instead of driver local defined macros. Signed-off-by: Claudiu Beznea --- sound/soc/atmel/mchp-pdmc.c | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/sound/soc/atmel/mchp-pdmc.c b/sound/soc/atmel/mchp-pdmc.c index 1aed3baa9369..6ec5324fd65e 100644 --- a/sound/soc/atmel/mchp-pdmc.c +++ b/sound/soc/atmel/mchp-pdmc.c @@ -8,6 +8,7 @@ #include +#include #include #include #include @@ -49,8 +50,6 @@ #define MCHP_PDMC_MR_OSR256 (3 << 16) #define MCHP_PDMC_MR_SINCORDER_MASK GENMASK(23, 20) -#define MCHP_PDMC_MR_SINCORDER(order) (((order) << 20) & \ - MCHP_PDMC_MR_SINCORDER_MASK) #define MCHP_PDMC_MR_SINC_OSR_MASK GENMASK(27, 24) #define MCHP_PDMC_MR_SINC_OSR_DIS (0 << 24) @@ -62,8 +61,6 @@ #define MCHP_PDMC_MR_SINC_OSR_256 (6 << 24) #define MCHP_PDMC_MR_CHUNK_MASK GENMASK(31, 28) -#define MCHP_PDMC_MR_CHUNK(chunk) (((chunk) << 28) & \ - MCHP_PDMC_MR_CHUNK_MASK) /* * ---- Configuration Register (Read/Write) ---- @@ -617,10 +614,10 @@ static int mchp_pdmc_hw_params(struct snd_pcm_substream *substream, mr_val |= mchp_pdmc_mr_set_osr(dd->audio_filter_en, osr); - mr_val |= MCHP_PDMC_MR_SINCORDER(dd->sinc_order); + mr_val |= FIELD_PREP(MCHP_PDMC_MR_SINCORDER_MASK, dd->sinc_order); dd->addr.maxburst = mchp_pdmc_period_to_maxburst(snd_pcm_lib_period_bytes(substream)); - mr_val |= MCHP_PDMC_MR_CHUNK(dd->addr.maxburst); + mr_val |= FIELD_PREP(MCHP_PDMC_MR_CHUNK_MASK, dd->addr.maxburst); dev_dbg(comp->dev, "maxburst set to %d\n", dd->addr.maxburst); snd_soc_component_update_bits(comp, MCHP_PDMC_MR, From patchwork Wed Mar 1 11:38:04 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155871 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 9D593C64ED6 for ; Wed, 1 Mar 2023 11:40:01 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=rh6BrmIilaNWGV2CGNSjKirHoXFevHLxyfxGh+U7Ua4=; b=26bMmOExjW6bdX YR4UEG7MtHC3OyzIWFejME/hhW7/6EKXBzfm53P0sbvxbPki5eECwlDLtgoOdb4xFCc0CewjT4zDv ckWWtv4iTlV8YxPVX7XEabKZVJMUXhRYJo7cZZqIAZMliVjsXZOZqLYatTrQqFkO8bKzCOP/DKzRb wEYRe+BdnN3oSnLmLXbulF7Rqid5CPc3b3HQL6HetxAR2dfLeBaPMEW8MIS/M7pD6v8VTwVCjXztf R4et/ea9qmAnp6ka6umpl3umGSz0uKeWuIM6Ocy0V8yFrP7CfIMzittx3Ink30wH0Mhu/GxF0ER0k B+Syvx9g/sYYgooqkRbg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKna-00FxLA-7R; Wed, 01 Mar 2023 11:39:06 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnF-00FxBR-Ur for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:38:47 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670725; x=1709206725; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=XHLvCT8Nt8YmIKi30XtbTBcw6kinTTqUBJYbD4/6SFc=; b=m3tA4J5+U/ucJ4nW56DxDrJLN35QaYKzvFHoZsKRg9ELGgq6MpfAT0eX BA+/OJ9IzEOhZTdtSSGZZonBIFV9IpBurX66rbOHUBHblIlrdtN+1V9jJ asm2rOiILS6jaK+XRjI46TEk7YXgR81dnDvDsoVtKoautY07Ekiy50l1U a52OCBsUoVQUI8lm7OdY13gvQWycFzCYz8kmgPUCIqLl/+gaW4TkP00jZ lSH+uGWC4iK6yomjHTtTblDADlsfbviOnZoTpvbW5veET3z4BzU+qtWZ5 TZ/b0iGipPgkmF+5PQ5UNPkask28oWL7s/ufO207a+iV4qC2opd+lnIvB Q==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="202995026" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa2.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:38:45 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.87.72) by chn-vm-ex02.mchp-main.com (10.10.87.72) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:38:45 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:42 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 5/8] ASoC: mchp-pdmc: return directly ret Date: Wed, 1 Mar 2023 13:38:04 +0200 Message-ID: <20230301113807.24036-6-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033846_099582_E696271E X-CRM114-Status: GOOD ( 10.64 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Return directly ret instead of having different branches for error and OK paths. Signed-off-by: Claudiu Beznea --- sound/soc/atmel/mchp-pdmc.c | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/sound/soc/atmel/mchp-pdmc.c b/sound/soc/atmel/mchp-pdmc.c index 6ec5324fd65e..853a7adfd654 100644 --- a/sound/soc/atmel/mchp-pdmc.c +++ b/sound/soc/atmel/mchp-pdmc.c @@ -759,12 +759,10 @@ static int mchp_pdmc_pcm_new(struct snd_soc_pcm_runtime *rtd, int ret; ret = mchp_pdmc_add_chmap_ctls(rtd->pcm, dd); - if (ret < 0) { + if (ret < 0) dev_err(dd->dev, "failed to add channel map controls: %d\n", ret); - return ret; - } - return 0; + return ret; } static struct snd_soc_dai_driver mchp_pdmc_dai = { From patchwork Wed Mar 1 11:38:05 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155873 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 58E8FC64EC7 for ; Wed, 1 Mar 2023 11:40:31 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=fozIUdLCJ1WW1X2UoqEmSKkh0Eq3rq3hF45cpiqm1+0=; b=QZY2WNSgv+vhSo LjVD3KT6mEhcyF0JHUAgvQ0gxhECHVs0shbQbh4wH2LMs4aIYIjcvl4Kd4qRB+6Ae2zcbkaawO0Ca htQduQ7IOWeT+TFcclPueRnqhxCJSe4dLkrkupNXNG9brBBwppxgO3DS6bhfIemIM+EqL4HkVIe/m 11vUh5n17UTmloHzUbHE57fKFtCOI8qDPLZvxUM1RPo5Ov7JckRCb9KKoiwkoox2KHdkSLEv/4GKx saYSAk9G/69W1494+5qepuE6VhOiht1xHed9igbTY1KgTVggh1wBnLHlo3oQLXhkM2u4xmtiXIsRp 7uMJ6tCS8yWICkpSwn5Q==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnz-00FxZx-Eb; Wed, 01 Mar 2023 11:39:32 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnN-00FxDa-20 for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:38:54 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670733; x=1709206733; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Xy2RIIqGA7KYL9HehO+5TET6KnrqhumxLiivp/+DeYk=; b=t9wBuP+xk1M1pfHSlOxn9fS2ndEC9lLIes9Fj393IgbdXlvdszPU2amI S7qRR0hmm2l2UlKmbayVffD1TIW92s78+DCEwRCxk/MFCD9YlS3L9kpkW Q4MQHepcOmeRx1xYD6GA8DhMQuPcPh8rdd1ygTCGvKGk9vK8WwudrYur2 f1pFKhJtzdtDcWg5pQ/cBStz6Dd5YvZQ6okL62/PkC5qGCtR0PvKfTPtB My6bUnjSOeKhsd75LUOAC9cjyjTi1FpI7naP91olG4A15bPD/IBKNEqP0 NWRlxgHa8n2cioDwCS6Mnkobmo/RVAQRWqG9SU2F9v5KSanu36HqSyPSn A==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="139640271" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa6.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:38:50 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:38:49 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:45 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 6/8] ASoC: mchp-pdmc: avoid casting to/from void pointer Date: Wed, 1 Mar 2023 13:38:05 +0200 Message-ID: <20230301113807.24036-7-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033853_189452_A002530D X-CRM114-Status: GOOD ( 13.82 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Do not cast to and from void pointer. There is no need for this. Signed-off-by: Claudiu Beznea --- sound/soc/atmel/mchp-pdmc.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sound/soc/atmel/mchp-pdmc.c b/sound/soc/atmel/mchp-pdmc.c index 853a7adfd654..81bfa98fd516 100644 --- a/sound/soc/atmel/mchp-pdmc.c +++ b/sound/soc/atmel/mchp-pdmc.c @@ -783,7 +783,7 @@ static struct snd_soc_dai_driver mchp_pdmc_dai = { /* PDMC interrupt handler */ static irqreturn_t mchp_pdmc_interrupt(int irq, void *dev_id) { - struct mchp_pdmc *dd = (struct mchp_pdmc *)dev_id; + struct mchp_pdmc *dd = dev_id; u32 isr, msr, pending; irqreturn_t ret = IRQ_NONE; @@ -1077,7 +1077,7 @@ static int mchp_pdmc_probe(struct platform_device *pdev) } ret = devm_request_irq(dev, irq, mchp_pdmc_interrupt, 0, - dev_name(&pdev->dev), (void *)dd); + dev_name(&pdev->dev), dd); if (ret < 0) { dev_err(dev, "can't register ISR for IRQ %u (ret=%i)\n", irq, ret); From patchwork Wed Mar 1 11:38:06 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155875 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 3B936C64EC7 for ; Wed, 1 Mar 2023 11:41:07 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=c/xmGV3kNEYQ3a68HNjI5bafGAhXVi3ZUosY6cRyCko=; b=wtV8OcoM+igIkF SrJDX5eevc73FIgpBQ77I6kxV5wJSaF9n1kb6II8KlvMcwLo93wEyRNWxwJ6u7gBnalLXCsnI9vT/ IsLl7BZKPMAHzF3jnNvAo2w/49bXrcMMIMFldmM2tUYDd85ETprvr5cDnZLWV3uABySPYCKHvCql3 x/vEbA9n3+Ap6IYMwXYjQmTIegCh8OK7Xqn/RhggNASit3/9vTAwVuFwQR2ThLkLHoY/lruluLoBv NXRcKDV+AaaWlO4B0ByQbYy/I/qAncmrd1kSqGzVeAhDQd74td/zSX0WZc+vXLLBTSNmd9dC22oLJ oRJ7UrUggSt3iaS65Wuw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKoc-00Fxxf-4I; Wed, 01 Mar 2023 11:40:10 +0000 Received: from esa.microchip.iphmx.com ([68.232.154.123]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnX-00FxJF-54 for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:39:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670743; x=1709206743; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=0sZyrt4VnnZxnHrao1ck3NRJLPAVFkEpYF9Axnjts2Y=; b=W00FdqI/dQYz6X9GCfUoQChrWoNQILdipbSmNqFLPgiPsAIFX+G+VawX QSzk7Jhp/r6BeXOUx9ZhD0AWMszB2Q3yucXw1TBfzZXnMblxZp+UNpD78 W8MbxEpk7WG8cfQ8zZHZxmh1HLKSeV8/iULZz7+wafWJobyUksSzi0Txs C1a8lUgu2cZkXuIn1DaAXZHrIqTsuFh+ZPGX/qV42LaikFfEj2lr6HIG+ LwbefcnMS9cS+cxkVokgDMdZEC9LLZK0cEB+bShO1N2M9LgeDPbIZQ+31 YcoOXeBFx6XDJPwK4qx9PemsuWnvf1BcnBuqDRWLHgOT+yfvvbuA0Y04P A==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="199325323" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa4.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:39:01 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex01.mchp-main.com (10.10.85.143) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:38:56 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:50 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 7/8] MAINTAINERS: add myself as maintainer for Microchip AT91 sound drivers Date: Wed, 1 Mar 2023 13:38:06 +0200 Message-ID: <20230301113807.24036-8-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033903_303951_A90F0E6B X-CRM114-Status: GOOD ( 10.33 ) 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Codrin is not with Microchip anymore. As I worked lately with Microchip AT91 sound drivers add myself as maintainer for these. Signed-off-by: Claudiu Beznea Acked-by: Nicolas Ferre --- MAINTAINERS | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 1e246c16aff6..252cc33f0f5c 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -13666,7 +13666,7 @@ F: Documentation/devicetree/bindings/serial/atmel,at91-usart.yaml F: drivers/spi/spi-at91-usart.c MICROCHIP AUDIO ASOC DRIVERS -M: Codrin Ciubotariu +M: Claudiu Beznea L: alsa-devel@alsa-project.org (moderated for non-subscribers) S: Supported F: sound/soc/atmel @@ -13833,7 +13833,7 @@ S: Supported F: drivers/spi/spi-atmel.* MICROCHIP SSC DRIVER -M: Codrin Ciubotariu +M: Claudiu Beznea L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) S: Supported F: drivers/misc/atmel-ssc.c From patchwork Wed Mar 1 11:38:07 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Claudiu Beznea X-Patchwork-Id: 13155874 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 337C6C64EC7 for ; Wed, 1 Mar 2023 11:40:50 +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:Date:Subject:CC:To:From:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=fPGCZYixTswIvujtsr/h+7hkParurq0SBF9xfAf/cjg=; b=NH4b5tpcmgiDEn Dyo+cNuBKC5LrnaQhCdJGa2Oe6AjqmTTHvWqGLsLJppW6ColNN0ezfSz3nJEJku+SY5Ut9wa0W4kC AkywPzGXDjTjhQQyYFyYbFhvy6ZulW/084AYhVypZ7dnoJGDj8gPwEXLH8QG2+/vQcEsOeoECvd5H 0dIEE5fh2GYoW4Gjj0xHFhbajRNQ8afhbf2MztxN9HWMl9Yu+V7+w7B3dzII5w8voTmAmNLWruDih LO+sM8VObEb2sNeyk3f/4rNRWSpWMJDiq/KrKdIAdbGZX6Dre9vlXw7h3A927VvnzZY9LSGy7UdmN /r3DeIx6KNMJjGiNiISg==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKoH-00FxkU-GK; Wed, 01 Mar 2023 11:39:49 +0000 Received: from esa.microchip.iphmx.com ([68.232.153.233]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1pXKnX-00FxJG-38 for linux-arm-kernel@lists.infradead.org; Wed, 01 Mar 2023 11:39:04 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=microchip.com; i=@microchip.com; q=dns/txt; s=mchp; t=1677670742; x=1709206742; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=Y7gJN/0y8MxfRhsCcPrVR7dxAp760NI/rHw1ZXLbncM=; b=TSzINeI+c6RqK09Q469NVg7OEBY44+WgFpv/3cqRDe6EnZPDLLA6FpbB Is/bUqqEheQ+jRs8F0YEVGhs/K2NirB334OiOgwuSOjLIK9fnD5l3y14C o/ml383+0d9/5F81v9l7PTOTh1eFze2BJq4xSI10ZhNLGkrFv0I3NETAI x+aOmvWlUgr5aiOoKh3lmCKt6JdIvMvkaA0Z0eGAnhEggwZTdPuVoHJJs 8c/WX70Lgn3yoLtV7UuX/mIwcpG+kLwVGWT49R3eoATRTPbaJnoqR09cQ nXKlzHwWfebIash05W757AutZHlenCDHbIqU8T3+TR5CcPxtpXrZ3J98r w==; X-IronPort-AV: E=Sophos;i="5.98,224,1673938800"; d="scan'208";a="214196885" Received: from unknown (HELO email.microchip.com) ([170.129.1.10]) by esa1.microchip.iphmx.com with ESMTP/TLS/AES256-SHA256; 01 Mar 2023 04:39:01 -0700 Received: from chn-vm-ex02.mchp-main.com (10.10.85.144) by chn-vm-ex03.mchp-main.com (10.10.85.151) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.16; Wed, 1 Mar 2023 04:39:00 -0700 Received: from m18063-ThinkPad-T460p.mchp-main.com (10.10.115.15) by chn-vm-ex02.mchp-main.com (10.10.85.144) with Microsoft SMTP Server id 15.1.2507.16 via Frontend Transport; Wed, 1 Mar 2023 04:38:56 -0700 From: Claudiu Beznea To: , , , , , CC: , , , Claudiu Beznea Subject: [PATCH 8/8] MAINTAINERS: update Microchip AT91 sound entries with documentation files Date: Wed, 1 Mar 2023 13:38:07 +0200 Message-ID: <20230301113807.24036-9-claudiu.beznea@microchip.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230301113807.24036-1-claudiu.beznea@microchip.com> References: <20230301113807.24036-1-claudiu.beznea@microchip.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20230301_033903_176598_C1AD7223 X-CRM114-Status: UNSURE ( 8.33 ) X-CRM114-Notice: Please train this message. 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: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add documentation files to Microchip AT91 sound entries. Signed-off-by: Claudiu Beznea Acked-by: Nicolas Ferre --- MAINTAINERS | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 252cc33f0f5c..b5a966f84d89 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -13669,6 +13669,10 @@ MICROCHIP AUDIO ASOC DRIVERS M: Claudiu Beznea L: alsa-devel@alsa-project.org (moderated for non-subscribers) S: Supported +F: Documentation/devicetree/bindings/sound/atmel* +F: Documentation/devicetree/bindings/sound/axentia,tse850-pcm5142.txt +F: Documentation/devicetree/bindings/sound/microchip,sama7g5-* +F: Documentation/devicetree/bindings/sound/mikroe,mikroe-proto.txt F: sound/soc/atmel MICROCHIP CSI2DC DRIVER @@ -13836,6 +13840,7 @@ MICROCHIP SSC DRIVER M: Claudiu Beznea L: linux-arm-kernel@lists.infradead.org (moderated for non-subscribers) S: Supported +F: Documentation/devicetree/bindings/misc/atmel-ssc.txt F: drivers/misc/atmel-ssc.c F: include/linux/atmel-ssc.h