aboutsummaryrefslogtreecommitdiff
path: root/packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2017-05-03 20:26:55 +0000
committerDimitry Andric <dim@FreeBSD.org>2017-05-03 20:26:55 +0000
commit52fd8de56a8a12201c1e6188e1f34d28c3d3398d (patch)
tree69810dbf8f7743a20c29413ac665494c713276b3 /packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp
parent773dd0e6e632d48d7123a321ba86f50847b9afc0 (diff)
downloadsrc-52fd8de56a8a12201c1e6188e1f34d28c3d3398d.tar.gz
src-52fd8de56a8a12201c1e6188e1f34d28c3d3398d.zip
Vendor import of lldb trunk r302069:vendor/lldb/lldb-trunk-r302069
Notes
Notes: svn path=/vendor/lldb/dist/; revision=317769 svn path=/vendor/lldb/lldb-trunk-r302069/; revision=317770; tag=vendor/lldb/lldb-trunk-r302069
Diffstat (limited to 'packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp')
-rw-r--r--packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp b/packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp
index d9adb550023c..3e528d281eee 100644
--- a/packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp
+++ b/packages/Python/lldbsuite/test/functionalities/register/intel_xtended_registers/main.cpp
@@ -14,6 +14,11 @@
int
main(int argc, char const *argv[])
{
+// PR_MPX_ENABLE_MANAGEMENT won't be defined on linux kernel versions below 3.19
+#ifndef PR_MPX_ENABLE_MANAGEMENT
+ return -1;
+#endif
+
// This call returns 0 only if the CPU and the kernel support Intel(R) MPX.
if (prctl(PR_MPX_ENABLE_MANAGEMENT, 0, 0, 0, 0) != 0)
return -1;