/* * Copyright 2016, Michael Ellerman, IBM Corp. * Licensed under GPLv2. */ #include #include #include #include #include #include "utils.h" #define SIZE (64 * 1024) int test_prot_sao(void) { char *p; /* 2.06 or later should support SAO */ SKIP_IF(!have_hwcap(PPC_FEATURE_ARCH_2_06)); /* * Ensure we can ask for PROT_SAO. * We can't really verify that it does the right thing, but at least we * confirm the kernel will accept it. */ p = mmap(NULL, SIZE, PROT_READ | PROT_WRITE | PROT_SAO, MAP_ANONYMOUS | MAP_PRIVATE, -1, 0); FAIL_IF(p == MAP_FAILED); /* Write to the mapping, to at least cause a fault */ memset(p, 0xaa, SIZE); return 0; } int main(void) { return test_harness(test_prot_sao, "prot-sao"); } href='/cgit.cgi/'>index : net-next.git
net-next plumbingsTobias Klauser
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2017-02-06 14:42:34 -0800
committerLinus Torvalds <torvalds@linux-foundation.org>2017-02-06 14:42:34 -0800
commit50dcb6cdb70281d76b28d1564f8e076bb08f2c60 (patch)
treec8884d0b8676fa7a9b44c1d678b48e40561aa994 /drivers/usb/dwc2
parent72df5eba704252e54b5b19395cb938f8bb55cab8 (diff)
parentf5b0cba8f23915e92932f11eb063e37d70556a89 (diff)
Merge tag 'dm-4.10-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm
Pull device mapper fixes from Mike Snitzer: - a fix for a race in .request_fn request-based DM request handling vs DM device destruction - an RCU fix for dm-crypt's kernel keyring support that was included in 4.10-rc1 - a -Wbool-operation warning fix for DM multipath * tag 'dm-4.10-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/device-mapper/linux-dm: dm crypt: replace RCU read-side section with rwsem dm rq: cope with DM device destruction while in dm_old_request_fn() dm mpath: cleanup -Wbool-operation warning in choose_pgpath()
Diffstat (limited to 'drivers/usb/dwc2')