diff options
author | Randy Dunlap <rdunlap@xenotime.net> | 2005-05-17 04:53:56 (GMT) |
---|---|---|
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | 2005-05-17 14:59:21 (GMT) |
commit | afbf510d47c4009f5d67ec3c0e0b45eb0441bca3 (patch) | |
tree | 129434483daa8180e35751f231d28045f9e8ead0 /drivers/pcmcia/ds.c | |
parent | 24d568ed1b97cb93c2a917cd90296655a8b661a6 (diff) | |
download | linux-fsl-qoriq-afbf510d47c4009f5d67ec3c0e0b45eb0441bca3.tar.xz |
[PATCH] pcmcia/ds: handle any error code
register_chrdev() can return errors (negative) other then -EBUSY, so check
for any negative error code.
Signed-off-by: Randy Dunlap <rdunlap@xenotime.net>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'drivers/pcmcia/ds.c')
-rw-r--r-- | drivers/pcmcia/ds.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/pcmcia/ds.c b/drivers/pcmcia/ds.c index 66150d0..c4ade28 100644 --- a/drivers/pcmcia/ds.c +++ b/drivers/pcmcia/ds.c @@ -1592,9 +1592,9 @@ static int __init init_pcmcia_bus(void) /* Set up character device for user mode clients */ i = register_chrdev(0, "pcmcia", &ds_fops); - if (i == -EBUSY) + if (i < 0) printk(KERN_NOTICE "unable to find a free device # for " - "Driver Services\n"); + "Driver Services (error=%d)\n", i); else major_dev = i; |