refactoring suspend/resume demo driver