From patchwork Mon Jul 31 22:58:33 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ross Zwisler X-Patchwork-Id: 9873265 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 825CA6037D for ; Mon, 31 Jul 2017 22:59:59 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 80CFE28648 for ; Mon, 31 Jul 2017 22:59:59 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 5F29227C05; Mon, 31 Jul 2017 22:59:59 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 2652E2860D for ; Mon, 31 Jul 2017 22:59:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751862AbdGaW7i (ORCPT ); Mon, 31 Jul 2017 18:59:38 -0400 Received: from mga01.intel.com ([192.55.52.88]:17443 "EHLO mga01.intel.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751859AbdGaW7h (ORCPT ); Mon, 31 Jul 2017 18:59:37 -0400 Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga101.fm.intel.com with ESMTP/TLS/DHE-RSA-AES256-GCM-SHA384; 31 Jul 2017 15:59:37 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.41,304,1498546800"; d="scan'208";a="1178322240" Received: from theros.lm.intel.com ([10.232.112.77]) by fmsmga001.fm.intel.com with ESMTP; 31 Jul 2017 15:59:08 -0700 From: Ross Zwisler To: fstests@vger.kernel.org, linux-xfs@vger.kernel.org Cc: Ross Zwisler , Eric Sandeen , Dave Chinner , Jan Kara Subject: [PATCH] xfs_io: allow lsattr & lsproj on foreign filesystems Date: Mon, 31 Jul 2017 16:58:33 -0600 Message-Id: <20170731225833.11104-1-ross.zwisler@linux.intel.com> X-Mailer: git-send-email 2.9.4 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP The following commit: commit 73b54bb6a2fb ("xfs_io: allow chattr & chproj on foreign filesystems") allowed chattr and chproj to be run on non-xfs filesystems now that FS_IOC_FSSETXATTR is a generic vfs call. It failed to enable the corresponding lsattr and lsproj commands for those filesystems, though. Signed-off-by: Ross Zwisler Fixes: 73b54bb6a2fb ("xfs_io: allow chattr & chproj on foreign filesystems") Cc: Eric Sandeen Cc: Dave Chinner Cc: Jan Kara Reviewed-by: Darrick J. Wong --- io/attr.c | 2 +- io/open.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/io/attr.c b/io/attr.c index b8eec1b..728560e 100644 --- a/io/attr.c +++ b/io/attr.c @@ -353,7 +353,7 @@ attr_init(void) lsattr_cmd.args = _("[-R|-D|-a|-v]"); lsattr_cmd.argmin = 0; lsattr_cmd.argmax = 1; - lsattr_cmd.flags = CMD_NOMAP_OK; + lsattr_cmd.flags = CMD_NOMAP_OK | CMD_FOREIGN_OK; lsattr_cmd.oneline = _("list extended inode flags set on the currently open file"); lsattr_cmd.help = lsattr_help; diff --git a/io/open.c b/io/open.c index b50f068..f2ea7c3 100644 --- a/io/open.c +++ b/io/open.c @@ -812,7 +812,7 @@ open_init(void) lsproj_cmd.args = _("[-D | -R]"); lsproj_cmd.argmin = 0; lsproj_cmd.argmax = -1; - lsproj_cmd.flags = CMD_NOMAP_OK; + lsproj_cmd.flags = CMD_NOMAP_OK | CMD_FOREIGN_OK; lsproj_cmd.oneline = _("list project identifier set on the currently open file"); lsproj_cmd.help = lsproj_help;