drivers/gpu/drm/i915/i915_syncmap.c:285:45-51: ERROR: application of sizeof to 
pointer

 sizeof when applied to a pointer typed expression gives the size of
 the pointer

Generated by: scripts/coccinelle/misc/noderef.cocci

Signed-off-by: Fengguang Wu <fengguang...@intel.com>
---

 i915_syncmap.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/drivers/gpu/drm/i915/i915_syncmap.c
+++ b/drivers/gpu/drm/i915/i915_syncmap.c
@@ -282,7 +282,7 @@ static noinline int __sync_set(struct i9
                        unsigned int above;
 
                        /* Insert a join above the current layer */
-                       next = kzalloc(sizeof(*next) + KSYNCMAP * sizeof(next),
+                       next = kzalloc(sizeof(*next) + KSYNCMAP * sizeof(*next),
                                       GFP_KERNEL);
                        if (unlikely(!next))
                                return -ENOMEM;
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

Reply via email to