Received: by 2002:ac0:a582:0:0:0:0:0 with SMTP id m2-v6csp3869864imm; Mon, 15 Oct 2018 05:39:04 -0700 (PDT) X-Google-Smtp-Source: ACcGV62Frg9EfKOgK+nlfsCk0AofV9L+mtF1x1QRAh609OYk0PbHVEiyU10DggATTqN8hCCF8efM X-Received: by 2002:a17:902:b83:: with SMTP id 3-v6mr1313371plr.250.1539607144287; Mon, 15 Oct 2018 05:39:04 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1539607144; cv=none; d=google.com; s=arc-20160816; b=fhRTu47Y6kU3z1624nilOhVNu/i+U+I5SNSMHdhNgIe4Jxjo9pEps1xfrIbOJDd44Q cqNeWE/3kiLc9q4XVlEZ2wc6MrNYLa8pU6vuOftEdnedGR1grBb5LpSkoihSlVNUv/CN 4+7PPUVoHbjeJ4mfHIbL7eQlrTL7XV+db4MGUD3MlU7LMKmjJ5vleuSccpW+oSCaF43M rEyqqKHsMQRXOIPst/36ZvF8EY1lFiVwJ03ZtDLGw+Dc8VmscpV+EPDVeMVL/3daArdh Cqj3v7vGKOJqApLSByXx+sAUyR6nf8P6ysj9jdvIS89br0Dp59P6p1UCWFk/KhWIQgLj YKFQ== 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:from:references:to:subject; bh=nWJYEx31CPnl0UC5sszMZ/y4yNoQwiBQlSa4N5eRz1w=; b=d+MlmYR0o3e7QG2i9ZVeiAktQ0DY4J8qc3KwF5Gg0e2yi9Myz6iivKdknKKGIJb+7a 3Jp1NAgUfRsXkbKGPwLf0mkEyhC3BezLqyG9td+RY3uAaR2bmMGZKvIhVBR2yl/JIo4i owWHelFgBBxkgSRTXtS1xIoGSn9jNHGxvT4ZVYnSbLkATNxa3MM/MlCLLz54RwDe7zgP NEOGrfRG2JT1i4yQ6z9ThPkniK37VRCO6lE/pP1gffzov9PuldRSh5mGcvghvFbXrdS/ F99VdCE7vqSC2Agm1KdR6PZHYiqTjlppLH3rwVLKvPGUxR1nDja0EWvMmcBObUdoD5Vm Ph7w== 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 a11-v6si10581224pgd.400.2018.10.15.05.38.50; Mon, 15 Oct 2018 05:39:04 -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 S1726989AbeJOUXR (ORCPT + 99 others); Mon, 15 Oct 2018 16:23:17 -0400 Received: from szxga06-in.huawei.com ([45.249.212.32]:58888 "EHLO huawei.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1726870AbeJOUXP (ORCPT ); Mon, 15 Oct 2018 16:23:15 -0400 Received: from DGGEMS405-HUB.china.huawei.com (unknown [172.30.72.60]) by Forcepoint Email with ESMTP id 2980ACBDE9BFC; Mon, 15 Oct 2018 20:38:06 +0800 (CST) Received: from [127.0.0.1] (10.134.22.195) by DGGEMS405-HUB.china.huawei.com (10.3.19.205) with Microsoft SMTP Server id 14.3.399.0; Mon, 15 Oct 2018 20:38:02 +0800 Subject: Re: [f2fs-dev] [PATCH] f2fs: clear cold data flag if IO is not counted To: Jaegeuk Kim , , References: <20181010212217.52289-1-jaegeuk@kernel.org> From: Chao Yu Message-ID: <3f08031e-d195-5bc1-67e1-f3b6eab3506b@huawei.com> Date: Mon, 15 Oct 2018 20:38:01 +0800 User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.9.1 MIME-Version: 1.0 In-Reply-To: <20181010212217.52289-1-jaegeuk@kernel.org> Content-Type: text/plain; charset="windows-1252" Content-Language: en-US Content-Transfer-Encoding: 7bit X-Originating-IP: [10.134.22.195] X-CFilter-Loop: Reflected Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2018/10/11 5:22, Jaegeuk Kim wrote: > If we clear the cold data flag out of the writeback flow, we can miscount > -1 by end_io. I didn't get it, which count do you mean? Thanks, > > Signed-off-by: Jaegeuk Kim > --- > fs/f2fs/data.c | 4 ---- > 1 file changed, 4 deletions(-) > > diff --git a/fs/f2fs/data.c b/fs/f2fs/data.c > index 29a9d3b8f709..4102799b5558 100644 > --- a/fs/f2fs/data.c > +++ b/fs/f2fs/data.c > @@ -2636,10 +2636,6 @@ static int f2fs_set_data_page_dirty(struct page *page) > if (!PageUptodate(page)) > SetPageUptodate(page); > > - /* don't remain PG_checked flag which was set during GC */ > - if (is_cold_data(page)) > - clear_cold_data(page); > - > if (f2fs_is_atomic_file(inode) && !f2fs_is_commit_atomic_write(inode)) { > if (!IS_ATOMIC_WRITTEN_PAGE(page)) { > f2fs_register_inmem_page(inode, page); >