From: Steven Whitehouse <swhiteho@redhat.com>
To: linux-kernel@vger.kernel.org, cluster-devel@redhat.com
Cc: Steven Whitehouse <swhiteho@redhat.com>
Subject: [PATCH 23/32] GFS2: Remove gfs2_dinode_print() function
Date: Thu, 19 May 2011 09:47:18 +0100 [thread overview]
Message-ID: <1305794847-3291-24-git-send-email-swhiteho@redhat.com> (raw)
In-Reply-To: <1305794847-3291-1-git-send-email-swhiteho@redhat.com>
This function was intended for debugging purposes, but it is not very
useful. If we want to know what is on disk then all we need is a
block number and gfs2_edit can give us much better information about
what is there. Otherwise, if we are interested in what is stored in
the in-core inode, it doesn't help us out there either.
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
diff --git a/fs/gfs2/inode.c b/fs/gfs2/inode.c
index a8c14c9..7c2121f 100644
--- a/fs/gfs2/inode.c
+++ b/fs/gfs2/inode.c
@@ -329,8 +329,7 @@ static int gfs2_dinode_in(struct gfs2_inode *ip, const void *buf)
return 0;
corrupt:
- if (gfs2_consist_inode(ip))
- gfs2_dinode_print(ip);
+ gfs2_consist_inode(ip);
return -EIO;
}
@@ -901,24 +900,3 @@ void gfs2_dinode_out(const struct gfs2_inode *ip, void *buf)
str->di_mtime_nsec = cpu_to_be32(ip->i_inode.i_mtime.tv_nsec);
str->di_ctime_nsec = cpu_to_be32(ip->i_inode.i_ctime.tv_nsec);
}
-
-void gfs2_dinode_print(const struct gfs2_inode *ip)
-{
- printk(KERN_INFO " no_formal_ino = %llu\n",
- (unsigned long long)ip->i_no_formal_ino);
- printk(KERN_INFO " no_addr = %llu\n",
- (unsigned long long)ip->i_no_addr);
- printk(KERN_INFO " i_size = %llu\n",
- (unsigned long long)i_size_read(&ip->i_inode));
- printk(KERN_INFO " blocks = %llu\n",
- (unsigned long long)gfs2_get_inode_blocks(&ip->i_inode));
- printk(KERN_INFO " i_goal = %llu\n",
- (unsigned long long)ip->i_goal);
- printk(KERN_INFO " i_diskflags = 0x%.8X\n", ip->i_diskflags);
- printk(KERN_INFO " i_height = %u\n", ip->i_height);
- printk(KERN_INFO " i_depth = %u\n", ip->i_depth);
- printk(KERN_INFO " i_entries = %u\n", ip->i_entries);
- printk(KERN_INFO " i_eattr = %llu\n",
- (unsigned long long)ip->i_eattr);
-}
-
diff --git a/fs/gfs2/inode.h b/fs/gfs2/inode.h
index f9b8289..7ed60aa 100644
--- a/fs/gfs2/inode.h
+++ b/fs/gfs2/inode.h
@@ -115,7 +115,6 @@ extern int gfs2_permission(struct inode *inode, int mask, unsigned int flags);
extern int gfs2_setattr_simple(struct gfs2_inode *ip, struct iattr *attr);
extern struct inode *gfs2_lookup_simple(struct inode *dip, const char *name);
extern void gfs2_dinode_out(const struct gfs2_inode *ip, void *buf);
-extern void gfs2_dinode_print(const struct gfs2_inode *ip);
extern const struct inode_operations gfs2_file_iops;
extern const struct inode_operations gfs2_dir_iops;
diff --git a/fs/gfs2/ops_inode.c b/fs/gfs2/ops_inode.c
index 6b8c2bd..2607c2c 100644
--- a/fs/gfs2/ops_inode.c
+++ b/fs/gfs2/ops_inode.c
@@ -754,8 +754,7 @@ static int gfs2_rename(struct inode *odir, struct dentry *odentry,
if (S_ISDIR(nip->i_inode.i_mode)) {
if (nip->i_entries < 2) {
- if (gfs2_consist_inode(nip))
- gfs2_dinode_print(nip);
+ gfs2_consist_inode(nip);
error = -EIO;
goto out_gunlock;
}
diff --git a/fs/gfs2/super.c b/fs/gfs2/super.c
index 58fe3a4..3061ac6 100644
--- a/fs/gfs2/super.c
+++ b/fs/gfs2/super.c
@@ -1341,8 +1341,7 @@ static int gfs2_dinode_dealloc(struct gfs2_inode *ip)
int error;
if (gfs2_get_inode_blocks(&ip->i_inode) != 1) {
- if (gfs2_consist_inode(ip))
- gfs2_dinode_print(ip);
+ gfs2_consist_inode(ip);
return -EIO;
}
--
1.7.4
next prev parent reply other threads:[~2011-05-19 9:10 UTC|newest]
Thread overview: 33+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-19 8:46 GFS2: Pre-pull patch posting (merge window) Steven Whitehouse
2011-05-19 8:46 ` [PATCH 01/32] GFS2: Dump better debug info if a bitmap inconsistency is detected Steven Whitehouse
2011-05-19 8:46 ` [PATCH 02/32] GFS2: remove *leaf_call_t and simplify leaf_dealloc Steven Whitehouse
2011-05-19 8:46 ` [PATCH 03/32] GFS2: Combine transaction from gfs2_dir_exhash_dealloc Steven Whitehouse
2011-05-19 8:46 ` [PATCH 04/32] GFS2: pass leaf_bh into leaf_dealloc Steven Whitehouse
2011-05-19 8:47 ` [PATCH 05/32] GFS2: move function foreach_leaf to gfs2_dir_exhash_dealloc Steven Whitehouse
2011-05-19 8:47 ` [PATCH 06/32] GFS2: Make ->write_inode() really write Steven Whitehouse
2011-05-19 8:47 ` [PATCH 07/32] GFS2: Use filemap_fdatawrite() to write back the AIL Steven Whitehouse
2011-05-19 8:47 ` [PATCH 08/32] GFS2: Alter point of entry to glock lru list for glocks with an address_space Steven Whitehouse
2011-05-19 8:47 ` [PATCH 09/32] GFS2: Remove unused macro Steven Whitehouse
2011-05-19 8:47 ` [PATCH 10/32] GFS2: Clean up fsync() Steven Whitehouse
2011-05-19 8:47 ` [PATCH 11/32] GFS2: Improve tracing support (adds two flags) Steven Whitehouse
2011-05-19 8:47 ` [PATCH 12/32] GFS2: Optimise glock lru and end of life inodes Steven Whitehouse
2011-05-19 8:47 ` [PATCH 13/32] GFS2: Make writeback more responsive to system conditions Steven Whitehouse
2011-05-19 8:47 ` [PATCH 14/32] GFS2: Add an AIL writeback tracepoint Steven Whitehouse
2011-05-19 8:47 ` [PATCH 15/32] GFS2: make sure fallocate bytes is a multiple of blksize Steven Whitehouse
2011-05-19 8:47 ` [PATCH 16/32] GFS2: Fix ail list traversal Steven Whitehouse
2011-05-19 8:47 ` [PATCH 17/32] GFS2: Improve bug trap code in ->releasepage() Steven Whitehouse
2011-05-19 8:47 ` [PATCH 18/32] GFS2: Double check link count under glock Steven Whitehouse
2011-05-19 8:47 ` [PATCH 19/32] GFS2: Don't use a try lock when promoting to a higher mode Steven Whitehouse
2011-05-19 8:47 ` [PATCH 20/32] GFS2: Don't use gfs2_change_nlink in link syscall Steven Whitehouse
2011-05-19 8:47 ` [PATCH 21/32] GFS2: Make gfs2_dir_del update link count when required Steven Whitehouse
2011-05-19 8:47 ` [PATCH 22/32] GFS2: When adding a new dir entry, inc link count if it is a subdir Steven Whitehouse
2011-05-19 8:47 ` Steven Whitehouse [this message]
2011-05-19 8:47 ` [PATCH 24/32] GFS2: Move gfs2_refresh_inode() and friends into glops.c Steven Whitehouse
2011-05-19 8:47 ` [PATCH 25/32] GFS2: Move most of the remaining inode.c into ops_inode.c Steven Whitehouse
2011-05-19 8:47 ` [PATCH 26/32] GFS2: Move final part of inode.c into super.c Steven Whitehouse
2011-05-19 8:47 ` [PATCH 27/32] GFS2: Inode.c is empty now, remove it Steven Whitehouse
2011-05-19 8:47 ` [PATCH 28/32] GFS2: Rename ops_inode.c to inode.c Steven Whitehouse
2011-05-19 8:47 ` [PATCH 29/32] GFS2: Use UUID field in generic superblock Steven Whitehouse
2011-05-19 8:47 ` [PATCH 30/32] GFS2: Clean up mkdir Steven Whitehouse
2011-05-19 8:47 ` [PATCH 31/32] GFS2: Clean up symlink creation Steven Whitehouse
2011-05-19 8:47 ` [PATCH 32/32] GFS2: Move all locking inside the inode creation function Steven Whitehouse
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1305794847-3291-24-git-send-email-swhiteho@redhat.com \
--to=swhiteho@redhat.com \
--cc=cluster-devel@redhat.com \
--cc=linux-kernel@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®