✗ CI.checkpatch: warning for drm/xe/guc: Fix dereference before NULL check (rev5)
Patchwork
patchwork at emeril.freedesktop.org
Fri Oct 25 03:33:49 UTC 2024
== Series Details ==
Series: drm/xe/guc: Fix dereference before NULL check (rev5)
URL : https://patchwork.freedesktop.org/series/139890/
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
30ab6715fc09baee6cc14cb3c89ad8858688d474
+ cd /kernel
+ git config --global --add safe.directory /kernel
+ git log -n1
commit aec8ed40e82e38f8611eb0ddd687068984c91f40
Author: Everest K.C. <everestkc at everestkc.com.np>
Date: Wed Oct 23 17:33:55 2024 -0600
drm/xe/guc: Fix dereference before NULL check
The pointer list->list is dereferenced before the NULL check.
Fix this by moving the NULL check outside the for loop, so that
the check is performed before the dereferencing.
The list->list pointer cannot be NULL so this has no effect on runtime.
It's just a correctness issue.
This issue was reported by Coverity Scan.
https://scan7.scan.coverity.com/#/project-view/51525/11354?selectedIssue=1600335
Fixes: 0f1fdf559225 ("drm/xe/guc: Save manual engine capture into capture list")
Signed-off-by: Everest K.C. <everestkc at everestkc.com.np>
Reviewed-by: Dan Carpenter <dan.carpenter at linaro.org>
+ /mt/dim checkpatch 75eab7b9ee32a121d95a42ac704b679097f1fac4 drm-intel
aec8ed40e82e drm/xe/guc: Fix dereference before NULL check
-:13: WARNING:COMMIT_LOG_LONG_LINE: Prefer a maximum 75 chars per line (possible unwrapped commit description?)
#13:
https://scan7.scan.coverity.com/#/project-view/51525/11354?selectedIssue=1600335
total: 0 errors, 1 warnings, 0 checks, 17 lines checked
More information about the Intel-xe
mailing list