mirror of
https://github.com/RGBCube/serenity
synced 2025-05-17 15:35:06 +00:00
Kernel: Protect FramebufferDevice with spinlock instead of mutex
This commit is contained in:
parent
ddde9e7ee5
commit
ca42621be1
5 changed files with 18 additions and 19 deletions
|
@ -124,7 +124,7 @@ ErrorOr<void> GenericFramebufferDevice::ioctl(OpenFileDescription&, unsigned req
|
|||
auto flush_rects = TRY(copy_typed_from_user(user_flush_rects));
|
||||
if (Checked<unsigned>::multiplication_would_overflow(flush_rects.count, sizeof(FBRect)))
|
||||
return Error::from_errno(EFAULT);
|
||||
MutexLocker locker(m_flushing_lock);
|
||||
SpinlockLocker locker(m_flushing_lock);
|
||||
if (flush_rects.count > 0) {
|
||||
for (unsigned i = 0; i < flush_rects.count; i++) {
|
||||
FBRect user_dirty_rect;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue