diff options
author | Paul Mackerras <paulus@samba.org> | 2006-03-28 21:24:50 -0500 |
---|---|---|
committer | Paul Mackerras <paulus@samba.org> | 2006-03-28 21:24:50 -0500 |
commit | bac30d1a78d0f11c613968fc8b351a91ed465386 (patch) | |
tree | e52f3c876522a2f6047a6ec1c27df2e8a79486b8 /drivers/isdn/capi/capi.c | |
parent | e8222502ee6157e2713da9e0792c21f4ad458d50 (diff) | |
parent | ca9ba4471c1203bb6e759b76e83167fec54fe590 (diff) |
Merge ../linux-2.6
Diffstat (limited to 'drivers/isdn/capi/capi.c')
-rw-r--r-- | drivers/isdn/capi/capi.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/isdn/capi/capi.c b/drivers/isdn/capi/capi.c index 623adbb0d13a..9b493f0becc4 100644 --- a/drivers/isdn/capi/capi.c +++ b/drivers/isdn/capi/capi.c | |||
@@ -1485,6 +1485,7 @@ static int __init capi_init(void) | |||
1485 | { | 1485 | { |
1486 | char *p; | 1486 | char *p; |
1487 | char *compileinfo; | 1487 | char *compileinfo; |
1488 | int major_ret; | ||
1488 | 1489 | ||
1489 | if ((p = strchr(revision, ':')) != 0 && p[1]) { | 1490 | if ((p = strchr(revision, ':')) != 0 && p[1]) { |
1490 | strlcpy(rev, p + 2, sizeof(rev)); | 1491 | strlcpy(rev, p + 2, sizeof(rev)); |
@@ -1493,11 +1494,12 @@ static int __init capi_init(void) | |||
1493 | } else | 1494 | } else |
1494 | strcpy(rev, "1.0"); | 1495 | strcpy(rev, "1.0"); |
1495 | 1496 | ||
1496 | if (register_chrdev(capi_major, "capi20", &capi_fops)) { | 1497 | major_ret = register_chrdev(capi_major, "capi20", &capi_fops); |
1498 | if (major_ret < 0) { | ||
1497 | printk(KERN_ERR "capi20: unable to get major %d\n", capi_major); | 1499 | printk(KERN_ERR "capi20: unable to get major %d\n", capi_major); |
1498 | return -EIO; | 1500 | return major_ret; |
1499 | } | 1501 | } |
1500 | 1502 | capi_major = major_ret; | |
1501 | capi_class = class_create(THIS_MODULE, "capi"); | 1503 | capi_class = class_create(THIS_MODULE, "capi"); |
1502 | if (IS_ERR(capi_class)) { | 1504 | if (IS_ERR(capi_class)) { |
1503 | unregister_chrdev(capi_major, "capi20"); | 1505 | unregister_chrdev(capi_major, "capi20"); |