Commit 95601d65 authored by Mark Brown's avatar Mark Brown

regmap: spi: Handle allocation failures gracefully

Signed-off-by: default avatarMark Brown <broonie@opensource.wolfsonmicro.com>
parent f88948ef
......@@ -86,6 +86,8 @@ static struct regmap_async *regmap_spi_async_alloc(void)
struct regmap_async_spi *async_spi;
async_spi = kzalloc(sizeof(*async_spi), GFP_KERNEL);
if (!async_spi)
return NULL;
return &async_spi->core;
}
......
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