* [CI 1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer
@ 2016-04-03 13:14 Chris Wilson
2016-04-03 13:14 ` [CI 2/2] drm/i915: Show PCI power state under debugfs/i915_runtime_pm_status Chris Wilson
2016-04-03 13:59 ` ✓ Fi.CI.BAT: success for series starting with [CI,1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer Patchwork
0 siblings, 2 replies; 3+ messages in thread
From: Chris Wilson @ 2016-04-03 13:14 UTC (permalink / raw)
To: intel-gfx
Since describe_obj() looks at state guarded by the struct_mutex, we need
to be holding it.
[ 580.201054] drv_suspend: starting subtest debugfs-reader
[ 580.239652] ------------[ cut here ]------------
[ 580.239696] WARNING: CPU: 0 PID: 920 at include/linux/list_check.h:25 describe_obj+0x419/0x440()
[ 580.239725] CPU: 0 PID: 920 Comm: cat Not tainted 4.5.0-rc6+ #835
[ 580.239745] Hardware name: /NUC5CPYB, BIOS PYBSWCEL.86A.0027.2015.0507.1758 05/07/2015
[ 580.239767] 0000000000000000 ffff88027554fcf8 ffffffff812c1135 0000000000000000
[ 580.239815] ffffffff8193dc42 ffff88027554fd30 ffffffff8107419d ffff880071727c00
[ 580.239858] ffff8802757d8000 ffffffff818f693c ffffffff818f693c ffff8802757b9048
[ 580.239896] Call Trace:
[ 580.239917] [<ffffffff812c1135>] dump_stack+0x67/0x92
[ 580.239939] [<ffffffff8107419d>] warn_slowpath_common+0x7d/0xb0
[ 580.239959] [<ffffffff810742ba>] warn_slowpath_null+0x1a/0x20
[ 580.239981] [<ffffffff813ce579>] describe_obj+0x419/0x440
[ 580.240006] [<ffffffff813ced22>] i915_gem_framebuffer_info+0xa2/0x100
[ 580.240033] [<ffffffff811a9286>] seq_read+0xe6/0x3b0
[ 580.240059] [<ffffffff81182288>] __vfs_read+0x28/0xd0
[ 580.240085] [<ffffffff81173378>] ? SyS_fadvise64+0x228/0x2c0
[ 580.240112] [<ffffffff811823b2>] vfs_read+0x82/0x110
[ 580.240137] [<ffffffff811827d9>] SyS_read+0x49/0xa0
[ 580.240162] [<ffffffff815bac57>] entry_SYSCALL_64_fastpath+0x12/0x6b
[ 580.240187] ---[ end trace 3e2cbf34576c9878 ]---
[ 580.281900] ------------[ cut here ]------------
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
drivers/gpu/drm/i915/i915_debugfs.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index 74f227415765..6b384d7738f1 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -134,6 +134,8 @@ describe_obj(struct seq_file *m, struct drm_i915_gem_object *obj)
int pin_count = 0;
enum intel_engine_id id;
+ lockdep_assert_held(&obj->base.dev->struct_mutex);
+
seq_printf(m, "%pK: %s%s%s%s %8zdKiB %02x %02x [ ",
&obj->base,
obj->active ? "*" : " ",
@@ -1894,6 +1896,11 @@ static int i915_gem_framebuffer_info(struct seq_file *m, void *data)
struct drm_device *dev = node->minor->dev;
struct intel_framebuffer *fbdev_fb = NULL;
struct drm_framebuffer *drm_fb;
+ int ret;
+
+ ret = mutex_lock_interruptible(&dev->struct_mutex);
+ if (ret)
+ return ret;
#ifdef CONFIG_DRM_FBDEV_EMULATION
if (to_i915(dev)->fbdev) {
@@ -1928,6 +1935,7 @@ static int i915_gem_framebuffer_info(struct seq_file *m, void *data)
seq_putc(m, '\n');
}
mutex_unlock(&dev->mode_config.fb_lock);
+ mutex_unlock(&dev->struct_mutex);
return 0;
}
--
2.8.0.rc3
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [CI 2/2] drm/i915: Show PCI power state under debugfs/i915_runtime_pm_status
2016-04-03 13:14 [CI 1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer Chris Wilson
@ 2016-04-03 13:14 ` Chris Wilson
2016-04-03 13:59 ` ✓ Fi.CI.BAT: success for series starting with [CI,1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer Patchwork
1 sibling, 0 replies; 3+ messages in thread
From: Chris Wilson @ 2016-04-03 13:14 UTC (permalink / raw)
To: intel-gfx
As the current PCI power state is an essential feature of runtime pm,
include it in the debugfs/i915_runtime_pm_status.
v2: Use pci_power_name()
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Imre Deak <imre.deak@intel.com>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
---
drivers/gpu/drm/i915/i915_debugfs.c | 9 +++++----
1 file changed, 5 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c
index 6b384d7738f1..0b25228c202e 100644
--- a/drivers/gpu/drm/i915/i915_debugfs.c
+++ b/drivers/gpu/drm/i915/i915_debugfs.c
@@ -2694,10 +2694,8 @@ static int i915_runtime_pm_status(struct seq_file *m, void *unused)
struct drm_device *dev = node->minor->dev;
struct drm_i915_private *dev_priv = dev->dev_private;
- if (!HAS_RUNTIME_PM(dev)) {
- seq_puts(m, "not supported\n");
- return 0;
- }
+ if (!HAS_RUNTIME_PM(dev_priv))
+ seq_puts(m, "Runtime power management not supported\n");
seq_printf(m, "GPU idle: %s\n", yesno(!dev_priv->mm.busy));
seq_printf(m, "IRQs disabled: %s\n",
@@ -2708,6 +2706,9 @@ static int i915_runtime_pm_status(struct seq_file *m, void *unused)
#else
seq_printf(m, "Device Power Management (CONFIG_PM) disabled\n");
#endif
+ seq_printf(m, "PCI device power state: %s [%d]\n",
+ pci_power_name(dev_priv->dev->pdev->current_state),
+ dev_priv->dev->pdev->current_state);
return 0;
}
--
2.8.0.rc3
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply related [flat|nested] 3+ messages in thread
* ✓ Fi.CI.BAT: success for series starting with [CI,1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer
2016-04-03 13:14 [CI 1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer Chris Wilson
2016-04-03 13:14 ` [CI 2/2] drm/i915: Show PCI power state under debugfs/i915_runtime_pm_status Chris Wilson
@ 2016-04-03 13:59 ` Patchwork
1 sibling, 0 replies; 3+ messages in thread
From: Patchwork @ 2016-04-03 13:59 UTC (permalink / raw)
To: Chris Wilson; +Cc: intel-gfx
== Series Details ==
Series: series starting with [CI,1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer
URL : https://patchwork.freedesktop.org/series/5235/
State : success
== Summary ==
Series 5235v1 Series without cover letter
http://patchwork.freedesktop.org/api/1.0/series/5235/revisions/1/mbox/
Test kms_flip:
Subgroup basic-flip-vs-wf_vblank:
fail -> PASS (snb-x220t)
fail -> PASS (ilk-hp8440p) UNSTABLE
Test kms_force_connector_basic:
Subgroup force-connector-state:
pass -> SKIP (ivb-t430s)
Subgroup force-edid:
pass -> SKIP (ivb-t430s)
bdw-nuci7 total:196 pass:184 dwarn:0 dfail:0 fail:0 skip:12
bdw-ultra total:196 pass:175 dwarn:0 dfail:0 fail:0 skip:21
bsw-nuc-2 total:196 pass:159 dwarn:0 dfail:0 fail:0 skip:37
byt-nuc total:196 pass:161 dwarn:0 dfail:0 fail:0 skip:35
hsw-brixbox total:196 pass:174 dwarn:0 dfail:0 fail:0 skip:22
hsw-gt2 total:17 pass:13 dwarn:0 dfail:0 fail:0 skip:3
ilk-hp8440p total:196 pass:132 dwarn:0 dfail:0 fail:0 skip:64
ivb-t430s total:196 pass:169 dwarn:0 dfail:0 fail:0 skip:27
snb-dellxps total:196 pass:162 dwarn:0 dfail:0 fail:0 skip:34
snb-x220t total:196 pass:162 dwarn:0 dfail:0 fail:1 skip:33
Results at /archive/results/CI_IGT_test/Patchwork_1782/
ce3f49e2a53a54308ed171613c2567f04fab8228 drm-intel-nightly: 2016y-04m-01d-20h-30m-13s UTC integration manifest
bf7969308eb88942dab4eceaf91aa8c317468875 drm/i915: Show PCI power state under debugfs/i915_runtime_pm_status
e35f64aba51dc5c4b6a70abd41f263227c7b5ffa drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/intel-gfx
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2016-04-03 13:59 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-04-03 13:14 [CI 1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer Chris Wilson
2016-04-03 13:14 ` [CI 2/2] drm/i915: Show PCI power state under debugfs/i915_runtime_pm_status Chris Wilson
2016-04-03 13:59 ` ✓ Fi.CI.BAT: success for series starting with [CI,1/2] drm/i915: Add struct_mutex locking for debugs/i915_gem_framebuffer 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.