svn commit: r262850 - stable/10/sys/dev/mps

Alexander Motin mav at FreeBSD.org
Thu Mar 6 13:24:52 UTC 2014


Author: mav
Date: Thu Mar  6 13:24:51 2014
New Revision: 262850
URL: http://svnweb.freebsd.org/changeset/base/262850

Log:
  MFC r262553:
  Pass proper pointer to bus_dmamem_free() in mps_iocfacts_free().
  
  Passing there pointer into the middle of allocated area caused kernel
  panic during reinit, for example, after firmware upgrade.

Modified:
  stable/10/sys/dev/mps/mps.c
Directory Properties:
  stable/10/   (props changed)

Modified: stable/10/sys/dev/mps/mps.c
==============================================================================
--- stable/10/sys/dev/mps/mps.c	Thu Mar  6 13:20:38 2014	(r262849)
+++ stable/10/sys/dev/mps/mps.c	Thu Mar  6 13:24:51 2014	(r262850)
@@ -617,8 +617,8 @@ mps_iocfacts_free(struct mps_softc *sc)
 
 	if (sc->post_busaddr != 0)
 		bus_dmamap_unload(sc->queues_dmat, sc->queues_map);
-	if (sc->post_queue != NULL)
-		bus_dmamem_free(sc->queues_dmat, sc->post_queue,
+	if (sc->free_queue != NULL)
+		bus_dmamem_free(sc->queues_dmat, sc->free_queue,
 		    sc->queues_map);
 	if (sc->queues_dmat != NULL)
 		bus_dma_tag_destroy(sc->queues_dmat);


More information about the svn-src-all mailing list