✗ CI.checkpatch: warning for drm/xe: fixup xe_alloc_pf_queue

Patchwork patchwork at emeril.freedesktop.org
Wed Aug 21 17:47:05 UTC 2024


== Series Details ==

Series: drm/xe: fixup xe_alloc_pf_queue
URL   : https://patchwork.freedesktop.org/series/137584/
State : warning

== Summary ==

+ KERNEL=/kernel
+ git clone https://gitlab.freedesktop.org/drm/maintainer-tools mt
Cloning into 'mt'...
warning: redirecting to https://gitlab.freedesktop.org/drm/maintainer-tools.git/
+ git -C mt rev-list -n1 origin/master
9fe5037901cabbcdf27a6fe0dfb047ca1474d363
+ cd /kernel
+ git config --global --add safe.directory /kernel
+ git log -n1
commit 4af590fe0fb63dfc67373759601cf87c46accbf9
Author: Matthew Auld <matthew.auld at intel.com>
Date:   Wed Aug 21 18:19:18 2024 +0100

    drm/xe: fixup xe_alloc_pf_queue
    
    kzalloc expects number of bytes, therefore we should convert the number
    of dw into bytes, otherwise we are likely just accessing beyond the
    array causing all kinds of carnage. Also fixup the error handling while
    we are here.
    
    Fixes: 3338e4f90c14 ("drm/xe: Use topology to determine page fault queue size")
    Signed-off-by: Matthew Auld <matthew.auld at intel.com>
    Cc: Stuart Summers <stuart.summers at intel.com>
    Cc: Matthew Brost <matthew.brost at intel.com>
+ /mt/dim checkpatch ddbda36f876f53498924155abfa1cd4c58517903 drm-intel
4af590fe0fb6 drm/xe: fixup xe_alloc_pf_queue
-:25: WARNING:ALLOC_WITH_MULTIPLY: Prefer kcalloc over kzalloc with multiply
#25: FILE: drivers/gpu/drm/xe/xe_gt_pagefault.c:420:
+	pf_queue->data = kzalloc(pf_queue->num_dw * sizeof(u32), GFP_KERNEL);

total: 0 errors, 1 warnings, 0 checks, 11 lines checked




More information about the Intel-xe mailing list