Received: by 2002:ac0:98c7:0:0:0:0:0 with SMTP id g7-v6csp382429imd; Sat, 3 Nov 2018 02:18:57 -0700 (PDT) X-Google-Smtp-Source: AJdET5dMkf64jcwSgjJPRsP1Nma3qO7qdb3AliM+Ebgoxu49w0nVSNMr6yPqu6zROqinWmtzo7JH X-Received: by 2002:a62:5e83:: with SMTP id s125-v6mr509323pfb.232.1541236737635; Sat, 03 Nov 2018 02:18:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1541236737; cv=none; d=google.com; s=arc-20160816; b=Icoo6wyVBMK/vZc2uU4yIUTxwA8kBcQN4Hv2DD4a3jfF07FsqBuXdAC5cWREpbB6yb ItQljCGwW9tuXgPFJWUoBYFScel6byFMhw1hCslYkf5bKIAoIVCg6VglZCfvbmFmGG6e rytZidkGpx9Ea6n90EHaQj+1mkbixYfUMo7x42c4fIh8CvuZdOz0XJNHq977OaMrS2Hi LuV6n8rWqDVMTL/LlziwMFY/6qwEyvlEOxThYJL5eimmRhULbF3EutwrbSTRJbDbAcK9 pKgW76zVAAyxIuZtnTwiU+BibXcryYlYzyfKtwfu9xe2SkUASYc1+PEEg42C7n/AFsBY kB9w== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding :content-language:in-reply-to:mime-version:user-agent:date :message-id:autocrypt:openpgp:from:references:cc:to:subject; bh=cfQ1NDD1KBf0zTsR/3CitYevH1Q6J+hKmatJNV9QWxI=; b=Dh1fDLfgEkkYjUaHOZofZDodtsDWGW8PwouMiedFLEqFU6qqrAJQWoFVIbsdUfM2G3 GwUd14E5CAIIG67nv5gTBOXytF1eBl9c3gZMynBYDQ05EcV1QW2cIN6M4H6LU6Ii/uM0 ehzuzPI8Xqo6cud5TaK439ayHYBE/+yuCZzvjTlYXca2ksRBmiBdxxp4xZMJnWmaBNH4 0ABD3bMZ79tbhDykle2b2kSYymT89G4/RxcXX8P+SGcHCOwbwV2mX3xdPnScm/00hoHq 2+VizMAWnA/odlFgZ9U/Gb9zF7ZqWxI+mIkyO5EAgX8+8BQiLVcUvSux8ohYGmVcyuqz 5vIA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f11-v6si31791025pgi.378.2018.11.03.02.18.41; Sat, 03 Nov 2018 02:18:57 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727256AbeKCS3A (ORCPT + 99 others); Sat, 3 Nov 2018 14:29:00 -0400 Received: from mout.gmx.net ([212.227.15.18]:36781 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726539AbeKCS3A (ORCPT ); Sat, 3 Nov 2018 14:29:00 -0400 Received: from [0.0.0.0] ([210.140.77.29]) by mail.gmx.com (mrgmx003 [212.227.17.184]) with ESMTPSA (Nemesis) id 0MexaL-1fuLyA2YG1-00OXoo; Sat, 03 Nov 2018 10:18:08 +0100 Received: from [0.0.0.0] ([210.140.77.29]) by mail.gmx.com (mrgmx003 [212.227.17.184]) with ESMTPSA (Nemesis) id 0MexaL-1fuLyA2YG1-00OXoo; Sat, 03 Nov 2018 10:18:08 +0100 Subject: Re: [PATCH] Change the total_dirty from SZ_256M to SZ_64M. To: Nikolay Borisov , hmsjwzb Cc: clm@fb.com, Josef Bacik , David Sterba , Omar Sandoval , Filipe Manana , linux-btrfs@vger.kernel.org, linux-kernel@vger.kernel.org References: <20181103083654.655-1-weizhefix@gmail.com> <8965ea1d-c29f-7bdf-44cb-874511899567@suse.com> From: Qu Wenruo Openpgp: preference=signencrypt Autocrypt: addr=quwenruo.btrfs@gmx.com; prefer-encrypt=mutual; keydata= xsBNBFnVga8BCACyhFP3ExcTIuB73jDIBA/vSoYcTyysFQzPvez64TUSCv1SgXEByR7fju3o 8RfaWuHCnkkea5luuTZMqfgTXrun2dqNVYDNOV6RIVrc4YuG20yhC1epnV55fJCThqij0MRL 1NxPKXIlEdHvN0Kov3CtWA+R1iNN0RCeVun7rmOrrjBK573aWC5sgP7YsBOLK79H3tmUtz6b 9Imuj0ZyEsa76Xg9PX9Hn2myKj1hfWGS+5og9Va4hrwQC8ipjXik6NKR5GDV+hOZkktU81G5 gkQtGB9jOAYRs86QG/b7PtIlbd3+pppT0gaS+wvwMs8cuNG+Pu6KO1oC4jgdseFLu7NpABEB AAHNIlF1IFdlbnJ1byA8cXV3ZW5ydW8uYnRyZnNAZ214LmNvbT7CwJQEEwEIAD4CGwMFCwkI BwIGFQgJCgsCBBYCAwECHgECF4AWIQQt33LlpaVbqJ2qQuHCPZHzoSX+qAUCWdWCnQUJCWYC bgAKCRDCPZHzoSX+qAR8B/94VAsSNygx1C6dhb1u1Wp1Jr/lfO7QIOK/nf1PF0VpYjTQ2au8 ihf/RApTna31sVjBx3jzlmpy+lDoPdXwbI3Czx1PwDbdhAAjdRbvBmwM6cUWyqD+zjVm4RTG rFTPi3E7828YJ71Vpda2qghOYdnC45xCcjmHh8FwReLzsV2A6FtXsvd87bq6Iw2axOHVUax2 FGSbardMsHrya1dC2jF2R6n0uxaIc1bWGweYsq0LXvLcvjWH+zDgzYCUB0cfb+6Ib/ipSCYp 3i8BevMsTs62MOBmKz7til6Zdz0kkqDdSNOq8LgWGLOwUTqBh71+lqN2XBpTDu1eLZaNbxSI ilaVzsBNBFnVga8BCACqU+th4Esy/c8BnvliFAjAfpzhI1wH76FD1MJPmAhA3DnX5JDORcga CbPEwhLj1xlwTgpeT+QfDmGJ5B5BlrrQFZVE1fChEjiJvyiSAO4yQPkrPVYTI7Xj34FnscPj /IrRUUka68MlHxPtFnAHr25VIuOS41lmYKYNwPNLRz9Ik6DmeTG3WJO2BQRNvXA0pXrJH1fN GSsRb+pKEKHKtL1803x71zQxCwLh+zLP1iXHVM5j8gX9zqupigQR/Cel2XPS44zWcDW8r7B0 q1eW4Jrv0x19p4P923voqn+joIAostyNTUjCeSrUdKth9jcdlam9X2DziA/DHDFfS5eq4fEv ABEBAAHCwHwEGAEIACYWIQQt33LlpaVbqJ2qQuHCPZHzoSX+qAUCWdWBrwIbDAUJA8JnAAAK CRDCPZHzoSX+qA3xB/4zS8zYh3Cbm3FllKz7+RKBw/ETBibFSKedQkbJzRlZhBc+XRwF61mi f0SXSdqKMbM1a98fEg8H5kV6GTo62BzvynVrf/FyT+zWbIVEuuZttMk2gWLIvbmWNyrQnzPl mnjK4AEvZGIt1pk+3+N/CMEfAZH5Aqnp0PaoytRZ/1vtMXNgMxlfNnb96giC3KMR6U0E+siA 4V7biIoyNoaN33t8m5FwEwd2FQDG9dAXWhG13zcm9gnk63BN3wyCQR+X5+jsfBaS4dvNzvQv h8Uq/YGjCoV1ofKYh3WKMY8avjq25nlrhzD/Nto9jHp8niwr21K//pXVA81R2qaXqGbql+zo Message-ID: <52fc83c0-4455-0d1b-0fee-42cfdec2580b@gmx.com> Date: Sat, 3 Nov 2018 17:17:58 +0800 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:60.0) Gecko/20100101 Thunderbird/60.2.1 MIME-Version: 1.0 In-Reply-To: <8965ea1d-c29f-7bdf-44cb-874511899567@suse.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 8bit X-Provags-ID: V03:K1:if2LHHLbr5BCDitmjkbaFbYraasI78D6H+uQIp/QsY2FwiZ8uyC VMh8Rw0zhnWdf2omoMBUhSozMCG+Fv9Xy46BoLAVCwGyh9XrpEzdrysPj8Jhqx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UsxEC2RfKTiq2WhmFGtnF2tsYXUd/EPHpERG1kv8PJ99uW5G6tRB/7Is5y3+TUh5kwxkGA v5fZCw5SKfQ== Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018/11/3 下午5:01, Nikolay Borisov wrote: > > > On 3.11.18 г. 10:36 ч., hmsjwzb wrote: >> The SZ_256M will cause trouble in platform with less than 256M memory. >> For example, a qemu virtual machine. >> >> Signed-off-by: hmsjwzb > > If you have actually taken the care to understand the code in > test_find_delalloc you would have seen that total_dirty and max_bytes > are actually inter-dependent so you cannot really change total_bytes > without adjusting max_bytes as well. Otherwise tests will start breaking. Nowadays even for VM, the memory size should start from 2G. If this 256M is causing problem, one should really re-consider the memory size of the VM. Not to mention the magic number is two ensure we have at least 2 file extents. > > NACK on this (and likely any future postings of this) since the tests > are sized in a such a way so as to test design limits (such as the max > extent size which is 128MB) And we should add some comment about this. Personally I prefer some comment with this and also use (2 * BTRFS_MAX_EXTENT_SIZE) other than this intermediate number. Thanks, Qu > > >> --- >> fs/btrfs/tests/extent-io-tests.c | 2 +- >> 1 file changed, 1 insertion(+), 1 deletion(-) >> >> diff --git a/fs/btrfs/tests/extent-io-tests.c b/fs/btrfs/tests/extent-io-tests.c >> index 9e0f4a01be14..cb23dce96a2d 100644 >> --- a/fs/btrfs/tests/extent-io-tests.c >> +++ b/fs/btrfs/tests/extent-io-tests.c >> @@ -62,7 +62,7 @@ static int test_find_delalloc(u32 sectorsize) >> struct page *page; >> struct page *locked_page = NULL; >> unsigned long index = 0; >> - u64 total_dirty = SZ_256M; >> + u64 total_dirty = SZ_64M; >> u64 max_bytes = SZ_128M; >> u64 start, end, test_start; >> u64 found; >>