Hi, These patches are based upon the hard work of Lauro. He put in the time and effort to understand and debug the code.
So while I didn't take many of his actual patches; I want to thank him for doing the work. Hopefully the "Debugged-by:" tag conveys some of that. In any case, please have a look. I think these should about cover things. Rik, Lauro, could you guys in particular look at the final patch that adds a few comments. I attempted to document the intent and understanding there. But given I've been staring at this stuff too long I could've missed the obvious. Comments and or suggestions welcome.

