* [PATCH] mISDN: positive error return should be negative in mode_hfcmulti()
@ 2010-01-29 9:57 Roel Kluin
2010-02-04 4:17 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Roel Kluin @ 2010-01-29 9:57 UTC (permalink / raw)
To: Karsten Keil, isdn4linux, Andrew Morton, LKML, David S. Miller
The error return should be negative. Its only caller that acts upon its return,
handle_bmsg(), transmits the positive error but can also return negative errors.
Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
---
diff --git a/drivers/isdn/hardware/mISDN/hfcmulti.c b/drivers/isdn/hardware/mISDN/hfcmulti.c
index 1a1420d..ad36df9 100644
--- a/drivers/isdn/hardware/mISDN/hfcmulti.c
+++ b/drivers/isdn/hardware/mISDN/hfcmulti.c
@@ -2846,7 +2846,7 @@ mode_hfcmulti(struct hfc_multi *hc, int ch, int protocol, int slot_tx,
int conf;
if (ch < 0 || ch > 31)
- return EINVAL;
+ return -EINVAL;
oslot_tx = hc->chan[ch].slot_tx;
oslot_rx = hc->chan[ch].slot_rx;
conf = hc->chan[ch].conf;
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] mISDN: positive error return should be negative in mode_hfcmulti()
2010-01-29 9:57 [PATCH] mISDN: positive error return should be negative in mode_hfcmulti() Roel Kluin
@ 2010-02-04 4:17 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2010-02-04 4:17 UTC (permalink / raw)
To: roel.kluin; +Cc: isdn, isdn4linux, akpm, linux-kernel
From: Roel Kluin <roel.kluin@gmail.com>
Date: Fri, 29 Jan 2010 10:57:20 +0100
> The error return should be negative. Its only caller that acts upon its return,
> handle_bmsg(), transmits the positive error but can also return negative errors.
>
> Signed-off-by: Roel Kluin <roel.kluin@gmail.com>
Applied.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2010-02-04 4:16 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-29 9:57 [PATCH] mISDN: positive error return should be negative in mode_hfcmulti() Roel Kluin
2010-02-04 4:17 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox