Skip to content
  • Eric W. Biederman's avatar
    afs: Support interacting with multiple user namespaces · a0a5386a
    Eric W. Biederman authored
    
    
    Modify struct afs_file_status to store owner as a kuid_t and group as
    a kgid_t.
    
    In xdr_decode_AFSFetchStatus as owner is now a kuid_t and group is now
    a kgid_t don't use the EXTRACT macro.  Instead perform the work of
    the extract macro explicitly.  Read the value with ntohl and
    convert it to the appropriate type with make_kuid or make_kgid.
    Test if the value is different from what is stored in status and
    update changed.   Update the value in status.
    
    In xdr_encode_AFS_StoreStatus call from_kuid or from_kgid as
    we are computing the on the wire encoding.
    
    Initialize uids with GLOBAL_ROOT_UID instead of 0.
    Initialize gids with GLOBAL_ROOT_GID instead of 0.
    
    Cc: David Howells <dhowells@redhat.com>
    Acked-by: default avatarSerge Hallyn <serge.hallyn@canonical.com>
    Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
    a0a5386a