From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753124AbbF2VoH (ORCPT ); Mon, 29 Jun 2015 17:44:07 -0400 Received: from ipmail05.adl6.internode.on.net ([150.101.137.143]:36724 "EHLO ipmail05.adl6.internode.on.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752718AbbF2Vn7 (ORCPT ); Mon, 29 Jun 2015 17:43:59 -0400 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A2B3CADKupFVPN6zLHlbgxGBM4JQg3ykPQEBBo15jAMCAgEBAoE/TQEBAQEBAQcBAQEBQAE/hCIBAQEDATocIwULCAMUAQMJJQ8FJQMHGhOIJwfJcQEBAQEGAQEBAR4YhgSFLoUGB4MXgRQBBJEngl2LVI12ikaBCYFagU8sMYJIAQEB Date: Tue, 30 Jun 2015 07:43:55 +1000 From: Dave Chinner To: SF Markus Elfring Cc: xfs@oss.sgi.com, LKML , kernel-janitors@vger.kernel.org, Julia Lawall Subject: Re: [PATCH] XFS: Delete unnecessary checks before the function call "xfs_qm_dqrele" Message-ID: <20150629214355.GE7943@dastard> References: <530CD2C4.4050903@users.sourceforge.net> <530CF8FF.8080600@users.sourceforge.net> <530DD06F.4090703@users.sourceforge.net> <5317A59D.4@users.sourceforge.net> <5479F823.60900@users.sourceforge.net> <20141130230904.GF16151@dastard> <558D1833.3080009@users.sourceforge.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <558D1833.3080009@users.sourceforge.net> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Jun 26, 2015 at 11:15:31AM +0200, SF Markus Elfring wrote: > From: Markus Elfring > Date: Fri, 26 Jun 2015 11:05:41 +0200 > > The xfs_qm_dqrele() function tests whether its argument is NULL and > then returns immediately. True. > Thus the test around the call is not needed. But wrong. xfs_dqrele_inode() gets called on every inode in the inode cache, and this change results in a cacheline in every inode being dirtied even if they don't have dquots attached. Given the inode cache can hold tens to hundreds of millions of inodes on large machines, we don't want to dirty any cachelines we don't need to while walking the inode cache and releasing dquots... Cheers, Dave. -- Dave Chinner david@fromorbit.com