Merge "Add keys to prerequisites of mac_permissions.xml"
diff --git a/file.te b/file.te
index 8e3bbe5..f30911a 100644
--- a/file.te
+++ b/file.te
@@ -215,7 +215,7 @@
# Allow files to be created in their appropriate filesystems.
allow fs_type self:filesystem associate;
allow sysfs_type sysfs:filesystem associate;
-allow debugfs_type debugfs:filesystem associate;
+allow debugfs_type { debugfs debugfs_tracing }:filesystem associate;
allow file_type labeledfs:filesystem associate;
allow file_type tmpfs:filesystem associate;
allow file_type rootfs:filesystem associate;
diff --git a/genfs_contexts b/genfs_contexts
index 2700a94..d823476 100644
--- a/genfs_contexts
+++ b/genfs_contexts
@@ -34,6 +34,7 @@
genfscon inotifyfs / u:object_r:inotify:s0
genfscon vfat / u:object_r:vfat:s0
genfscon debugfs / u:object_r:debugfs:s0
+genfscon tracefs / u:object_r:debugfs_tracing:s0
genfscon fuse / u:object_r:fuse:s0
genfscon pstore / u:object_r:pstorefs:s0
genfscon functionfs / u:object_r:functionfs:s0
diff --git a/init.te b/init.te
index 9a7fde7..7160466 100644
--- a/init.te
+++ b/init.te
@@ -156,7 +156,7 @@
}:lnk_file { create getattr setattr relabelfrom unlink };
allow init {file_type -system_file -exec_type}:dir_file_class_set relabelto;
-allow init { sysfs debugfs }:{ dir file lnk_file } { getattr relabelfrom };
+allow init { sysfs debugfs debugfs_tracing }:{ dir file lnk_file } { getattr relabelfrom };
allow init { sysfs_type debugfs_type }:{ dir file lnk_file } relabelto;
allow init dev_type:dir create_dir_perms;
allow init dev_type:lnk_file create;
diff --git a/tools/check_seapp.c b/tools/check_seapp.c
index 69db388..751fb5c 100644
--- a/tools/check_seapp.c
+++ b/tools/check_seapp.c
@@ -23,7 +23,7 @@
/**
* Initializes an empty, static list.
*/
-#define list_init(free_fn) { .head = NULL, .tail = NULL, .freefn = free_fn }
+#define list_init(free_fn) { .head = NULL, .tail = NULL, .freefn = (free_fn) }
/**
* given an item in the list, finds the offset for the container
@@ -35,7 +35,7 @@
*
*/
#define list_entry(element, type, name) \
- (type *)(((uint8_t *)element) - (uint8_t *)&(((type *)NULL)->name))
+ (type *)(((uint8_t *)(element)) - (uint8_t *)&(((type *)NULL)->name))
/**
* Iterates over the list, do not free elements from the list when using this.
@@ -43,7 +43,7 @@
* @var The variable name for the cursor
*/
#define list_for_each(list, var) \
- for(var = (list)->head; var != NULL; var = var->next)
+ for(var = (list)->head; var != NULL; var = var->next) /*NOLINT*/
typedef struct hash_entry hash_entry;