Use CheckedCall for mprotects

Aims to prevent silent failures causing SIGSEGV in random places.

Bug: 66910552
Test: test-art-host

Change-Id: I91742b0b0059b5125ac663c3c3422ac5562df0fa
diff --git a/runtime/class_linker.cc b/runtime/class_linker.cc
index eeb5569..8999e17 100644
--- a/runtime/class_linker.cc
+++ b/runtime/class_linker.cc
@@ -1768,7 +1768,11 @@
     // We cannot do that for app image even after the fixup as some interned
     // String references may actually end up pointing to moveable Strings.
     uint8_t* const_section_begin = space->Begin() + header.GetBootImageConstantTablesOffset();
-    mprotect(const_section_begin, header.GetBootImageConstantTablesSize(), PROT_READ);
+    CheckedCall(mprotect,
+                "protect constant tables",
+                const_section_begin,
+                header.GetBootImageConstantTablesSize(),
+                PROT_READ);
   }
 
   ClassTable* class_table = nullptr;