Skip to content

scope.c: use mutex_lock_killable to prevent unkillable processes#3

Open
tomvanbraeckel wants to merge 1 commit intoabbradar:masterfrom
tomvanbraeckel:prevent_unkillable_process_due_to_kernel_deadlock
Open

scope.c: use mutex_lock_killable to prevent unkillable processes#3
tomvanbraeckel wants to merge 1 commit intoabbradar:masterfrom
tomvanbraeckel:prevent_unkillable_process_due_to_kernel_deadlock

Conversation

@tomvanbraeckel
Copy link

When doing rmmod quickly after insmod, a race condition causes
the code to wait for the lock forever so it hangs until the next reboot.

This commit changes mutex_lock to mutex_lock_killable so at least
the user can kill the userspace process waiting for the driver.

Even though this is not a permanent proper fix, it makes the issue a lot
less annoying because it removes the need for a full system restart when this happens.

When doing rmmod quickly after insmod, a race condition causes
the code to wait for the lock forever so it hangs until the next reboot.

This commit changes mutex_lock to mutex_lock_killable so at least
the user can kill the userspace process waiting for the driver.

Even though this is not a permanent proper fix, it makes the issue a lot
less annoying because it removes the need for a full system restart when this happens.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant