Merge "Handle timeouts while dozing" into tm-dev