implement wait on freeze

Docker-DCO-1.1-Signed-off-by: Victor Vieux <vieux@docker.com> (github: vieux)
Merge pull request #6187 from vieux/wait_freeze

Implement wait on freeze