diff options
author | Svatopluk Kraus <skra@FreeBSD.org> | 2015-11-21 19:55:01 +0000 |
---|---|---|
committer | Svatopluk Kraus <skra@FreeBSD.org> | 2015-11-21 19:55:01 +0000 |
commit | 6fa7734d6fbbec1e34bfee33427969ac9a92ff80 (patch) | |
tree | a2f950be9ed45eef9d36916983f76f162e19fe58 /sys/net80211/ieee80211_ht.c | |
parent | 3bf2363dca0c66c10256e5f6d6f29fae42171930 (diff) | |
download | src-6fa7734d6fbbec1e34bfee33427969ac9a92ff80.tar.gz src-6fa7734d6fbbec1e34bfee33427969ac9a92ff80.zip |
Fix BUS_DMA_MIN_ALLOC_COMP flag logic. When bus_dmamap_t map is being
created for bus_dma_tag_t tag, bounce pages should be allocated
only if needed.
Before the fix, they were allocated always if BUS_DMA_COULD_BOUNCE flag
was set but BUS_DMA_MIN_ALLOC_COMP not. As bounce pages are never freed,
it could cause memory exhaustion when a lot of such tags together with
their maps were created.
Note that there could be more maps in one tag by current design.
However BUS_DMA_MIN_ALLOC_COMP flag is tag's flag. It's set after
bounce pages are allocated. Thus, they are allocated only for first
tag's map which needs them.
Approved by: kib (mentor)
Notes
Notes:
svn path=/head/; revision=291142
Diffstat (limited to 'sys/net80211/ieee80211_ht.c')
0 files changed, 0 insertions, 0 deletions