|
|
@@ -6056,13 +6056,13 @@ static int megasas_io_attach(struct megasas_instance *instance)
|
|
|
* @instance: Adapter soft state
|
|
|
* Description:
|
|
|
*
|
|
|
- * For Ventura, driver/FW will operate in 64bit DMA addresses.
|
|
|
+ * For Ventura, driver/FW will operate in 63bit DMA addresses.
|
|
|
*
|
|
|
* For invader-
|
|
|
* By default, driver/FW will operate in 32bit DMA addresses
|
|
|
* for consistent DMA mapping but if 32 bit consistent
|
|
|
- * DMA mask fails, driver will try with 64 bit consistent
|
|
|
- * mask provided FW is true 64bit DMA capable
|
|
|
+ * DMA mask fails, driver will try with 63 bit consistent
|
|
|
+ * mask provided FW is true 63bit DMA capable
|
|
|
*
|
|
|
* For older controllers(Thunderbolt and MFI based adapters)-
|
|
|
* driver/FW will operate in 32 bit consistent DMA addresses.
|
|
|
@@ -6075,15 +6075,15 @@ megasas_set_dma_mask(struct megasas_instance *instance)
|
|
|
u32 scratch_pad_2;
|
|
|
|
|
|
pdev = instance->pdev;
|
|
|
- consistent_mask = (instance->adapter_type == VENTURA_SERIES) ?
|
|
|
- DMA_BIT_MASK(64) : DMA_BIT_MASK(32);
|
|
|
+ consistent_mask = (instance->adapter_type >= VENTURA_SERIES) ?
|
|
|
+ DMA_BIT_MASK(63) : DMA_BIT_MASK(32);
|
|
|
|
|
|
if (IS_DMA64) {
|
|
|
- if (dma_set_mask(&pdev->dev, DMA_BIT_MASK(64)) &&
|
|
|
+ if (dma_set_mask(&pdev->dev, DMA_BIT_MASK(63)) &&
|
|
|
dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)))
|
|
|
goto fail_set_dma_mask;
|
|
|
|
|
|
- if ((*pdev->dev.dma_mask == DMA_BIT_MASK(64)) &&
|
|
|
+ if ((*pdev->dev.dma_mask == DMA_BIT_MASK(63)) &&
|
|
|
(dma_set_coherent_mask(&pdev->dev, consistent_mask) &&
|
|
|
dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)))) {
|
|
|
/*
|
|
|
@@ -6096,7 +6096,7 @@ megasas_set_dma_mask(struct megasas_instance *instance)
|
|
|
if (!(scratch_pad_2 & MR_CAN_HANDLE_64_BIT_DMA_OFFSET))
|
|
|
goto fail_set_dma_mask;
|
|
|
else if (dma_set_mask_and_coherent(&pdev->dev,
|
|
|
- DMA_BIT_MASK(64)))
|
|
|
+ DMA_BIT_MASK(63)))
|
|
|
goto fail_set_dma_mask;
|
|
|
}
|
|
|
} else if (dma_set_mask_and_coherent(&pdev->dev, DMA_BIT_MASK(32)))
|
|
|
@@ -6108,8 +6108,8 @@ megasas_set_dma_mask(struct megasas_instance *instance)
|
|
|
instance->consistent_mask_64bit = true;
|
|
|
|
|
|
dev_info(&pdev->dev, "%s bit DMA mask and %s bit consistent mask\n",
|
|
|
- ((*pdev->dev.dma_mask == DMA_BIT_MASK(64)) ? "64" : "32"),
|
|
|
- (instance->consistent_mask_64bit ? "64" : "32"));
|
|
|
+ ((*pdev->dev.dma_mask == DMA_BIT_MASK(64)) ? "63" : "32"),
|
|
|
+ (instance->consistent_mask_64bit ? "63" : "32"));
|
|
|
|
|
|
return 0;
|
|
|
|