From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751429AbdGQOjT (ORCPT ); Mon, 17 Jul 2017 10:39:19 -0400 Received: from mx1.redhat.com ([209.132.183.28]:46962 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751300AbdGQOjR (ORCPT ); Mon, 17 Jul 2017 10:39:17 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 41845C02C73F Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx07.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=longman@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 41845C02C73F Subject: Re: [PATCH 2/4] fs/dcache: Report negative dentry number in dentry-state To: Matthew Wilcox Cc: Alexander Viro , Jonathan Corbet , linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org, linux-fsdevel@vger.kernel.org, "Paul E. McKenney" , Andrew Morton , Ingo Molnar , Miklos Szeredi References: <1500298773-7510-1-git-send-email-longman@redhat.com> <1500298773-7510-3-git-send-email-longman@redhat.com> <20170717140934.GA14983@bombadil.infradead.org> From: Waiman Long Organization: Red Hat Message-ID: Date: Mon, 17 Jul 2017 10:39:11 -0400 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:52.0) Gecko/20100101 Thunderbird/52.2.0 MIME-Version: 1.0 In-Reply-To: <20170717140934.GA14983@bombadil.infradead.org> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit Content-Language: en-US X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.31]); Mon, 17 Jul 2017 14:39:17 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 07/17/2017 10:09 AM, Matthew Wilcox wrote: > On Mon, Jul 17, 2017 at 09:39:31AM -0400, Waiman Long wrote: >> @@ -63,9 +63,10 @@ struct qstr { >> struct dentry_stat_t { >> long nr_dentry; >> long nr_unused; >> - long age_limit; /* age in seconds */ >> - long want_pages; /* pages requested by system */ >> - long dummy[2]; >> + long nr_negative; /* # of negative dentries */ >> + long age_limit; /* age in seconds */ >> + long want_pages; /* pages requested by system */ >> + long dummy; >> }; >> extern struct dentry_stat_t dentry_stat; > You can't just insert a field in the middle like that. It'll break any code > parsing /proc/sys/fs/dentry-state. You have to put it at the end: > > long age_limit; /* age in seconds */ > long want_pages; /* pages requested by system */ > - long dummy[2]; > + long nr_negative; /* # of negative dentries */ > + long dummy; > }; My mistake. I will send out an updated patches later on after collecting more feedback to make the new field go to the end. Cheers, Longman