✗ CI.checkpatch: warning for drm/xe/guc: Improve GuC log dumping and add to devcoredump (rev2)

Patchwork patchwork at emeril.freedesktop.org
Thu Sep 5 20:57:33 UTC 2024


== Series Details ==

Series: drm/xe/guc: Improve GuC log dumping and add to devcoredump (rev2)
URL   : https://patchwork.freedesktop.org/series/137985/
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
c62d7e164862503a3662a095da1c6c9014248cb2
+ cd /kernel
+ git config --global --add safe.directory /kernel
+ git log -n1
commit 394a22c1f649be5bf07d58b630aa3e36c084f3c8
Author: John Harrison <John.C.Harrison at Intel.com>
Date:   Thu Sep 5 13:51:05 2024 -0700

    drm/xe/guc: Add a helper function for dumping GuC log to dmesg
    
    Create a helper function that can be used to dump the GuC log to dmesg
    in a manner that is reliable for extraction and decode. The intention
    is that calls to this can be added by developers when debugging
    specific issues that require a GuC log but do not allow easy capture
    of the log - e.g. failures in selftests and failues that lead to
    kernel hangs.
    
    Also note that this is really a temporary stop-gap. The aim is to
    allow on demand creation and dumping of devcoredump captures (which
    includes the GuC log and much more). Currently this is not possible as
    much of the devcoredump code requires a 'struct xe_sched_job' and
    those are not available at many places that might want to do the dump.
    
    v2: Add kerneldoc - review feedback from Michal W.
    
    Signed-off-by: John Harrison <John.C.Harrison at Intel.com>
+ /mt/dim checkpatch 7f3ffaf88a3a1b3e29416488fb4e58fd551cd89d drm-intel
c1b6085dae2e drm/xe/guc: Remove spurious line feed in debug print
93c2469fde94 drm/xe/devcoredump: Add a section heading for the submission backend
41e9a65650a5 drm/xe/devcoredump: Add ASCII85 dump helper function
0319f8f8d6b9 drm/xe/guc: Copy GuC log prior to dumping
9923ff30ac15 drm/xe/guc: Use a two stage dump for GuC logs and add more info
8cdf5b5e9e12 drm/print: Introduce drm_line_printer
7332d3d58548 drm/xe/guc: Dead CT helper
-:87: CHECK:MACRO_ARG_REUSE: Macro argument reuse 'ct' - possible side-effects?
#87: FILE: drivers/gpu/drm/xe/xe_guc_ct.c:55:
+#define CT_DEAD(ct, ctb, reason_code)								\
+	do {											\
+		struct guc_ctb *_ctb = (ctb);							\
+		if (_ctb)									\
+			_ctb->info.broken = true;						\
+		if (!(ct)->dead.reported) {							\
+			struct xe_guc *guc = ct_to_guc(ct);					\
+			spin_lock_irq(&ct->dead.lock);						\
+			(ct)->dead.reason |= 1 << CT_DEAD_##reason_code;			\
+			(ct)->dead.snapshot_log = xe_guc_log_snapshot_capture(&guc->log, true);	\
+			(ct)->dead.snapshot_ct = xe_guc_ct_snapshot_capture((ct), true);	\
+			spin_unlock_irq(&ct->dead.lock);					\
+			queue_work(system_unbound_wq, &(ct)->dead.worker);			\
+		}										\
+	} while (0)

-:103: WARNING:MACRO_ARG_UNUSED: Argument 'ct' is not used in function-like macro
#103: FILE: drivers/gpu/drm/xe/xe_guc_ct.c:71:
+#define CT_DEAD(ct, ctb, reason)			\
+	do {						\
+		struct guc_ctb *_ctb = (ctb);		\
+		if (_ctb)				\
+			_ctb->info.broken = true;	\
+	} while (0)

-:103: WARNING:MACRO_ARG_UNUSED: Argument 'reason' is not used in function-like macro
#103: FILE: drivers/gpu/drm/xe/xe_guc_ct.c:71:
+#define CT_DEAD(ct, ctb, reason)			\
+	do {						\
+		struct guc_ctb *_ctb = (ctb);		\
+		if (_ctb)				\
+			_ctb->info.broken = true;	\
+	} while (0)

total: 0 errors, 2 warnings, 1 checks, 510 lines checked
7358f7258afc drm/xe/guc: Dump entire CTB on errors
-:16: WARNING:TYPO_SPELLING: 'seperately' may be misspelled - perhaps 'separately'?
#16: 
v5: Dump the entire CTB object rather than seperately dumping just the
                                           ^^^^^^^^^^

total: 0 errors, 1 warnings, 0 checks, 195 lines checked
f67041bdc3d0 drm/xe/guc: Add GuC log to devcoredump captures
394a22c1f649 drm/xe/guc: Add a helper function for dumping GuC log to dmesg




More information about the Intel-xe mailing list