From patchwork Fri Nov 23 05:59:30 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chandan Rajendra X-Patchwork-Id: 10695051 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 E59675A4 for ; Fri, 23 Nov 2018 05:59:51 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id D3A9C2C53D for ; Fri, 23 Nov 2018 05:59:51 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id C7DBB2C543; Fri, 23 Nov 2018 05:59:51 +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.9 required=2.0 tests=BAYES_00,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 773902C53D for ; Fri, 23 Nov 2018 05:59:51 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2501987AbeKWQme (ORCPT ); Fri, 23 Nov 2018 11:42:34 -0500 Received: from mx0a-001b2d01.pphosted.com ([148.163.156.1]:50372 "EHLO mx0a-001b2d01.pphosted.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729305AbeKWQmd (ORCPT ); Fri, 23 Nov 2018 11:42:33 -0500 Received: from pps.filterd (m0098410.ppops.net [127.0.0.1]) by mx0a-001b2d01.pphosted.com (8.16.0.22/8.16.0.22) with SMTP id wAN5sSpE101970 for ; Fri, 23 Nov 2018 00:59:49 -0500 Received: from e36.co.us.ibm.com (e36.co.us.ibm.com [32.97.110.154]) by mx0a-001b2d01.pphosted.com with ESMTP id 2nx24t9x31-1 (version=TLSv1.2 cipher=AES256-GCM-SHA384 bits=256 verify=NOT) for ; Fri, 23 Nov 2018 00:59:48 -0500 Received: from localhost by e36.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Fri, 23 Nov 2018 05:59:40 -0000 Received: from b03cxnp07029.gho.boulder.ibm.com (9.17.130.16) by e36.co.us.ibm.com (192.168.1.136) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; (version=TLSv1/SSLv3 cipher=AES256-GCM-SHA384 bits=256/256) Fri, 23 Nov 2018 05:59:37 -0000 Received: from b03ledav005.gho.boulder.ibm.com (b03ledav005.gho.boulder.ibm.com [9.17.130.236]) by b03cxnp07029.gho.boulder.ibm.com (8.14.9/8.14.9/NCO v10.0) with ESMTP id wAN5xauw8519858 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=FAIL); Fri, 23 Nov 2018 05:59:36 GMT Received: from b03ledav005.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id B3060BE04F; Fri, 23 Nov 2018 05:59:36 +0000 (GMT) Received: from b03ledav005.gho.boulder.ibm.com (unknown [127.0.0.1]) by IMSVA (Postfix) with ESMTP id 5A58DBE053; Fri, 23 Nov 2018 05:59:35 +0000 (GMT) Received: from localhost.localdomain.com (unknown [9.85.75.147]) by b03ledav005.gho.boulder.ibm.com (Postfix) with ESMTP; Fri, 23 Nov 2018 05:59:34 +0000 (GMT) From: Chandan Rajendra To: fstests@vger.kernel.org Cc: Chandan Rajendra , guaneryu@gmail.com Subject: [PATCH 2/2] ext4/021: Work with 64k block size Date: Fri, 23 Nov 2018 11:29:30 +0530 X-Mailer: git-send-email 2.19.1 In-Reply-To: <20181123055930.21423-1-chandan@linux.vnet.ibm.com> References: <20181123055930.21423-1-chandan@linux.vnet.ibm.com> MIME-Version: 1.0 X-TM-AS-GCONF: 00 x-cbid: 18112305-0020-0000-0000-00000E8EEEFA X-IBM-SpamModules-Scores: X-IBM-SpamModules-Versions: BY=3.00010104; HX=3.00000242; KW=3.00000007; PH=3.00000004; SC=3.00000270; SDB=6.01121447; UDB=6.00582004; IPR=6.00901566; MB=3.00024288; MTD=3.00000008; XFM=3.00000015; UTC=2018-11-23 05:59:38 X-IBM-AV-DETECTION: SAVI=unused REMOTE=unused XFE=unused x-cbparentid: 18112305-0021-0000-0000-000063CF052F Message-Id: <20181123055930.21423-2-chandan@linux.vnet.ibm.com> X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:,, definitions=2018-11-23_05:,, signatures=0 X-Proofpoint-Spam-Details: rule=outbound_notspam policy=outbound score=0 priorityscore=1501 malwarescore=0 suspectscore=1 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 lowpriorityscore=0 mlxscore=0 impostorscore=0 mlxlogscore=999 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-1810050000 definitions=main-1811230050 Sender: fstests-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP For 64k blocksize, 10MiB as the filesystem size isn't sufficient to have a journal included. Hence this commit computes the test FS size based on the block size of the underlying filesystem. Signed-off-by: Chandan Rajendra --- tests/ext4/021 | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/tests/ext4/021 b/tests/ext4/021 index 3d36efd0..519737e1 100755 --- a/tests/ext4/021 +++ b/tests/ext4/021 @@ -34,13 +34,16 @@ _supported_os Linux _require_scratch _require_dumpe2fs -# 10M in bytes -fssize=$((10 * 1024 * 1024)) +_scratch_mkfs >> $seqres.full 2>&1 +_scratch_mount +blocksize=$(_get_block_size $SCRATCH_MNT) +_scratch_unmount + +# With 4k block size, this amounts to 10M FS instance. +fssize=$((2560 * $blocksize)) _scratch_mkfs_sized $fssize >> $seqres.full 2>&1 _require_metadata_journaling $SCRATCH_DEV -blocksize=`$DUMPE2FS_PROG -h $SCRATCH_DEV 2>/dev/null | grep "Block size" | \ - awk '{print $3}'` offset=0 found=0 # this is the jbd2 journal superblock magic number on disk, in big endian