]> xenbits.xensource.com Git - people/dwmw2/xen.git/commitdiff
xen/xsm: Rename CONFIG_FLASK_* to CONFIG_XSM_FLASK_*
authorAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 26 Jun 2018 09:56:50 +0000 (10:56 +0100)
committerAndrew Cooper <andrew.cooper3@citrix.com>
Tue, 28 Aug 2018 13:17:11 +0000 (14:17 +0100)
Flask is one single XSM module, and another is about to be introduced.
Properly namespace the symbols for clarity.

No functional change.

Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
Reviewed-by: Doug Goldstein <cardoe@cardoe.com>
Acked-by: Daniel De Graaf <dgdegra@tycho.nsa.gov>
xen/common/Kconfig
xen/include/Makefile
xen/include/xen/sched.h
xen/include/xsm/xsm.h
xen/xsm/Makefile
xen/xsm/flask/avc.c
xen/xsm/flask/flask_op.c
xen/xsm/flask/include/avc.h

index cf9b351be668c303f8a74d5160002056408dcc25..3a7c752e931cf4bcc5e6e5bab32e00a6768f1d56 100644 (file)
@@ -114,7 +114,7 @@ config XSM
 
          If unsure, say N.
 
-config FLASK
+config XSM_FLASK
        def_bool y
        prompt "FLux Advanced Security Kernel support" if EXPERT = "y"
        depends on XSM
@@ -127,10 +127,10 @@ config FLASK
 
          If unsure, say Y.
 
-config FLASK_AVC_STATS
+config XSM_FLASK_AVC_STATS
        def_bool y
        prompt "Maintain statistics on the FLASK access vector cache" if EXPERT = "y"
-       depends on FLASK
+       depends on XSM_FLASK
        ---help---
          Maintain counters on the access vector cache that can be viewed using
          the FLASK_AVC_CACHESTATS sub-op of the xsm_op hypercall.  Disabling
index df041829653b15efad1aa949b81fbb02099bd79a..f7895e4d4e46426f2e5a7f56c394f7e1573aee2c 100644 (file)
@@ -30,7 +30,7 @@ headers-$(CONFIG_X86)     += compat/hvm/dm_op.h
 headers-$(CONFIG_X86)     += compat/hvm/hvm_op.h
 headers-$(CONFIG_X86)     += compat/hvm/hvm_vcpu.h
 headers-y                 += compat/arch-$(compat-arch-y).h compat/pmu.h compat/xlat.h
-headers-$(CONFIG_FLASK)   += compat/xsm/flask_op.h
+headers-$(CONFIG_XSM_FLASK) += compat/xsm/flask_op.h
 
 cppflags-y                := -include public/xen-compat.h -DXEN_GENERATING_COMPAT_HEADERS
 cppflags-$(CONFIG_X86)    += -m32
index 51ceebe6ccccff8eeba5ccdbbe28b25eceb3b1b0..2cffb2c91911dfa7d373dd492dd44f915cfa55b1 100644 (file)
@@ -122,7 +122,7 @@ struct evtchn
          */
         void *generic;
 #endif
-#ifdef CONFIG_FLASK
+#ifdef CONFIG_XSM_FLASK
         /*
          * Inlining the contents of the structure for FLASK avoids unneeded
          * allocations, and on 64-bit platforms with only FLASK enabled,
index 7636bcbb42049baa528e6fd0fdf3fe61e5c03701..b692aece711e615f73a073645a12347c01e5f430 100644 (file)
@@ -24,7 +24,7 @@ DEFINE_XEN_GUEST_HANDLE(xsm_op_t);
 /* policy magic number (defined by XSM_MAGIC) */
 typedef u32 xsm_magic_t;
 
-#ifdef CONFIG_FLASK
+#ifdef CONFIG_XSM_FLASK
 #define XSM_MAGIC 0xf97cff8c
 #else
 #define XSM_MAGIC 0x0
@@ -720,7 +720,7 @@ extern int register_xsm(struct xsm_operations *ops);
 extern struct xsm_operations dummy_xsm_ops;
 extern void xsm_fixup_ops(struct xsm_operations *ops);
 
-#ifdef CONFIG_FLASK
+#ifdef CONFIG_XSM_FLASK
 extern void flask_init(const void *policy_buffer, size_t policy_size);
 #else
 static inline void flask_init(const void *policy_buffer, size_t policy_size)
index 3252c46e64f5dd8c65cf5a132f45c47c7895d617..8bb4a24f09d3950170dbef47c7649f7b05e86ccd 100644 (file)
@@ -2,4 +2,4 @@ obj-y += xsm_core.o
 obj-$(CONFIG_XSM) += xsm_policy.o
 obj-$(CONFIG_XSM) += dummy.o
 
-subdir-$(CONFIG_FLASK) += flask
+subdir-$(CONFIG_XSM_FLASK) += flask
index a3e6108a3479d07b39a7f853f9021d5a289384e6..640c708659b00888c863bf54b17d7fa162926d8c 100644 (file)
@@ -56,7 +56,7 @@ const struct selinux_class_perm selinux_class_perm = {
 #define AVC_DEF_CACHE_THRESHOLD        512
 #define AVC_CACHE_RECLAIM        16
 
-#ifdef CONFIG_FLASK_AVC_STATS
+#ifdef CONFIG_XSM_FLASK_AVC_STATS
 #define avc_cache_stats_incr(field)                 \
 do {                                \
     __get_cpu_var(avc_cache_stats).field++;        \
@@ -89,7 +89,7 @@ struct avc_cache {
 /* Exported via Flask hypercall */
 unsigned int avc_cache_threshold = AVC_DEF_CACHE_THRESHOLD;
 
-#ifdef CONFIG_FLASK_AVC_STATS
+#ifdef CONFIG_XSM_FLASK_AVC_STATS
 DEFINE_PER_CPU(struct avc_cache_stats, avc_cache_stats);
 #endif
 
index 03baa28b686d13fc530c160b17181833429223c4..1c4decc6cd1ce01552ff5d27304f797bbbdfa3f9 100644 (file)
@@ -425,7 +425,7 @@ static int flask_security_make_bools(void)
     return ret;
 }
 
-#ifdef CONFIG_FLASK_AVC_STATS
+#ifdef CONFIG_XSM_FLASK_AVC_STATS
 
 static int flask_security_avc_cachestats(struct xen_flask_cache_stats *arg)
 {
@@ -713,7 +713,7 @@ ret_t do_flask_op(XEN_GUEST_HANDLE_PARAM(xsm_op_t) u_flask_op)
         rv = avc_get_hash_stats(&op.u.hash_stats);
         break;
 
-#ifdef CONFIG_FLASK_AVC_STATS
+#ifdef CONFIG_XSM_FLASK_AVC_STATS
     case FLASK_AVC_CACHESTATS:
         rv = flask_security_avc_cachestats(&op.u.cache_stats);
         break;
index bfc69f4acdaf5397da3555aebd6c8ca3de20d638..4046516b9c32172e22e9e31cb7795302f7de92af 100644 (file)
@@ -95,7 +95,7 @@ struct xen_flask_hash_stats;
 int avc_get_hash_stats(struct xen_flask_hash_stats *arg);
 extern unsigned int avc_cache_threshold;
 
-#ifdef CONFIG_FLASK_AVC_STATS
+#ifdef CONFIG_XSM_FLASK_AVC_STATS
 DECLARE_PER_CPU(struct avc_cache_stats, avc_cache_stats);
 #endif