On Wed, Aug 09, 2006 at 10:12:10PM +0200, Rafael J. Wysocki wrote: > AFAIK, the AHCI suspend to RAM support is on its way, but does anyone know > about the other SATA/PATA drivers?
AFAICT, the situation with drivers/ide is that it happens to work (by luck) well enough for most people that it's been ignored until now. And when it doesn't work, the result is a hard, difficult-to-debug hang on resume that is rarely diagnosed because the standard try-it-with-all-modules-unloaded trick doesn't cover permanent non-unloadable ide drivers. Or because the ide layer eventually resets the bus without hanging machine and the user just thinks the resume is "slow". I gather that there are two important phases to ide suspend: the ide buses (meaning the drives), and the ide controller (usually on the pci bus) that gives access to the ide bus. My first patch was NACKed by Alan because I was doing IDE drive resume at the pci ide controller level. Benjamin Herrenschmidt <[EMAIL PROTECTED]> had this to say: > On Fri, 2006-07-28 at 21:00 +0100, Alan Cox wrote: > > It should be done globally. In many cases the chips start up from power > > on configured for PIO 0 so that side happens to work, but not all chips > > do this as you've found out. Setting the PIO side correctly is a fix > > even if its not a bug people hit a lot. > > It's actually incorrect to just "restore" the previous timings. In many > case, the disk will have been reset too. The safe thing is to force the > controller in PIO0 mode at resume, and the best place to do that is from > the controller's own resume(), as I do on pmac. It's the parent of the > hwif and thus will be resumed before the later. > > Later on, the state machine will redo the tuning to get to a better > speed, including sending the right commands to also reconfigure the > drive. I think Benjamin's may be describing my hardware. My current patch is calling hwif->tuneproc(), which resets both controller and drives afaict. I plan on coding up a patch to poke only the controller, following the drivers/ide/ppc/pmac.c approach, but I haven't found the time. Jason ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ Suspend-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/suspend-devel
