Skip to contentSkip to conversation

mm/memblock.c: return -ENOMEM instead of -ENXIO on failure of debugfs_create_dir in memblock_init_debugfs

PATCH RESEND New Wang Sheng-Hui 1 participant 1 message Nov 9, 2011

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH RESEND 1/3 mm/memblock.c: return -ENOMEM instead of -ENXIO on failure of debugfs_create_dir in memblock_init_debugfs

On the failure of debugfs_create_dir, we should return -ENOMEM instead of -ENXIO.

---
 mm/memblock.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
mm/memblock.c +1 -1
index ccbf973..4d4d5ee 100644
@@ -852,7 +852,7 @@ static int __init memblock_init_debugfs(void)
 {
 	struct dentry *root = debugfs_create_dir("memblock", NULL);
 	if (!root)
-		return -ENXIO;
+		return -ENOMEM;
 	debugfs_create_file("memory", S_IRUGO, root, &memblock.memory, &memblock_debug_fops);
 	debugfs_create_file("reserved", S_IRUGO, root, &memblock.reserved, &memblock_debug_fops);
 
Signature · 8 lines
1.7.1

--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to [email protected].  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Fight unfair telecom internet charges in Canada: sign http://stopthemeter.ca/
Don't email: <a href=mailto:"[email protected]"> [email protected] </a>