powerpc/t4240: Adding workaround errata A-005871
authorShengzhou Liu <Shengzhou.Liu@freescale.com>
Wed, 23 Jan 2013 19:56:23 +0000 (19:56 +0000)
committerAndy Fleming <afleming@freescale.com>
Wed, 30 Jan 2013 17:25:15 +0000 (11:25 -0600)
When CoreNet Fabric (CCF) internal resources are consumed by the cores,
inbound SRIO messaging traffic through RMan can put the device into a
deadlock condition.

This errata workaround forces internal resources to be reserved for
upstream transactions. This ensures resources exist on the device for
upstream transactions and removes the deadlock condition.

The Workaround is for the T4240 silicon rev 1.0.

Signed-off-by: Shengzhou Liu <Shengzhou.Liu@freescale.com>
Signed-off-by: Andy Fleming <afleming@freescale.com>
arch/powerpc/cpu/mpc85xx/cmd_errata.c
arch/powerpc/cpu/mpc85xx/cpu_init.c
arch/powerpc/include/asm/config_mpc85xx.h

index e5ecf5d..5d72f4c 100644 (file)
@@ -240,6 +240,10 @@ static int do_errata(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 #ifdef CONFIG_SYS_FSL_ERRATUM_A_004934
        puts("Work-around for Erratum A004934 enabled\n");
 #endif
+#ifdef CONFIG_SYS_FSL_ERRATUM_A005871
+       if (IS_SVR_REV(svr, 1, 0))
+               puts("Work-around for Erratum A005871 enabled\n");
+#endif
 #ifdef CONFIG_SYS_FSL_ERRATUM_A004849
        /* This work-around is implemented in PBI, so just check for it */
        check_erratum_a4849(svr);
index cc09300..de9d916 100644 (file)
@@ -548,6 +548,20 @@ skip_l2:
        /* needs to be in ram since code uses global static vars */
        fsl_serdes_init();
 
+#ifdef CONFIG_SYS_FSL_ERRATUM_A005871
+       if (IS_SVR_REV(svr, 1, 0)) {
+               int i;
+               __be32 *p = (void __iomem *)CONFIG_SYS_DCSRBAR + 0xb004c;
+
+               for (i = 0; i < 12; i++) {
+                       p += i + (i > 5 ? 11 : 0);
+                       out_be32(p, 0x2);
+               }
+               p = (void __iomem *)CONFIG_SYS_DCSRBAR + 0xb0108;
+               out_be32(p, 0x34);
+       }
+#endif
+
 #ifdef CONFIG_SYS_SRIO
        srio_init();
 #ifdef CONFIG_SYS_FSL_SRIO_PCIE_BOOT_MASTER 
index 7943fa4..d57c178 100644 (file)
 #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY
 #define CONFIG_SYS_FSL_ERRATUM_A004468
 #define CONFIG_SYS_FSL_ERRATUM_A_004934
+#define CONFIG_SYS_FSL_ERRATUM_A005871
 #define CONFIG_SYS_CCSRBAR_DEFAULT     0xfe000000
 
 #elif defined(CONFIG_PPC_B4420)