diff mbox series

ASoC: ti: davinci-mcasp: remove always zero of davinci_mcasp_get_dt_params

Message ID 20201102103428.32678-1-zhangqilong3@huawei.com (mailing list archive)
State Accepted
Commit 19f6e424d6150b5eede2277dbc6dfd3bf42e994f
Headers show
Series ASoC: ti: davinci-mcasp: remove always zero of davinci_mcasp_get_dt_params | expand

Commit Message

Zhang Qilong Nov. 2, 2020, 10:34 a.m. UTC
davinci_mcasp_get_dt_params alway return zero, and its return value
could be ignored by the caller. So make it 'void' type to avoid the
check its return value.

Fixes: 764958f2b5239 ("ASoC: ti: davinci-mcasp: Support for auxclk-fs-ratio")
Signed-off-by: Zhang Qilong <zhangqilong3@huawei.com>
---
 sound/soc/ti/davinci-mcasp.c | 10 +++-------
 1 file changed, 3 insertions(+), 7 deletions(-)

Comments

Mark Brown Nov. 3, 2020, 6:14 p.m. UTC | #1
On Mon, 2 Nov 2020 18:34:28 +0800, Zhang Qilong wrote:
> davinci_mcasp_get_dt_params alway return zero, and its return value
> could be ignored by the caller. So make it 'void' type to avoid the
> check its return value.

Applied to

   https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-next

Thanks!

[1/1] ASoC: ti: davinci-mcasp: remove always zero of davinci_mcasp_get_dt_params
      commit: 19f6e424d6150b5eede2277dbc6dfd3bf42e994f

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
diff mbox series

Patch

diff --git a/sound/soc/ti/davinci-mcasp.c b/sound/soc/ti/davinci-mcasp.c
index 4b46dd827f3f..63c492862383 100644
--- a/sound/soc/ti/davinci-mcasp.c
+++ b/sound/soc/ti/davinci-mcasp.c
@@ -2112,20 +2112,18 @@  static inline int davinci_mcasp_init_gpiochip(struct davinci_mcasp *mcasp)
 }
 #endif /* CONFIG_GPIOLIB */
 
-static int davinci_mcasp_get_dt_params(struct davinci_mcasp *mcasp)
+static void davinci_mcasp_get_dt_params(struct davinci_mcasp *mcasp)
 {
 	struct device_node *np = mcasp->dev->of_node;
 	int ret;
 	u32 val;
 
 	if (!np)
-		return 0;
+		return;
 
 	ret = of_property_read_u32(np, "auxclk-fs-ratio", &val);
 	if (ret >= 0)
 		mcasp->auxclk_fs_ratio = val;
-
-	return 0;
 }
 
 static int davinci_mcasp_probe(struct platform_device *pdev)
@@ -2361,9 +2359,7 @@  static int davinci_mcasp_probe(struct platform_device *pdev)
 	if (ret)
 		goto err;
 
-	ret = davinci_mcasp_get_dt_params(mcasp);
-	if (ret)
-		return -EINVAL;
+	davinci_mcasp_get_dt_params(mcasp);
 
 	ret = devm_snd_soc_register_component(&pdev->dev,
 					&davinci_mcasp_component,