optimize wakeup