Merge a set of device state improvements from team/russell/events.