提交 c80ddf00 编写于 作者: J James Bottomley

[SCSI] dpt_i2o: driver is only 32 bit so don't set 64 bit DMA mask

This fixes a potential corruption bug where the truncation would cause
reading or writing to the wrong memory area on machines with >4GB of
main memory.

Cc: Stable Kernel Tree <stable@kernel.org>
Signed-off-by: NJames Bottomley <James.Bottomley@HansenPartnership.com>
上级 7ee2413c
...@@ -906,8 +906,7 @@ static int adpt_install_hba(struct scsi_host_template* sht, struct pci_dev* pDev ...@@ -906,8 +906,7 @@ static int adpt_install_hba(struct scsi_host_template* sht, struct pci_dev* pDev
} }
pci_set_master(pDev); pci_set_master(pDev);
if (pci_set_dma_mask(pDev, DMA_64BIT_MASK) && if (pci_set_dma_mask(pDev, DMA_32BIT_MASK))
pci_set_dma_mask(pDev, DMA_32BIT_MASK))
return -EINVAL; return -EINVAL;
base_addr0_phys = pci_resource_start(pDev,0); base_addr0_phys = pci_resource_start(pDev,0);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册