* [patch 2/3] btrfs cleanup: remove more dead code
@ 2010-03-20 11:37 ` Dan Carpenter
0 siblings, 0 replies; 2+ messages in thread
From: Dan Carpenter @ 2010-03-20 11:37 UTC (permalink / raw)
To: Chris Mason
Cc: Dan Carpenter, Christoph Hellwig, Venkatesh Pallipadi,
André Goddard Rosa, linux-btrfs, linux-kernel,
kernel-janitors
rb_node cannot be an ERR_PTR() here so I removed the misleading check.
Also I removed some more dead code at the bottom.
It looks like the code from lookup_extent_mapping() may have been
copy and pasted into search_extent_mapping()?
Signed-off-by: Dan Carpenter <error27@gmail.com>
---
This doesn't change anything. Could you put it into linux-next?
diff --git a/fs/btrfs/extent_map.c b/fs/btrfs/extent_map.c
index 94668b1..010f299 100644
--- a/fs/btrfs/extent_map.c
+++ b/fs/btrfs/extent_map.c
@@ -380,16 +380,7 @@ struct extent_map *search_extent_mapping(struct extent_map_tree *tree,
em = NULL;
goto out;
}
- if (IS_ERR(rb_node)) {
- em = ERR_PTR(PTR_ERR(rb_node));
- goto out;
- }
em = rb_entry(rb_node, struct extent_map, rb_node);
- goto found;
-
- em = NULL;
- goto out;
-
found:
atomic_inc(&em->refs);
out:
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [patch 2/3] btrfs cleanup: remove more dead code
@ 2010-03-20 11:37 ` Dan Carpenter
0 siblings, 0 replies; 2+ messages in thread
From: Dan Carpenter @ 2010-03-20 11:37 UTC (permalink / raw)
To: Chris Mason
Cc: Dan Carpenter, Christoph Hellwig, Venkatesh Pallipadi,
André Goddard Rosa, linux-btrfs, linux-kernel,
kernel-janitors
rb_node cannot be an ERR_PTR() here so I removed the misleading check.
Also I removed some more dead code at the bottom.
It looks like the code from lookup_extent_mapping() may have been
copy and pasted into search_extent_mapping()?
Signed-off-by: Dan Carpenter <error27@gmail.com>
---
This doesn't change anything. Could you put it into linux-next?
diff --git a/fs/btrfs/extent_map.c b/fs/btrfs/extent_map.c
index 94668b1..010f299 100644
--- a/fs/btrfs/extent_map.c
+++ b/fs/btrfs/extent_map.c
@@ -380,16 +380,7 @@ struct extent_map *search_extent_mapping(struct extent_map_tree *tree,
em = NULL;
goto out;
}
- if (IS_ERR(rb_node)) {
- em = ERR_PTR(PTR_ERR(rb_node));
- goto out;
- }
em = rb_entry(rb_node, struct extent_map, rb_node);
- goto found;
-
- em = NULL;
- goto out;
-
found:
atomic_inc(&em->refs);
out:
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-03-20 11:37 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-20 11:37 [patch 2/3] btrfs cleanup: remove more dead code Dan Carpenter
2010-03-20 11:37 ` Dan Carpenter
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.