summaryrefslogtreecommitdiffstats
path: root/drivers/mtd/devices
diff options
context:
space:
mode:
authorJulia Lawall <Julia.Lawall@inria.fr>2022-02-10 21:42:21 +0100
committerMiquel Raynal <miquel.raynal@bootlin.com>2022-02-18 15:14:01 +0100
commitccb7bc50177c5e94e0609126654abeb4f3b67819 (patch)
tree060ecf9298de69b3907347f96c84e172e580d1a2 /drivers/mtd/devices
parentd71dac3b897f51d7d1fcf28d2a2ab29e541a6cda (diff)
downloadlinux-ccb7bc50177c5e94e0609126654abeb4f3b67819.tar.gz
linux-ccb7bc50177c5e94e0609126654abeb4f3b67819.tar.bz2
linux-ccb7bc50177c5e94e0609126654abeb4f3b67819.zip
mtd: spear_smi: use GFP_KERNEL
Platform_driver probe functions aren't called with locks held and thus don't need GFP_ATOMIC. Use GFP_KERNEL instead. Problem found with Coccinelle. Signed-off-by: Julia Lawall <Julia.Lawall@inria.fr> Signed-off-by: Miquel Raynal <miquel.raynal@bootlin.com> Link: https://lore.kernel.org/linux-mtd/20220210204223.104181-8-Julia.Lawall@inria.fr
Diffstat (limited to 'drivers/mtd/devices')
-rw-r--r--drivers/mtd/devices/spear_smi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/mtd/devices/spear_smi.c b/drivers/mtd/devices/spear_smi.c
index 2e00862389dd..24073518587f 100644
--- a/drivers/mtd/devices/spear_smi.c
+++ b/drivers/mtd/devices/spear_smi.c
@@ -969,7 +969,7 @@ static int spear_smi_probe(struct platform_device *pdev)
goto err;
}
- dev = devm_kzalloc(&pdev->dev, sizeof(*dev), GFP_ATOMIC);
+ dev = devm_kzalloc(&pdev->dev, sizeof(*dev), GFP_KERNEL);
if (!dev) {
ret = -ENOMEM;
goto err;