]> git.baikalelectronics.ru Git - kernel.git/commit
swiotlb: don't panic when the swiotlb buffer can't be allocated
authorChristoph Hellwig <hch@lst.de>
Wed, 11 May 2022 06:44:29 +0000 (08:44 +0200)
committerChristoph Hellwig <hch@lst.de>
Fri, 13 May 2022 10:48:58 +0000 (12:48 +0200)
commit049951ed7f7f79a8090a18408c83a48e18191e3a
treecf20ea2b5617ab50fb2dd183bbf4a6aa3c896a47
parentb11124d5194a81e556e60a31a26a2242640e56ba
swiotlb: don't panic when the swiotlb buffer can't be allocated

For historical reasons the switlb code paniced when the metadata could
not be allocated, but just printed a warning when the actual main
swiotlb buffer could not be allocated.  Restore this somewhat unexpected
behavior as changing it caused a boot failure on the Microchip RISC-V
PolarFire SoC Icicle kit.

Fixes: b4156af37861 ("swiotlb: remove swiotlb_init_with_tbl and swiotlb_init_late_with_tbl")
Reported-by: Conor Dooley <Conor.Dooley@microchip.com>
Signed-off-by: Christoph Hellwig <hch@lst.de>
Reviewed-by: Stefano Stabellini <sstabellini@kernel.org>
Acked-by: Conor Dooley <conor.dooley@microchip.com>
Tested-by: Conor Dooley <Conor.Dooley@microchip.com>
kernel/dma/swiotlb.c