linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ext4: annotate unhandled kmem_cache_alloc() error
@ 2008-12-23 10:40 Akinobu Mita
  2008-12-23 14:29 ` Josef Bacik
  0 siblings, 1 reply; 8+ messages in thread
From: Akinobu Mita @ 2008-12-23 10:40 UTC (permalink / raw)
  To: linux-kernel; +Cc: akpm, Theodore Tso, adilger, linux-ext4

kmem_cache_alloc() error in ext4_mb_free_metadata is not handled.
I don't know how to fix it. But I can put BUG_ON to let others
know the problem.

Cc: Theodore Tso <tytso@mit.edu>
Cc: adilger@sun.com
Cc: linux-ext4@vger.kernel.org
Signed-off-by: Akinobu Mita <akinobu.mita@gmail.com>
---
 fs/ext4/mballoc.c |    1 +
 1 file changed, 1 insertion(+)

Index: 2.6-rc/fs/ext4/mballoc.c
===================================================================
--- 2.6-rc.orig/fs/ext4/mballoc.c
+++ 2.6-rc/fs/ext4/mballoc.c
@@ -4417,6 +4417,7 @@ ext4_mb_free_metadata(handle_t *handle, 
 	BUG_ON(e4b->bd_buddy_page == NULL);
 
 	new_entry  = kmem_cache_alloc(ext4_free_ext_cachep, GFP_NOFS);
+	BUG_ON(!new_entry);
 	new_entry->start_blk = block;
 	new_entry->group  = group;
 	new_entry->count = count;

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2009-01-12 15:04 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-12-23 10:40 [PATCH] ext4: annotate unhandled kmem_cache_alloc() error Akinobu Mita
2008-12-23 14:29 ` Josef Bacik
2008-12-23 22:37   ` Akinobu Mita
2009-01-11  2:03     ` [PATCH] ext4: fix unhandled ext4_free_data allocation failure Akinobu Mita
2009-01-11 14:39       ` Josef Bacik
2009-01-11 14:46         ` Eric Sandeen
2009-01-12  3:58           ` Theodore Tso
2009-01-12 15:03             ` Theodore Tso

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).