From mboxrd@z Thu Jan 1 00:00:00 1970 From: Wu Fengguang Subject: Re: [PATCH 4/5] writeback: per task dirty rate limit Date: Tue, 16 Aug 2011 15:22:51 +0800 Message-ID: <20110816072251.GA12264@localhost> References: <20110816022006.348714319@intel.com> <20110816022329.063575688@intel.com> <20110816071709.GA1302@thinkpad> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: "linux-fsdevel@vger.kernel.org" , Peter Zijlstra , Andrew Morton , Jan Kara , Christoph Hellwig , Dave Chinner , Greg Thelen , Minchan Kim , Vivek Goyal , linux-mm , LKML To: Andrea Righi Return-path: Content-Disposition: inline In-Reply-To: <20110816071709.GA1302@thinkpad> Sender: owner-linux-mm@kvack.org List-Id: linux-fsdevel.vger.kernel.org > > + if (!bdi->dirty_exceeded) > > + ratelimit = current->nr_dirtied_pause; > > + else > > + ratelimit = min(ratelimit, 32 >> (PAGE_SHIFT - 10)); > > Usage of ratelimit before init? > > Maybe: > > ratelimit = current->nr_dirtied_pause; > if (bdi->dirty_exceeded) > ratelimit = min(ratelimit, 32 >> (PAGE_SHIFT - 10)); Good catch, thanks! That's indeed the original form. I changed it to make the code more aligned... Thanks, Fengguang -- To unsubscribe, send a message with 'unsubscribe linux-mm' in the body to majordomo@kvack.org. For more info on Linux MM, see: http://www.linux-mm.org/ . Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/ Don't email: email@kvack.org