[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20200420142509.9728-1-tangbin@cmss.chinamobile.com>
Date: Mon, 20 Apr 2020 22:25:09 +0800
From: Tang Bin <tangbin@...s.chinamobile.com>
To: broonie@...nel.org, perex@...ex.cz, tiwai@...e.com,
shawnguo@...nel.org, s.hauer@...gutronix.de, lgirdwood@...il.com
Cc: alsa-devel@...a-project.org, linux-arm-kernel@...ts.infradead.org,
linux-kernel@...r.kernel.org,
Tang Bin <tangbin@...s.chinamobile.com>,
Shengju Zhang <zhangshengju@...s.chinamobile.com>
Subject: [PATCH] ASoC: mxs-saif: Avoid unnecessary check
The function mxs_saif_probe() is only called with an
openfirmware platform device. Therefore there is no
need to check that it has an openfirmware node.
Signed-off-by: Shengju Zhang <zhangshengju@...s.chinamobile.com>
Signed-off-by: Tang Bin <tangbin@...s.chinamobile.com>
---
sound/soc/mxs/mxs-saif.c | 3 ---
1 file changed, 3 deletions(-)
diff --git a/sound/soc/mxs/mxs-saif.c b/sound/soc/mxs/mxs-saif.c
index 1e38ce858..64c095b91 100644
--- a/sound/soc/mxs/mxs-saif.c
+++ b/sound/soc/mxs/mxs-saif.c
@@ -736,9 +736,6 @@ static int mxs_saif_probe(struct platform_device *pdev)
int irq, ret = 0;
struct device_node *master;
- if (!np)
- return -EINVAL;
-
saif = devm_kzalloc(&pdev->dev, sizeof(*saif), GFP_KERNEL);
if (!saif)
return -ENOMEM;
--
2.20.1.windows.1
Powered by blists - more mailing lists