Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C253FC61DA4 for ; Fri, 3 Feb 2023 06:12:07 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S231277AbjBCGMG (ORCPT ); Fri, 3 Feb 2023 01:12:06 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:54762 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230094AbjBCGME (ORCPT ); Fri, 3 Feb 2023 01:12:04 -0500 Received: from ams.source.kernel.org (ams.source.kernel.org [145.40.68.75]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id DB09789FAE for ; Thu, 2 Feb 2023 22:11:33 -0800 (PST) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id 92745B82916 for ; Fri, 3 Feb 2023 06:11:17 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id C4CBCC433D2; Fri, 3 Feb 2023 06:11:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1675404676; bh=MAggVnzFKDMQ6sFkdhtLT/WSLZ0MVSVv/6OXYW3ftB4=; h=Date:Subject:To:Cc:References:From:In-Reply-To:From; b=QJlRH8umlV+0TMBPBrCGs0UJ1hukXG5vVraOL+qqlSLAxvO3P9jW4ehrIwXKF8dT5 JPB62P/JXtyB4Xh+bx0ixF/EJwYYOecTbNkJ7/pkJ97AGuskaKAYX4HZ15UUHEhTmH vAbdw2cUvUuBkq1GUsTi62QSNQPypOKRQkfoMs46BCzoeqYWwyfGItoEsvqBhtGzrX XnHoijtn72lUlJ0NcirHRR40uRkaGr+jsGH170McSW4ZqFQX854XdTtAaPKM2HFe8I ylUlXal6ItW+H2gY7OKYco/r8/VikioBB3mARdWrsykGkSKqmfu9F41IRp9VvcbV7e zLnNlu16i3Wfg== Message-ID: Date: Fri, 3 Feb 2023 14:11:12 +0800 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.6.1 Subject: Re: [PATCH 1/2 v3] f2fs: fix wrong calculation of block age Content-Language: en-US To: qixiaoyu1 , Jaegeuk Kim Cc: linux-kernel@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, Ping Xiong , Xiaoyu Qi References: <938a8e61-4e47-1acc-938c-c90d213d2c86@kernel.org> <20230202082028.9013-1-qixiaoyu1@xiaomi.com> From: Chao Yu In-Reply-To: <20230202082028.9013-1-qixiaoyu1@xiaomi.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2023/2/2 16:20, qixiaoyu1 wrote: > Currently we wrongly calculate the new block age to > old * LAST_AGE_WEIGHT / 100. > > Fix it to new * (100 - LAST_AGE_WEIGHT) / 100 > + old * LAST_AGE_WEIGHT / 100. > > Signed-off-by: qixiaoyu1 > Signed-off-by: xiongping1 Reviewed-by: Chao Yu Thanks,