Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758559AbYB1ENo (ORCPT ); Wed, 27 Feb 2008 23:13:44 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755943AbYB1ENd (ORCPT ); Wed, 27 Feb 2008 23:13:33 -0500 Received: from namei.org ([69.55.235.186]:53343 "EHLO us.intercode.com.au" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751978AbYB1ENd (ORCPT ); Wed, 27 Feb 2008 23:13:33 -0500 Date: Thu, 28 Feb 2008 15:13:07 +1100 (EST) From: James Morris X-X-Sender: jmorris@us.intercode.com.au To: "David P. Quigley" cc: hch@infradead.org, viro@ftp.linux.org.uk, trond.myklebust@fys.uio.no, bfields@fieldses.org, linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org Subject: Re: [PATCH 08/11] NFS: Introduce lifecycle management for label attribute. In-Reply-To: <1204150294-4678-9-git-send-email-dpquigl@tycho.nsa.gov> Message-ID: References: <1204150294-4678-1-git-send-email-dpquigl@tycho.nsa.gov> <1204150294-4678-9-git-send-email-dpquigl@tycho.nsa.gov> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 945 Lines: 35 On Wed, 27 Feb 2008, David P. Quigley wrote: > +#ifdef CONFIG_NFS_V4_SECURITY_LABEL > + if (nfs_server_capable(dir, NFS_CAP_SECURITY_LABEL)) > + nfs_fattr_alloc(&fattr, GFP_NOWAIT); > +#endif There are at least ten instances of the above. (Why do some of them use GFP_NOWAIT ?) > +#ifdef CONFIG_NFS_V4_SECURITY_LABEL > + if (server->caps & NFS_CAP_SECURITY_LABEL) { > + nfs_fattr_alloc(&fattr, GFP_KERNEL); > + nfs_fattr_alloc(&dir_fattr, GFP_KERNEL); > + } And a few of these. Static inline them, please. > +#define nfs_fattr_alloc(fattr, flags) > +#define nfs_fattr_fini(fattr) The preferred way to do this in Linux is as a static inline. - James -- James Morris -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/