From c3e9b937fb817ca36610dc10677cb1442aa07e72 Mon Sep 17 00:00:00 2001 From: ching Huang Date: Thu, 23 Mar 2023 01:13:20 +0800 Subject: [PATCH] scsi: arcmsr: Fix ADAPTER_TYPE_B 64-bit DMA compatibility issue Fix ADAPTER_TYPE_B 64-bit DMA compatibility issue on some motherboards. Signed-off-by: ching Huang Link: https://lore.kernel.org/r/81c1f98819dfdfa18ae4d3b854b7733af9d34ea5.camel@areca.com.tw Signed-off-by: Martin K. Petersen --- drivers/scsi/arcmsr/arcmsr_hba.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/scsi/arcmsr/arcmsr_hba.c b/drivers/scsi/arcmsr/arcmsr_hba.c index 603860959c5f..ce92d4281da6 100644 --- a/drivers/scsi/arcmsr/arcmsr_hba.c +++ b/drivers/scsi/arcmsr/arcmsr_hba.c @@ -997,6 +997,8 @@ static int arcmsr_set_dma_mask(struct AdapterControlBlock *acb) if (((acb->adapter_type == ACB_ADAPTER_TYPE_A) && !dma_mask_64) || dma_set_mask(&pcidev->dev, DMA_BIT_MASK(64))) goto dma32; + if (acb->adapter_type <= ACB_ADAPTER_TYPE_B) + return 0; if (dma_set_coherent_mask(&pcidev->dev, DMA_BIT_MASK(64)) || dma_set_mask_and_coherent(&pcidev->dev, DMA_BIT_MASK(64))) { printk("arcmsr: set DMA 64 mask failed\n");