From ae2d990eede0ef5938c210d48a177c044258ecd8 Mon Sep 17 00:00:00 2001 From: Alan Stern Date: Wed, 23 May 2007 13:58:12 -0700 Subject: HiSax: fix error checking for hisax_register()] This patch (as875) adds error-checking to the callers of hisax_register(). It also changes an error pathway in that routine, making it return an error code rather than 0. This fixes Bugzilla #7960. Signed-off-by: Alan Stern Acked-by: Karsten Keil Cc: Martin Bachem Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/isdn/hisax/config.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/isdn/hisax/config.c') diff --git a/drivers/isdn/hisax/config.c b/drivers/isdn/hisax/config.c index da4196f21e0f..8d53a7fd2671 100644 --- a/drivers/isdn/hisax/config.c +++ b/drivers/isdn/hisax/config.c @@ -1551,7 +1551,7 @@ int hisax_register(struct hisax_d_if *hisax_d_if, struct hisax_b_if *b_if[], if (retval == 0) { // yuck cards[i].typ = 0; nrcards--; - return retval; + return -EINVAL; } cs = cards[i].cs; hisax_d_if->cs = cs; -- cgit v1.2.2