From patchwork Tue Apr 18 18:17:23 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Amir Goldstein X-Patchwork-Id: 9685973 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 486E6602C2 for ; Tue, 18 Apr 2017 18:17:24 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 3DC0C1FFD6 for ; Tue, 18 Apr 2017 18:17:24 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 329E2201F5; Tue, 18 Apr 2017 18:17:24 +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.3 required=2.0 tests=BAYES_00, DKIM_ADSP_CUSTOM_MED, DKIM_SIGNED, FREEMAIL_FROM, RCVD_IN_DNSWL_HI, RCVD_IN_SORBS_SPAM, T_DKIM_INVALID 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 C830820373 for ; Tue, 18 Apr 2017 18:17:23 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753623AbdDRSRX (ORCPT ); Tue, 18 Apr 2017 14:17:23 -0400 Received: from mail-wm0-f67.google.com ([74.125.82.67]:36528 "EHLO mail-wm0-f67.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752936AbdDRSRV (ORCPT ); Tue, 18 Apr 2017 14:17:21 -0400 Received: by mail-wm0-f67.google.com with SMTP id q125so882545wmd.3; Tue, 18 Apr 2017 11:17:20 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=j3vULE7UV/Cfl5KuFKXGrRQE94DsPYbI6ChHXcGgRPM=; b=gioW/ubRJc0xaANZaeEvtQJsBXMJo2VbUyfz3o4kdEf90ssoM2X9c5zDRBZwVqxx8U h6+E/sWi8UB5b0LIrw8Rjj+jQ9s9O58mROMwq/Z+cELap2Tuvewq+O3/j2ZfeLBTKMFc UQyjczlguM+WWTDLMbsYoHyxcNbGR66zfycL5ORv9g82qvsxZ6XKw4YMDH9h4yuVtB7k 3K+gIeyMCtpFV10izQ+3EnU4OiqdnHWWtEmOVHkr6qR2yaOo5C1+NR+hBX3GHm7+EHgr +i0Ug+HzsnofHlM7e64CqYbQ62ffvno1rjyXgyZYfOj3NZWj/crJshGLIwgxyHGbX2DT F0jA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=j3vULE7UV/Cfl5KuFKXGrRQE94DsPYbI6ChHXcGgRPM=; b=OVKISSklTlaVmlgnFgy23iEwSRCoJBiQXvICrm8OdMoosoX1q4OEZQw8EeUjiI2Ebp Kp494OvnJ+ZeewNqXPP9/5/gKMq5veP52gXU+78rLTzVVijuGdmG0gYj0GZ/INxe2UU0 onlbrQQ53vjsPhjL042+qbjAyIN54yWlT0BvGPjIKf0I7MHiah4w3COxSsEvZ93McoTL aUowUFXfN1a3BBm2l2lPS32ljzw9Z0I/WcV6uh1OIoL2h6Z17LQF8+rglCdrN7kEjUoG o4rnq4FLdj/pf1UuieR/4LQQCYz9P9Xn0sNc1S58Eh8GM/JJ4mvW1ahxJkbDxGHd2V3n xbHg== X-Gm-Message-State: AN3rC/4B6GeMnyJU1Q3I1vH2ZjULtB6xGDAHuRsXKtZNsRVm1lzl9GSl L74VWO8GKFKeHA== X-Received: by 10.28.126.77 with SMTP id z74mr15233700wmc.15.1492539440205; Tue, 18 Apr 2017 11:17:20 -0700 (PDT) Received: from amir-VirtualBox.lan (bzq-79-179-55-127.red.bezeqint.net. [79.179.55.127]) by smtp.gmail.com with ESMTPSA id v126sm15958709wmd.11.2017.04.18.11.17.18 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 18 Apr 2017 11:17:19 -0700 (PDT) From: Amir Goldstein To: Eryu Guan Cc: Miklos Szeredi , Trond Myklebust , Jeff Layton , "J . Bruce Fields" , fstests@vger.kernel.org, linux-unionfs@vger.kernel.org Subject: [PATCH 3/4] fstests: add helper _require_exportfs Date: Tue, 18 Apr 2017 21:17:23 +0300 Message-Id: <1492539444-25938-4-git-send-email-amir73il@gmail.com> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1492539444-25938-1-git-send-email-amir73il@gmail.com> References: <1492539444-25938-1-git-send-email-amir73il@gmail.com> Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Use open_by_handle -c to determine if filesystem supports NFS export --- common/rc | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/common/rc b/common/rc index 685b859..f24a21f 100644 --- a/common/rc +++ b/common/rc @@ -2857,6 +2857,15 @@ _require_freeze() [ $result -eq 0 ] || _notrun "$FSTYP does not support freezing" } +# Does NFS export work on this fs? +_require_exportfs() +{ + mkdir -p "$TEST_DIR"/export_test + $here/src/open_by_handle -c "$TEST_DIR"/export_test 2>&1 \ + || _notrun "$FSTYP does not support NFS export" +} + + # Does shutdown work on this fs? _require_scratch_shutdown() {