Skip to content

Commit

Permalink
ASoC: fsl_spdif: Fix unnecessary check in fsl_spdif_probe()
Browse files Browse the repository at this point in the history
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: Zhang Shengju <zhangshengju@cmss.chinamobile.com>
Signed-off-by: Tang Bin <tangbin@cmss.chinamobile.com>
Link: https://lore.kernel.org/r/20200826150918.16116-1-tangbin@cmss.chinamobile.com
Signed-off-by: Mark Brown <broonie@kernel.org>
  • Loading branch information
Tang Bin authored and Mark Brown committed Oct 1, 2020
1 parent 08dd413 commit 601fd3a
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions sound/soc/fsl/fsl_spdif.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
Expand Down

0 comments on commit 601fd3a

Please sign in to comment.