From patchwork Fri Aug 13 01:59:32 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anand Jain X-Patchwork-Id: 12434513 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id DCA44C4338F for ; Fri, 13 Aug 2021 01:59:57 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id C3C0460FBF for ; Fri, 13 Aug 2021 01:59:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234657AbhHMCAW (ORCPT ); Thu, 12 Aug 2021 22:00:22 -0400 Received: from mx0a-00069f02.pphosted.com ([205.220.165.32]:39860 "EHLO mx0a-00069f02.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229919AbhHMCAW (ORCPT ); Thu, 12 Aug 2021 22:00:22 -0400 Received: from pps.filterd (m0246627.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 17D1vMw9029444; Fri, 13 Aug 2021 01:59:56 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2021-07-09; bh=0vRsLyY6G4abi4FEb4lsqZ9EwtzkCWCytQGmWfdRgtY=; b=zD0JdcRWwsG9IABfiwfv+jfPv4Jv12M1uQZgp3jkfqjV1sNdnlkZ94c0pTvgauBt/F5D L9c9WXYBYMeiQ6FEf0HQoaUTFoL81G27Y1sSiagMCy5/07YQopSCWYciA0VjeHLXGmLv e6nulLatw7eZWKT3ZgYsSrQosPGegqYUFRucayMij/3QdyRkD0lJ1Ayph4LITQ8hQjgz SJnprOI5AE84bzreIHy2JhBkeFEGOyQG5jumx1hn9dItp3YfYJyBt75+dwmCRCORle6N a9vxF3peWi9nB2CZfBsGE48LL3bUIhWLdacb7+lmSFL32H2cQwBYIp2IXdeRFseE+8Z1 ng== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2020-01-29; bh=0vRsLyY6G4abi4FEb4lsqZ9EwtzkCWCytQGmWfdRgtY=; b=iAzaPRssip/Tt7q+ogH/ehBGMcvDPWJAyQ9zdKvnNpGPEB/NffdXB8ueJPjq7igsSHUr TSXBq1xhzd/SFGv2xvADLOaXTx90Me9tyt+EGU57raBCdPQk0fqYhqzdT+HV/5OC0B8K 4ffWp5cWlpwMDejZ2v3X46C8ATDCiNcPK3d33oVlqGSYrfQK05B6QC5lcyT4oJScCma6 Ihup40w15h9dIqJS1GNqfuQ18kvG77+zF9kC8EjNMkb5IXpTazcWwlxqS/b+Rx3FtrmA Wqh0pAoc6TNT07Vl9CCkMqOp7CNIPXt/5Qwdj8L5JShgzZgx9JFdxqzvbXNjyTfOVFPz qA== Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by mx0b-00069f02.pphosted.com with ESMTP id 3acd64cbtn-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 01:59:55 +0000 Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 17D1udRt112637; Fri, 13 Aug 2021 01:59:54 GMT Received: from nam11-bn8-obe.outbound.protection.outlook.com (mail-bn8nam11lp2173.outbound.protection.outlook.com [104.47.58.173]) by aserp3030.oracle.com with ESMTP id 3abx3yv9md-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 01:59:54 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=hQAzVG42cgYLta6w+BQ8Bc/lVCUsqqWJg/L6YwY262JMbVB8saFAzfA+svTH3E6lSCTMUZv+bfHLN4iZSsMSNEzWrNojCeBKXDt2GQ3fhgtwPLxE1l9WBsFzo61+OD+9DF+W3K3GubDQICIOVV4UM22WeTAOItr53YJoHHFvjofxVomD5H6Dn/ElfoJ2DcsF7rK3N6XzcK6hak/hyGAmFafbk7SkF4QABknUYPFsO0VG61v3mf3yTV3hISmDihmKjshCeaU6x/ffSG4uc0MxIjhyr6JCYQwj9BDzH6xqZsnZjZso+DLcEFlbr9u6Bq+iS3FKtbhYfM124i7Uee6q+w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0vRsLyY6G4abi4FEb4lsqZ9EwtzkCWCytQGmWfdRgtY=; b=jGBtR++SiCK8cULfx9nWFnEgG4j6VytGIuCQ2fLVu8E4R8lQ5VUGj/eEFon5kTPp0lg8s+HINVWVY0u1zZl+YP2u0qpXSxbo06tu/WkvURDY9XbvI8jMO1V4t6fvaUzo0PqCONCpmTFIQCufU27CQh5ye/GdcUAHKOMNIXw1rp4Z8thKEkEYlkOmG1hNE4JLw+RarcTlIlaNXSQoRVtuKdpYEg5oEkivbJTkeZN44EDaUwfyXVS21ccrTp3CmSMFVZfC6BEcrlA93iJEH4KNZvob4TXo7BMtePWh2Yf7HsAKBsCTQoUAsKxboYH4Rq0blZVWOBXhPU14dYfsE8tkBA== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=0vRsLyY6G4abi4FEb4lsqZ9EwtzkCWCytQGmWfdRgtY=; b=rsp8DTgT4ZlJ5nta20LmocF6TbYmrZoGXtXHzyT/5qmijVpWCUiuwKFVZn7XHLmBFqF6Chd8Y8h8sWkkXVZLuNjHlNI+1w7SGvbV4Npq2gEHusP0hZfbQDJ3daEnKCI1iRleEK8jZpCCq4+HuizPEP2/vSHCUsl49evIT7McAxM= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=oracle.com; Received: from MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) by BL0PR10MB2771.namprd10.prod.outlook.com (2603:10b6:208:7b::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.15; Fri, 13 Aug 2021 01:59:53 +0000 Received: from MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a]) by MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a%4]) with mapi id 15.20.4394.025; Fri, 13 Aug 2021 01:59:53 +0000 From: Anand Jain To: fstests@vger.kernel.org Cc: linux-btrfs@vger.kernel.org Subject: [PATCH 1/4] rc: debug add _scratch_mount_options to the _scratch_mount Date: Fri, 13 Aug 2021 09:59:32 +0800 Message-Id: <339e6b40db7628a8828c78f49c75d12e375d0004.1628818510.git.anand.jain@oracle.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: X-ClientProxiedBy: SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) To MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (39.109.186.25) by SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.15 via Frontend Transport; Fri, 13 Aug 2021 01:59:51 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3e4cb6af-4733-4108-8c50-08d95dfe0a47 X-MS-TrafficTypeDiagnostic: BL0PR10MB2771: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:3826; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: Ow8kInkNavAwXRoqy5Ke5icd9kkarXi/kz3UdjEX1a1+oCwDkf6dDzYcS+j2nAhRUZTOFBtnQcFhFMWdni6p3nA2ZXGoNfVYcsKSCh/uel0e1+TXJlLmHe0/w+Y9WI/8F2KOPrvQa5A0liR/b8c72vA/hBaprMeaWMMBud/8jViZSeWXK72BCcN71rHyqTnCNA9DxaAMVajDj803MG745DSOULsUr6kpzgdRWYJ1gcwj/MAEtbATDhDsELWj+O+pPaJlq9j0rRklHuyQUCav1E0B7jnwzqPFxm5BLvzi5mY0S1xFSJvuW/257YvDNTXL0X9VW23TU2Bwly1TzzhD9aY/7QWpfMLAFjG9swmuooyRhN01OV6AEJXAbvkwa7qXmlxL+x5V6YQnQ1+OqpiV3PpDf68ZHVDfKGBpHR6J3QjAQuS8+NgIcXNeJZblBppJNZWrwthOWYY6CMEYqz0N8fFWDY6olMNQYry6p2Ygu2w8lnxDiJQDp9s5M23zg7fDbR2XE1t0pUcKHpyxflmA54dDQjInoh2AcPJD8pYXBvAfW6NxKMrlkqOLGDj3bOUXW+RcyIw6SDO1P/HYUYZGNIIKWLzDjUPN4brnEEi5Fezw6S+PrC5euunpkK7wR/AQJOL9QQ0eGftLu3EuU03gNEKDisT93UGDtyznwvOQXh/JWr1L3viCcNHJBHFLx2TvPFK5IVdIfKFhYWUNBxWUbA== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MN2PR10MB4128.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(396003)(366004)(136003)(39860400002)(376002)(346002)(956004)(2616005)(44832011)(8936002)(8676002)(26005)(66476007)(316002)(52116002)(2906002)(478600001)(186003)(66556008)(66946007)(6916009)(6512007)(6486002)(4744005)(450100002)(6506007)(86362001)(4326008)(6666004)(38350700002)(38100700002)(5660300002)(83380400001)(36756003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: wGpOUqdTtaZTv6U+QKAUkJWzElpAgQtXRYt/uFhhRBCnKLZ4yRegUt3utNcpAet/hKXE3jjWUnR1k8ZwghHJ7Wh+j55/CIKxm4agxxGl7NRf9G29zievPAQ1AdxdA1D2frLyVg6AvCkyPX+SPAAmLKcCC+ux9g+wRYfworsJbhxWcrV9YL2t7T78kth0UwrkudHddVs4v/zjHVJMw6kXfmsfN256xiCQK62MsQFhLdzKRPBkLOkBvccS9qfFefzJzcAh1DUWqg6DGfsyGjPN+01IugIGqS0wy0ddUiaa3/4lv2ZyIao489o6ZI3FpDjk4cx2WGRioug437JuQrmwYI7xcVqjPsQEwil7C37Vzt6rBLpqjgN35wGvLIBnG27bdmtZq4tIh7t5mUzrb9uhc3WZhr3M1mciFkvaPokRDVSvDBrFsrHFGXTalHvEuuZEaYY1U/U0lZZoF/U4yl/0BOp2/10azOzeU0Dmewihz6t1odasVkXnPtZ2dLSgvZl5fzXt4eUiRRNrCsSyD2mMB3Wk3j1i7kgGsl4lUzHF+DTVapUg4QbmxXysUbaqc5dBrMyGPrSfJYS+l3F8WQYFF53k6UoLm8U+eK2bOFu5p2f1x8QzvUlIqCEy8Ec85yCZHslD4XfP3hn41Ce5bolzMkVit7FeSlEiQwGjPL+mX9oiqgwEmiUl4T+moVDDhrOZPWDM6gYFXcFpc2KZRCs58jyXqB4qzxL1MJOzq3vHrBfS00sjhK/Xb1IWKe+hlX7JkSKOn2W1FLtXfVUIO06LPdFfzlbjiZ3SKAXaqTVBf/l2god4AGr3e9G92ZWkJkBT0w93BSlOvSlA3PiwYnAXwaC+bAc4E51tcsvSZYsy/0uPSiX243gkaBsvWA2f8H3rMaCrpZSnbaKqyx8GGIBhxRdq2tWFFKx8xgh8wNw+mzc5MGT8NQh/oUHWiqnG2euZNquKYtgztzEIiliklwmayhGx99GgDmQBD9r64Kb6B/ggHMBoZvQvJT/V7krrUMTPSlmSIz8UM7V5aciXIfuAvvgyi35jOa9YkNllZvqa2qm1+p3gRjimVfdvHRrYE0NOR3xRnh2eTYA7xM+IaE6oLmnrAlzIlH2Hma9pvI5C3KmR8TXxZ0X/iO54WM+/j2Cfd25/qvFYXf0vBkuYH2lZvXWTLJZWqzd4XXsx+1mTCb7gRbMN7bwY1Vn1lFHUNbQegcH55LwbxSOVMTSvkSk8hAWlyyp+olqSo4apPS3Gs/1pkBgnEWbFf8cksXr95bdd5wGj5yvvXG1QlW7TsSIf/66o6jU9N7dSLG0dJArnFqamNtU7mElZNq7LjALGqxHU X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 3e4cb6af-4733-4108-8c50-08d95dfe0a47 X-MS-Exchange-CrossTenant-AuthSource: MN2PR10MB4128.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Aug 2021 01:59:52.9335 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: uLOf5qvzMwRnp4eLqfdvcWX3kumk87NgFRUDFTEf4zGQ5ejG4u2HalfUcJN0hJGwKY5E8wFLpADVd/5FiPVgEA== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR10MB2771 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=10074 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 mlxscore=0 bulkscore=0 spamscore=0 phishscore=0 mlxlogscore=999 suspectscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2107140000 definitions=main-2108130010 X-Proofpoint-GUID: e9_UlDcnm5NC2cGGKv2DoyaM_CY0rXVQ X-Proofpoint-ORIG-GUID: e9_UlDcnm5NC2cGGKv2DoyaM_CY0rXVQ Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org When the _scratch_mount fails, there isn't any clue on why it failed as of now, change this and add the $(_scratch_mount_options $*) to the _fail. Signed-off-by: Anand Jain --- common/rc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/rc b/common/rc index e04d9365d902..4e939da37010 100644 --- a/common/rc +++ b/common/rc @@ -339,7 +339,7 @@ _try_scratch_mount() # mount scratch device with given options and _fail if mount fails _scratch_mount() { - _try_scratch_mount $* || _fail "mount failed" + _try_scratch_mount $* || _fail "mount $(_scratch_mount_options $*) failed" } _scratch_mount_idmapped() From patchwork Fri Aug 13 01:59:33 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anand Jain X-Patchwork-Id: 12434515 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 3A23DC432BE for ; Fri, 13 Aug 2021 01:59:59 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 1F5D5610CC for ; Fri, 13 Aug 2021 01:59:59 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S234949AbhHMCAY (ORCPT ); Thu, 12 Aug 2021 22:00:24 -0400 Received: from mx0a-00069f02.pphosted.com ([205.220.165.32]:41686 "EHLO mx0a-00069f02.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229919AbhHMCAX (ORCPT ); Thu, 12 Aug 2021 22:00:23 -0400 Received: from pps.filterd (m0246629.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 17D1v1cb008979; Fri, 13 Aug 2021 01:59:58 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2021-07-09; bh=xS3M2G6+kjO+oxXkCiXpjOQIrLRE8ml8bol9IS0Nqu8=; b=m8LVCWnFNWWpF2Ceo+3X1V+nBaoSFCKyeHAMpv+WLWK7MABnJHZgrj17acCnovk9Y1Mw kZXUxZLPh5r7k+adKVcNkFttAl2xCPItCBjtPukZA9HLIe9JAE9aN1uzmjiRRXR2orcQ XbslnDN1nkNha4o0hQ2ljBGFmx0f0chHXkzEGTXFraojszYX2bb1ewIx0MSMtitx9IUx ltAS0K2fRGtya2ABqwIwFFcfVmoQxpglDW4Mw1AsOiOeXWLKtgBHcQciH+eiKhWDcuQk LwIgQwWO5nUVcjH0LhlObupYhep4cPZGzWIl3FGxMVe8PbKz5DWdY0Xgi+VqplUxuAVS 3Q== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2020-01-29; bh=xS3M2G6+kjO+oxXkCiXpjOQIrLRE8ml8bol9IS0Nqu8=; b=O09W/T5Dpmmcnqo4mf6zmCqgsN+pTFiYkILKGfP4L+8PhkOEPs90SLfrTKygGkTvsi7i 15HNYju3txSIVxnaDGaUXfIxV8EiAr/gsNK3We3vPBm+21nmgnq9GWArtpDytb1iGU+T /q7LAPt74PNXxnwrXRWKaonBsla2+3NInC/9o5+bienxWM3+I6+rhn7KoHstPiyDE6sh 7Ah1dSBt93FtSFgftVRcQKGXw8S/ScwSEg4bZh7XAW0WuvUVH5lKqnmcFr0FUAZNWxHf OQwUuYZCqAjh6zND8GxTJ/80IOBmmw596U7ntogBHkei8Ix3UqE4tuaaBvWIv0vDBP5V xA== Received: from userp3020.oracle.com (userp3020.oracle.com [156.151.31.79]) by mx0b-00069f02.pphosted.com with ESMTP id 3acw9p29jq-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 01:59:57 +0000 Received: from pps.filterd (userp3020.oracle.com [127.0.0.1]) by userp3020.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 17D1uRfL107973; Fri, 13 Aug 2021 01:59:56 GMT Received: from nam11-bn8-obe.outbound.protection.outlook.com (mail-bn8nam11lp2173.outbound.protection.outlook.com [104.47.58.173]) by userp3020.oracle.com with ESMTP id 3aa3xyeunp-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 01:59:56 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=fwbT3jlKYNndpqonnCuO3sE4zmDMr9soWddVV9iNdWLPEJVQxuhOAIw2YlUPLTBfiS2nNP4TJwFDVjaQcXJ4FgJ9sHS5yQt66dswwGwFfPewUSsZzZ5iXTGf/IkFXnlVP1nvkOwhNZnWUChYnyNsAZHNlM5qNamqWpaNQDetdArt26Ie/k2gE6nmsM0qupwlndku51W+gb7ebga2ABHnwvwQPeUCOzVw9xgEgpnKXACtB6/6Zh2k370ASbiNjjuB2MOaIkcsx/QZhwHM1zTRtOliQQm7vOWFqvcEdgVTyYRijVKw8/buT+0DDMW1J3+OwpYZQV8EoQ/gmzpXv31q1w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xS3M2G6+kjO+oxXkCiXpjOQIrLRE8ml8bol9IS0Nqu8=; b=QgbDO+cO+8VSLQt8asTLLcQeS75p4mesJxp6e/o+hEqYnlO3UtB6jDL8WuTqa6G4TmuZ+RlDebTMaq6N9SrXR2E0mTe3SGKoytTwmuci2ucHIyiyrJQ2KYPtyo2Ajy28v6WKacPl99nb3KOvOm1ndjkV56yes1FeH/tyIVkZ00crpg9CVusww8wdeemXMu2iFmm3iic6F+5LnrOoiorZS7kfB/zOPtTfGwH9IgsSgH0tgIc0X00V0RcPa2CMYyj48m8sv2wQCqd5rlXuSXY/rpaTrbtA7+CVLdjaL+Gk2eA9LAbLIUD0CMcUL6oAoFeAITsx6d3TS0sbjH8zElNDjw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=xS3M2G6+kjO+oxXkCiXpjOQIrLRE8ml8bol9IS0Nqu8=; b=OX6JcYvzr2Ikk7cRSxDQLfqWB/SS82RFzAZaNJXWU70CJr26qTIEjqPJ17fdW3YmpThKk/SOCkVmm9wSh0ndg2WLZuCuEYmG+Albfk2cOWgz8sjW4dVIA+O3XT0rsW+d40VSED2folqRkF2rrsNwZJrhrYftM/W/DEw5BlZsHBA= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=oracle.com; Received: from MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) by BL0PR10MB2771.namprd10.prod.outlook.com (2603:10b6:208:7b::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.15; Fri, 13 Aug 2021 01:59:54 +0000 Received: from MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a]) by MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a%4]) with mapi id 15.20.4394.025; Fri, 13 Aug 2021 01:59:54 +0000 From: Anand Jain To: fstests@vger.kernel.org Cc: linux-btrfs@vger.kernel.org Subject: [PATCH 2/4] btrfs/220: discard=sync support older kernel Date: Fri, 13 Aug 2021 09:59:33 +0800 Message-Id: <7f0731e5ed53fdd5b51ff1f2e51492415a46732a.1628818510.git.anand.jain@oracle.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: X-ClientProxiedBy: SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) To MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (39.109.186.25) by SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.15 via Frontend Transport; Fri, 13 Aug 2021 01:59:53 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: c85038bf-1f72-4434-8cef-08d95dfe0b58 X-MS-TrafficTypeDiagnostic: BL0PR10MB2771: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:1388; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: rxE90kVSBET4ExOdxVERvaJwDPzhreHtpi0Q32SurnkTkF1KOhKKufHNJxZRlGSdpoSeSaO7pnAGB7uSKoLyDrHS0fvSi2G3A/bqZKj6kl9BmWYFFu//2J0FBF21GplX32JVBWiMDAC1NzGwUMAB1auShsXLdkF0JR/UggGdiMH9aSbDsf4OHb9DdO0OhMqWTNY5XEbmyG+tO63wwzY7tYFKth1AvxP8depR0T7bn94W7ngAyZqnLz0UmOXFlE/SdtI89WeVTdUSO4rzRC9KjFPhESO8PCHtcbTLLmAu/t41rGjQ1gb90b9OD4s5yJFBmp+Naqrx+EfMaNUwJbzLFL5DdwzR6uUOCUz2+nDPf9WFd2K8o+7NBO4/TRTEWZmlrQrLR9aYcF91xZXpuNReqVhSq7qjkZP8fBJhAqunPax4CUx4312NRgDWOlqM/thvNlnPTBCQisUX91H2LHIfBadYhYIA2b85yWfzlLhTmVnLkuumpkk1oTxLRHxMzsgfGjCWhZpU5vHKKKa6OqcKTUzcHY99dwNxSuHCEeD/Ee7C6Rp9GdsWwPIQL08FByPVINyHv7aoQKTO5at6Dc7eI95nKwCwN6buDpe/sCKV/NxOMfqYdvkYsPvzoR3QePRIDLtomIsIDXE3mlebdKFGANlhfViBOGlhySrmIQaK8T25wWefet/hqk3ePHaU5vCCxcSGxPU3bmIpWl8lRwEHzg== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MN2PR10MB4128.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(396003)(366004)(136003)(39860400002)(376002)(346002)(956004)(2616005)(44832011)(8936002)(8676002)(26005)(66476007)(316002)(52116002)(2906002)(478600001)(186003)(66556008)(66946007)(6916009)(6512007)(6486002)(450100002)(6506007)(86362001)(4326008)(6666004)(38350700002)(38100700002)(5660300002)(83380400001)(36756003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: mmNg1yrIXYO7FCw4TX+O9G7AsvODz0Skf3b3LtmAFUIBtq4aTcd5WNCkgMQDu4sXI4XVzsRdXQ7xfUOMHdEOHPzI/5BMreN+F5/xCiIdJtzGixAsNIMkK0L546AKzqjqhcEY3JTSxBX3jCRvsFPnCRFBxWdsfH1MhccpYwapgBjW3E4kCllPe5knRRMm4zwb5BzUmtJoA1plJTp8KqyvbSkhlWNIi15Scfgv/k1EWwfZQcy11eCYb3gYLLsGf2A7UNbltvmDkx7XESNbv3hxk7ExEuD6iuICykK2WAlZdFS4uPKKZUNKmY0YCmijRvYh6ipgLSMQLqRzuUTaI+3ZVy2wuSQ06fMVlTUjcwulMvG8CeDhZnnwLCOapEXie2gIRyvm1laWof35Qm2T+ERdEahNpfRezC3F8F0EsSUI+RtcBSwaQ72aL1TT3I0oj9+e/cMX5k53dvW/Y9Otg0cOXti6m3t2zlrsdngqVNsagvvLY7kvOz+6XXC4ItF8Sm0nx6lmvMI0rFHXkzqR+Eqy1qCVXVal9OlEhr+5gAoISUQemFrAmIdPDdX9JGnf9SDN68adVMGPEaVqfBlM92USKXRQPC5aV5ERpn34vcUUCPyp7fFRdxfaouVaPCTdmWv9KO4DTUFKzBH1Vxz8k21aUUOnD5NXsMS4tLb1hfssiqnlGTr5MPeWHlOSIRvKzCFBU9U+wnnh4UfNR9IQIweeurI3qkKXYbl24NNKoxFSO3AxPYSY9RLT+nvKmtCCXzUqjiI6ELWSdB1N6b0mV+p+rhPQw8BXayH/gWJGa0GmDvil18byORosxpCAAvqhATQ3/J3eotULFRDyUrwuOigZYTuI4ClkCEL7XxBX3mIEejvwn4pXxnzi3mIr0w9kx4Y5nVav0RCoHg6Uv5YeDdcQJFHxtWlJn7kVJBxuRKPv740ZNdRWj0uAo81HABhtK0i424NCm0BWUpW9aX1LaVZb2yVOaraxmbxIadnsih5Agska6f3sZpYtOGq2kcvYn1t8QpJNB31F+jGiyoU2I9Y/UsIOLdzJqALteyi4YMaqiKleVVJqheTS2ktSK0zEEbJ1sSx22uq1cZIkDdk5/EAQSTr6jn65rsEnUzrIwKyRC3sv98p3c1OryRpNeM2IA4vHlnZlrzC0kNLHHCBJTV7zcih/QnjGQPHWyuUPo6GRyMCHVREGeUia22C8FKxKefLrZgYu0JlsgSSjmpmg8Pd91RnSenVMmcL13mCom62+AIGDjQO0/JWyRtXg7Ih5yWHajHJBPoTxX7lVQaeUGhuoPxdxEY8BSEyt6cmxhLJwmzHMK/t0peHS8HEMKkipKda/ X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: c85038bf-1f72-4434-8cef-08d95dfe0b58 X-MS-Exchange-CrossTenant-AuthSource: MN2PR10MB4128.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Aug 2021 01:59:54.6897 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: TPeEKgq7qm6qUSXeHtiG3xNK8htFa4YYXFLxd9CS03QsK1mM2DO7LocvNCKYKOPTYaeIN7143omxGo575oGwNg== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR10MB2771 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=10074 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 mlxlogscore=999 mlxscore=0 suspectscore=0 malwarescore=0 phishscore=0 adultscore=0 spamscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2107140000 definitions=main-2108130010 X-Proofpoint-GUID: LWl8VVBVcsSnMLFQpDFdgJvOnqYu7tMD X-Proofpoint-ORIG-GUID: LWl8VVBVcsSnMLFQpDFdgJvOnqYu7tMD Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org mount option -o discard=sync isn't supported on the older kernel, make this test case older kernel compatible by checking if the mount option is supported. Signed-off-by: Anand Jain --- tests/btrfs/220 | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/tests/btrfs/220 b/tests/btrfs/220 index 7207c6967793..a01b28a6e42f 100755 --- a/tests/btrfs/220 +++ b/tests/btrfs/220 @@ -263,9 +263,14 @@ test_revertible_options() test_roundtrip_mount "nodatasum" "nodatasum" "datasum" "$DEFAULT_OPTS" test_should_fail "discard=invalid" - test_roundtrip_mount "discard" "discard" "discard=sync" "discard" - test_roundtrip_mount "discard=async" "discard=async" "discard=sync" "discard" - test_roundtrip_mount "discard=sync" "discard" "nodiscard" "$DEFAULT_OPTS" + if [ "$enable_discard_sync" = true ]; then + test_roundtrip_mount "discard" "discard" "discard=sync" "discard" + test_roundtrip_mount "discard=async" "discard=async" "discard=sync" "discard" + test_roundtrip_mount "discard=sync" "discard" "nodiscard" "$DEFAULT_OPTS" + else + test_roundtrip_mount "discard" "discard" "discard" "discard" + test_roundtrip_mount "discard" "discard" "nodiscard" "$DEFAULT_OPTS" + fi test_roundtrip_mount "enospc_debug" "enospc_debug" "noenospc_debug" "$DEFAULT_OPTS" @@ -292,6 +297,13 @@ test_revertible_options() test_roundtrip_mount "notreelog" "notreelog" "treelog" "$DEFAULT_OPTS" } +# Find out if the running kernel supports the -o discard=sync option. +_scratch_mkfs >/dev/null +MOUNT_OPTIONS= +enable_discard_sync=false +_try_scratch_mount "-o discard=sync" > /dev/null 2>&1 && \ + { enable_discard_sync=true; _scratch_unmount; } + # real QA test starts here _scratch_mkfs >/dev/null From patchwork Fri Aug 13 01:59:34 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anand Jain X-Patchwork-Id: 12434517 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 79479C4320E for ; Fri, 13 Aug 2021 02:00:00 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 61F79610CC for ; Fri, 13 Aug 2021 02:00:00 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235413AbhHMCAZ (ORCPT ); Thu, 12 Aug 2021 22:00:25 -0400 Received: from mx0a-00069f02.pphosted.com ([205.220.165.32]:42896 "EHLO mx0a-00069f02.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229919AbhHMCAZ (ORCPT ); Thu, 12 Aug 2021 22:00:25 -0400 Received: from pps.filterd (m0246629.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 17D1umKP008939; Fri, 13 Aug 2021 01:59:59 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2021-07-09; bh=GyCFn1YRKMYK13Rygn6g/qraAJfogh/vjNcDtRNt7SE=; b=ms157C/MaQ1AYnZso6jX2YTY6HunBNtKdjsBECIGGqJxeElRZIXFZytPNucNN8mGSZdp XeWg1D91BrSZtW1o1eQIgcuWPgL8Utxv72+j/6D0E3f5yuzVmi/VeKQnxzkGMmWvb/L9 HA0wgCWPEznuzOB2OTCkER6jc6lj3cmJj4Ogsnu0ZCo/PeCc03HomYUGrT1GbpqXTFIn R5VPVgO7xe/hFjtRhy+a7YuHf35LT52B04UgRIc+nAs3Aw8yDlfwwpeZ0dLwPqQJoOZ6 /3f1bVLtgQuqa7SPv/KqybULnIHl+/+URlt4Zw/EhUEF5nCPjIX8ZdQrw7IVwv+OFC+0 nw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2020-01-29; bh=GyCFn1YRKMYK13Rygn6g/qraAJfogh/vjNcDtRNt7SE=; b=wNoS7LpPAMKP91jdGfjuttlQ2++OAtOTb0doOdMCNAy+GR7pAXUnUXpWD1fdZh7fXHHY ZdQAscwHBG8YovVfw63peQYGT4cmestQLLRwrJreQGZs1NeHKMfW7cRn8wLOQsrBJBvV 5bgW/9TUBMWlodN3b8zh3PBt028kA0AyELvYBa2fafI4nMjSj45WDSOqOK4z482B+lTM cxeCZPK4Gsmz9AKoahMMVy7zOpg1SkMMRFa0SKB+x1ffJ6ixloWqnqruzt6LQDnCXYW5 0j1oksvV07doeo7snlaeeeCxsXgjyZ9OEuccs2fYVf+CoSfzfopUKMaGyNkSVmAfKr+L Kg== Received: from aserp3030.oracle.com (aserp3030.oracle.com [141.146.126.71]) by mx0b-00069f02.pphosted.com with ESMTP id 3acw9p29jy-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 01:59:58 +0000 Received: from pps.filterd (aserp3030.oracle.com [127.0.0.1]) by aserp3030.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 17D1udAA112689; Fri, 13 Aug 2021 01:59:58 GMT Received: from nam11-bn8-obe.outbound.protection.outlook.com (mail-bn8nam11lp2168.outbound.protection.outlook.com [104.47.58.168]) by aserp3030.oracle.com with ESMTP id 3abx3yv9nf-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 01:59:57 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=dSIkzmUIwnh85idTfgfcauUjH2Qm1CtDxWEeG9Uwvdfva6hRwvSZfJSK4f5ph7DBy5PjVPjKw/YTpmohoEVjApN1MOOxjRsPNpzRds/AN47vTX0WgNu5cOHU3Dr6YfK5uEVWZNWLLvL60uAV3XH1rpaLg4qM+9XFYwklHiwEvvpLjs76UA39GFjm6KbzFmjHTAfMrz7Zt/HhDmjPl3yKJnbKxowZ7pGVWsRhQ1Lig9yZxL6qxIju2ZwkGWFOLZCtRNzcjjZA/VRlhNfwlyfzzSKVr0gdFqtL0o5UQ/Y2ym1teTbIC8fGUhsFkHN/kugfKO5CGq3ZSa7kxTC2sw/Eew== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=GyCFn1YRKMYK13Rygn6g/qraAJfogh/vjNcDtRNt7SE=; b=m2+DOn87Vxbti5Oh+vN8Y9zxKEudiMxVdm9aK+5zuzJbBE9OFf1ZyLdDpzgkuaqPjEQXO8KfbkDfVT4v/wLfUN+FGQm5rUSsbJGGybgwTnzE0CNEl377u86BHcqibyQAT/+7bjnCaZeDG8vUUvA2d+uVhL0acyXWc3QfyJ0r6fc3nQTTBmBxAGtUWSjPJdtGmt51yEnmQrW+Z9v/zn6uER8f4hdWnSp5ED+tE4Y9qylwzNI0e+FfmQzRHxmmyb9DX5jbpuVMg1gRW5zCTrQRJ+UG/nD/k8nL96gIfsmvVhtKvNAaT1oTjwT/232urztm3e0vbfME7zpCHA9Aly7NBQ== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=GyCFn1YRKMYK13Rygn6g/qraAJfogh/vjNcDtRNt7SE=; b=b2m9oNh1NoUZb362zr68kxKd+Of7bSDNRXTyQrCI+VCHaS1HPG7hKs/RWI2yzHaoQbsu0JodFAxjObsZ7tIIjspmGSPW99myFfOVQOl8XdCRGfWOuBp1aJ5oxkEtfU+pyDOhCXYteVKCFkYUTvlA+OsmIRFh6qg7aLOUYokC/ew= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=oracle.com; Received: from MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) by BL0PR10MB2771.namprd10.prod.outlook.com (2603:10b6:208:7b::29) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.15; Fri, 13 Aug 2021 01:59:56 +0000 Received: from MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a]) by MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a%4]) with mapi id 15.20.4394.025; Fri, 13 Aug 2021 01:59:56 +0000 From: Anand Jain To: fstests@vger.kernel.org Cc: linux-btrfs@vger.kernel.org Subject: [PATCH 3/4] btrfs/220: nologreplay support older kernel Date: Fri, 13 Aug 2021 09:59:34 +0800 Message-Id: <1419f13a972043a6e7d2de8300adccfd29021079.1628818510.git.anand.jain@oracle.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: X-ClientProxiedBy: SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) To MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (39.109.186.25) by SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.15 via Frontend Transport; Fri, 13 Aug 2021 01:59:55 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 93aade8d-72c7-4edc-186a-08d95dfe0c5d X-MS-TrafficTypeDiagnostic: BL0PR10MB2771: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:2887; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: 5qRcAnGyT3CDexstWmjeFCvVSWwV2SsQLFSQ2WjgGE490T376kIa9Ch/1jtfOjOktlUs+MVBwetWC6K7f4FngGDU690G3Hzpvqo9H5aQoE9ErDtUCrxC83UNjkHxpwdn+yqFFzErixf/UL7Y8HVN2sdD5oNhQdYET6pvggEcSakousFnrADLmLT9dOxDo7hzNsF08F7sbUwRPRxGwUpEdtidIbcycfaqgveQ/RxiE5X99J+vpY7pmKQlnwLS22u4o/vkbQqiiV5az+ff/dXFL7ugVLsjq2GSaw9f7OlrXqA1RUoenpei4NA/JETCwKoppNM4U1v0N+90mOv8+zMiMBOqrR4XXDId3pd4lodgDyhA6Y3brB5PkV4smdoKJoOcE+fNCxi/lx+ZkrTfaicE/JYMREmIluRveoWmbden88X6IWi7LxnJKORS/kJZ+/bIzylLoLidbEXLvOQzYGntaYMbxoyK3EEEO6x581iZGkHwhgVtNum/q/XCOi2TNKzPDtSNzLmeXTovnjh5+If3fTAI8rurSAfLRNRiZi3sPzcKYi3d4stRREuKmiD3+jOmi5030TQ/f3cpY+Lr+KmhRa+b0KFrziLFjkWPpW1Ih8ZjQE1Q+oBqS9eIkRkuRNdJIdZP5itwCB3xCsuXV8emQ9L0zLmTahdtttYVEKnBDvOSurINVBUdVeGO4CcR8y4XpD7DPHZkIc64KaiK+wIxuw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MN2PR10MB4128.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(396003)(366004)(136003)(39860400002)(376002)(346002)(956004)(2616005)(44832011)(8936002)(8676002)(26005)(66476007)(316002)(52116002)(2906002)(478600001)(186003)(66556008)(66946007)(6916009)(6512007)(6486002)(450100002)(6506007)(86362001)(4326008)(6666004)(38350700002)(38100700002)(5660300002)(83380400001)(36756003);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: KmSJBZd81F4Ve7eSmWcRh8RS0a4gUuVJ3hsRBHPSmAg+/Xq8P3IfyG4HiLR8nFkfQzLlsbETUJg8fxGS3WAEr8+/SZ1SiAvGsT1M8HQ8Kr5SORyN/8MdKqLg1IAg8KjN8O85Gw14XjoyFWvkC2H9LmRwZHM11TjmGMLAo2WxKVLA+DYkWLO5GQ4VpoxY/fg16yDIal0RlTU7q3Rfc/oTDbB5N9B1btqiOsiityPTJLdYIYm7dqPRSlCInU3plvg8jJ9hlUx+Z3ZIpvTsIjr3UqbuMWhTNp35XuNTJT82S9/JkmL8RR6imcn7XgDg6kTblPddbhfrMrsmIcpUAFKRLMlO6hZqhtaZBf/Tli1IM3kGuiro8o+X6PUgzxL5LK7fNv4LDoqUKFamefjUbkB1ZugyxMU2nGM6MLaIeBSkd/rFQ3/+Jr2/jhMCXupClJTcJhDqsctFLMrqltMBCPC+nTvzkzVlOyNkEzdW/tmfUesdYaoNyr1mGc1tcTWkFin47628yTueKkv+PT4xVbdY0sekqR7ww7JauKgSpgn8DKZsq3u+g+V98vNdMBfFZC+7n9TEdB4gRWingblGVCr/F7mzjZvNbiNalReHjxqwYow8Hs4atOPHedNpB1rfCh4b0ngZ+Z8FArZ+FZ+FBmPS9Y9/l5iRtqpMwgnuCzXUA+zZJnP7rcT/qy8Eu3UJY6IMlxVCAI/eJ5ebYPlboT3x7qsOIJMsMhNsLIz0MHMdXThat/KXxJu65aTCg7Prxkjg04HsPqZe8EnxxIs7gzSadkS5T611bt7vd55pd6y3w0Boo6x8CIr8JxDu/9FMkBzfApNdPmwkzPg6LAMRxz52bLPEH3mmOwBlWdBWoU3Nh+Aydv1tvcN6WokD4b7xSKJZJli+xB7UKJL2j/IiHYHZPtt/z43iaq6S7J76SThB3A36BjEDGa01ZceVqxkHWOLQHFwIRocX3UftatDhbGc8puZEODsIwOj4lWBiREhWhau8UovNyCnZRbuwKohSBkyM9Ve0zTdhYqjaz+quHMYLIRnDT7QFTz+9NiQClviPBl53CNrv1mCqsyu+Mt4WSESnOep6AJPVPgFrgVLnNWE2oOlQLThz4cYWLcjsub9PAE4/Ysb99P7VOslgtp99OTA2VUqRwZaJG7BdSxsavF76NAD3ZkTLFck8u5fgWSu/2849CFPHBtw4VJyOahJhT4Gob+9vrk14byQ2HnIYpehsdXL3xtqGtu9Pyy78XBOyIqI9SELMlp/W6SVPsQUK+X5zniLzMQUHrrLBdES6JAwvLOoS4dp5HCfV79/lWRyram3s2WwFzQV6JWrQ2fNYBDGL X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 93aade8d-72c7-4edc-186a-08d95dfe0c5d X-MS-Exchange-CrossTenant-AuthSource: MN2PR10MB4128.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Aug 2021 01:59:56.3903 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: vFuvUoljIv8RCZaE4oiPN08MEN22lSB1Lw8iQ5tecfN7D2yfXYUOOmuic5P0VXBnheJGiGcruajJDUnWXKKXhQ== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR10MB2771 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=10074 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 adultscore=0 mlxscore=0 bulkscore=0 spamscore=0 phishscore=0 mlxlogscore=999 suspectscore=0 malwarescore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2107140000 definitions=main-2108130010 X-Proofpoint-GUID: Cqr8bY3ewWpfH8hOjc6RTj8NUCsasg9t X-Proofpoint-ORIG-GUID: Cqr8bY3ewWpfH8hOjc6RTj8NUCsasg9t Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org mount option -o rescue=nologreplay isn't supported on the older kernel, make this test case older kernel compatible by checking if the mount option is supported. Signed-off-by: Anand Jain --- tests/btrfs/220 | 28 ++++++++++++++++++++-------- 1 file changed, 20 insertions(+), 8 deletions(-) diff --git a/tests/btrfs/220 b/tests/btrfs/220 index a01b28a6e42f..9f2f07d723c4 100755 --- a/tests/btrfs/220 +++ b/tests/btrfs/220 @@ -209,22 +209,30 @@ test_non_revertible_options() { test_mount_opt "degraded" "degraded" - # nologreplay should be used only with + # nologreplay should be used only with readonly test_should_fail "nologreplay" - test_mount_opt "nologreplay,ro" "ro,rescue=nologreplay" - # norecovery should be used only with. This options is an alias to nologreplay + # norecovery should be used only with readonly. + # This options is an alias to nologreplay test_should_fail "norecovery" - test_mount_opt "norecovery,ro" "ro,rescue=nologreplay" + + if [ "$enable_rescue_nologreplay" = true ]; then + #rescue=nologreplay should be used only with readonly + test_should_fail "rescue=nologreplay" + + test_mount_opt "nologreplay,ro" "ro,rescue=nologreplay" + test_mount_opt "norecovery,ro" "ro,rescue=nologreplay" + test_mount_opt "rescue=nologreplay,ro" "ro,rescue=nologreplay" + else + test_mount_opt "nologreplay,ro" "ro,nologreplay" + test_mount_opt "norecovery,ro" "ro,nologreplay" + fi + test_mount_opt "rescan_uuid_tree" "rescan_uuid_tree" test_mount_opt "skip_balance" "skip_balance" test_mount_opt "user_subvol_rm_allowed" "user_subvol_rm_allowed" test_should_fail "rescue=invalid" - - # nologreplay requires readonly - test_should_fail "rescue=nologreplay" - test_mount_opt "rescue=nologreplay,ro" "ro,rescue=nologreplay" } test_one_shot_options() @@ -304,6 +312,10 @@ enable_discard_sync=false _try_scratch_mount "-o discard=sync" > /dev/null 2>&1 && \ { enable_discard_sync=true; _scratch_unmount; } +enable_rescue_nologreplay=false +_try_scratch_mount "-o ro,rescue=nologreplay" > /dev/null 2>&1 && \ + { enable_rescue_nologreplay=true; _scratch_unmount; } + # real QA test starts here _scratch_mkfs >/dev/null From patchwork Fri Aug 13 01:59:35 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Anand Jain X-Patchwork-Id: 12434519 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-18.7 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_CR_TRAILER, INCLUDES_PATCH,MAILING_LIST_MULTI,MSGID_FROM_MTA_HEADER,SPF_HELO_NONE, SPF_PASS,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 4A2E7C4338F for ; Fri, 13 Aug 2021 02:00:02 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 2AAAD610CF for ; Fri, 13 Aug 2021 02:00:02 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235750AbhHMCA1 (ORCPT ); Thu, 12 Aug 2021 22:00:27 -0400 Received: from mx0a-00069f02.pphosted.com ([205.220.165.32]:45244 "EHLO mx0a-00069f02.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229919AbhHMCA0 (ORCPT ); Thu, 12 Aug 2021 22:00:26 -0400 Received: from pps.filterd (m0246627.ppops.net [127.0.0.1]) by mx0b-00069f02.pphosted.com (8.16.0.43/8.16.0.43) with SMTP id 17D1vCOk029145; Fri, 13 Aug 2021 02:00:01 GMT DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2021-07-09; bh=pEWgkQQxspOqOT2IFRP1+xn5SeVExSH2gGUyDKsSxJw=; b=RQv6P0QgCGCRkm2CaHvOUsBQBdDGT+y1LT11KMcVR53Ab6DdHsUCFpyP5yFLqI7GLXxZ 7xo2LDKgnQ/MNr0iINym2OTb+oQ3/xNIYjOTJLYdVgQ7Uopf16RXv9JY2gtbBRVNim2r H3fYIy805A/AckBlN6tsa1T0FEFfiF8nMgcSb/jKYI8FQDQ3DWUgdsYhArtNcM4Y8epn tUPg3pAQK630gm7/lTvrltMG48Mw3mnxy+zanZPLPxVqYkkcPY/NmVNNGfOduG4ezsAT Hlb1rnf/ZMXFBB7cnKBx435HtVzTK+xSAOsUS9KWMnkSFQ8e7CBkPgonPVnEiV9BJeRR 0w== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.com; h=from : to : cc : subject : date : message-id : in-reply-to : references : content-transfer-encoding : content-type : mime-version; s=corp-2020-01-29; bh=pEWgkQQxspOqOT2IFRP1+xn5SeVExSH2gGUyDKsSxJw=; b=YF1jsd5Tq5Ag04Li2iYGQMDtraKPkbbgMk8as8I1ybajAXp1RDsOzZFtu+Zhecd9Mirc zZr6ZtKrKbqMAf3RsHHwpFGrhCEOjEMY6phwf6/YBGGf4XJzWlnaLWqKqGkpupmfGhkB WcbWYmGj03yXg63Rnkpy0rFCb0BAKQ9nmDZJ2spN1malO/0UzyoACatp7ufH0pBwchzC szEe72RK+jX06J8492dCKv60/gMlExDyUBciAOuRXUEZpGc+fXl9HJ6AuCIlQzXyF3OD AHd5KZVCsRKCL/1da7GERNX2teTfZQMcHa/Q55gJhDCC1kXuqFX7OL04TMj064UdMUl9 KA== Received: from aserp3020.oracle.com (aserp3020.oracle.com [141.146.126.70]) by mx0b-00069f02.pphosted.com with ESMTP id 3acd64cbtw-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 02:00:00 +0000 Received: from pps.filterd (aserp3020.oracle.com [127.0.0.1]) by aserp3020.oracle.com (8.16.0.42/8.16.0.42) with SMTP id 17D1uXGW128927; Fri, 13 Aug 2021 01:59:59 GMT Received: from nam10-dm6-obe.outbound.protection.outlook.com (mail-dm6nam10lp2106.outbound.protection.outlook.com [104.47.58.106]) by aserp3020.oracle.com with ESMTP id 3accrd5ys1-1 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=OK); Fri, 13 Aug 2021 01:59:59 +0000 ARC-Seal: i=1; a=rsa-sha256; s=arcselector9901; d=microsoft.com; cv=none; b=UI6lCcJr2OM0vFAbOyoCMh44KMpLkJrl3E7f7wvn+jtCOxp9vvFs+X/v031Q+2b8Zu007RqHcC38fR6qtsKtKGK36ztETJ8r3yJm7G5wEBPswDkXI/OqMxHt4tnyD3bnnCc3rrPyju2loaglAWfnPZ+Ittm50dMrjaiqBBxbyK6o35Xj9k/Rc+2Zhvna0Mp3mzVeSFOH9yHjae8+TwpMWtJR2HLBqERHlmvS+vsHPX3ElU2S8xjF8FJvbwDyr8JAU6o6l3rsbD1avCW2/pgnkgkpOX6N9kQ5t1pBdo4IraRAB26h4s0SOnZVLtmo3qAqw08B3O4Jri2fhkw0WEdc5w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=microsoft.com; s=arcselector9901; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=pEWgkQQxspOqOT2IFRP1+xn5SeVExSH2gGUyDKsSxJw=; b=Yk0Gdj+xFP2N/PdpV+lt6YeS+J+PqNHVtJATakkaWe6mEkI+C8FwP81JuVKdhoh9NeQi4S6wOtyWGw7uawst/KEcie7NB/25CWUN+FhnxGD1jP+2B+SMaM6pzdK+eKAg6sIkVzpERwhT2WNZWo4tZrAUVurGh7M6vCVUpCc25uO2GOe93gMtj0pDDDz9aUxDZQPcvWR7Aa8mmwjz2wyOw2xSVWZBSHk5hjvvSJesSF4d2+ZReXN2XqDyRT+2tz2szryPvIniKvm7i6M/n6eL90fm2pV2G41lWpG1sg3KUf12xjJXuW+ZG1q2kLPiiNDX1uHT4o8lT7ze/TiHqhSMgw== ARC-Authentication-Results: i=1; mx.microsoft.com 1; spf=pass smtp.mailfrom=oracle.com; dmarc=pass action=none header.from=oracle.com; dkim=pass header.d=oracle.com; arc=none DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=oracle.onmicrosoft.com; s=selector2-oracle-onmicrosoft-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=pEWgkQQxspOqOT2IFRP1+xn5SeVExSH2gGUyDKsSxJw=; b=V8p51+t1myGGy2EATQAPxshvlGZq7ITXmFmnTpwxK8KlnFH+NrzvrcmgedN2FyAOiXUr2t95tbUP/qzAw10nq9V3obg/nT1AkwrCjEkjl4XqHVAB+wlbN6tlhlyWXesikNZ+z7BO2Y/ZtB1uxyERqTgfeYn/GlyHO9VAz5h3roc= Authentication-Results: vger.kernel.org; dkim=none (message not signed) header.d=none;vger.kernel.org; dmarc=none action=none header.from=oracle.com; Received: from MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) by BL0PR10MB2804.namprd10.prod.outlook.com (2603:10b6:208:77::13) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.14; Fri, 13 Aug 2021 01:59:57 +0000 Received: from MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a]) by MN2PR10MB4128.namprd10.prod.outlook.com ([fe80::b813:4805:31e:d36a%4]) with mapi id 15.20.4394.025; Fri, 13 Aug 2021 01:59:57 +0000 From: Anand Jain To: fstests@vger.kernel.org Cc: linux-btrfs@vger.kernel.org Subject: [PATCH 4/4] btrfs/220: clear_cache fix for older kernel Date: Fri, 13 Aug 2021 09:59:35 +0800 Message-Id: <6b714b7e0fcff9d89098b15246e58fcdf8e2b681.1628818510.git.anand.jain@oracle.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: References: X-ClientProxiedBy: SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) To MN2PR10MB4128.namprd10.prod.outlook.com (2603:10b6:208:1d2::24) MIME-Version: 1.0 X-MS-Exchange-MessageSentRepresentingType: 1 Received: from localhost.localdomain (39.109.186.25) by SG2PR06CA0191.apcprd06.prod.outlook.com (2603:1096:4:1::23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.4415.15 via Frontend Transport; Fri, 13 Aug 2021 01:59:56 +0000 X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 9807654d-9237-44f4-e471-08d95dfe0d59 X-MS-TrafficTypeDiagnostic: BL0PR10MB2804: X-Microsoft-Antispam-PRVS: X-MS-Oob-TLC-OOBClassifiers: OLM:5516; X-MS-Exchange-SenderADCheck: 1 X-MS-Exchange-AntiSpam-Relay: 0 X-Microsoft-Antispam: BCL:0; X-Microsoft-Antispam-Message-Info: lvtDbrJxKannYUJRRIbRS1S7SC25oHj4tHVdVF88Vj+X4d7ZKdiNg5PuVarOylSyK82j/Avb+EMscnezLP3rfyLipua5MstvqTWRk8xHM66PrXILZFPn4Liq0abMyWJ42H8Tayhrrae9PRy+qHyFX65YmdXJyRDYqRtdx8lKeXe+Y5I/4DO8j4fr507F0CK7fmq+d70CM72yrWXw0AQAtHWz/mRA8+qlWUa1AR5TrPUQ/iMYVqHXpBVkpQSHThCRf4t5hsrs6g0Wlt68pY3aPEysGvSCttAXSIWKqrgMPxTc3fD0kf6zcvrnxOsoAwC+6NOqv5PE2BF27jtU33O2OxS8NVg1MWP735wTB5hSsYZbbUhG/DSUgSJEj0vDT5dt5Zxfkcg8FdP8orRKAFE0ZTe4aWAiThTY8ot7c/UJi6u9EkzX3rxViZWcScwGTjZaG4D0Cc2eHcYgAiNI4fiPuvgRoNiQJ3wBnKFbnqqAqnlj31tbdYg4XLa9n14+RCvkSDKSaRfa5n4JyaKNT+CGXluUlnlNMVf7EeXQBDOtk7gLbZ/YGmS/O+qjqi4z7mplWwR7USbOZBjxdfu/A5e1sn1K0gcoXv2tpUgaX3vAOUfU4ewFE+8UwpYPop3kN9oEMp9KgBb00wRlxLgczKsRqcBvhHO1tw4KYz5MGiDDi64zmHvlm6mMu0Lflru5RvdMnbAtWWjVYYhCp2eGNJ/szw== X-Forefront-Antispam-Report: CIP:255.255.255.255;CTRY:;LANG:en;SCL:1;SRV:;IPV:NLI;SFV:NSPM;H:MN2PR10MB4128.namprd10.prod.outlook.com;PTR:;CAT:NONE;SFS:(346002)(39860400002)(366004)(376002)(136003)(396003)(38100700002)(44832011)(6916009)(38350700002)(6486002)(6666004)(5660300002)(52116002)(2616005)(316002)(478600001)(86362001)(4326008)(8676002)(83380400001)(186003)(450100002)(956004)(26005)(66476007)(66556008)(66946007)(2906002)(8936002)(36756003)(6506007)(6512007);DIR:OUT;SFP:1101; X-MS-Exchange-AntiSpam-MessageData-ChunkCount: 1 X-MS-Exchange-AntiSpam-MessageData-0: 9rTNWuRjZeAbfFosxRSvpsQ+6w9dyDGngBOrLBx69qSptJaIQ3aeKbxALhrzI6OL6v8ePjQec6imdSdrr4NwVRA+hhnxuPYd3lCgoVMRoG/5Wjkjx4jCVe9imCpTUMoWOPWUOwwhOb2deuGD6LiqmLYrh33fAOdAnOTz9N08TlU8ci92q2OdfujnYE3v0xfFlvelruwhpMjunKoM4yF7hZQCIHTddV6b4gyF8q87f6dwNquIbffYfcCM77ONnp9pD1zKr9v3wKFwR3GtZDLIuGLKq9dD3q1GbSmu72/xuA0MaYiZ5l66vGMa0U5zhdqBRmwYLWolhq/e9mJaUPa9KMtCdFhykyXUiJm1EWHvvU4Z00Bvn/9AzYi10rW+hg6F7aNJnTVwnE5Ho/vcPCMZkihxPHFCm1BxttmN9vmR+BnYia/EaoW/zJ66GFOp3HQ27d6C6zqMYd84cSIDRoUABvg69Qvdssxb9mmv/mb1Qmv6C4L5Ug+kW6cg/oQefHaOT5PWjUUZ4rAQvD7QkOjJuQzJsJE4oU+s7IvwpzufWC5RF+b+fQDqxa1CFxPFKlhidHyfImWQTmyBxJ4vx/4hY7J6QSX9heUDE7I3th7F0+h/d/xfG7Y8issogQKD7S5PpV9xAoluxyZSZ2hJid5VxJLiwCWuvfSMuDGOtRFF08FLCKg0wbBLJJp/+iUsRR9e0iHpzPFfUfHq1Wbsc1L6zLcyxhatPIPCV4xx9iOMCy+GkCqQyi9tTkBiArnMb67yvxy7CiJ+xMEpZhBxleWnD5bszmtcl3SJFh2mflmZU+2TrGUKsjq9hCKrI2YrSALGX9sdaE6lD5qpRtVHrss6qW2kQLKF8x5/wHYXKv+rT8G7FlfM474oAv6zfnL+h5KfbzDmPVc/XJDGll2rLETw6QlX/RS5aEFK3W8WygVdN5XsXyRUzwuBNiq4MQYqczWgb/tfrQWzHnLPtygFg07DIFrqwYDEAbzDuVs030+EQQNGOHZowRO3rL1Lvxu82KMp+9ixp+PIF/oA3RzpNoXjHVzo7jRm4mAfqga1hR8fuy3hZsU0xiXoQlW2rbibyDqJGXoudVd9+ZLkiXAOQYae1/CPENVjASXo4NN7nYex60DjhMzQYoSC93EuHFvkeH1RGu0+U0k2bzPuXiJKSC+AHYWK+Ol2/DepF4bUqkvIvFqSCmGxzzEPhzf/KZBrREfu/qIV2d5mSjm0J4+4uRnbZardB0F2ZoAhMRPKuvdB4n4UaDjnYBGhchNspuuHcdJTVq7p3i2UdrUatui83Ad/yVpJ9ECBFI82+Q331+Tzw51wNan5BmY09WnDPCn8nHgy X-OriginatorOrg: oracle.com X-MS-Exchange-CrossTenant-Network-Message-Id: 9807654d-9237-44f4-e471-08d95dfe0d59 X-MS-Exchange-CrossTenant-AuthSource: MN2PR10MB4128.namprd10.prod.outlook.com X-MS-Exchange-CrossTenant-AuthAs: Internal X-MS-Exchange-CrossTenant-OriginalArrivalTime: 13 Aug 2021 01:59:57.8519 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 4e2c6054-71cb-48f1-bd6c-3a9705aca71b X-MS-Exchange-CrossTenant-MailboxType: HOSTED X-MS-Exchange-CrossTenant-UserPrincipalName: BD/H7Old/+E2Fj3K5z4PgvxL5yeHN8ylFzp8QHPK6px9ppV4F5XTSgYxyY3I+dndN/jRnsw5iNawCxh0o9BX5A== X-MS-Exchange-Transport-CrossTenantHeadersStamped: BL0PR10MB2804 X-Proofpoint-Virus-Version: vendor=nai engine=6200 definitions=10074 signatures=668682 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=0 mlxlogscore=999 malwarescore=0 adultscore=0 spamscore=0 bulkscore=0 mlxscore=0 phishscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.12.0-2107140000 definitions=main-2108130010 X-Proofpoint-GUID: OqzA6sLHkpbeZ6nTWhuAY3va027Mzdml X-Proofpoint-ORIG-GUID: OqzA6sLHkpbeZ6nTWhuAY3va027Mzdml Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org mount option -o clear_cache shown in /proc/self/mounts isn't supported in the newer kernel, make this test case older kernel compatible by checking if clear_cache is shown in the /proc/self/mounts. Signed-off-by: Anand Jain --- tests/btrfs/220 | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) diff --git a/tests/btrfs/220 b/tests/btrfs/220 index 9f2f07d723c4..fa91a38493af 100755 --- a/tests/btrfs/220 +++ b/tests/btrfs/220 @@ -237,7 +237,11 @@ test_non_revertible_options() test_one_shot_options() { - test_mount_opt "clear_cache" "" + if [ "$enable_clear_cache_shown" = true ]; then + test_mount_opt "clear_cache" "clear_cache" + else + test_mount_opt "clear_cache" "" + fi } # All these options can be reverted (with their "no" counterpart), or can have @@ -316,6 +320,13 @@ enable_rescue_nologreplay=false _try_scratch_mount "-o ro,rescue=nologreplay" > /dev/null 2>&1 && \ { enable_rescue_nologreplay=true; _scratch_unmount; } +enable_clear_cache_shown=false +_try_scratch_mount "-o clear_cache" > /dev/null 2>&1 && \ + { shown_opts=$(cat /proc/self/mounts | grep $SCRATCH_MNT | \ + $AWK_PROG '{ print $4 }') + echo $shown_opts | grep -q clear_cache && enable_clear_cache_shown=true + _scratch_unmount; } + # real QA test starts here _scratch_mkfs >/dev/null