Module Name:    src
Committed By:   martin
Date:           Wed Nov  6 10:25:27 UTC 2019

Modified Files:
        src/sys/dev/sdmmc [netbsd-8]: sbt.c
        src/sys/dev/usb [netbsd-8]: ubt.c

Log Message:
Pull up following revision(s) (requested by msaitoh in ticket #1429):

        sys/dev/usb/ubt.c: revision 1.61
        sys/dev/sdmmc/sbt.c: revision 1.6

m_free -> m_freem, m_copyback could have added mbufs in the chain


To generate a diff of this commit:
cvs rdiff -u -r1.5 -r1.5.10.1 src/sys/dev/sdmmc/sbt.c
cvs rdiff -u -r1.59.2.1 -r1.59.2.2 src/sys/dev/usb/ubt.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/sdmmc/sbt.c
diff -u src/sys/dev/sdmmc/sbt.c:1.5 src/sys/dev/sdmmc/sbt.c:1.5.10.1
--- src/sys/dev/sdmmc/sbt.c:1.5	Thu Jul 14 04:00:46 2016
+++ src/sys/dev/sdmmc/sbt.c	Wed Nov  6 10:25:27 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: sbt.c,v 1.5 2016/07/14 04:00:46 msaitoh Exp $	*/
+/*	$NetBSD: sbt.c,v 1.5.10.1 2019/11/06 10:25:27 martin Exp $	*/
 /*	$OpenBSD: sbt.c,v 1.9 2007/06/19 07:59:57 uwe Exp $	*/
 
 /*
@@ -20,7 +20,7 @@
 /* Driver for Type-A/B SDIO Bluetooth cards */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sbt.c,v 1.5 2016/07/14 04:00:46 msaitoh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sbt.c,v 1.5.10.1 2019/11/06 10:25:27 martin Exp $");
 
 #include <sys/param.h>
 #include <sys/device.h>
@@ -357,7 +357,7 @@ sbt_intr(void *arg)
 		m->m_len = MIN(MHLEN, m->m_pkthdr.len);
 	} else {
 		DPRINTF(("%s: sbt_intr: m_copyback failed\n", DEVNAME(sc)));
-		m_free(m);
+		m_freem(m);
 		m = NULL;
 	}
 
@@ -383,7 +383,7 @@ eoi:
 			DPRINTF(("%s: recv 0x%x packet (%d bytes)\n",
 			    DEVNAME(sc), sc->sc_buf[0], m->m_pkthdr.len));
 			sc->sc_stats.err_rx++;
-			m_free(m);
+			m_freem(m);
 			break;
 		}
 	} else

Index: src/sys/dev/usb/ubt.c
diff -u src/sys/dev/usb/ubt.c:1.59.2.1 src/sys/dev/usb/ubt.c:1.59.2.2
--- src/sys/dev/usb/ubt.c:1.59.2.1	Wed Jan 31 18:01:54 2018
+++ src/sys/dev/usb/ubt.c	Wed Nov  6 10:25:26 2019
@@ -1,4 +1,4 @@
-/*	$NetBSD: ubt.c,v 1.59.2.1 2018/01/31 18:01:54 martin Exp $	*/
+/*	$NetBSD: ubt.c,v 1.59.2.2 2019/11/06 10:25:26 martin Exp $	*/
 
 /*-
  * Copyright (c) 2006 Itronix Inc.
@@ -67,7 +67,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ubt.c,v 1.59.2.1 2018/01/31 18:01:54 martin Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ubt.c,v 1.59.2.2 2019/11/06 10:25:26 martin Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_usb.h"
@@ -1528,7 +1528,7 @@ ubt_mbufload(uint8_t *buf, int count, ui
 	m->m_pkthdr.len = m->m_len = MHLEN;
 	m_copyback(m, 1, count, buf);	// (extends if necessary)
 	if (m->m_pkthdr.len != MAX(MHLEN, count + 1)) {
-		m_free(m);
+		m_freem(m);
 		return NULL;
 	}
 

Reply via email to