query for aclsupport per superblock
This commit is contained in:
parent
87f1005ea0
commit
c11e5ebce2
4 changed files with 11 additions and 3 deletions
|
|
@ -41,6 +41,7 @@ typedef struct __nfs41_superblock {
|
||||||
uint64_t maxwrite;
|
uint64_t maxwrite;
|
||||||
uint32_t layout_types;
|
uint32_t layout_types;
|
||||||
bool_t cansettime;
|
bool_t cansettime;
|
||||||
|
uint32_t aclsupport;
|
||||||
struct list_entry entry; /* position in nfs41_server.superblocks */
|
struct list_entry entry; /* position in nfs41_server.superblocks */
|
||||||
|
|
||||||
SRWLOCK lock;
|
SRWLOCK lock;
|
||||||
|
|
|
||||||
|
|
@ -83,7 +83,7 @@ static int get_superblock_attrs(
|
||||||
|
|
||||||
attr_request.arr[0] = FATTR4_WORD0_SUPPORTED_ATTRS |
|
attr_request.arr[0] = FATTR4_WORD0_SUPPORTED_ATTRS |
|
||||||
FATTR4_WORD0_CANSETTIME | FATTR4_WORD0_MAXREAD |
|
FATTR4_WORD0_CANSETTIME | FATTR4_WORD0_MAXREAD |
|
||||||
(uint32_t)(FATTR4_WORD0_MAXWRITE);
|
(uint32_t)(FATTR4_WORD0_MAXWRITE) | FATTR4_WORD0_ACLSUPPORT;
|
||||||
attr_request.arr[1] = FATTR4_WORD1_FS_LAYOUT_TYPE |
|
attr_request.arr[1] = FATTR4_WORD1_FS_LAYOUT_TYPE |
|
||||||
FATTR4_WORD1_TIME_DELTA;
|
FATTR4_WORD1_TIME_DELTA;
|
||||||
attr_request.count = 2;
|
attr_request.count = 2;
|
||||||
|
|
@ -122,13 +122,15 @@ static int get_superblock_attrs(
|
||||||
if (!bitmap_isset(&info.attrmask, 1, FATTR4_WORD1_TIME_DELTA))
|
if (!bitmap_isset(&info.attrmask, 1, FATTR4_WORD1_TIME_DELTA))
|
||||||
superblock->time_delta.seconds = 1;
|
superblock->time_delta.seconds = 1;
|
||||||
|
|
||||||
|
superblock->aclsupport = info.aclsupport;
|
||||||
dprintf(SBLVL, "attributes for fsid(%llu,%llu): "
|
dprintf(SBLVL, "attributes for fsid(%llu,%llu): "
|
||||||
"maxread=%llu, maxwrite=%llu, layout_types: 0x%X, "
|
"maxread=%llu, maxwrite=%llu, layout_types: 0x%X, "
|
||||||
"cansettime=%u, time_delta={%ll,%u}\n",
|
"cansettime=%u, time_delta={%llu,%u}, aclsupport=%d\n",
|
||||||
superblock->fsid.major, superblock->fsid.minor,
|
superblock->fsid.major, superblock->fsid.minor,
|
||||||
superblock->maxread, superblock->maxwrite,
|
superblock->maxread, superblock->maxwrite,
|
||||||
superblock->layout_types, superblock->cansettime,
|
superblock->layout_types, superblock->cansettime,
|
||||||
superblock->time_delta.seconds, superblock->time_delta.nseconds);
|
superblock->time_delta.seconds, superblock->time_delta.nseconds,
|
||||||
|
superblock->aclsupport);
|
||||||
out:
|
out:
|
||||||
return status;
|
return status;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -216,6 +216,7 @@ typedef struct __nfs41_file_info {
|
||||||
uint32_t owner_len;
|
uint32_t owner_len;
|
||||||
unsigned char owner_group[NFS4_OPAQUE_LIMIT];
|
unsigned char owner_group[NFS4_OPAQUE_LIMIT];
|
||||||
uint32_t owner_group_len;
|
uint32_t owner_group_len;
|
||||||
|
uint32_t aclsupport;
|
||||||
} nfs41_file_info;
|
} nfs41_file_info;
|
||||||
|
|
||||||
#endif /* !__NFS41_DAEMON_TYPES_H__ */
|
#endif /* !__NFS41_DAEMON_TYPES_H__ */
|
||||||
|
|
|
||||||
|
|
@ -1627,6 +1627,10 @@ static bool_t decode_file_attrs(
|
||||||
if (!xdr_u_int32_t(xdr, &info->rdattr_error))
|
if (!xdr_u_int32_t(xdr, &info->rdattr_error))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
}
|
}
|
||||||
|
if (attrs->attrmask.arr[0] & FATTR4_WORD0_ACLSUPPORT) {
|
||||||
|
if (!xdr_u_int32_t(xdr, &info->aclsupport))
|
||||||
|
return FALSE;
|
||||||
|
}
|
||||||
if (attrs->attrmask.arr[0] & FATTR4_WORD0_CANSETTIME) {
|
if (attrs->attrmask.arr[0] & FATTR4_WORD0_CANSETTIME) {
|
||||||
if (!xdr_bool(xdr, &info->cansettime))
|
if (!xdr_bool(xdr, &info->cansettime))
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue