netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch 4/4] mISDN: positive error return should be negative in mode_hfcmulti()
@ 2010-02-02 22:43 akpm
  2010-02-04  4:17 ` David Miller
  0 siblings, 1 reply; 2+ messages in thread
From: akpm @ 2010-02-02 22:43 UTC (permalink / raw)
  To: isdn; +Cc: netdev, akpm, roel.kluin

From: Roel Kluin <roel.kluin@gmail.com>

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>
Cc: Karsten Keil <isdn@linux-pingi.de>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
---

 drivers/isdn/hardware/mISDN/hfcmulti.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff -puN drivers/isdn/hardware/mISDN/hfcmulti.c~misdn-positive-error-return-should-be-negative-in-mode_hfcmulti drivers/isdn/hardware/mISDN/hfcmulti.c
--- a/drivers/isdn/hardware/mISDN/hfcmulti.c~misdn-positive-error-return-should-be-negative-in-mode_hfcmulti
+++ a/drivers/isdn/hardware/mISDN/hfcmulti.c
@@ -2846,7 +2846,7 @@ mode_hfcmulti(struct hfc_multi *hc, int 
 	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	[flat|nested] 2+ messages in thread

* Re: [patch 4/4] mISDN: positive error return should be negative in mode_hfcmulti()
  2010-02-02 22:43 [patch 4/4] mISDN: positive error return should be negative in mode_hfcmulti() akpm
@ 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: akpm; +Cc: isdn, netdev, roel.kluin

From: akpm@linux-foundation.org
Date: Tue, 02 Feb 2010 14:43:47 -0800

> From: Roel Kluin <roel.kluin@gmail.com>
> 
> 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>
> Cc: Karsten Keil <isdn@linux-pingi.de>
> Signed-off-by: Andrew Morton <akpm@linux-foundation.org>

Applied.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2010-02-04  4:17 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-02 22:43 [patch 4/4] mISDN: positive error return should be negative in mode_hfcmulti() akpm
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;
as well as URLs for NNTP newsgroup(s).