Intel-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel.vetter@ffwll.ch>
To: Intel Graphics Development <intel-gfx@lists.freedesktop.org>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>,
	Daniel Vetter <daniel.vetter@intel.com>
Subject: [PATCH] HAX FOR CI: Enable cross-release
Date: Fri, 23 Nov 2018 09:53:07 +0100	[thread overview]
Message-ID: <20181123085307.13304-1-daniel.vetter@ffwll.ch> (raw)
In-Reply-To: <20181122163526.16873-1-daniel.vetter@ffwll.ch>

Only way to convince our CI to enable stuff that's new and defaulting
to off. Obviously not for merging.

v2: Also enable fullstack backtraces.

v3: Try to chase this elusive stack trace corruption CI is seeing.

v4: Make it compile. Silly me.

Signed-off-by: Daniel Vetter <daniel.vetter@intel.com>
---
 kernel/locking/lockdep.c | 13 +++++++++++++
 lib/Kconfig.debug        |  3 ++-
 2 files changed, 15 insertions(+), 1 deletion(-)

diff --git a/kernel/locking/lockdep.c b/kernel/locking/lockdep.c
index e74add63f317..1ceb97cc6ec0 100644
--- a/kernel/locking/lockdep.c
+++ b/kernel/locking/lockdep.c
@@ -4841,8 +4841,15 @@ static void add_xhlock(struct held_lock *hlock)
 	xhlock->trace.entries = xhlock->trace_entries;
 
 	if (crossrelease_fullstack) {
+		int i;
+
 		xhlock->trace.skip = 3;
 		save_stack_trace(&xhlock->trace);
+
+		for (i = 0; i < xlock->trace.nr_entries; i++) {
+			if (xlock->trace.entries[i] == 0x6b6b6b6b6b6b6b6bUL)
+				print_lockdep_off("BUG: list poison in add_xlock!");
+		}
 	} else {
 		xhlock->trace.nr_entries = 1;
 		xhlock->trace.entries[0] = hlock->acquire_ip;
@@ -4950,12 +4957,18 @@ static int copy_trace(struct stack_trace *trace)
 	unsigned long *buf = stack_trace + nr_stack_trace_entries;
 	unsigned int max_nr = MAX_STACK_TRACE_ENTRIES - nr_stack_trace_entries;
 	unsigned int nr = min(max_nr, trace->nr_entries);
+	int i;
 
 	trace->nr_entries = nr;
 	memcpy(buf, trace->entries, nr * sizeof(trace->entries[0]));
 	trace->entries = buf;
 	nr_stack_trace_entries += nr;
 
+	for (i = 0; i < trace->nr_entries; i++) {
+		if (trace->entries[i] == 0x6b6b6b6b6b6b6b6bUL)
+			print_lockdep_off("BUG: list poison in copy_trace!");
+	}
+
 	if (nr_stack_trace_entries >= MAX_STACK_TRACE_ENTRIES-1) {
 		if (!debug_locks_off_graph_unlock())
 			return 0;
diff --git a/lib/Kconfig.debug b/lib/Kconfig.debug
index 6074fa3463ac..8e1c30e3face 100644
--- a/lib/Kconfig.debug
+++ b/lib/Kconfig.debug
@@ -1095,6 +1095,7 @@ config LOCKDEP_CROSSRELEASE
 	bool "Enable cross-release checking"
 	depends on PROVE_LOCKING
 	select LOCKDEP_COMPLETIONS
+	default y
 	help
 	 This makes lockdep work for crosslock which is a lock allowed to
 	 be released in a different context from the acquisition context.
@@ -1208,7 +1209,7 @@ config LOCKDEP_COMPLETIONS
 config BOOTPARAM_LOCKDEP_CROSSRELEASE_FULLSTACK
 	bool "Enable the boot parameter, crossrelease_fullstack"
 	depends on LOCKDEP_CROSSRELEASE
-	default n
+	default y
 	help
 	 The lockdep "cross-release" feature needs to record stack traces
 	 (of calling functions) for all acquisitions, for eventual later
-- 
2.19.1

_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

  reply	other threads:[~2018-11-23  8:53 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-07 15:30 [PATCH 01/13] locking/lockdep: restore cross-release checks Daniel Vetter
2018-11-07 15:30 ` [PATCH 02/13] kthread: finer-grained lockdep/cross-release completion Daniel Vetter
2018-11-07 15:30 ` [PATCH 03/13] lockdep: Remove GFP_NOLOCKDEP annotation Daniel Vetter
2018-11-07 15:30 ` [PATCH 04/13] kernel/lockdep: Make cross-release a config option Daniel Vetter
2018-11-07 15:30 ` [PATCH 05/13] mm: Check if mmu notifier callbacks are allowed to fail Daniel Vetter
2018-11-07 15:30 ` [PATCH 06/13] mm, notifier: Catch sleeping/blocking for !blockable Daniel Vetter
2018-11-07 15:30 ` [PATCH 07/13] mm, notifier: Add a lockdep map for invalidate_range_start Daniel Vetter
2018-11-07 15:30 ` [PATCH 08/13] dma-fence: cross-release annotations Daniel Vetter
2018-11-07 15:30 ` [PATCH 09/13] reservation: Annotate dma_fence waits Daniel Vetter
2018-11-07 15:30 ` [PATCH 10/13] drm/i915: " Daniel Vetter
2018-11-07 15:30 ` [PATCH 11/13] drm/i915: annotate intel_atomic_commit_fence_wait Daniel Vetter
2018-11-07 15:30 ` [PATCH 12/13] HAX FOR CI: Enable cross-release Daniel Vetter
2018-11-08  9:31   ` [PATCH] " Daniel Vetter
2018-11-08  9:41     ` Chris Wilson
2018-11-20 11:00       ` Daniel Vetter
2018-11-20 10:58     ` Daniel Vetter
2018-11-22 16:35       ` Daniel Vetter
2018-11-23  8:53         ` Daniel Vetter [this message]
2018-11-23 12:45           ` Daniel Vetter
2018-11-23 13:24             ` Daniel Vetter
2018-11-07 15:30 ` [PATCH 13/13] Revert "locking/lockdep, cpu/hotplug: Annotate AP thread" Daniel Vetter
2018-11-07 16:51 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/13] locking/lockdep: restore cross-release checks Patchwork
2018-11-07 16:57 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-11-07 17:07 ` ✗ Fi.CI.BAT: failure " Patchwork
2018-11-08 10:04 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/13] locking/lockdep: restore cross-release checks (rev2) Patchwork
2018-11-08 10:10 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-11-08 10:21 ` ✗ Fi.CI.BAT: failure " Patchwork
2018-11-20 12:33 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/13] locking/lockdep: restore cross-release checks (rev3) Patchwork
2018-11-20 12:39 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-11-20 12:53 ` ✗ Fi.CI.BAT: failure " Patchwork
2018-11-22 16:39 ` ✗ Fi.CI.BAT: failure for series starting with [01/13] locking/lockdep: restore cross-release checks (rev4) Patchwork
2018-11-23  8:57 ` ✗ Fi.CI.BAT: failure for series starting with [01/13] locking/lockdep: restore cross-release checks (rev5) Patchwork
2018-11-23 12:51 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/13] locking/lockdep: restore cross-release checks (rev6) Patchwork
2018-11-23 12:57 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-11-23 13:08 ` ✗ Fi.CI.BAT: failure " Patchwork
2018-11-23 13:55 ` ✗ Fi.CI.CHECKPATCH: warning for series starting with [01/13] locking/lockdep: restore cross-release checks (rev7) Patchwork
2018-11-23 14:01 ` ✗ Fi.CI.SPARSE: " Patchwork
2018-11-23 14:12 ` ✗ Fi.CI.BAT: failure " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181123085307.13304-1-daniel.vetter@ffwll.ch \
    --to=daniel.vetter@ffwll.ch \
    --cc=daniel.vetter@intel.com \
    --cc=intel-gfx@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox