iommu/vt-d: Fix QI_DEV_IOTLB_PFSID and QI_DEV_EIOTLB_PFSID macros
[linux-2.6-microblaze.git] / kernel / kexec.c
index 1b018f1..bc933c0 100644 (file)
@@ -205,6 +205,14 @@ static inline int kexec_load_check(unsigned long nr_segments,
        if (result < 0)
                return result;
 
+       /*
+        * kexec can be used to circumvent module loading restrictions, so
+        * prevent loading in that case
+        */
+       result = security_locked_down(LOCKDOWN_KEXEC);
+       if (result)
+               return result;
+
        /*
         * Verify we have a legal set of flags
         * This leaves us room for future extensions.