Proof using.
unfold locks_correct_unlock, valid_unlock.
intros.
exists x.
intuition; now rewrite_update.
Qed.

Lemma locks_correct_unlock_input_handlers_new :
forall h i sigma u st' out ms p,
InputHandler h i (sigma h) = (u, out, st', ms) ->
locks_correct sigma ->
In (pDst p, pBody p) ms ->
pSrc p = h ->
locks_correct_unlock (update name_eq_dec sigma h st') p.