Squashfs: fix use of __le64 annotated variable
This fixes a sparse with endian checking warning. Signed-off-by: Phillip Lougher <phillip@lougher.demon.co.uk>
This commit is contained in:
parent
f6f94e2ab1
commit
07724586b4
|
@ -158,17 +158,18 @@ static int squashfs_xattr_get(struct inode *inode, int name_index,
|
||||||
strncmp(target, name, name_size) == 0) {
|
strncmp(target, name, name_size) == 0) {
|
||||||
/* found xattr */
|
/* found xattr */
|
||||||
if (type & SQUASHFS_XATTR_VALUE_OOL) {
|
if (type & SQUASHFS_XATTR_VALUE_OOL) {
|
||||||
__le64 xattr;
|
__le64 xattr_val;
|
||||||
|
u64 xattr;
|
||||||
/* val is a reference to the real location */
|
/* val is a reference to the real location */
|
||||||
err = squashfs_read_metadata(sb, &val, &start,
|
err = squashfs_read_metadata(sb, &val, &start,
|
||||||
&offset, sizeof(val));
|
&offset, sizeof(val));
|
||||||
if (err < 0)
|
if (err < 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
err = squashfs_read_metadata(sb, &xattr, &start,
|
err = squashfs_read_metadata(sb, &xattr_val,
|
||||||
&offset, sizeof(xattr));
|
&start, &offset, sizeof(xattr_val));
|
||||||
if (err < 0)
|
if (err < 0)
|
||||||
goto failed;
|
goto failed;
|
||||||
xattr = le64_to_cpu(xattr);
|
xattr = le64_to_cpu(xattr_val);
|
||||||
start = SQUASHFS_XATTR_BLK(xattr) +
|
start = SQUASHFS_XATTR_BLK(xattr) +
|
||||||
msblk->xattr_table;
|
msblk->xattr_table;
|
||||||
offset = SQUASHFS_XATTR_OFFSET(xattr);
|
offset = SQUASHFS_XATTR_OFFSET(xattr);
|
||||||
|
|
Loading…
Reference in New Issue