diff options
author | Marcin Slusarz <marcin.slusarz@gmail.com> | 2008-05-15 06:30:06 (GMT) |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-05-15 06:30:06 (GMT) |
commit | 066b2118976e6e7cc50eed39e2747c75343a23c4 (patch) | |
tree | ecf0fc1da7278665b39c5f77438032dd18457c76 | |
parent | ffd8211fb18e1052b2d9eded629cc3c0b872d06a (diff) | |
download | linux-066b2118976e6e7cc50eed39e2747c75343a23c4.tar.xz |
isdn/capi: Return proper errnos on module init.
cdebug_init() is called from kcapi_init() which is module
initialization function, so it must return negative values on errors.
Signed-off-by: Marcin Slusarz <marcin.slusarz@gmail.com>
Acked-by: Karsten Keil <kkeil@suse.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | drivers/isdn/capi/capiutil.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/isdn/capi/capiutil.c b/drivers/isdn/capi/capiutil.c index ebef4ce..29419a8 100644 --- a/drivers/isdn/capi/capiutil.c +++ b/drivers/isdn/capi/capiutil.c @@ -948,17 +948,17 @@ int __init cdebug_init(void) { g_cmsg= kmalloc(sizeof(_cmsg), GFP_KERNEL); if (!g_cmsg) - return ENOMEM; + return -ENOMEM; g_debbuf = kmalloc(sizeof(_cdebbuf), GFP_KERNEL); if (!g_debbuf) { kfree(g_cmsg); - return ENOMEM; + return -ENOMEM; } g_debbuf->buf = kmalloc(CDEBUG_GSIZE, GFP_KERNEL); if (!g_debbuf->buf) { kfree(g_cmsg); kfree(g_debbuf); - return ENOMEM;; + return -ENOMEM;; } g_debbuf->size = CDEBUG_GSIZE; g_debbuf->buf[0] = 0; |