here are 4 necessary conditions, out of which even if one is correct, it will lead the system into a condition of deadlock.
1. Mutual Exclusion
If the resources can not be shared, then it is possible that the requested resource can not be acquired. That means, if one or more resources of the system are non-sharable, then deadlock may arise.
2. Hold and Wait
In this condition, a process holds one or more resources and waits for acquiring other resources, that may be already occupied.
3. No Preemption
This condition implies that a process will never leave its resources until and unless it gets the requested resources. Then no process will leave the resouces leading to a deadlock.
4. Circular Wait
The condition just similar to hold and wait condition, the only difference is the circular fashion. Processes wait for acquiring each other in a circular form.