]> git.kernelconcepts.de Git - karo-tx-uboot.git/commitdiff
powerpc/85xx: Add workaround for errata USB-14 (enable on P204x/P3041/P50x0)
authorXulei <B33228@freescale.com>
Mon, 11 Mar 2013 17:56:34 +0000 (17:56 +0000)
committerAndy Fleming <afleming@freescale.com>
Thu, 2 May 2013 21:56:44 +0000 (16:56 -0500)
On P204x/P304x/P50x0 Rev1.0, USB transmit will result in false internal
multi-bit ECC errors, which has impact on performance, so software should
disable all ECC reporting from USB1 and USB2.

In formal release document, the errata number should be USB14 instead of USB138.

Signed-off-by: xulei <Lei.Xu@freescale.com>
Signed-off-by: Roy Zang <tie-fei.zang@freescale.com>
Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
Signed-off-by: xulei <B33228@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
arch/powerpc/include/asm/immap_85xx.h

index 5d72f4c342d36dcb9462b67ed71e35e72426aec4..422782ca8f209e764dc9d9c9c103609dba593a1e 100644 (file)
@@ -254,6 +254,9 @@ static int do_errata(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
 #endif
 #ifdef CONFIG_SYS_P4080_ERRATUM_PCIE_A003
        puts("Work-around for Erratum PCIe-A003 enabled\n");
+#endif
+#ifdef CONFIG_SYS_FSL_ERRATUM_USB14
+       puts("Work-around for Erratum USB14 enabled\n");
 #endif
        return 0;
 }
index de9d9161115d1713fb02ee90c22845b04f7e58bd..53713e31d42a05b85aadd021a7c5528957ca5e2a 100644 (file)
@@ -623,6 +623,20 @@ skip_l2:
        }
 #endif
 
+#ifdef CONFIG_SYS_FSL_ERRATUM_USB14
+       /* On P204x/P304x/P50x0 Rev1.0, USB transmit will result internal
+        * multi-bit ECC errors which has impact on performance, so software
+        * should disable all ECC reporting from USB1 and USB2.
+        */
+       if (IS_SVR_REV(get_svr(), 1, 0)) {
+               struct dcsr_dcfg_regs *dcfg = (struct dcsr_dcfg_regs *)
+                       (CONFIG_SYS_DCSRBAR + CONFIG_SYS_DCSR_DCFG_OFFSET);
+               setbits_be32(&dcfg->ecccr1,
+                               (DCSR_DCFG_ECC_DISABLE_USB1 |
+                                DCSR_DCFG_ECC_DISABLE_USB2));
+       }
+#endif
+
 #ifdef CONFIG_FMAN_ENET
        fman_enet_init();
 #endif
index 8285ae148651eb6d360cabdb1b6a49dd03fc3134..284b82a9da679c7a3cda853100c67aeaf4489fb3 100644 (file)
 #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY
 #define CONFIG_SYS_FSL_ERRATUM_ESDHC111
 #define CONFIG_SYS_FSL_ERRATUM_NMG_CPU_A011
+#define CONFIG_SYS_FSL_ERRATUM_USB14
 #define CONFIG_SYS_FSL_ERRATUM_CPU_A003999
 #define CONFIG_SYS_FSL_ERRATUM_DDR_A003474
 #define CONFIG_SYS_FSL_SRIO_PCIE_BOOT_MASTER
 #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY
 #define CONFIG_SYS_FSL_ERRATUM_ESDHC111
 #define CONFIG_SYS_FSL_ERRATUM_NMG_CPU_A011
+#define CONFIG_SYS_FSL_ERRATUM_USB14
 #define CONFIG_SYS_FSL_ERRATUM_CPU_A003999
 #define CONFIG_SYS_FSL_ERRATUM_DDR_A003474
 #define CONFIG_SYS_FSL_SRIO_PCIE_BOOT_MASTER
 #define CONFIG_SYS_FSL_USB2_PHY_ENABLE
 #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY
 #define CONFIG_SYS_FSL_ERRATUM_ESDHC111
+#define CONFIG_SYS_FSL_ERRATUM_USB14
 #define CONFIG_SYS_FSL_ERRATUM_DDR_A003474
 #define CONFIG_SYS_FSL_SRIO_PCIE_BOOT_MASTER
 #define CONFIG_SYS_FSL_SRIO_MAX_PORTS  2
 #define CONFIG_SYS_FSL_USB2_PHY_ENABLE
 #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY
 #define CONFIG_SYS_FSL_ERRATUM_ESDHC111
-#define CONFIG_SYS_FSL_ERRATUM_USB138
+#define CONFIG_SYS_FSL_ERRATUM_USB14
 #define CONFIG_SYS_FSL_ERRATUM_DDR_A003
 #define CONFIG_SYS_FSL_ERRATUM_DDR_A003474
 #define CONFIG_SYS_FSL_ERRATUM_A004699
index 1c8d1ac0eea67343f4dbcf5ccf8ec4d7c1148cd0..baaa9fee534cbe86594b2258d422c34f39f6b481 100644 (file)
@@ -3161,4 +3161,13 @@ struct ccsr_cluster_l2 {
 #define CONFIG_SYS_FSL_CLUSTER_1_L2 \
        (CONFIG_SYS_IMMR + CONFIG_SYS_FSL_CLUSTER_1_L2_OFFSET)
 #endif /* CONFIG_SYS_FSL_QORIQ_CHASSIS2 */
+
+#define        CONFIG_SYS_DCSR_DCFG_OFFSET     0X20000
+struct dcsr_dcfg_regs {
+       u8  res_0[0x520];
+       u32 ecccr1;
+#define        DCSR_DCFG_ECC_DISABLE_USB1      0x00008000
+#define        DCSR_DCFG_ECC_DISABLE_USB2      0x00004000
+       u8  res_524[0x1000 - 0x524]; /* 0x524 - 0x1000 */
+};
 #endif /*__IMMAP_85xx__*/