(2) make "lfs setfacl" more like local client setfacl.
int ll_ioctl_getfacl(struct inode *inode, struct rmtacl_ioctl_data *ioc)
{
- struct ll_sb_info *sbi = ll_i2sbi(inode);
struct ptlrpc_request *req = NULL;
struct mdt_body *body;
char *cmd, *buf;
int rc, buflen;
ENTRY;
- if (!(sbi->ll_flags & LL_SBI_ACL) ||
- !(sbi->ll_flags & LL_SBI_RMT_CLIENT))
- RETURN(-EOPNOTSUPP);
-
LASSERT(ioc->cmd && ioc->cmd_len && ioc->res && ioc->res_len);
OBD_ALLOC(cmd, ioc->cmd_len);
rc = ioctl(fd, LL_IOC_SETFACL, &data);
close(fd);
- if (rc) {
+ if (errno == EOPNOTSUPP) {
+ fprintf(stderr, "setfacl: %s: %s\n", fname, strerror(errno));
+ rc = 1;
+ } else if (rc) {
err_msg("setfacl %s failed", fname);
} else {
printf("%s", out);