Searched hist:269216 (Results 1 - 1 of 1) sorted by relevance

/freebsd-11-stable/sys/arm/arm/
H A Dbusdma_machdep-v6.cdiff 269216 Tue Jul 29 00:45:40 MDT 2014 ian A while back, the array of segments used for a load/mapping operation was
moved from the stack into the tag structure. In retrospect that was a bad
idea, because nothing protects that array from concurrent access by
multiple threads.

This change moves the array to the map structure (actually it's allocated
following the structure, but all in a single malloc() call).

This also establishes a "sane" limit of 4096 segments per map. This is
mostly to prevent trying to allocate all of memory if someone accidentally
uses a tag with nsegments set to BUS_SPACE_UNRESTRICTED. If there's ever
a genuine need for more than 4096, don't hesitate to increase this (or
maybe make it tunable).

Reviewed by: cognet

Completed in 91 milliseconds