From patchwork Fri Oct 5 00:19:26 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Darrick J. Wong" X-Patchwork-Id: 10627073 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 ED3381926 for ; Fri, 5 Oct 2018 00:19:37 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DF693292FD for ; Fri, 5 Oct 2018 00:19:37 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D3D2B29301; Fri, 5 Oct 2018 00:19:37 +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=-8.0 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,MAILING_LIST_MULTI,RCVD_IN_DNSWL_HI, UNPARSEABLE_RELAY autolearn=unavailable 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 91BEC292FD for ; Fri, 5 Oct 2018 00:19:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727551AbeJEHPh (ORCPT ); Fri, 5 Oct 2018 03:15:37 -0400 Received: from userp2130.oracle.com ([156.151.31.86]:53298 "EHLO userp2130.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726038AbeJEHPh (ORCPT ); Fri, 5 Oct 2018 03:15:37 -0400 Received: from pps.filterd (userp2130.oracle.com [127.0.0.1]) by userp2130.oracle.com (8.16.0.22/8.16.0.22) with SMTP id w950JY5b012334; Fri, 5 Oct 2018 00:19:34 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=subject : from : to : cc : date : message-id : in-reply-to : references : mime-version : content-type : content-transfer-encoding; s=corp-2018-07-02; bh=OTfSOYTrp5qzQ2AxAJFohGWpTSraA72VZT8zy1Gaq8w=; b=X0XH2+jSUTfvintBzKQ4BwXeV2pBWmBTgHO/aM33222yVe8CJmR3+nbmWJUzTUZNJ6JZ PS+yOiHQW66tPulPWO+T0FMDE+x+EUJEeDP/T5nbQfF2twACTALt+dSSB9o/riPqgYel nYe1duu8zfzkgxWqb87XX5NpkIN7ulHIkGT+0KCVhpCbVHiydS/ZBU98RAWbaTIggS0V BJdd1EyVxNgz4Tu6vr69HGcWnZpfkuX8xDaMD7arljeQBjCUlq8laLheUDIi6fDk90Jr l3L/iE8d2PWfUwu0zOYfi0cS2pZE6NxdxAS29jRIf60huwTx+FT5lgdRYr7x73qWeVu8 ww== Received: from userv0022.oracle.com (userv0022.oracle.com [156.151.31.74]) by userp2130.oracle.com with ESMTP id 2mt0tu7kfn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 05 Oct 2018 00:19:34 +0000 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 w950JSk6016159 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 5 Oct 2018 00:19:28 GMT Received: from abhmp0015.oracle.com (abhmp0015.oracle.com [141.146.116.21]) by aserv0122.oracle.com (8.14.4/8.14.4) with ESMTP id w950JSnC032233; Fri, 5 Oct 2018 00:19:28 GMT Received: from localhost (/67.169.218.210) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 05 Oct 2018 00:19:27 +0000 Subject: [PATCH 3/6] xfs/189: skip 'barrier' mount option test on newer kernels From: "Darrick J. Wong" To: guaneryu@gmail.com, darrick.wong@oracle.com Cc: linux-xfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, fstests@vger.kernel.org Date: Thu, 04 Oct 2018 17:19:26 -0700 Message-ID: <153869876687.26648.3788433504474045378.stgit@magnolia> In-Reply-To: <153869874763.26648.516233620615833277.stgit@magnolia> References: <153869874763.26648.516233620615833277.stgit@magnolia> User-Agent: StGit/0.17.1-dirty MIME-Version: 1.0 X-Proofpoint-Virus-Version: vendor=nai engine=5900 definitions=9036 signatures=668706 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 mlxscore=0 mlxlogscore=773 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1807170000 definitions=main-1810050002 Sender: linux-fsdevel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-fsdevel@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP From: Darrick J. Wong Starting in Linux 4.19 the 'barrier' and 'nobarrier' mount options were removed. If mount complains about a bad option when we remount with 'barrier', just skip the test. Signed-off-by: Darrick J. Wong --- tests/xfs/189 | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/tests/xfs/189 b/tests/xfs/189 index c1c52a22..2a2682ef 100755 --- a/tests/xfs/189 +++ b/tests/xfs/189 @@ -165,7 +165,19 @@ _test_remount_barrier() echo # mention barrier explicitly even if it's currently the default just to be sure - _try_scratch_mount -o barrier + _try_scratch_mount -o barrier > $tmp.barriermount 2>&1 + + # If the kernel doesn't recognize 'barrier' as a mount option then + # just fake the output. The barrier option was removed in 4.19. + if grep -q "bad option" $tmp.barriermount; then + cat << ENDL +SCRATCH_DEV on SCRATCH_MNT type xfs (rw) +SCRATCH_DEV on SCRATCH_MNT type xfs (rw,nobarrier) +SCRATCH_DEV on SCRATCH_MNT type xfs (rw) +ENDL + return + fi + [ $? -eq 0 ] || echo "mount failed unexpectedly!" _check_mount rw