#include #ifndef FUTEX_WAIT_BITSET #define FUTEX_WAIT_BITSET 9 #endif #ifndef FUTEX_WAKE_BITSET #define FUTEX_WAKE_BITSET 10 #endif #ifndef FUTEX_WAIT_REQUEUE_PI #define FUTEX_WAIT_REQUEUE_PI 11 #endif #ifndef FUTEX_CMP_REQUEUE_PI #define FUTEX_CMP_REQUEUE_PI 12 #endif #ifndef FUTEX_CLOCK_REALTIME #define FUTEX_CLOCK_REALTIME 256 #endif static size_t syscall_arg__scnprintf_futex_op(char *bf, size_t size, struct syscall_arg *arg) { enum syscall_futex_args { SCF_UADDR = (1 << 0), SCF_OP = (1 << 1), SCF_VAL = (1 << 2), SCF_TIMEOUT = (1 << 3), SCF_UADDR2 = (1 << 4), SCF_VAL3 = (1 << 5), }; int op = arg->val; int cmd = op & FUTEX_CMD_MASK; size_t printed = 0; switch (cmd) { #define P_FUTEX_OP(n) case FUTEX_##n: printed = scnprintf(bf, size, #n); P_FUTEX_OP(WAIT); arg->mask |= SCF_VAL3|SCF_UADDR2; break; P_FUTEX_OP(WAKE); arg->mask |= SCF_VAL3|SCF_UADDR2|SCF_TIMEOUT; break; P_FUTEX_OP(FD); arg->mask |= SCF_VAL3|SCF_UADDR2|SCF_TIMEOUT; break; P_FUTEX_OP(REQUEUE); arg->mask |= SCF_VAL3|SCF_TIMEOUT; break; P_FUTEX_OP(CMP_REQUEUE); arg->mask |= SCF_TIMEOUT; break; P_FUTEX_OP(CMP_REQUEUE_PI); arg->mask |= SCF_TIMEOUT; break; P_FUTEX_OP(WAKE_OP); break; P_FUTEX_OP(LOCK_PI); arg->mask |= SCF_VAL3|SCF_UADDR2|SCF_TIMEOUT; break; P_FUTEX_OP(UNLOCK_PI); arg->mask |= SCF_VAL3|SCF_UADDR2|SCF_TIMEOUT; break; P_FUTEX_OP(TRYLOCK_PI); arg->mask |= SCF_VAL3|SCF_UADDR2; break; P_FUTEX_OP(WAIT_BITSET); arg->mask |= SCF_UADDR2; break; P_FUTEX_OP(WAKE_BITSET); arg->mask |= SCF_UADDR2; break; P_FUTEX_OP(WAIT_REQUEUE_PI); break; default: printed = scnprintf(bf, size, "%#x", cmd); break; } if (op & FUTEX_PRIVATE_FLAG) printed += scnprintf(bf + printed, size - printed, "|PRIV"); if (op & FUTEX_CLOCK_REALTIME) printed += scnprintf(bf + printed, size - printed, "|CLKRT"); return printed; } #define SCA_FUTEX_OP syscall_arg__scnprintf_futex_op ='active' href='/cgit.cgi/linux/net-next.git/commit/tools/build?h=nds-private-remove&id=2d5a7101a140adcf7a5d8677649847fbb2dd5a2f'>commitdiff
path: root/tools/build
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2017-01-15 12:38:53 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2017-01-15 12:38:53 -0800
commit2d5a7101a140adcf7a5d8677649847fbb2dd5a2f (patch)
tree02e3532964dd4c42aa6ea2187fee67e6dfee36dd /tools/build
parent7f138b9706f5f3528d598aefd35337d54a8c1afb (diff)
parentc7334ce814f7e5d8fc1f9b3126cda0640c2f81b3 (diff)
Merge tag 'driver-core-4.10-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core
Pull driver core fix from Greg KH: "Here is a single patch being reverted to remove a feature that was added in 4.10-rc1 that isn't quite ready for release. It will be redone as a debugfs file instead of a sysfs file in the future" * tag 'driver-core-4.10-rc4' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/driver-core: Revert "driver core: Add deferred_probe attribute to devices in sysfs"
Diffstat (limited to 'tools/build')