From: Vijaya Mohan Guvva Date: Mon, 13 May 2013 09:33:24 +0000 (-0700) Subject: [SCSI] bfa: Fix 1860 port initialize when ATC is enabled X-Git-Url: http://drtracing.org/?a=commitdiff_plain;h=e1aaab89dee184646f7001850e1fe6d55090a728;p=deliverable%2Flinux.git [SCSI] bfa: Fix 1860 port initialize when ATC is enabled On Xen kernels, if ATC (address translation cache) is enabled, the first PCIe DMA read from the adapter fails with an error. This is due to a bug ASIC, which leads to a failure of 1860 ports to be initialised. This patch includes the fix to disable Invalidated Tag Match Enable capability by setting the bit 26 of CHIP_MISC_PRG to 0, by default it is set to 1. Signed-off-by: Anil Gurumurthy Signed-off-by: Vijaya Mohan Guvva Signed-off-by: James Bottomley --- diff --git a/drivers/scsi/bfa/bfa_ioc_ct.c b/drivers/scsi/bfa/bfa_ioc_ct.c index de4e726a1263..a8e52a108710 100644 --- a/drivers/scsi/bfa/bfa_ioc_ct.c +++ b/drivers/scsi/bfa/bfa_ioc_ct.c @@ -918,6 +918,16 @@ bfa_ioc_ct2_pll_init(void __iomem *rb, enum bfi_asic_mode mode) } } + /* + * The very first PCIe DMA Read done by LPU fails with a fatal error, + * when Address Translation Cache (ATC) has been enabled by system BIOS. + * + * Workaround: + * Disable Invalidated Tag Match Enable capability by setting the bit 26 + * of CHIP_MISC_PRG to 0, by default it is set to 1. + */ + r32 = readl(rb + CT2_CHIP_MISC_PRG); + writel((r32 & 0xfbffffff), (rb + CT2_CHIP_MISC_PRG)); /* * Mask the interrupts and clear any