From patchwork Sat Nov 10 11:51:42 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Christoph Hellwig X-Patchwork-Id: 10677091 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id B004B139B for ; Sat, 10 Nov 2018 11:51:57 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 9F29B2CF08 for ; Sat, 10 Nov 2018 11:51:57 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 93F2B2CF6D; Sat, 10 Nov 2018 11:51:57 +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=-7.7 required=2.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,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 336722CF08 for ; Sat, 10 Nov 2018 11:51:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729013AbeKJVgm (ORCPT ); Sat, 10 Nov 2018 16:36:42 -0500 Received: from bombadil.infradead.org ([198.137.202.133]:35900 "EHLO bombadil.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728983AbeKJVgm (ORCPT ); Sat, 10 Nov 2018 16:36:42 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=bombadil.20170209; h=Content-Transfer-Encoding: MIME-Version:References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender :Reply-To:Content-Type:Content-ID:Content-Description:Resent-Date:Resent-From :Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help: List-Unsubscribe:List-Subscribe:List-Post:List-Owner:List-Archive; bh=XJwnmLnaFIEuzGp0nkPcSPThSJtpj9DQFVRh+JPJkIc=; b=lIEp7fa+r+5N9GbYQrcBeK/n4f 89TVAMlkLSLO7hMp3E85r+WeQTfBk+g9pC6Q1xRQwvoV0PSVWkDBzHnumtCIQE6lgjOUrn5Z0J9QD hD4u0LwYjgsZWYIpeP9ruxjzf8+7DOy65HECfBX6HrPTgdDtjSQhU5v9IF/zRuthiNQViRRUPw+zX THtc7/fLVDgHrvibFDL2qcrCQwgMdfOA4nK4bR3qLMKsbYCTEnbGFwsZJcF2MtanZQvPoZBFSIxvs V9mHLwYO0yghGTzHzbUF/TwDcvYWlJG67IC3VoHlgB+psubndCjw0Udp6iALuan1H1uIXUQREKMI3 IdLg1A8w==; Received: from 089144211136.atnat0020.highway.a1.net ([89.144.211.136] helo=localhost) by bombadil.infradead.org with esmtpsa (Exim 4.90_1 #2 (Red Hat Linux)) id 1gLRnv-0000ca-Ti; Sat, 10 Nov 2018 11:51:56 +0000 From: Christoph Hellwig To: guaneryu@gmail.com Cc: fstests@vger.kernel.org, linux-xfs@vger.kernel.org Subject: [PATCH 2/5] generic: don't assume preallocation is supported when reflinks are supported Date: Sat, 10 Nov 2018 12:51:42 +0100 Message-Id: <20181110115145.30356-3-hch@lst.de> X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181110115145.30356-1-hch@lst.de> References: <20181110115145.30356-1-hch@lst.de> MIME-Version: 1.0 X-SRS-Rewrite: SMTP reverse-path rewritten from by bombadil.infradead.org. See http://www.infradead.org/rpr.html Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Various reflink tests currently use fallocate to preallocate space without first checking that preallocations are supported. Add explicit checks. Signed-off-by: Christoph Hellwig --- tests/generic/176 | 1 + tests/generic/372 | 1 + tests/generic/414 | 1 + tests/generic/415 | 1 + tests/generic/447 | 1 + tests/generic/515 | 1 + 6 files changed, 6 insertions(+) diff --git a/tests/generic/176 b/tests/generic/176 index e0c0f225..a084578a 100755 --- a/tests/generic/176 +++ b/tests/generic/176 @@ -31,6 +31,7 @@ _cleanup() _supported_os Linux _require_scratch_reflink _require_cp_reflink +_require_xfs_io_command "fpunch" _require_test_program "punch-alternating" rm -f "$seqres.full" diff --git a/tests/generic/372 b/tests/generic/372 index 44914453..21cf283b 100755 --- a/tests/generic/372 +++ b/tests/generic/372 @@ -31,6 +31,7 @@ _cleanup() _supported_os Linux _supported_fs generic _require_scratch_reflink +_require_xfs_io_command "falloc" _require_xfs_io_command "fiemap" _require_scratch_explicit_shared_extents diff --git a/tests/generic/414 b/tests/generic/414 index 7c76d580..f9f26744 100755 --- a/tests/generic/414 +++ b/tests/generic/414 @@ -32,6 +32,7 @@ _cleanup() _supported_os Linux _supported_fs generic _require_scratch_reflink +_require_xfs_io_command "falloc" _require_xfs_io_command "fiemap" echo "Format and mount" diff --git a/tests/generic/415 b/tests/generic/415 index 14fbc232..0b7554ff 100755 --- a/tests/generic/415 +++ b/tests/generic/415 @@ -34,6 +34,7 @@ _supported_fs generic _supported_os Linux _require_scratch_reflink _require_cp_reflink +_require_xfs_io_command "fpunch" _scratch_mkfs >> $seqres.full 2>&1 || _fail "mkfs failed" _scratch_mount || _fail "mount failed" diff --git a/tests/generic/447 b/tests/generic/447 index 3775e49f..1e7cb3c8 100755 --- a/tests/generic/447 +++ b/tests/generic/447 @@ -32,6 +32,7 @@ _supported_os Linux _require_scratch_reflink _require_cp_reflink _require_test_program "punch-alternating" +_require_xfs_io_command "fpunch" rm -f "$seqres.full" diff --git a/tests/generic/515 b/tests/generic/515 index 1ae9fbfe..f9e0b3be 100755 --- a/tests/generic/515 +++ b/tests/generic/515 @@ -31,6 +31,7 @@ _cleanup() _supported_fs generic _supported_os Linux _require_scratch_reflink +_require_xfs_io_command "falloc" rm -f $seqres.full