alsa: resume output when waking up, fix #1286. some coding style cleanup