[PATCH 26/48] staging/lustre/osc: Check return code for lu_kmem_init
From: Peng Tao
Date: Mon Jul 22 2013 - 12:12:13 EST
From: Keith Mannthey <keith.mannthey@xxxxxxxxx>
lu_kmem_init can fail and returns has a return code.
Check for this return code in lu_kmem_init.
This issue was found during 2gb VM Racer testing
Intel-bug-id: https://jira.hpdd.intel.com/browse/LU-3063
Lustre-change: http://review.whamcloud.com/6514
Signed-off-by: Keith Mannthey <keith.mannthey@xxxxxxxxx>
Reviewed-by: Mike Pershin <mike.pershin@xxxxxxxxx>
Reviewed-by: Nathaniel Clark <nathaniel.l.clark@xxxxxxxxx>
Reviewed-by: Bob Glossman <bob.glossman@xxxxxxxxx>
Reviewed-by: Oleg Drokin <oleg.drokin@xxxxxxxxx>
Signed-off-by: Peng Tao <tao.peng@xxxxxxx>
Signed-off-by: Andreas Dilger <andreas.dilger@xxxxxxxxx>
---
drivers/staging/lustre/lustre/osc/osc_request.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/staging/lustre/lustre/osc/osc_request.c b/drivers/staging/lustre/lustre/osc/osc_request.c
index 0c0e07b..fea04ca 100644
--- a/drivers/staging/lustre/lustre/osc/osc_request.c
+++ b/drivers/staging/lustre/lustre/osc/osc_request.c
@@ -3681,6 +3681,8 @@ int __init osc_init(void)
CDEBUG(D_INFO, "Lustre OSC module (%p).\n", &osc_caches);
rc = lu_kmem_init(osc_caches);
+ if (rc)
+ RETURN(rc);
lprocfs_osc_init_vars(&lvars);
--
1.7.9.5
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/