When a process in the kernel space is holding a spin_lock, the process cannot be preempted due to any of the following conditions :
- When the time-slice of the process gets exhausted
- When a high priority process becomes runnable
- When an interrupt occurs
However the process can yield the processor if it blocks, sleeps, or explicitly call schedule(). Is my understanding correct?
When a process in the kernel space is holding a mutex_lock, can the process be preempted due to the above conditions listed as 1, 2 and 3.