mtd: nand: qcom: Add a NULL check for devm_kasprintf()
authorFabio Estevam <fabio.estevam@nxp.com>
Fri, 5 Jan 2018 20:02:55 +0000 (18:02 -0200)
committerBoris Brezillon <boris.brezillon@free-electrons.com>
Sat, 6 Jan 2018 20:55:42 +0000 (21:55 +0100)
commit069f05346d01e7298939f16533953cdf52370be3
treea97ad81733fb534fc2e990e4ff86caff9a1e08d3
parent039b4377e5621a2cc197a7aff1e06db432e4dcc2
mtd: nand: qcom: Add a NULL check for devm_kasprintf()

devm_kasprintf() may fail, so we should better add a NULL check
and propagate an error on failure.

Signed-off-by: Fabio Estevam <fabio.estevam@nxp.com>
Signed-off-by: Boris Brezillon <boris.brezillon@free-electrons.com>
drivers/mtd/nand/qcom_nandc.c