Merge "Do not wake device when going from emulated -> non-emulated state" into main