Function securityfs_remove() is called when securityfs_create_file failed, this is needless. And dentry ima_policy is removed after ima_dir is illogical. Signed-off-by: Liguang Zhang <zhangliguang@xxxxxxxxxxxxxxxxx> --- security/integrity/ima/ima_fs.c | 1 - 1 file changed, 1 deletion(-) diff --git a/security/integrity/ima/ima_fs.c b/security/integrity/ima/ima_fs.c index 2000e8d..9c60ddc 100644 --- a/security/integrity/ima/ima_fs.c +++ b/security/integrity/ima/ima_fs.c @@ -501,6 +501,5 @@ int __init ima_fs_init(void) securityfs_remove(binary_runtime_measurements); securityfs_remove(ima_symlink); securityfs_remove(ima_dir); - securityfs_remove(ima_policy); return -1; } -- 1.8.3.1