From patchwork Wed Nov 23 02:10:54 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Darrick J. Wong" X-Patchwork-Id: 9442487 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 C5552606DB for ; Wed, 23 Nov 2016 02:11:02 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id A98A620587 for ; Wed, 23 Nov 2016 02:11:02 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 9DC95205B0; Wed, 23 Nov 2016 02:11:02 +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, UNPARSEABLE_RELAY 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 2158420587 for ; Wed, 23 Nov 2016 02:11:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754325AbcKWCLB (ORCPT ); Tue, 22 Nov 2016 21:11:01 -0500 Received: from aserp1040.oracle.com ([141.146.126.69]:47884 "EHLO aserp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755351AbcKWCLA (ORCPT ); Tue, 22 Nov 2016 21:11:00 -0500 Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by aserp1040.oracle.com (Sentrion-MTA-4.3.2/Sentrion-MTA-4.3.2) with ESMTP id uAN2Aubq009351 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 23 Nov 2016 02:10:56 GMT Received: from aserv0122.oracle.com (aserv0122.oracle.com [141.146.126.236]) by userv0022.oracle.com (8.14.4/8.14.4) with ESMTP id uAN2AtSf027938 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Wed, 23 Nov 2016 02:10:56 GMT Received: from abhmp0002.oracle.com (abhmp0002.oracle.com [141.146.116.8]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id uAN2At1i014620; Wed, 23 Nov 2016 02:10:55 GMT Received: from localhost (/24.21.211.40) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Tue, 22 Nov 2016 18:10:55 -0800 Subject: [PATCH 1/3] generic/182: retain existing btrfs behavior when len == 0 From: "Darrick J. Wong" To: david@fromorbit.com, eguan@redhat.com, darrick.wong@oracle.com Cc: linux-xfs@vger.kernel.org, fstests@vger.kernel.org Date: Tue, 22 Nov 2016 18:10:54 -0800 Message-ID: <147986705412.27133.3961713804630246198.stgit@birch.djwong.org> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 X-Source-IP: userv0022.oracle.com [156.151.31.74] Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Since btrfs doesn't interpret len=0 as "go to EOF", test for that instead. Signed-off-by: Darrick J. Wong --- tests/generic/182 | 3 ++- tests/generic/182.out | 2 -- 2 files changed, 2 insertions(+), 3 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe fstests" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/tests/generic/182 b/tests/generic/182 index f484399..dacb989 100755 --- a/tests/generic/182 +++ b/tests/generic/182 @@ -1,7 +1,8 @@ #! /bin/bash # FS QA Test No. 182 # -# Test the convention that dedupe with length == 0 means "to the end of fileA" +# Test the convention that dedupe with length == 0 doesn't mean "to the end of +# fileA" # - Create a file. # - Try to dedupe "zero" bytes (which means dedupe to EOF). # - Check that the dedupe happened. diff --git a/tests/generic/182.out b/tests/generic/182.out index 049a3ee..9841b76 100644 --- a/tests/generic/182.out +++ b/tests/generic/182.out @@ -1,12 +1,10 @@ QA output created by 182 Create the original files -dedupe: Extents did not match. f4820540fc0ac02750739896fe028d56 TEST_DIR/test-182/file1 69ad53078a16243d98e21d9f8704a071 TEST_DIR/test-182/file2 69ad53078a16243d98e21d9f8704a071 TEST_DIR/test-182/file2.chk Compare against check files Make the original file almost dedup-able -dedupe: Extents did not match. f4820540fc0ac02750739896fe028d56 TEST_DIR/test-182/file1 158d4e3578b94b89cbb44493a2110fb9 TEST_DIR/test-182/file2 158d4e3578b94b89cbb44493a2110fb9 TEST_DIR/test-182/file2.chk