提交 47c4f997 编写于 作者: E Ed Lin 提交者: James Bottomley

[SCSI] stex: add value check in hard reset routine

During hard reset, an all-1 value from PCI_COMMAND should be invalid.
Signed-off-by: NEd Lin <ed.lin@promise.com>
Signed-off-by: NJames Bottomley <James.Bottomley@SteelEye.com>
上级 4eea9dc4
......@@ -1041,7 +1041,7 @@ static void stex_hard_reset(struct st_hba *hba)
for (i = 0; i < MU_MAX_DELAY_TIME; i++) {
pci_read_config_word(hba->pdev, PCI_COMMAND, &pci_cmd);
if (pci_cmd & PCI_COMMAND_MASTER)
if (pci_cmd != 0xffff && (pci_cmd & PCI_COMMAND_MASTER))
break;
msleep(1);
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册