generic/020: limit xattr value by 3802 bytes
PATCH 1/1 generic/020: limit xattr value by 3802 bytes
HFS+ implementation supports only inline extended attributes. The size of value for inline xattr is limited by 3802 bytes [1].
[1] https://elixir.bootlin.com/linux/v6.19-rc2/source/include/linux/hfs_common.h#L626
Signed-off-by Viacheslav Dubeyko <[email protected]>
--- tests/generic/020 | 5 +++++ 1 file changed, 5 insertions(+)
tests/generic/020 +5 -0
@@ -168,6 +168,11 @@ _attr_get_maxval_size() fi max_attrval_size=$((65536 - $size - $selinux_size - $max_attrval_namelen)) ;; + hfsplus) + # HFS+ implementation supports only inline extended attributes. + # The size of value for inline xattr is limited by 3802 bytes. + max_attrval_size=3802 + ;; *) # Assume max ~1 block of attrs BLOCK_SIZE=`_get_block_size $TEST_DIR`
Signature · 1 line
2.43.0
Quoted 15 lines · Viacheslav Dubeyko
HFS+ implementation supports only inline extended attributes. The size of value for inline xattr is limited by 3802 bytes [1].
[1] https://elixir.bootlin.com/linux/v6.19-rc2/source/include/linux/hfs_common.h#L626
Signed-off-by Viacheslav Dubeyko <[email protected]>--- tests/generic/020 | 5 +++++ 1 file changed, 5 insertions(+)tests/generic/020 +0
-0
tests/generic/020 _attr_get_maxval_size() · line 175
Quoted 8 lines
tests/generic/020 +5
-0@@ -168,6 +168,11 @@ _attr_get_maxval_size() fi max_attrval_size=$((65536 - $size - $selinux_size - $max_attrval_namelen)) ;; + hfsplus) + # HFS+ implementation supports only inline extended attributes. + # The size of value for inline xattr is limited by 3802 bytes. + max_attrval_size=3802 + ;;
Glad to get supportes from HFS list, this patch looks good to me.
Reviewed-by Zorro Lang <[email protected]>
Quoted 6 lines
tests/generic/020 +0
-0*) # Assume max ~1 block of attrs BLOCK_SIZE=`_get_block_size $TEST_DIR`Signature · 1 line
2.43.0