]> 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)
commit05e062f0fbb76ee88460ee07c28cf01ed943c9cc
tree066c3e6401fa68816347a4c109db5b94d729af56
parent11a3fb418452f7a751b6c992e06246ae94d03965
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