Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755476AbZCaJDN (ORCPT ); Tue, 31 Mar 2009 05:03:13 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1752303AbZCaJC5 (ORCPT ); Tue, 31 Mar 2009 05:02:57 -0400 Received: from wa-out-1112.google.com ([209.85.146.180]:43800 "EHLO wa-out-1112.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751464AbZCaJCz (ORCPT ); Tue, 31 Mar 2009 05:02:55 -0400 DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=BsiWyrFgpe43aThF7WZjSPLqZMq/ba7nX+MzuH1Y0blp+R0Bz7sqzFk7mXlXv+kN1z gzDcmutxmebawlqgotllQJSLD2/dD9Qd1X1iw6EQ3xVt0e76Hi0JvUvNO9FZPcE+bszJ NFPmV/anYkJ9n+gJ+ARTjLqDw9D6DQfOG9H5g= MIME-Version: 1.0 In-Reply-To: <20090331060423.GR28946@ZenIV.linux.org.uk> References: <20090330163619.d08ba85e.akpm@linux-foundation.org> <20090331060423.GR28946@ZenIV.linux.org.uk> Date: Tue, 31 Mar 2009 14:32:37 +0530 Message-ID: Subject: Re: [PATCH] : Code cleanup for fs/inode.c as per checkpatch.pl From: Manish Katiyar To: Al Viro Cc: Andrew Morton , trivial@kernel.org, LKML Content-Type: multipart/mixed; boundary=0016363ba868d4a41d04666676cf Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 25697 Lines: 618 --0016363ba868d4a41d04666676cf Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable On Tue, Mar 31, 2009 at 11:34 AM, Al Viro wrote: > On Tue, Mar 31, 2009 at 08:13:56AM +0530, Manish Katiyar wrote: >> On Tue, Mar 31, 2009 at 5:06 AM, Andrew Morton >> wrote: >> > On Mon, 23 Mar 2009 09:09:26 +0530 >> > Manish Katiyar wrote: >> > >> >> Code cleanup for fs/inode.c as per checkpatch.pl >> >> Before: >> >> total: 24 errors, 25 warnings, 1546 lines checked >> >> After: >> >> total: 0 errors, 0 warnings, 1539 lines checked >> > >> > Probably OK, but again, please cc linux-kernel and/or linx-fsdevel. >> >> Hi Andrew, >> >> [ cced lkml ] > > That you have. =A0Now, how about the patch itself? ;-) Sorry, didn't realise that this didn't send the original message :-(. Below is the complete patch. I have also attached it in case it gets word wrapped even after using plugin with gmail. Code cleanup for fs/inode.c as per checkpatch.pl Before: total: 24 errors, 25 warnings, 1546 lines checked After: total: 0 errors, 0 warnings, 1539 lines checked Signed-off-by: Manish Katiyar --- fs/inode.c | 78 ++++++++++++++++++++++++--------------------------------= --- 1 files changed, 32 insertions(+), 46 deletions(-) diff --git a/fs/inode.c b/fs/inode.c index f75e9a4..e0dad15 100644 --- a/fs/inode.c +++ b/fs/inode.c @@ -98,7 +98,7 @@ static DEFINE_MUTEX(iprune_mutex); */ struct inodes_stat_t inodes_stat; -static struct kmem_cache * inode_cachep __read_mostly; +static struct kmem_cache *inode_cachep __read_mostly; static void wake_up_inode(struct inode *inode) { @@ -123,7 +123,7 @@ struct inode *inode_init_always(struct super_block *sb, struct inode *inode) static struct inode_operations empty_iops; static const struct file_operations empty_fops; - struct address_space * const mapping =3D &inode->i_data; + struct address_space *const mapping =3D &inode->i_data; inode->i_sb =3D sb; inode->i_blkbits =3D sb->s_blocksize_bits; @@ -206,7 +206,7 @@ static struct inode *alloc_inode(struct super_block *sb= ) return NULL; } -void destroy_inode(struct inode *inode) +void destroy_inode(struct inode *inode) { BUG_ON(inode_has_buffers(inode)); security_inode_free(inode); @@ -242,12 +242,11 @@ void inode_init_once(struct inode *inode) mutex_init(&inode->inotify_mutex); #endif } - EXPORT_SYMBOL(inode_init_once); static void init_once(void *foo) { - struct inode * inode =3D (struct inode *) foo; + struct inode *inode =3D (struct inode *) foo; inode_init_once(inode); } @@ -255,7 +254,7 @@ static void init_once(void *foo) /* * inode_lock must be held */ -void __iget(struct inode * inode) +void __iget(struct inode *inode) { if (atomic_read(&inode->i_count)) { atomic_inc(&inode->i_count); @@ -279,7 +278,7 @@ void clear_inode(struct inode *inode) { might_sleep(); invalidate_inode_buffers(inode); - + BUG_ON(inode->i_data.nrpages); BUG_ON(!(inode->i_state & I_FREEING)); BUG_ON(inode->i_state & I_CLEAR); @@ -293,7 +292,6 @@ void clear_inode(struct inode *inode) cd_forget(inode); inode->i_state =3D I_CLEAR; } - EXPORT_SYMBOL(clear_inode); /* @@ -341,8 +339,8 @@ static int invalidate_list(struct list_head *head, struct list_head *dispose) next =3D head->next; for (;;) { - struct list_head * tmp =3D next; - struct inode * inode; + struct list_head *tmp =3D next; + struct inode *inode; /* * We can reschedule here without worrying about the list's @@ -378,7 +376,7 @@ static int invalidate_list(struct list_head *head, struct list_head *dispose) * fails because there are busy inodes then a non zero value is returned. * If the discard is successful all the inodes have been discarded. */ -int invalidate_inodes(struct super_block * sb) +int invalidate_inodes(struct super_block *sb) { int busy; LIST_HEAD(throw_away); @@ -394,7 +392,6 @@ int invalidate_inodes(struct super_block * sb) return busy; } - EXPORT_SYMBOL(invalidate_inodes); static int can_unuse(struct inode *inode) @@ -490,7 +487,7 @@ static int shrink_icache_memory(int nr, gfp_t gfp_mask) * Nasty deadlock avoidance. We may hold various FS locks, * and we don't want to recurse into the FS that called us * in clear_inode() and friends.. - */ + */ if (!(gfp_mask & __GFP_FS)) return -1; prune_icache(nr); @@ -510,10 +507,11 @@ static void __wait_on_freeing_inode(struct inode *ino= de); * by hand after calling find_inode now! This simplifies iunique and won't * add any additional branch in the common code. */ -static struct inode * find_inode(struct super_block * sb, struct hlist_head *head, int (*test)(struct inode *, void *), void *data) +static struct inode *find_inode(struct super_block *sb, struct hlist_head *head, + int (*test)(struct inode *, void *), void *data) { struct hlist_node *node; - struct inode * inode =3D NULL; + struct inode *inode =3D NULL; repeat: hlist_for_each_entry(inode, node, head, i_hash) { @@ -534,10 +532,11 @@ repeat: * find_inode_fast is the fast path version of find_inode, see the comment= at * iget_locked for details. */ -static struct inode * find_inode_fast(struct super_block * sb, struct hlist_head *head, unsigned long ino) +static struct inode *find_inode_fast(struct super_block *sb, + struct hlist_head *head, unsigned long ino) { struct hlist_node *node; - struct inode * inode =3D NULL; + struct inode *inode =3D NULL; repeat: hlist_for_each_entry(inode, node, head, i_hash) { @@ -617,10 +616,10 @@ struct inode *new_inode(struct super_block *sb) * here to attempt to avoid that. */ static unsigned int last_ino; - struct inode * inode; + struct inode *inode; spin_lock_prefetch(&inode_lock); -=09 + inode =3D alloc_inode(sb); if (inode) { spin_lock(&inode_lock); @@ -631,7 +630,6 @@ struct inode *new_inode(struct super_block *sb) } return inode; } - EXPORT_SYMBOL(new_inode); void unlock_new_inode(struct inode *inode) @@ -659,7 +657,6 @@ void unlock_new_inode(struct inode *inode) inode->i_state &=3D ~(I_LOCK|I_NEW); wake_up_inode(inode); } - EXPORT_SYMBOL(unlock_new_inode); /* @@ -668,13 +665,16 @@ EXPORT_SYMBOL(unlock_new_inode); * We no longer cache the sb_flags in i_flags - see fs.h * -- rmk@arm.uk.linux.org */ -static struct inode * get_new_inode(struct super_block *sb, struct hlist_head *head, int (*test)(struct inode *, void *), int (*set)(struct inode *, void *), void *data) +static struct inode *get_new_inode(struct super_block *sb, + struct hlist_head *head, + int (*test)(struct inode *, void *), + int (*set)(struct inode *, void *), void *data) { - struct inode * inode; + struct inode *inode; inode =3D alloc_inode(sb); if (inode) { - struct inode * old; + struct inode *old; spin_lock(&inode_lock); /* We released the lock, so.. */ @@ -716,13 +716,14 @@ set_failed: * get_new_inode_fast is the fast path version of get_new_inode, see the * comment at iget_locked for details. */ -static struct inode * get_new_inode_fast(struct super_block *sb, struct hlist_head *head, unsigned long ino) +static struct inode *get_new_inode_fast(struct super_block *sb, + struct hlist_head *head, unsigned long ino) { - struct inode * inode; + struct inode *inode; inode =3D alloc_inode(sb); if (inode) { - struct inode * old; + struct inode *old; spin_lock(&inode_lock); /* We released the lock, so.. */ @@ -808,7 +809,6 @@ struct inode *igrab(struct inode *inode) spin_unlock(&inode_lock); return inode; } - EXPORT_SYMBOL(igrab); /** @@ -909,7 +909,6 @@ struct inode *ilookup5_nowait(struct super_block *sb, unsigned long hashval, return ifind(sb, head, test, data, 0); } - EXPORT_SYMBOL(ilookup5_nowait); /** @@ -938,7 +937,6 @@ struct inode *ilookup5(struct super_block *sb, unsigned long hashval, return ifind(sb, head, test, data, 1); } - EXPORT_SYMBOL(ilookup5); /** @@ -961,7 +959,6 @@ struct inode *ilookup(struct super_block *sb, unsigned long ino) return ifind_fast(sb, head, ino); } - EXPORT_SYMBOL(ilookup); /** @@ -1000,7 +997,6 @@ struct inode *iget5_locked(struct super_block *sb, unsigned long hashval, */ return get_new_inode(sb, head, test, set, data); } - EXPORT_SYMBOL(iget5_locked); /** @@ -1032,7 +1028,6 @@ struct inode *iget_locked(struct super_block *sb, unsigned long ino) */ return get_new_inode_fast(sb, head, ino); } - EXPORT_SYMBOL(iget_locked); int insert_inode_locked(struct inode *inode) @@ -1061,7 +1056,6 @@ int insert_inode_locked(struct inode *inode) iput(old); } } - EXPORT_SYMBOL(insert_inode_locked); int insert_inode_locked4(struct inode *inode, unsigned long hashval, @@ -1091,7 +1085,6 @@ int insert_inode_locked4(struct inode *inode, unsigned long hashval, iput(old); } } - EXPORT_SYMBOL(insert_inode_locked4); /** @@ -1109,7 +1102,6 @@ void __insert_inode_hash(struct inode *inode, unsigned long hashval) hlist_add_head(&inode->i_hash, head); spin_unlock(&inode_lock); } - EXPORT_SYMBOL(__insert_inode_hash); /** @@ -1124,7 +1116,6 @@ void remove_inode_hash(struct inode *inode) hlist_del_init(&inode->i_hash); spin_unlock(&inode_lock); } - EXPORT_SYMBOL(remove_inode_hash); /* @@ -1171,7 +1162,6 @@ void generic_delete_inode(struct inode *inode) BUG_ON(inode->i_state !=3D I_CLEAR); destroy_inode(inode); } - EXPORT_SYMBOL(generic_delete_inode); static void generic_forget_inode(struct inode *inode) @@ -1218,12 +1208,11 @@ void generic_drop_inode(struct inode *inode) else generic_forget_inode(inode); } - EXPORT_SYMBOL_GPL(generic_drop_inode); /* * Called when we're dropping the last reference - * to an inode. + * to an inode. * * Call the FS "drop()" function, defaulting to * the legacy UNIX filesystem behaviour.. @@ -1243,7 +1232,7 @@ static inline void iput_final(struct inode *inode) } /** - * iput - put an inode + * iput - put an inode * @inode: inode to put * * Puts an inode, dropping its usage count. If the inode use count hits @@ -1260,7 +1249,6 @@ void iput(struct inode *inode) iput_final(inode); } } - EXPORT_SYMBOL(iput); /** @@ -1271,10 +1259,10 @@ EXPORT_SYMBOL(iput); * Returns the block number on the device holding the inode that * is the disk block number for the block of the file requested. * That is, asked for block 4 of inode 1 the function will return the - * disk block relative to the disk start that holds that block of the + * disk block relative to the disk start that holds that block of the * file. */ -sector_t bmap(struct inode * inode, sector_t block) +sector_t bmap(struct inode *inode, sector_t block) { sector_t res =3D 0; if (inode->i_mapping->a_ops->bmap) @@ -1377,7 +1365,6 @@ void file_update_time(struct file *file) mark_inode_dirty_sync(inode); mnt_drop_write(file->f_path.mnt); } - EXPORT_SYMBOL(file_update_time); int inode_needs_sync(struct inode *inode) @@ -1388,7 +1375,6 @@ int inode_needs_sync(struct inode *inode) return 1; return 0; } - EXPORT_SYMBOL(inode_needs_sync); int inode_wait(void *word) --=20 1.5.4.3 Thanks - Manish > --0016363ba868d4a41d04666676cf Content-Type: text/x-diff; charset=US-ASCII; name="0002-Patch-cleanup-for-fs-inode.c-as-per-checkpatch.pl.patch" Content-Disposition: attachment; filename="0002-Patch-cleanup-for-fs-inode.c-as-per-checkpatch.pl.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_fsyda3u60 RnJvbSAzZWMxOGUyOGQ0MzlkNTBjMjc0NzExZGFiYjBlZmU0ZTA5NGRhNTFmIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBNYW5pc2ggS2F0aXlhci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IHN0YXJ0IHRoYXQgaG9sZHMgdGhhdCBibG9j ayBvZiB0aGUKICAqCWZpbGUuCiAgKi8KLXNlY3Rvcl90IGJtYXAoc3RydWN0IGlub2RlICogaW5v ZGUsIHNlY3Rvcl90IGJsb2NrKQorc2VjdG9yX3QgYm1hcChzdHJ1Y3QgaW5vZGUgKmlub2RlLCBz ZWN0b3JfdCBibG9jaykKIHsKIAlzZWN0b3JfdCByZXMgPSAwOwogCWlmIChpbm9kZS0+aV9tYXBw aW5nLT5hX29wcy0+Ym1hcCkKQEAgLTEzNzcsNyArMTM2NSw2IEBAIHZvaWQgZmlsZV91cGRhdGVf dGltZShzdHJ1Y3QgZmlsZSAqZmlsZSkKIAkJbWFya19pbm9kZV9kaXJ0eV9zeW5jKGlub2RlKTsK IAltbnRfZHJvcF93cml0ZShmaWxlLT5mX3BhdGgubW50KTsKIH0KLQogRVhQT1JUX1NZTUJPTChm aWxlX3VwZGF0ZV90aW1lKTsKIAogaW50IGlub2RlX25lZWRzX3N5bmMoc3RydWN0IGlub2RlICpp bm9kZSkKQEAgLTEzODgsNyArMTM3NSw2IEBAIGludCBpbm9kZV9uZWVkc19zeW5jKHN0cnVjdCBp bm9kZSAqaW5vZGUpCiAJCXJldHVybiAxOwogCXJldHVybiAwOwogfQotCiBFWFBPUlRfU1lNQk9M KGlub2RlX25lZWRzX3N5bmMpOwogCiBpbnQgaW5vZGVfd2FpdCh2b2lkICp3b3JkKQotLSAKMS41 LjQuMwoK --0016363ba868d4a41d04666676cf-- -- 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/