diff options
author | Ilya Dryomov <idryomov@gmail.com> | 2016-12-02 18:35:07 +0300 |
---|---|---|
committer | Ilya Dryomov <idryomov@gmail.com> | 2016-12-13 01:09:19 +0300 |
commit | 7882a26d2e2e520099e2961d5e2e870f8e4172dc (patch) | |
tree | be084fd64e02745bf8ab5de2c697517467a11c34 /net/ceph/auth_x.h | |
parent | a45f795c65b479b4ba107b6ccde29b896d51ee98 (diff) | |
download | linux-7882a26d2e2e520099e2961d5e2e870f8e4172dc.tar.xz |
libceph: rename and align ceph_x_authorizer::reply_buf
It's going to be used as a temporary buffer for in-place en/decryption
with ceph_crypt() instead of on-stack buffers, so rename to enc_buf.
Ensure alignment to avoid GFP_ATOMIC allocations in the crypto stack.
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Reviewed-by: Sage Weil <sage@redhat.com>
Diffstat (limited to 'net/ceph/auth_x.h')
-rw-r--r-- | net/ceph/auth_x.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/net/ceph/auth_x.h b/net/ceph/auth_x.h index 21a5af904bae..48e9ad41bd2a 100644 --- a/net/ceph/auth_x.h +++ b/net/ceph/auth_x.h @@ -24,6 +24,7 @@ struct ceph_x_ticket_handler { unsigned long renew_after, expires; }; +#define CEPHX_AU_ENC_BUF_LEN 128 /* big enough for encrypted blob */ struct ceph_x_authorizer { struct ceph_authorizer base; @@ -32,7 +33,7 @@ struct ceph_x_authorizer { unsigned int service; u64 nonce; u64 secret_id; - char reply_buf[128]; /* big enough for encrypted blob */ + char enc_buf[CEPHX_AU_ENC_BUF_LEN] __aligned(8); }; struct ceph_x_info { |