Date: Thu, 6 Mar 2014 13:24:51 +0000 (UTC) From: Alexander Motin <mav@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-10@freebsd.org Subject: svn commit: r262850 - stable/10/sys/dev/mps Message-ID: <201403061324.s26DOq4r005296@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
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);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201403061324.s26DOq4r005296>