Author: manu Date: Tue Nov 24 14:05:35 2020 New Revision: 367984 URL: https://svnweb.freebsd.org/changeset/base/367984
Log: arm64: Check if we have a map before checking the flags This fixes amdgpu on arm64 where linuxkpi is calling id_mapped and we call might_bounce without a map. Modified: head/sys/arm64/arm64/busdma_bounce.c Modified: head/sys/arm64/arm64/busdma_bounce.c ============================================================================== --- head/sys/arm64/arm64/busdma_bounce.c Tue Nov 24 13:19:31 2020 (r367983) +++ head/sys/arm64/arm64/busdma_bounce.c Tue Nov 24 14:05:35 2020 (r367984) @@ -207,7 +207,7 @@ might_bounce(bus_dma_tag_t dmat, bus_dmamap_t map, bus { /* Memory allocated by bounce_bus_dmamem_alloc won't bounce */ - if ((map->flags & DMAMAP_FROM_DMAMEM) != 0) + if (map && (map->flags & DMAMAP_FROM_DMAMEM) != 0) return (false); if ((dmat->bounce_flags & BF_COULD_BOUNCE) != 0) _______________________________________________ svn-src-all@freebsd.org mailing list https://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"