MLK-19500: drm: imx: dcss: fix tracing function
authorLaurentiu Palcu <laurentiu.palcu@nxp.com>
Fri, 7 Sep 2018 07:14:57 +0000 (10:14 +0300)
committerLeonard Crestez <leonard.crestez@nxp.com>
Wed, 17 Apr 2019 23:51:34 +0000 (02:51 +0300)
kzalloc with GFP_KERNEL argument, may sleep. dcss_trace_write() is
called also from interrupt context and sleeping is not acceptable.

This patch will make kzalloc() call atomic.

Signed-off-by: Laurentiu Palcu <laurentiu.palcu@nxp.com>
drivers/gpu/imx/dcss/dcss-common.c

index d8094a1..d4a9fe3 100644 (file)
@@ -353,7 +353,7 @@ void dcss_trace_write(u64 tag)
        if (!dcss_tracing)
                return;
 
-       trace = kzalloc(sizeof(*trace), GFP_KERNEL);
+       trace = kzalloc(sizeof(*trace), GFP_ATOMIC);
        if (!trace)
                return;