USB: fix up suspend and resume for PCI host controllers
A message that is not in the archive (sent off-list or not yet received): 1232144882.23611.2.camel@pasglop
Quoted 18 lines · Benjamin Herrenschmidt
Quoted 5 lines
Ben, we need to check with you on this also. These patches we have been throwing around move the code to disable and enable the
PPC_PMACASIC clocks for USB. Can that code execute safely at any time while the host controller isn't running? Is it okay to execute the code with interrupts disabled?Wow, that's digging old stuff I haven't touched for some time :-)
So I think running the pmac hooks with IRQs off might be ok. They have delays but they use
mdelay()notmsleep().As to when it is safe to run that code, it isn't a trivial answer. I'd say any time after it's been suspended and before it's resumed sounds about right, but my experience with those earlier Apple built-in OHCIs is that they are -very- sensitive to random environmental conditions when suspending/resuming and if -anything- goes wrong, they start happily scribbling all over system memory when suspended :-(
Quoted 5 lines
So I think it's going to boil down to testing. Might be useful to find somebody with one of the really old powerbooks, I see if I can find that around the lab here, mine is dead.
Do you have a git tree I can pull to test your stuff ?
Not exactly. Just try this patch:
http://marc.info/?l=linux-kernel&m=123184641714487&w=2
with vanilla 2.6.29-rc1 or rc2.
Alan Stern