]> git.baikalelectronics.ru Git - kernel.git/commit
swiotlb: ensure a segment doesn't cross the area boundary
authorChao Gao <chao.gao@intel.com>
Fri, 15 Jul 2022 10:45:35 +0000 (18:45 +0800)
committerChristoph Hellwig <hch@lst.de>
Mon, 18 Jul 2022 04:50:01 +0000 (06:50 +0200)
commitdd2c4bbb218916e578e2756d3bb082e1b66ddc68
tree066c3e6401fa68816347a4c109db5b94d729af56
parent6dd00807b2681e07ee0bb137eeb5dd152f2aaaf4
swiotlb: ensure a segment doesn't cross the area boundary

Free slots tracking assumes that slots in a segment can be allocated to
fulfill a request. This implies that slots in a segment should belong to
the same area. Although the possibility of a violation is low, it is better
to explicitly enforce segments won't span multiple areas by adjusting the
number of slabs when configuring areas.

Signed-off-by: Chao Gao <chao.gao@intel.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
kernel/dma/swiotlb.c