mirror of
https://github.com/Fishwaldo/linux-bl808.git
synced 2025-06-17 20:25:19 +00:00
udf: Adjust UDF_NAME_LEN to better reflect actual restrictions
Actual name length restriction is 254 bytes, this is used in 'ustr' structure, and this is what fits into UDF File Ident structures. And in most cases the constant is used as UDF_NAME_LEN-2. So, it's better to just modify the constant to make it closer to reality. Also, in some cases it's useful to have a separate constant for the maximum length of file name field in CS0 encoding in UDF File Ident structures. Also, remove the unused UDF_PATH_LEN constant. Signed-off-by: Andrew Gabbasov <andrew_gabbasov@mentor.com> Signed-off-by: Jan Kara <jack@suse.cz>
This commit is contained in:
parent
3e7fc2055c
commit
9fba70569d
4 changed files with 12 additions and 12 deletions
|
@ -2358,7 +2358,7 @@ static int udf_statfs(struct dentry *dentry, struct kstatfs *buf)
|
|||
le32_to_cpu(lvidiu->numDirs)) : 0)
|
||||
+ buf->f_bfree;
|
||||
buf->f_ffree = buf->f_bfree;
|
||||
buf->f_namelen = UDF_NAME_LEN - 2;
|
||||
buf->f_namelen = UDF_NAME_LEN;
|
||||
buf->f_fsid.val[0] = (u32)id;
|
||||
buf->f_fsid.val[1] = (u32)(id >> 32);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue