]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Allocate right number of pages for the bounced buffers crossing the page.
authormmel <mmel@FreeBSD.org>
Wed, 16 Dec 2020 14:36:57 +0000 (14:36 +0000)
committermmel <mmel@FreeBSD.org>
Wed, 16 Dec 2020 14:36:57 +0000 (14:36 +0000)
commit720f0dd169993cf70246af7eab050e315664e1ca
tree68ce36e62d65c45688e35d767e2b5419b5b7cdfe
parentf000cce2c9c8e7ae154ceb23a0030cb0c46acdbb
Allocate right number of pages for the bounced buffers crossing the page.

One of the disadvantages of our current busdma code is the fact that
we process the bounced buffer in a page-by-page manner. This means that
the short (subpage) buffer allocated across page boundaries is bounced
to 2 separate pages.

This suboptimal behavior is consistent across all platforms and can be
related to (probably unimplementable or incompatible with bouncing)
BUS_DMA_KEEP_PG_OFFSET flag.

Therefore, allocate one additional page to be fully comply with this
requirement.

Discused with: markj
PR: 251018
sys/arm64/arm64/busdma_bounce.c