Commit 601fd3a7 authored by Tang Bin's avatar Tang Bin Committed by Mark Brown

ASoC: fsl_spdif: Fix unnecessary check in fsl_spdif_probe()

The function fsl_spdif_probe() is only called with an openfirmware
platform device. Therefore there is no need to check that the passed
in device is NULL.
Signed-off-by: default avatarZhang Shengju <zhangshengju@cmss.chinamobile.com>
Signed-off-by: default avatarTang Bin <tangbin@cmss.chinamobile.com>
Link: https://lore.kernel.org/r/20200826150918.16116-1-tangbin@cmss.chinamobile.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 08dd413b
......@@ -1259,9 +1259,6 @@ static int fsl_spdif_probe(struct platform_device *pdev)
void __iomem *regs;
int irq, ret, i;
if (!np)
return -ENODEV;
spdif_priv = devm_kzalloc(&pdev->dev, sizeof(*spdif_priv), GFP_KERNEL);
if (!spdif_priv)
return -ENOMEM;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment