]> git.proxmox.com Git - mirror_qemu.git/commit - hw/9pfs/9p-local.c
hw/9pfs: Use little-endian format for xattr values
authorAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Sun, 3 Aug 2014 11:32:55 +0000 (17:02 +0530)
committerAneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
Tue, 2 Sep 2014 21:02:33 +0000 (16:02 -0500)
commitf8ad4a89e99848a554b0049d7a612f5a585b7231
tree299afdbda123f887f91011eafae01253d3dfc946
parent30eaca3acdf17d7bcbd1213eb149c02037edfb0b
hw/9pfs: Use little-endian format for xattr values

With security_model=mapped-xattr, we encode the uid,gid and other file
attributes as extended attributes of the file. We save them under
user.virtfs.* namespace.

Use little-endian encoding for on-disk values. This enables us to export
the same directory from both little-endian and big-endian hosts.

NOTE: This will break big-endian host that have virtFS exports
using security model mapped-xattr. They will have to use external tools
to convert the xattr to little-endian format.

Signed-off-by: Aneesh Kumar K.V <aneesh.kumar@linux.vnet.ibm.com>
hw/9pfs/virtio-9p-local.c