Skip to content

Commit

Permalink
Merge tag 'x86_urgent_for_v5.17_rc4' of git://git.kernel.org/pub/scm/…
Browse files Browse the repository at this point in the history
…linux/kernel/git/tip/tip

Pull x86 fix from Borislav Petkov:
 "Prevent softlockups when tearing down large SGX enclaves"

* tag 'x86_urgent_for_v5.17_rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip:
  x86/sgx: Silence softlockup detection when releasing large enclaves
  • Loading branch information
Linus Torvalds committed Feb 13, 2022
2 parents e9c2578 + 8795359 commit 808f0ab
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions arch/x86/kernel/cpu/sgx/encl.c
Original file line number Diff line number Diff line change
Expand Up @@ -410,6 +410,8 @@ void sgx_encl_release(struct kref *ref)
}

kfree(entry);
/* Invoke scheduler to prevent soft lockups. */
cond_resched();
}

xa_destroy(&encl->page_array);
Expand Down

0 comments on commit 808f0ab

Please sign in to comment.