Ways we can deal with Deadlock

2. Deadlock Prevention

4. Making circular wait impossible

  1. Continuing our proof by contradiction:

    1. Now since P0 is waiting for a resource R1 while holding a resource R0, it must be the case that F0<F1. In like manner, F1<F2, etc. So we have F0<F1<F2...<Fn, and therefore, by transitivity, F0<Fn.

    2. But we also have process Pn requesting a resource R0 held by P0, while holding a resource Rn. Therefore, it must be that F0>Fn. Since this is a contradiction, our assumption that circular wait could arise is false.