* [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS
@ 2018-02-26 13:53 Chris Wilson
2018-02-26 13:59 ` Lofstedt, Marta
2018-02-26 14:19 ` ✗ Fi.CI.BAT: failure for " Patchwork
0 siblings, 2 replies; 9+ messages in thread
From: Chris Wilson @ 2018-02-26 13:53 UTC (permalink / raw)
To: intel-gfx
For large oops dump, for example if ftrace is included, we can easily
exceed the storage buffer and lose the most important bit of
information: where the OOPS occurred. So repeat the location information
just before the end marker.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Marta Lofstedt <marta.lofstedt@intel.com>
---
kernel/panic.c | 22 +++++++++++++++-------
1 file changed, 15 insertions(+), 7 deletions(-)
diff --git a/kernel/panic.c b/kernel/panic.c
index 2cfef408fec9..51914dcd1ab8 100644
--- a/kernel/panic.c
+++ b/kernel/panic.c
@@ -517,14 +517,9 @@ struct warn_args {
va_list args;
};
-void __warn(const char *file, int line, void *caller, unsigned taint,
- struct pt_regs *regs, struct warn_args *args)
+static void print_location(const char *file, int line, void *caller,
+ struct warn_args *args)
{
- disable_trace_on_warning();
-
- if (args)
- pr_warn(CUT_HERE);
-
if (file)
pr_warn("WARNING: CPU: %d PID: %d at %s:%d %pS\n",
raw_smp_processor_id(), current->pid, file, line,
@@ -535,6 +530,17 @@ void __warn(const char *file, int line, void *caller, unsigned taint,
if (args)
vprintk(args->fmt, args->args);
+}
+
+void __warn(const char *file, int line, void *caller, unsigned taint,
+ struct pt_regs *regs, struct warn_args *args)
+{
+ disable_trace_on_warning();
+
+ if (args)
+ pr_warn(CUT_HERE);
+
+ show_location(file, line, caller, args);
if (panic_on_warn) {
/*
@@ -554,6 +560,8 @@ void __warn(const char *file, int line, void *caller, unsigned taint,
else
dump_stack();
+ show_location(file, line, caller, args);
+
print_oops_end_marker();
/* Just a warning, don't kill lockdep. */
--
2.16.2
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS
2018-02-26 13:53 [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS Chris Wilson
@ 2018-02-26 13:59 ` Lofstedt, Marta
2018-02-26 14:19 ` ✗ Fi.CI.BAT: failure for " Patchwork
1 sibling, 0 replies; 9+ messages in thread
From: Lofstedt, Marta @ 2018-02-26 13:59 UTC (permalink / raw)
To: Chris Wilson, intel-gfx; +Cc: Kuoppala, Mika
Seems like a good idea to me.
+Mika
> -----Original Message-----
> From: Chris Wilson [mailto:chris@chris-wilson.co.uk]
> Sent: Monday, February 26, 2018 3:53 PM
> To: intel-gfx@lists.freedesktop.org
> Cc: Chris Wilson <chris@chris-wilson.co.uk>; Lofstedt, Marta
> <marta.lofstedt@intel.com>
> Subject: [RFC] kernel/panic: Repeat the line and caller information at the end
> of the OOPS
>
> For large oops dump, for example if ftrace is included, we can easily exceed
> the storage buffer and lose the most important bit of
> information: where the OOPS occurred. So repeat the location information
> just before the end marker.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Marta Lofstedt <marta.lofstedt@intel.com>
> ---
> kernel/panic.c | 22 +++++++++++++++-------
> 1 file changed, 15 insertions(+), 7 deletions(-)
>
> diff --git a/kernel/panic.c b/kernel/panic.c index 2cfef408fec9..51914dcd1ab8
> 100644
> --- a/kernel/panic.c
> +++ b/kernel/panic.c
> @@ -517,14 +517,9 @@ struct warn_args {
> va_list args;
> };
>
> -void __warn(const char *file, int line, void *caller, unsigned taint,
> - struct pt_regs *regs, struct warn_args *args)
> +static void print_location(const char *file, int line, void *caller,
> + struct warn_args *args)
> {
> - disable_trace_on_warning();
> -
> - if (args)
> - pr_warn(CUT_HERE);
> -
> if (file)
> pr_warn("WARNING: CPU: %d PID: %d at %s:%d
> %pS\n",
> raw_smp_processor_id(),
> current->pid, file, line, @@ -535,6 +530,17 @@ void __warn(const char *file,
> int line, void *caller, unsigned taint,
>
> if (args)
> vprintk(args->fmt, args->args);
> +}
> +
> +void __warn(const char *file, int line, void *caller, unsigned taint,
> + struct pt_regs *regs, struct warn_args *args) {
> + disable_trace_on_warning();
> +
> + if (args)
> + pr_warn(CUT_HERE);
> +
> + show_location(file, line, caller, args);
>
> if (panic_on_warn) {
> /*
> @@ -554,6 +560,8 @@ void __warn(const char *file, int line, void *caller,
> unsigned taint,
> else
> dump_stack();
>
> + show_location(file, line, caller, args);
> +
> print_oops_end_marker();
>
> /* Just a warning, don't kill lockdep. */
> --
> 2.16.2
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* ✗ Fi.CI.BAT: failure for kernel/panic: Repeat the line and caller information at the end of the OOPS
2018-02-26 13:53 [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS Chris Wilson
2018-02-26 13:59 ` Lofstedt, Marta
@ 2018-02-26 14:19 ` Patchwork
2018-02-26 14:29 ` [RFC] " Chris Wilson
` (2 more replies)
1 sibling, 3 replies; 9+ messages in thread
From: Patchwork @ 2018-02-26 14:19 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: kernel/panic: Repeat the line and caller information at the end of the OOPS
URL : https://patchwork.freedesktop.org/series/38962/
State : failure
== Summary ==
CHK include/config/kernel.release
CHK include/generated/uapi/linux/version.h
CHK include/generated/utsrelease.h
CHK include/generated/bounds.h
CHK include/generated/timeconst.h
CHK include/generated/asm-offsets.h
CALL scripts/checksyscalls.sh
DESCEND objtool
CHK scripts/mod/devicetable-offsets.h
CHK include/generated/compile.h
CC kernel/panic.o
kernel/panic.c: In function ‘__warn’:
kernel/panic.c:543:2: error: implicit declaration of function ‘show_location’ [-Werror=implicit-function-declaration]
show_location(file, line, caller, args);
^~~~~~~~~~~~~
At top level:
kernel/panic.c:520:13: warning: ‘print_location’ defined but not used [-Wunused-function]
static void print_location(const char *file, int line, void *caller,
^~~~~~~~~~~~~~
cc1: some warnings being treated as errors
scripts/Makefile.build:316: recipe for target 'kernel/panic.o' failed
make[1]: *** [kernel/panic.o] Error 1
Makefile:1048: recipe for target 'kernel' failed
make: *** [kernel] Error 2
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS
2018-02-26 14:19 ` ✗ Fi.CI.BAT: failure for " Patchwork
@ 2018-02-26 14:29 ` Chris Wilson
2018-02-27 10:50 ` Chris Wilson
2018-02-26 14:57 ` ✓ Fi.CI.BAT: success for kernel/panic: Repeat the line and caller information at the end of the OOPS (rev2) Patchwork
2018-02-26 18:15 ` ✓ Fi.CI.IGT: " Patchwork
2 siblings, 1 reply; 9+ messages in thread
From: Chris Wilson @ 2018-02-26 14:29 UTC (permalink / raw)
To: intel-gfx
For large oops dump, for example if ftrace is included, we can easily
exceed the storage buffer and lose the most important bit of
information: where the OOPS occurred. So repeat the location information
just before the end marker.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Marta Lofstedt <marta.lofstedt@intel.com>
---
git add ftw
-Chris
---
kernel/panic.c | 22 +++++++++++++++-------
1 file changed, 15 insertions(+), 7 deletions(-)
diff --git a/kernel/panic.c b/kernel/panic.c
index 2cfef408fec9..9049168d9445 100644
--- a/kernel/panic.c
+++ b/kernel/panic.c
@@ -517,14 +517,9 @@ struct warn_args {
va_list args;
};
-void __warn(const char *file, int line, void *caller, unsigned taint,
- struct pt_regs *regs, struct warn_args *args)
+static void show_location(const char *file, int line, void *caller,
+ struct warn_args *args)
{
- disable_trace_on_warning();
-
- if (args)
- pr_warn(CUT_HERE);
-
if (file)
pr_warn("WARNING: CPU: %d PID: %d at %s:%d %pS\n",
raw_smp_processor_id(), current->pid, file, line,
@@ -535,6 +530,17 @@ void __warn(const char *file, int line, void *caller, unsigned taint,
if (args)
vprintk(args->fmt, args->args);
+}
+
+void __warn(const char *file, int line, void *caller, unsigned taint,
+ struct pt_regs *regs, struct warn_args *args)
+{
+ disable_trace_on_warning();
+
+ if (args)
+ pr_warn(CUT_HERE);
+
+ show_location(file, line, caller, args);
if (panic_on_warn) {
/*
@@ -554,6 +560,8 @@ void __warn(const char *file, int line, void *caller, unsigned taint,
else
dump_stack();
+ show_location(file, line, caller, args);
+
print_oops_end_marker();
/* Just a warning, don't kill lockdep. */
--
2.16.2
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 9+ messages in thread
* ✓ Fi.CI.BAT: success for kernel/panic: Repeat the line and caller information at the end of the OOPS (rev2)
2018-02-26 14:19 ` ✗ Fi.CI.BAT: failure for " Patchwork
2018-02-26 14:29 ` [RFC] " Chris Wilson
@ 2018-02-26 14:57 ` Patchwork
2018-02-26 18:15 ` ✓ Fi.CI.IGT: " Patchwork
2 siblings, 0 replies; 9+ messages in thread
From: Patchwork @ 2018-02-26 14:57 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: kernel/panic: Repeat the line and caller information at the end of the OOPS (rev2)
URL : https://patchwork.freedesktop.org/series/38962/
State : success
== Summary ==
Series 38962v2 kernel/panic: Repeat the line and caller information at the end of the OOPS
https://patchwork.freedesktop.org/api/1.0/series/38962/revisions/2/mbox/
---- Known issues:
Test debugfs_test:
Subgroup read_all_entries:
incomplete -> PASS (fi-snb-2520m) fdo#103713
fdo#103713 https://bugs.freedesktop.org/show_bug.cgi?id=103713
fi-bdw-5557u total:288 pass:267 dwarn:0 dfail:0 fail:0 skip:21 time:419s
fi-bdw-gvtdvm total:288 pass:264 dwarn:0 dfail:0 fail:0 skip:24 time:425s
fi-blb-e6850 total:288 pass:223 dwarn:1 dfail:0 fail:0 skip:64 time:374s
fi-bsw-n3050 total:288 pass:242 dwarn:0 dfail:0 fail:0 skip:46 time:482s
fi-bwr-2160 total:288 pass:183 dwarn:0 dfail:0 fail:0 skip:105 time:283s
fi-bxt-dsi total:288 pass:258 dwarn:0 dfail:0 fail:0 skip:30 time:477s
fi-bxt-j4205 total:288 pass:259 dwarn:0 dfail:0 fail:0 skip:29 time:479s
fi-byt-j1900 total:288 pass:253 dwarn:0 dfail:0 fail:0 skip:35 time:463s
fi-byt-n2820 total:288 pass:249 dwarn:0 dfail:0 fail:0 skip:39 time:453s
fi-cfl-8700k total:288 pass:260 dwarn:0 dfail:0 fail:0 skip:28 time:392s
fi-cfl-s2 total:288 pass:262 dwarn:0 dfail:0 fail:0 skip:26 time:568s
fi-elk-e7500 total:288 pass:229 dwarn:0 dfail:0 fail:0 skip:59 time:408s
fi-gdg-551 total:288 pass:179 dwarn:0 dfail:0 fail:1 skip:108 time:282s
fi-glk-1 total:288 pass:260 dwarn:0 dfail:0 fail:0 skip:28 time:505s
fi-hsw-4770 total:288 pass:261 dwarn:0 dfail:0 fail:0 skip:27 time:385s
fi-ilk-650 total:288 pass:228 dwarn:0 dfail:0 fail:0 skip:60 time:408s
fi-ivb-3520m total:288 pass:259 dwarn:0 dfail:0 fail:0 skip:29 time:452s
fi-kbl-7500u total:288 pass:263 dwarn:1 dfail:0 fail:0 skip:24 time:452s
fi-kbl-7560u total:288 pass:269 dwarn:0 dfail:0 fail:0 skip:19 time:485s
fi-kbl-7567u total:288 pass:268 dwarn:0 dfail:0 fail:0 skip:20 time:449s
fi-kbl-r total:288 pass:261 dwarn:0 dfail:0 fail:0 skip:27 time:493s
fi-pnv-d510 total:288 pass:222 dwarn:1 dfail:0 fail:0 skip:65 time:584s
fi-skl-6260u total:288 pass:268 dwarn:0 dfail:0 fail:0 skip:20 time:422s
fi-skl-6600u total:288 pass:261 dwarn:0 dfail:0 fail:0 skip:27 time:502s
fi-skl-6700hq total:288 pass:262 dwarn:0 dfail:0 fail:0 skip:26 time:515s
fi-skl-6700k2 total:288 pass:264 dwarn:0 dfail:0 fail:0 skip:24 time:488s
fi-skl-6770hq total:288 pass:268 dwarn:0 dfail:0 fail:0 skip:20 time:473s
fi-skl-guc total:288 pass:260 dwarn:0 dfail:0 fail:0 skip:28 time:405s
fi-skl-gvtdvm total:288 pass:265 dwarn:0 dfail:0 fail:0 skip:23 time:432s
fi-snb-2520m total:288 pass:248 dwarn:0 dfail:0 fail:0 skip:40 time:513s
fi-snb-2600 total:288 pass:248 dwarn:0 dfail:0 fail:0 skip:40 time:402s
23012f548f1fe658192a8e43ad5af139b726676e drm-tip: 2018y-02m-26d-10h-58m-50s UTC integration manifest
360f92f614fa kernel/panic: Repeat the line and caller information at the end of the OOPS
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_8156/issues.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* ✓ Fi.CI.IGT: success for kernel/panic: Repeat the line and caller information at the end of the OOPS (rev2)
2018-02-26 14:19 ` ✗ Fi.CI.BAT: failure for " Patchwork
2018-02-26 14:29 ` [RFC] " Chris Wilson
2018-02-26 14:57 ` ✓ Fi.CI.BAT: success for kernel/panic: Repeat the line and caller information at the end of the OOPS (rev2) Patchwork
@ 2018-02-26 18:15 ` Patchwork
2 siblings, 0 replies; 9+ messages in thread
From: Patchwork @ 2018-02-26 18:15 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: kernel/panic: Repeat the line and caller information at the end of the OOPS (rev2)
URL : https://patchwork.freedesktop.org/series/38962/
State : success
== Summary ==
---- Possible new issues:
Test pm_rc6_residency:
Subgroup rc6-accuracy:
skip -> PASS (shard-snb)
---- Known issues:
Test kms_flip:
Subgroup 2x-flip-vs-wf_vblank-interruptible:
fail -> PASS (shard-hsw) fdo#100368 +1
Subgroup flip-vs-panning-vs-hang:
pass -> DMESG-WARN (shard-snb) fdo#103821
Test perf:
Subgroup buffer-fill:
pass -> FAIL (shard-apl) fdo#103755
fdo#100368 https://bugs.freedesktop.org/show_bug.cgi?id=100368
fdo#103821 https://bugs.freedesktop.org/show_bug.cgi?id=103821
fdo#103755 https://bugs.freedesktop.org/show_bug.cgi?id=103755
shard-apl total:3460 pass:1819 dwarn:1 dfail:0 fail:8 skip:1632 time:12115s
shard-hsw total:3460 pass:1767 dwarn:1 dfail:0 fail:1 skip:1690 time:11779s
shard-snb total:3460 pass:1359 dwarn:2 dfail:0 fail:1 skip:2098 time:6641s
Blacklisted hosts:
shard-kbl total:3393 pass:1909 dwarn:1 dfail:0 fail:7 skip:1475 time:9037s
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_8156/shards.html
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS
2018-02-26 14:29 ` [RFC] " Chris Wilson
@ 2018-02-27 10:50 ` Chris Wilson
2018-02-27 11:12 ` Lofstedt, Marta
0 siblings, 1 reply; 9+ messages in thread
From: Chris Wilson @ 2018-02-27 10:50 UTC (permalink / raw)
To: intel-gfx
Quoting Chris Wilson (2018-02-26 14:29:56)
> For large oops dump, for example if ftrace is included, we can easily
> exceed the storage buffer and lose the most important bit of
> information: where the OOPS occurred. So repeat the location information
> just before the end marker.
>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> Cc: Marta Lofstedt <marta.lofstedt@intel.com>
I've plonked this in topic/core-for-CI to see if it is effective in
helping us nail a few bugs.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS
2018-02-27 10:50 ` Chris Wilson
@ 2018-02-27 11:12 ` Lofstedt, Marta
2018-02-27 20:57 ` Chris Wilson
0 siblings, 1 reply; 9+ messages in thread
From: Lofstedt, Marta @ 2018-02-27 11:12 UTC (permalink / raw)
To: Chris Wilson, intel-gfx
OK cool I'll look out for it landing, CI_DRM_3838 or CI_DRM_3839 I guess.
> -----Original Message-----
> From: Chris Wilson [mailto:chris@chris-wilson.co.uk]
> Sent: Tuesday, February 27, 2018 12:50 PM
> To: intel-gfx@lists.freedesktop.org
> Cc: Lofstedt, Marta <marta.lofstedt@intel.com>
> Subject: Re: [RFC] kernel/panic: Repeat the line and caller information at the
> end of the OOPS
>
> Quoting Chris Wilson (2018-02-26 14:29:56)
> > For large oops dump, for example if ftrace is included, we can easily
> > exceed the storage buffer and lose the most important bit of
> > information: where the OOPS occurred. So repeat the location
> > information just before the end marker.
> >
> > Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> > Cc: Marta Lofstedt <marta.lofstedt@intel.com>
>
> I've plonked this in topic/core-for-CI to see if it is effective in helping us nail a
> few bugs.
> -Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS
2018-02-27 11:12 ` Lofstedt, Marta
@ 2018-02-27 20:57 ` Chris Wilson
0 siblings, 0 replies; 9+ messages in thread
From: Chris Wilson @ 2018-02-27 20:57 UTC (permalink / raw)
To: Lofstedt, Marta, intel-gfx
Quoting Lofstedt, Marta (2018-02-27 11:12:52)
> OK cool I'll look out for it landing, CI_DRM_3838 or CI_DRM_3839 I guess.
Bah, wrong path. This is only called to handle WARN() and we need the
extra information in BUG(). In fact, the information we need is in a raw
printk and not given to WARN, so we'll have to try a different tack.
-Chris
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2018-02-27 20:57 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-02-26 13:53 [RFC] kernel/panic: Repeat the line and caller information at the end of the OOPS Chris Wilson
2018-02-26 13:59 ` Lofstedt, Marta
2018-02-26 14:19 ` ✗ Fi.CI.BAT: failure for " Patchwork
2018-02-26 14:29 ` [RFC] " Chris Wilson
2018-02-27 10:50 ` Chris Wilson
2018-02-27 11:12 ` Lofstedt, Marta
2018-02-27 20:57 ` Chris Wilson
2018-02-26 14:57 ` ✓ Fi.CI.BAT: success for kernel/panic: Repeat the line and caller information at the end of the OOPS (rev2) Patchwork
2018-02-26 18:15 ` ✓ Fi.CI.IGT: " Patchwork
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.