]> git.baikalelectronics.ru Git - kernel.git/commit
swiotlb: fix setting ->force_bounce
authorChristoph Hellwig <hch@lst.de>
Wed, 1 Jun 2022 18:49:39 +0000 (20:49 +0200)
committerChristoph Hellwig <hch@lst.de>
Thu, 2 Jun 2022 05:17:59 +0000 (07:17 +0200)
commitaff3c9f5edbb7405439714c387c1e832fca076f9
tree9e5919c33c28c858fbd2182556abad35a9042ec8
parenta54e2d426a6cab4cb5175c48848ef01140ce8a43
swiotlb: fix setting ->force_bounce

The swiotlb_init refactor messed up assigning ->force_bounce by doing
it in different places based on what caused the setting of the flag.

Fix this by passing the SWIOTLB_* flags to swiotlb_init_io_tlb_mem
and just setting it there.

Fixes: 2b0a52cdecee ("swiotlb: make the swiotlb_init interface more useful")
Reported-by: Nathan Chancellor <nathan@kernel.org>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Tested-by: Nathan Chancellor <nathan@kernel.org>
kernel/dma/swiotlb.c