diff options
Diffstat (limited to 'net/xfrm/xfrm_state.c')
-rw-r--r-- | net/xfrm/xfrm_state.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/net/xfrm/xfrm_state.c b/net/xfrm/xfrm_state.c index cf43c49eab37..1af522bf12ca 100644 --- a/net/xfrm/xfrm_state.c +++ b/net/xfrm/xfrm_state.c | |||
@@ -2028,6 +2028,7 @@ void | |||
2028 | xfrm_audit_state_add(struct xfrm_state *x, int result, u32 auid, u32 sid) | 2028 | xfrm_audit_state_add(struct xfrm_state *x, int result, u32 auid, u32 sid) |
2029 | { | 2029 | { |
2030 | struct audit_buffer *audit_buf; | 2030 | struct audit_buffer *audit_buf; |
2031 | u32 spi; | ||
2031 | extern int audit_enabled; | 2032 | extern int audit_enabled; |
2032 | 2033 | ||
2033 | if (audit_enabled == 0) | 2034 | if (audit_enabled == 0) |
@@ -2037,8 +2038,8 @@ xfrm_audit_state_add(struct xfrm_state *x, int result, u32 auid, u32 sid) | |||
2037 | return; | 2038 | return; |
2038 | audit_log_format(audit_buf, " op=SAD-add res=%u",result); | 2039 | audit_log_format(audit_buf, " op=SAD-add res=%u",result); |
2039 | xfrm_audit_common_stateinfo(x, audit_buf); | 2040 | xfrm_audit_common_stateinfo(x, audit_buf); |
2040 | audit_log_format(audit_buf, " spi=%lu(0x%lx)", | 2041 | spi = ntohl(x->id.spi); |
2041 | (unsigned long)x->id.spi, (unsigned long)x->id.spi); | 2042 | audit_log_format(audit_buf, " spi=%u(0x%x)", spi, spi); |
2042 | audit_log_end(audit_buf); | 2043 | audit_log_end(audit_buf); |
2043 | } | 2044 | } |
2044 | EXPORT_SYMBOL_GPL(xfrm_audit_state_add); | 2045 | EXPORT_SYMBOL_GPL(xfrm_audit_state_add); |
@@ -2047,6 +2048,7 @@ void | |||
2047 | xfrm_audit_state_delete(struct xfrm_state *x, int result, u32 auid, u32 sid) | 2048 | xfrm_audit_state_delete(struct xfrm_state *x, int result, u32 auid, u32 sid) |
2048 | { | 2049 | { |
2049 | struct audit_buffer *audit_buf; | 2050 | struct audit_buffer *audit_buf; |
2051 | u32 spi; | ||
2050 | extern int audit_enabled; | 2052 | extern int audit_enabled; |
2051 | 2053 | ||
2052 | if (audit_enabled == 0) | 2054 | if (audit_enabled == 0) |
@@ -2056,8 +2058,8 @@ xfrm_audit_state_delete(struct xfrm_state *x, int result, u32 auid, u32 sid) | |||
2056 | return; | 2058 | return; |
2057 | audit_log_format(audit_buf, " op=SAD-delete res=%u",result); | 2059 | audit_log_format(audit_buf, " op=SAD-delete res=%u",result); |
2058 | xfrm_audit_common_stateinfo(x, audit_buf); | 2060 | xfrm_audit_common_stateinfo(x, audit_buf); |
2059 | audit_log_format(audit_buf, " spi=%lu(0x%lx)", | 2061 | spi = ntohl(x->id.spi); |
2060 | (unsigned long)x->id.spi, (unsigned long)x->id.spi); | 2062 | audit_log_format(audit_buf, " spi=%u(0x%x)", spi, spi); |
2061 | audit_log_end(audit_buf); | 2063 | audit_log_end(audit_buf); |
2062 | } | 2064 | } |
2063 | EXPORT_SYMBOL_GPL(xfrm_audit_state_delete); | 2065 | EXPORT_SYMBOL_GPL(xfrm_audit_state_delete); |