Skip to contentSkip to conversation

fscrypt: Remove __packed from fscrypt_policy

PATCH Applied Joe Richey 3 participants 3 messages Apr 6, 2017 – Apr 30, 2017

Subsystems (3)
lore
Share & tools
lore

Joe Richey

author
#0 lore raw

PATCH v2 1/1 fscrypt: Remove __packed from fscrypt_policy

From: Joe Richey <[email protected]>

This commit removes __packed from fscrypt_policy as it does not contain any implicit padding and does not refer to an on-disk structure. Even though this is a change to a UAPI file, no users will be broken as the structure doesn't change.

---
 include/uapi/linux/fs.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/uapi/linux/fs.h +1 -1
index 048a85e9f017..f6e1c54ac5e2 100644
@@ -279,7 +279,7 @@ struct fscrypt_policy {
 	__u8 filenames_encryption_mode;
 	__u8 flags;
 	__u8 master_key_descriptor[FS_KEY_DESCRIPTOR_SIZE];
-} __packed;
+};
 
 #define FS_IOC_SET_ENCRYPTION_POLICY	_IOR('f', 19, struct fscrypt_policy)
 #define FS_IOC_GET_ENCRYPTION_PWSALT	_IOW('f', 20, __u8[16])
Signature · 1 line
2.12.2.715.g7642488e1d-goog
#1 lore raw

Am 07.04.2017 um 01:14 schrieb Joe Richey:

Quoted 17 lines

From: Joe Richey <[email protected]>

This commit removes __packed from fscrypt_policy as it does not contain any implicit padding and does not refer to an on-disk structure. Even though this is a change to a UAPI file, no users will be broken as the structure doesn't change.

---
 include/uapi/linux/fs.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
include/uapi/linux/fs.h +0 -0
index 048a85e9f017..f6e1c54ac5e2 100644

include/uapi/linux/fs.h struct fscrypt_policy { · line 282

Quoted 5 lines
include/uapi/linux/fs.h +1 -1
@@ -279,7 +279,7 @@ struct fscrypt_policy {
 	__u8 filenames_encryption_mode;
 	__u8 flags;
 	__u8 master_key_descriptor[FS_KEY_DESCRIPTOR_SIZE];
-} __packed;
+};

Both patches are fine, just keep my Reviewed-by. :)

Thanks,
//richard