* [patch 1/2] block/cpqarray: Audit return code of create_proc_*
@ 2005-07-14 22:20 domen
0 siblings, 0 replies; only message in thread
From: domen @ 2005-07-14 22:20 UTC (permalink / raw)
To: axboe; +Cc: linux-kernel, Christophe Lucas, domen
[-- Attachment #1: return_code-drivers_block_cpqarray --]
[-- Type: text/plain, Size: 977 bytes --]
From: Christophe Lucas <clucas@rotomalug.org>
Audit return of create_proc_* functions.
Signed-off-by: Christophe Lucas <clucas@rotomalug.org>
Signed-off-by: Domen Puncer <domen@coderock.org>
---
cpqarray.c | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletion(-)
Index: quilt/drivers/block/cpqarray.c
===================================================================
--- quilt.orig/drivers/block/cpqarray.c
+++ quilt/drivers/block/cpqarray.c
@@ -212,13 +212,18 @@ static struct proc_dir_entry *proc_array
*/
static void __init ida_procinit(int i)
{
+ struct proc_dir_entry *ent;
+
if (proc_array == NULL) {
proc_array = proc_mkdir("cpqarray", proc_root_driver);
if (!proc_array) return;
}
- create_proc_read_entry(hba[i]->devname, 0, proc_array,
+ ent = create_proc_read_entry(hba[i]->devname, 0, proc_array,
ida_proc_get_info, hba[i]);
+ if (!ent)
+ printk(KERN_WARNING
+ "cpqarray: Unable to create /proc entry.\n");
}
/*
--
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2005-07-14 22:24 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-07-14 22:20 [patch 1/2] block/cpqarray: Audit return code of create_proc_* domen
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®