2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-27 22:53:55 +08:00

staging: nvec: remove unneccessary 'out of memory' message

Fix the following warning reported by checkpatch.pl:

WARNING: Possible unnecessary 'out of memory' message
811: FILE: drivers/staging/nvec/nvec.c:811

Signed-off-by: Pawel Lebioda <pawel.lebioda89@gmail.com>
Acked-by: Marc Dietrich <marvin24@gmx.de>
Reviewed-by: Thierry Reding <treding@nvidia.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Pawel Lebioda 2014-07-05 22:30:56 +02:00 committed by Greg Kroah-Hartman
parent aea2cda3d8
commit 5a9077a833

View File

@ -806,10 +806,9 @@ static int tegra_nvec_probe(struct platform_device *pdev)
}
nvec = devm_kzalloc(&pdev->dev, sizeof(struct nvec_chip), GFP_KERNEL);
if (nvec == NULL) {
dev_err(&pdev->dev, "failed to reserve memory\n");
if (nvec == NULL)
return -ENOMEM;
}
platform_set_drvdata(pdev, nvec);
nvec->dev = &pdev->dev;