Re: [PATCH] drm/i915: Acquire dpio_lock for VLV sideband programming in DP/HDMI

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Jul 26, 2013 at 06:46:43PM +0200, Daniel Vetter wrote:
> On Fri, Jul 26, 2013 at 6:17 PM, Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> wrote:
> > Otherwise we get flooded by the kernel warning us that we are doing
> > long sequences of IO without serialisation. For example,
> >
> >  WARNING: CPU: 0 PID: 11136 at drivers/gpu/drm/i915/intel_sideband.c:40 vlv_sideband_rw+0x48/0x1ef()
> >  Modules linked in:
> >  CPU: 0 PID: 11136 Comm: kworker/u2:0 Tainted: G        W    3.11.0-rc2+ #4
> >  Call Trace:
> >   [<c2028564>] ?  warn_slowpath_common+0x63/0x78
> >   [<c227ad43>] ?  vlv_sideband_rw+0x48/0x1ef
> >   [<c20285dd>] ?  warn_slowpath_null+0xf/0x13
> >   [<c227ad43>] ?  vlv_sideband_rw+0x48/0x1ef
> >   [<c227b060>] ?  vlv_dpio_write+0x1c/0x21
> >   [<c2262b3b>] ?  intel_dp_set_signal_levels+0x24a/0x385
> >   [<c2264909>] ?  intel_dp_complete_link_train+0x25/0x1d1
> >   [<c2264c55>] ?  intel_dp_check_link_status+0xf7/0x106
> >   [<c2238ced>] ?  i915_hotplug_work_func+0x17b/0x221
> >   [<c203a204>] ?  process_one_work+0x12e/0x210
> >   [<c203a5e4>] ?  worker_thread+0x116/0x1ad
> >   [<c203a4ce>] ?  rescuer_thread+0x1cb/0x1cb
> >   [<c203d8f5>] ?  kthread+0x67/0x6c
> >   [<c2457ebb>] ?  ret_from_kernel_thread+0x1b/0x30
> >   [<c203d88e>] ?  init_completion+0x18/0x18
> >
> > Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx>
> 
> The problem here is that Jesse was lazy and grabs the lock in
> vlv_crtc_enable, so I think your code here will deadlock. But I agree
> that grabbing the lock where we actually frob the sideband is what we
> want ...

Looks like vlv_crtc_enable() is the only place that takes the lock around
callbacks, so I propose dropping the locking in that function (and
scoping it around the sideband sequences as above).
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
http://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux