All of lore.kernel.org
 help / color / mirror / Atom feed
* s3c2443 hangs on msleep on resume from suspend
@ 2014-03-07 18:08 Alexander Varnin
  0 siblings, 0 replies; 2+ messages in thread
From: Alexander Varnin @ 2014-03-07 18:08 UTC (permalink / raw)
  To: linux-samsung-soc@vger.kernel.org

Hello.
I'm developing on Samsung s3c2443 CPU and now my aim is to make suspend
mode working properly. My kernel version is 3.6. Everything was OK,
however Linux hanged on resume, if usb ohci driver was loaded. My
investigation showed, that it hangs on msleep function, that is getting
called in ohci_run() function in drivers/usb/host/ohci-hcd.c file. Exact
line of code is [1]. I found on the web, that there was [2] similar
problem on s3c2410. The reason of hang is that msleep locks the only
working thread in system, and nobody can unlock it. The simple
workaround is to replace msleep with mdelay. But the usage of msleep is
in platform-independent usb-ohci code. That means, that other platforms
somehow bypass this problem, and work with msleep correctly. But I will
prefer to fix it in platform-depended, than to make workaround in common
code.

What bugs in platform-depended code could lead to such problem?

I suggest, that there is some problem with sequence of resume actions,
and usb resume happens much earlier, than it have to. But where exactly
should I search for the problem?

Thanks,
Alexander.

[1]
http://lxr.free-electrons.com/source/drivers/usb/host/ohci-hcd.c?v=3.6;a=arm#L621
[2] http://osdir.com/ml/handhelds.openmoko.kernel/2008-05/msg00168.html

^ permalink raw reply	[flat|nested] 2+ messages in thread

* s3c2443 hangs on msleep on resume from suspend
@ 2014-03-12 13:06 Alexander Varnin
  0 siblings, 0 replies; 2+ messages in thread
From: Alexander Varnin @ 2014-03-12 13:06 UTC (permalink / raw)
  To: linux-kernel

Hello.
I'm developing on Samsung s3c2443 CPU and now my aim is to make suspend
mode working properly. My kernel version is 3.6. Everything was OK,
however Linux hanged on resume, if usb ohci driver was loaded. My
investigation showed, that it hangs on msleep function, that is getting
called in ohci_run() function in drivers/usb/host/ohci-hcd.c file. Exact
line of code is [1]. I found on the web, that there was [2] similar
problem on s3c2410. The reason of hang is that msleep locks the only
working thread in system, and nobody can unlock it. The simple
workaround is to replace msleep with mdelay. But the usage of msleep is
in platform-independent usb-ohci code. That means, that other platforms
somehow bypass this problem, and work with msleep correctly. But I will
prefer to fix it in platform-depended, than to make workaround in common
code.

What bugs in platform-depended code could lead to such problem?

I suggest, that there is some problem with sequence of resume actions,
and usb resume happens much earlier, than it have to. But where exactly
should I search for the problem?

Thanks,
Alexander.

[1]
http://lxr.free-electrons.com/source/drivers/usb/host/ohci-hcd.c?v=3.6;a=arm#L621
[2] http://osdir.com/ml/handhelds.openmoko.kernel/2008-05/msg00168.html


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-03-12 13:12 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-07 18:08 s3c2443 hangs on msleep on resume from suspend Alexander Varnin
  -- strict thread matches above, loose matches on Subject: below --
2014-03-12 13:06 Alexander Varnin

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.