Skip to content
Commit b95044b3 authored by Jie Hai's avatar Jie Hai Committed by Vinod Koul
Browse files

dmaengine: hisi_dma: fix MSI allocate fail when reload hisi_dma

Remove the loaded hisi_dma driver and reload it, the driver fails
to work properly. The following error is reported in the kernel log:

[ 1475.597609] hisi_dma 0000:7b:00.0: Failed to allocate MSI vectors!
[ 1475.604915] hisi_dma: probe of 0000:7b:00.0 failed with error -28

As noted in "The MSI Driver Guide HOWTO"[1], the number of MSI
interrupt must be a power of two. The Kunpeng DMA driver allocates 30
MSI interrupts. As a result, no space left on device is reported
when the driver is reloaded and allocates interrupt vectors from the
interrupt domain.

This patch changes the number of interrupt vectors allocated by
hisi_dma driver to 32 to avoid this problem.

[1] https://www.kernel.org/doc/html/latest/PCI/msi-howto.html



Fixes: e9f08b65 ("dmaengine: hisilicon: Add Kunpeng DMA engine support")

Signed-off-by: default avatarJie Hai <haijie1@huawei.com>
Acked-by: default avatarZhou Wang <wangzhou1@hisilicon.com>
Link: https://lore.kernel.org/r/20220216072101.34473-1-haijie1@huawei.com


Signed-off-by: default avatarVinod Koul <vkoul@kernel.org>
parent e7c7a016
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment