summaryrefslogtreecommitdiff
path: root/security/integrity/ima/ima_api.c
diff options
context:
space:
mode:
authorEric Biggers <ebiggers@google.com>2018-09-07 23:22:23 +0300
committerMimi Zohar <zohar@linux.ibm.com>2018-10-10 19:56:15 +0300
commitb2724d5802a77b7fb47e84d9b88b80370eccbc64 (patch)
tree59917073de892c95ac1b59b3ae8c31f2ecf76749 /security/integrity/ima/ima_api.c
parent691115c3513ec83edf68ba6575ae85630bc94b8b (diff)
downloadlinux-b2724d5802a77b7fb47e84d9b88b80370eccbc64.tar.xz
security/integrity: constify some read-only data
Constify some static data that is never modified, so that it is placed in .rodata. Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Mimi Zohar <zohar@linux.ibm.com>
Diffstat (limited to 'security/integrity/ima/ima_api.c')
-rw-r--r--security/integrity/ima/ima_api.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/security/integrity/ima/ima_api.c b/security/integrity/ima/ima_api.c
index a02c5acfd403..99dd1d53fc35 100644
--- a/security/integrity/ima/ima_api.c
+++ b/security/integrity/ima/ima_api.c
@@ -51,7 +51,8 @@ int ima_alloc_init_template(struct ima_event_data *event_data,
(*entry)->template_desc = template_desc;
for (i = 0; i < template_desc->num_fields; i++) {
- struct ima_template_field *field = template_desc->fields[i];
+ const struct ima_template_field *field =
+ template_desc->fields[i];
u32 len;
result = field->field_init(event_data,