Re: [PATCH 1/1] scsi : megaraid_{mm,mbox}: a fix on 64-bit DMA capability check

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello Seokmann,

I would like to tell you that your patch is wrong, at least for
 MegaRAID SATA 150-4 RAID Controller

06:02.0 RAID bus controller: LSI Logic / Symbios Logic MegaRAID (rev 01)
        Subsystem: LSI Logic / Symbios Logic MegaRAID SATA 150-4 RAID Controller
00: 00 10 60 19 16 03 b0 04 01 00 04 01 08 20 00 00
10: 08 00 20 df 00 00 00 00 00 00 00 00 00 00 00 00
20: 00 00 00 00 00 00 00 00 00 00 00 00 00 10 23 45
30: 00 00 00 00 80 00 00 00 00 00 00 00 0a 01 00 00
40: 00 00 ff ff 00 00 00 d0 08 00 00 fc 00 00 00 fc
50: 00 00 00 d0 00 00 00 00 00 00 00 00 00 00 00 00
60: 00 00 00 00 88 1f 00 00 00 00 00 f8 00 00 00 00
70: 00 00 00 00 00 00 ff ff 00 00 f4 fe 00 00 00 00
80: 01 00 02 00 00 00 00 00 06 01 38 00 00 00 00 00
90: 00 00 00 00 00 00 00 00 06 01 00 20 9c 00 00 00
a0: cc cc 00 00 99 02 00 00 00 06 00 80 00 00 00 00
b0: 00 00 00 6e 00 00 00 00 00 00 00 00 fd 01 00 00
c0: fd 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
d0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
e0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00
f0: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00

As far as I see the 64-bit magic is set, pci(0xA4) == 0x0299 and driver tries to
enable 64-bit DMA. However the controller is not supported 64-bit DMA, and I
still have the same error messages.

Could you please check this issue and update your patch properly.

Thank you,
	Vasily Averin

SWsoft Virtuozzo/OpenVZ Linux kernel team

Ju, Seokmann wrote:
> Hi,
> 
> This patch contains a fix for 64-bit DMA capability check in
> megaraid_{mm,mbox} driver. With patch, the driver access PCI
> configuration space with dedicated offset to read a signature. If the
> signature read, it means that the controller has capability to handle
> 64-bit DMA. Before this patch, the driver blindly claimed the capability
> without checking with controller.
> The issue has been reported by Vasily Averin [[email protected]]. Thank you
> Vasily for the reporting.

> +#define HBA_SIGNATURE_64BIT		0x0299
> +#define PCI_CONF_AMISIG64		0xa4
...
> -	if (pci_set_dma_mask(adapter->pdev, DMA_64BIT_MASK) != 0) {
> +	pci_read_config_dword(adapter->pdev, PCI_CONF_AMISIG64,
> &magic64);
>  
> -		con_log(CL_ANN, (KERN_WARNING
> -			"megaraid: could not set DMA mask for
> 64-bit.\n"));
> +	if ((magic64 == HBA_SIGNATURE_64BIT) || 
> +		(adapter->pdev->vendor == PCI_VENDOR_ID_DELL &&
> +		adapter->pdev->device ==
> PCI_DEVICE_ID_PERC4_DI_EVERGLADES) ||
> +		(adapter->pdev->vendor == PCI_VENDOR_ID_LSI_LOGIC &&
> +		adapter->pdev->device == PCI_DEVICE_ID_VERDE) ||
> +		(adapter->pdev->vendor == PCI_VENDOR_ID_LSI_LOGIC &&
> +		adapter->pdev->device == PCI_DEVICE_ID_DOBSON) ||
> +		(adapter->pdev->vendor == PCI_VENDOR_ID_DELL &&
> +		adapter->pdev->device == PCI_DEVICE_ID_PERC4E_DI_KOBUK)
> ||
> +		(adapter->pdev->vendor == PCI_VENDOR_ID_LSI_LOGIC &&
> +		adapter->pdev->device == PCI_DEVICE_ID_LINDSAY)) {
> +		if (pci_set_dma_mask(adapter->pdev, DMA_64BIT_MASK) !=
> 0) {
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux