]> git.baikalelectronics.ru Git - kernel.git/commit
phy: phy-mvebu-sata: Add missing error check for devm_kzalloc
authorPeter Griffin <peter.griffin@linaro.org>
Fri, 15 Aug 2014 12:40:09 +0000 (13:40 +0100)
committerKishon Vijay Abraham I <kishon@ti.com>
Wed, 24 Sep 2014 09:48:31 +0000 (15:18 +0530)
commit5f0e7841d0abf456b76bdc2cce0f5d6be5733065
tree8400cf883a301832560187933eade98faa8a1e58
parent5850f492a22c8701ac29890532f2bd150f29ab49
phy: phy-mvebu-sata: Add missing error check for devm_kzalloc

Currently this driver is missing a check on the return value of devm_kzalloc,
which would cause a NULL pointer dereference in a OOM situation.

This patch adds the aformentioned missing check.

Signed-off-by: Peter Griffin <peter.griffin@linaro.org>
Acked-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Kishon Vijay Abraham I <kishon@ti.com>
drivers/phy/phy-mvebu-sata.c