Correct Answer - Option 4 : 10
The correct answer is option 4:
Data:
Maximum resource requirement of Process P1 = 3
Maximum resource requirement of Process P2 = 4
Maximum resource requirement of Process P3 = 5
Concept:
Deadlock can occur If any process gets available resource < demanded resource
Max resource for process P1 to be in deadlock = needed - 1 = 3 - 1 = 2
Max resource for process P2 to be in deadlock = needed - 1 = 4 - 1 = 3
Max resource for process P3 to be in deadlock = needed - 1 = 5 - 1 = 4
If one resource is added, any of the n processes can take it a finish its execution leaving behind the allocated resource, and hence the system will be deadlock-free.
Calculation:
The minimum value of m that ensures that deadlock will never occur = (2 + 3 + 4) + 1 = 10