mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-07 19:30:30 +09:00
Fix: Disable sys_membarrier when nohz_full is enabled
am: c0ef1f537a
Change-Id: I3650becd64c5156d24dee601990d48c68057e81d
This commit is contained in:
@@ -16,6 +16,7 @@
|
||||
|
||||
#include <linux/syscalls.h>
|
||||
#include <linux/membarrier.h>
|
||||
#include <linux/tick.h>
|
||||
|
||||
/*
|
||||
* Bitmask made from a "or" of all commands within enum membarrier_cmd,
|
||||
@@ -51,6 +52,9 @@
|
||||
*/
|
||||
SYSCALL_DEFINE2(membarrier, int, cmd, int, flags)
|
||||
{
|
||||
/* MEMBARRIER_CMD_SHARED is not compatible with nohz_full. */
|
||||
if (tick_nohz_full_enabled())
|
||||
return -ENOSYS;
|
||||
if (unlikely(flags))
|
||||
return -EINVAL;
|
||||
switch (cmd) {
|
||||
|
||||
Reference in New Issue
Block a user