drm/i915: Print the condition causing GEM_BUG_ON
Subsystems (2)
It is easier to categorize and debug bugs if the failed condition is in plain sight in the actual dmesg output. Make it so.
--- drivers/gpu/drm/i915/i915_gem.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/i915_gem.h +5 -1
@@ -28,7 +28,11 @@#include <linux/bug.h> #ifdef CONFIG_DRM_I915_DEBUG_GEM -#define GEM_BUG_ON (expr) BUG_ON(expr) +#define GEM_BUG_ON (condition) do { if (unlikely((condition))) { \ + printk(KERN_ERR "GEM_BUG_ON(%s)\n", __stringify(condition)); \ + BUG(); \ + } \ + } while(0)#define GEM_WARN_ON (expr) WARN_ON(expr)#define GEM_DEBUG_DECL (var) var
Signature · 6 lines
2.11.0 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Lofstedt, Marta
Reviewed-byI like this, because I would not need to check the actual code when we get BUG() backtraces for CI.
Quoted 40 lines
-----Original Message-----
From: Mika Kuoppala [mailto:[email protected]]
Sent: Thursday, November 16, 2017 10:40 AM
To: [email protected]
Cc: Mika Kuoppala <[email protected]>; Chris Wilson <[email protected]>; Joonas Lahtinen <[email protected]>; Lofstedt, Marta <[email protected]>
Subject: [CI] drm/i915: Print the condition causingGEM_BUG_ONIt is easier to categorize and debug bugs if the failed condition is in plain sight in the actual dmesg output. Make it so.
Cc Chris Wilson <[email protected]>Cc Joonas Lahtinen <[email protected]>Cc Marta Lofstedt <[email protected]>Signed-off-by Mika Kuoppala <[email protected]>Reviewed-by Joonas Lahtinen <[email protected]>--- drivers/gpu/drm/i915/i915_gem.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-)(quoted diff) +0
-0
b/drivers/gpu/drm/i915/i915_gem.hindexff42b5f0e981..e920dab7f1b8100644drivers/gpu/drm/i915/i915_gem.h +5
-1@@ -28,7 +28,11 @@#include <linux/bug.h> #ifdef CONFIG_DRM_I915_DEBUG_GEM -#define GEM_BUG_ON (expr) BUG_ON(expr) +#define GEM_BUG_ON (condition) do { if (unlikely((condition))) { \ + printk(KERN_ERR "GEM_BUG_ON(%s)\n", __stringify(condition)); \ +BUG (); \ + } \ + } while(0)#define GEM_WARN_ON (expr) WARN_ON(expr)
Quoted 3 lines
#define
GEM_DEBUG_DECL(var)var
--
2.11.0
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Patchwork
CI✓ Fi.CI.BAT: success for drm/i915: Print the condition causing GEM_BUG_ON (rev3)
In reply to Mika Kuoppala== Series Details ==
== Series Details ==
Series: drm/i915: Print the condition causing GEM_BUG_ON (rev3)
URL : https://patchwork.freedesktop.org/series/32050/
State : success
== Summary ==
Series 32050v3 drm/i915: Print the condition causing GEM_BUG_ON
https://patchwork.freedesktop.org/api/1.0/series/32050/revisions/3/mbox/
Test kms_pipe_crc_basic:
Subgroup suspend-read-crc-pipe-b:
incomplete -> PASS (fi-snb-2520m) fdo#103713fdo#103713 https://bugs.freedesktop.org/show_bug.cgi?id=103713
fi-bdw-5557u total:289 pass:268 dwarn:0 dfail:0 fail:0 skip:21 time:449s fi-bdw-gvtdvm total:289 pass:265 dwarn:0 dfail:0 fail:0 skip:24 time:463s fi-blb-e6850 total:289 pass:223 dwarn:1 dfail:0 fail:0 skip:65 time:389s fi-bsw-n3050 total:289 pass:243 dwarn:0 dfail:0 fail:0 skip:46 time:540s fi-bwr-2160 total:289 pass:183 dwarn:0 dfail:0 fail:0 skip:106 time:281s fi-bxt-dsi total:289 pass:259 dwarn:0 dfail:0 fail:0 skip:30 time:503s fi-bxt-j4205 total:289 pass:260 dwarn:0 dfail:0 fail:0 skip:29 time:512s fi-byt-j1900 total:289 pass:254 dwarn:0 dfail:0 fail:0 skip:35 time:502s fi-byt-n2820 total:289 pass:250 dwarn:0 dfail:0 fail:0 skip:39 time:496s fi-elk-e7500 total:289 pass:229 dwarn:0 dfail:0 fail:0 skip:60 time:428s fi-gdg-551 total:289 pass:178 dwarn:1 dfail:0 fail:1 skip:109 time:268s fi-glk-1 total:289 pass:261 dwarn:0 dfail:0 fail:0 skip:28 time:541s fi-hsw-4770 total:289 pass:262 dwarn:0 dfail:0 fail:0 skip:27 time:432s fi-hsw-4770r total:289 pass:262 dwarn:0 dfail:0 fail:0 skip:27 time:439s fi-ilk-650 total:289 pass:228 dwarn:0 dfail:0 fail:0 skip:61 time:430s fi-ivb-3520m total:289 pass:260 dwarn:0 dfail:0 fail:0 skip:29 time:488s fi-ivb-3770 total:289 pass:260 dwarn:0 dfail:0 fail:0 skip:29 time:465s fi-kbl-7500u total:289 pass:264 dwarn:1 dfail:0 fail:0 skip:24 time:485s fi-kbl-7560u total:289 pass:270 dwarn:0 dfail:0 fail:0 skip:19 time:534s fi-kbl-7567u total:289 pass:269 dwarn:0 dfail:0 fail:0 skip:20 time:479s fi-kbl-r total:289 pass:262 dwarn:0 dfail:0 fail:0 skip:27 time:533s fi-pnv-d510 total:289 pass:222 dwarn:1 dfail:0 fail:0 skip:66 time:578s fi-skl-6260u total:289 pass:269 dwarn:0 dfail:0 fail:0 skip:20 time:466s fi-skl-6600u total:289 pass:262 dwarn:0 dfail:0 fail:0 skip:27 time:546s fi-skl-6700hq total:289 pass:263 dwarn:0 dfail:0 fail:0 skip:26 time:564s fi-skl-6700k total:289 pass:265 dwarn:0 dfail:0 fail:0 skip:24 time:518s fi-skl-6770hq total:289 pass:269 dwarn:0 dfail:0 fail:0 skip:20 time:496s fi-skl-gvtdvm total:289 pass:266 dwarn:0 dfail:0 fail:0 skip:23 time:466s fi-snb-2520m total:289 pass:250 dwarn:0 dfail:0 fail:0 skip:39 time:563s fi-snb-2600 total:289 pass:249 dwarn:0 dfail:0 fail:0 skip:40 time:426s
Blacklisted hosts:
fi-cfl-s total:289 pass:254 dwarn:3 dfail:0 fail:0 skip:32 time:525s
7916df8b49cb8bb9783a8425e7345cc47159f3f0 drm-tip: 2017y-11m-15d-20h-05m-48s UTC integration manifest e36f5d2f27df drm/i915: Print the condition causing GEM_BUG_ON
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_7153/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Patchwork
CI✓ Fi.CI.IGT: success for drm/i915: Print the condition causing GEM_BUG_ON (rev3)
In reply to Mika Kuoppala== Series Details ==
== Series Details ==
Series: drm/i915: Print the condition causing GEM_BUG_ON (rev3)
URL : https://patchwork.freedesktop.org/series/32050/
State : success
== Summary ==
Test kms_plane:
Subgroup plane-panning-bottom-right-suspend-pipe-c-planes:
fail -> PASS (shard-hsw) fdo#103375
Test kms_setmode:
Subgroup basic:
pass -> FAIL (shard-hsw) fdo#99912
Test drv_selftest:
Subgroup mock_sanitycheck:
pass -> DMESG-WARN (shard-hsw) fdo#103719
Test kms_flip:
Subgroup rcs-wf_vblank-vs-dpms-interruptible:
dmesg-warn -> PASS (shard-hsw) fdo#102614
Test drv_module_reload:
Subgroup basic-reload-inject:
dmesg-warn -> PASS (shard-hsw) fdo#102707
Test kms_frontbuffer_tracking:
Subgroup fbc-1p-offscren-pri-indfb-draw-mmap-wc:
skip -> PASS (shard-hsw)
Test kms_chv_cursor_fail:
Subgroup pipe-a-256x256-bottom-edge:
skip -> PASS (shard-hsw)
Subgroup pipe-c-128x128-bottom-edge:
skip -> PASS (shard-hsw)
Test kms_cursor_legacy:
Subgroup flip-vs-cursor-toggle:
skip -> PASS (shard-hsw) fdo#102670
Test kms_vblank:
Subgroup wait-busy:
skip -> PASS (shard-hsw)
Test kms_concurrent:
Subgroup pipe-c:
skip -> PASS (shard-hsw)
Test pm_rpm:
Subgroup gem-mmap-cpu:
skip -> PASS (shard-hsw)fdo#103375 https://bugs.freedesktop.org/show_bug.cgi?id=103375
fdo#99912 https://bugs.freedesktop.org/show_bug.cgi?id=99912
fdo#103719 https://bugs.freedesktop.org/show_bug.cgi?id=103719
fdo#102614 https://bugs.freedesktop.org/show_bug.cgi?id=102614
fdo#102707 https://bugs.freedesktop.org/show_bug.cgi?id=102707
fdo#102670 https://bugs.freedesktop.org/show_bug.cgi?id=102670
shard-hsw total:2584 pass:1469 dwarn:5 dfail:1 fail:10 skip:1099 time:9526s
Blacklisted hosts:
shard-apl total:2584 pass:1622 dwarn:2 dfail:2 fail:22 skip:936 time:13405s shard-kbl total:2565 pass:1674 dwarn:30 dfail:2 fail:25 skip:833 time:10783s shard-snb total:2584 pass:1257 dwarn:2 dfail:1 fail:12 skip:1312 time:8055s
== Logs ==
For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_7153/shards.html
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx