Abstract out the sync on shutdown code and add call to it
from the suspend path at an opportune spot.
We have a reset on resume bug (at least for my laptop)
and I'm growing weary of the fsck spewing several screens when
there's lots of dirty buffers.
This seems to mostly solve the problem: the filesystem still gets
fsck'd because it's marked as dirty, but no further damage is apparent.
This is the first cut at doing this, and is being circulated for review
and comments.