CVS commit: [netbsd-8] src/sys/dev/pcmcia

2017-12-10 Thread Soren Jacobsen
Module Name:src
Committed By:   snj
Date:   Sun Dec 10 09:50:59 UTC 2017

Modified Files:
src/sys/dev/pcmcia [netbsd-8]: if_malo_pcmcia.c

Log Message:
Pull up following revision(s) (requested by msaitoh in ticket #426):
sys/dev/pcmcia/if_malo_pcmcia.c: revision 1.14
two spl leaks, found by Mootja


To generate a diff of this commit:
cvs rdiff -u -r1.13 -r1.13.6.1 src/sys/dev/pcmcia/if_malo_pcmcia.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pcmcia/if_malo_pcmcia.c
diff -u src/sys/dev/pcmcia/if_malo_pcmcia.c:1.13 src/sys/dev/pcmcia/if_malo_pcmcia.c:1.13.6.1
--- src/sys/dev/pcmcia/if_malo_pcmcia.c:1.13	Thu Feb  2 10:05:35 2017
+++ src/sys/dev/pcmcia/if_malo_pcmcia.c	Sun Dec 10 09:50:59 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: if_malo_pcmcia.c,v 1.13 2017/02/02 10:05:35 nonaka Exp $	*/
+/*	$NetBSD: if_malo_pcmcia.c,v 1.13.6.1 2017/12/10 09:50:59 snj Exp $	*/
 /*  $OpenBSD: if_malo.c,v 1.65 2009/03/29 21:53:53 sthen Exp $ */
 
 /*
@@ -18,7 +18,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: if_malo_pcmcia.c,v 1.13 2017/02/02 10:05:35 nonaka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: if_malo_pcmcia.c,v 1.13.6.1 2017/12/10 09:50:59 snj Exp $");
 
 #ifdef _MODULE
 #include 
@@ -242,6 +242,7 @@ malo_pcmcia_activate(device_t dev, devac
 		if_deactivate(ifp);
 		break;
 	default:
+		splx(s);
 		return EOPNOTSUPP;
 	}
 	splx(s);
@@ -1983,6 +1984,7 @@ cmalo_cmd_response(struct malo_softc *sc
 	if (psize > MALO_CMD_BUFFER_SIZE) {
 		aprint_error_dev(sc->sc_dev,
 		"command response too large: %dbyte\n", psize);
+		splx(s);
 		return EIO;
 	}
 



CVS commit: [netbsd-8] src/sys/dev/pcmcia

2017-08-04 Thread Soren Jacobsen
Module Name:src
Committed By:   snj
Date:   Sat Aug  5 03:52:57 UTC 2017

Modified Files:
src/sys/dev/pcmcia [netbsd-8]: aic_pcmcia.c

Log Message:
Pull up following revision(s) (requested by christos in ticket #177):
sys/dev/pcmcia/aic_pcmcia.c: revision 1.44
>From bjoern johannesson, in netbsd-general... Reset the mask to 0, used to
be 0xa. Is it wrong in the cfe? Should this better be done via a quirk?


To generate a diff of this commit:
cvs rdiff -u -r1.43 -r1.43.56.1 src/sys/dev/pcmcia/aic_pcmcia.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/pcmcia/aic_pcmcia.c
diff -u src/sys/dev/pcmcia/aic_pcmcia.c:1.43 src/sys/dev/pcmcia/aic_pcmcia.c:1.43.56.1
--- src/sys/dev/pcmcia/aic_pcmcia.c:1.43	Thu Nov 12 19:24:06 2009
+++ src/sys/dev/pcmcia/aic_pcmcia.c	Sat Aug  5 03:52:57 2017
@@ -1,4 +1,4 @@
-/*	$NetBSD: aic_pcmcia.c,v 1.43 2009/11/12 19:24:06 dyoung Exp $	*/
+/*	$NetBSD: aic_pcmcia.c,v 1.43.56.1 2017/08/05 03:52:57 snj Exp $	*/
 
 /*
  * Copyright (c) 1997 Marc Horowitz.  All rights reserved.
@@ -30,7 +30,7 @@
  */
 
 #include 
-__KERNEL_RCSID(0, "$NetBSD: aic_pcmcia.c,v 1.43 2009/11/12 19:24:06 dyoung Exp $");
+__KERNEL_RCSID(0, "$NetBSD: aic_pcmcia.c,v 1.43.56.1 2017/08/05 03:52:57 snj Exp $");
 
 #include 
 #include 
@@ -101,6 +101,8 @@ aic_pcmcia_validate_config(struct pcmcia
 	cfe->num_memspace != 0 ||
 	cfe->num_iospace != 1)
 		return (EINVAL);
+
+	cfe->iomask = 0;		/* XXX: wrong from cfe?, quirk? */
 	return (0);
 }