mpc85xx/powerpc:cpu_init: Modified the errata according to endianness
PATCH 1/1 mpc85xx/powerpc:cpu_init: Modified the errata according to endianness
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian. Also, Adds errata for P1010 and P2041 2.0.
--- arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 6 ++++-- 4 files changed, 9 insertions(+), 4 deletions(-)
arch/powerpc/cpu/mpc85xx/cpu_init.c +2 -2
@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }
arch/powerpc/include/asm/config_mpc85xx.h +1 -0
@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE #define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10
arch/powerpc/include/asm/immap_85xx.h +2 -0
@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )
drivers/usb/common/fsl-errata.c +4 -2
@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
@@ -72,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }
Signature · 1 line
2.1.0
PATCH 1/1 mpc85xx/powerpc:cpu_init: Modified the errata according to endianness
Quoted 3 lines · Sriram Dash
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian. Also
Please split this into two patches.
, Adds errata for P1010 and
Quoted 78 lines
P2041 2.0.
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 6 ++++-- 4 files changed, 9 insertions(+), 4 deletions(-)arch/powerpc/cpu/mpc85xx/cpu_init.c +2
-2@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }arch/powerpc/include/asm/config_mpc85xx.h +1
-0@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE #define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10arch/powerpc/include/asm/immap_85xx.h +2
-0@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )drivers/usb/common/fsl-errata.c +4
-2@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||@@ -72,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }
Signature · 2 lines
Best regards, Marek Vasut
PATCH 1/1 mpc85xx/powerpc:cpu_init: Modified the errata according to endianness
In reply to Sriram Dash+Suresh Gupta
Quoted 4 lines · Sriram Dash
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian. Also, Adds errata for P1010 and P2041 2.0.
It would be helpful to mention erratum number A-006261 in the commit message in case you need to find this commit later.
Quoted 15 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 6 ++++-- 4 files changed, 9 insertions(+), 4 deletions(-)arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0
arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy) · line 120
Quoted 9 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +2
-2@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;
Has this been wrong all the time? If the disconnect voltage threshold was wrong, did someone observe abnormal behavior?
Suresh, please comment here.
arch/powerpc/include/asm/config_mpc85xx.h line 165
Quoted 12 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }arch/powerpc/include/asm/config_mpc85xx.h +1
-0@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE
Enabling the workaround for another SoC should be in a separated patch.
Quoted 31 lines
arch/powerpc/include/asm/config_mpc85xx.h +0
-0#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10arch/powerpc/include/asm/immap_85xx.h +2
-0@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )drivers/usb/common/fsl-errata.c +2
-1@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
drivers/usb/common/fsl-errata.c bool has_erratum_a006261(void) · line 79
Quoted 8 lines
drivers/usb/common/fsl-errata.c +2
-1@@ -72,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }
Are you sure this erratum applies to P5040 rev 2.0 and rev 2.1? My document shows it doesn't (only applies to rev 1.0).
York
PATCH 1/1 mpc85xx/powerpc:cpu_init: Modified the errata according to endianness
In reply to Marek VasutQuoted 8 lines
From: Marek Vasut [mailto:marex at denx.de]
Quoted 3 lines · Sriram Dash
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian. Also
Please split this into two patches.
OK. Will take care in v2.
Quoted 90 lines
, Adds errata for P1010 and
arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct
Quoted 17 lines
P2041 2.0.
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 6 ++++-- 4 files changed, 9 insertions(+), 4 deletions(-)arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct
ccsr_usb_phy__iomem*usb_phy)arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)
Quoted 4 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-1setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct · line 117
Quoted 1 line
arch/powerpc/cpu/mpc85xx/cpu_init.c +1
-0+ temp = squelch_prog_rd_0_2 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)
Quoted 3 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-1out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct · line 120
Quoted 1 line
arch/powerpc/cpu/mpc85xx/cpu_init.c +1
-0+ temp = squelch_prog_rd_3_5 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0;Quoted 44 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); #endif } diff --git a/arch/powerpc/include/asm/config_mpc85xx.h
b/arch/powerpc/include/asm/config_mpc85xx.h
index 505d355..9b7feda 100644arch/powerpc/include/asm/config_mpc85xx.h +0
-0@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define
CONFIG_SYS_FSL_ERRATUM_A007075
+#defineCONFIG_SYS_FSL_USB1_PHY_ENABLE
#defineCONFIG_SYS_FSL_ERRATUM_A006261#defineCONFIG_SYS_FSL_ERRATUM_A004477
#defineCONFIG_SYS_FSL_A004447_SVR_REV0x10arch/powerpc/include/asm/immap_85xx.h +2
-0@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )(quoted diff) +0
-0
b/drivers/usb/common/fsl-errata.cindex ebe60a8..a69b977 100644drivers/usb/common/fsl-errata.c +2
-1@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||drivers/usb/common/fsl-errata.c bool has_erratum_a006261(void) · line 80
Quoted 9 lines
drivers/usb/common/fsl-errata.c +2
-1@@ -72,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }--
Best regards,
Marek Vasut
PATCH 1/1 mpc85xx/powerpc:cpu_init: Modified the errata according to endianness
In reply to york sunQuoted 4 lines
From: york sun
+Suresh Gupta
Quoted 9 lines
Quoted 4 lines · Sriram Dash
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian. Also, Adds errata for P1010 and P2041 2.0.
It would be helpful to mention erratum number A-006261 in the commit message in case you need to find this commit later.
Hello York,
OK. Will take care in v2.
Quoted 36 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct
Quoted 16 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 6 ++++-- 4 files changed, 9 insertions(+), 4 deletions(-)arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct
ccsr_usb_phy__iomem*usb_phy)arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)
Quoted 4 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-1setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct · line 117
Quoted 1 line
arch/powerpc/cpu/mpc85xx/cpu_init.c +1
-0+ temp = squelch_prog_rd_0_2 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)
Quoted 3 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-1out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct · line 120
Quoted 1 line
arch/powerpc/cpu/mpc85xx/cpu_init.c +1
-0+ temp = squelch_prog_rd_3_5 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0;Has this been wrong all the time? If the disconnect voltage threshold was wrong, did someone observe abnormal behavior?
Suresh, please comment here.
Quoted 16 lines
arch/powerpc/include/asm/config_mpc85xx.h line 165
Quoted 13 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }arch/powerpc/include/asm/config_mpc85xx.h +1
-0@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE Enabling the workaround for another SoC should be in a separated patch.
OK. Will take care in v2.
Quoted 35 lines
Quoted 35 lines
arch/powerpc/include/asm/config_mpc85xx.h +0
-0#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10arch/powerpc/include/asm/immap_85xx.h +2
-0@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )(quoted diff) +0
-0
b/drivers/usb/common/fsl-errata.cindex ebe60a8..a69b977 100644drivers/usb/common/fsl-errata.c +2
-1@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||@@ -72,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 :
Quoted 9 lines
drivers/usb/common/fsl-errata.c bool has_erratum_a006261(void) · line 79
Quoted 5 lines
drivers/usb/common/fsl-errata.c +2
-1-return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }Are you sure this erratum applies to P5040 rev 2.0 and rev 2.1? My document shows it doesn't (only applies to rev 1.0).
Yes. Apparently, some more boards are using the same phy. There has been some addition and removal off Socs for the errata, which is to be updated. I will add another patch for the removal of Socs, in which the errata is not applicable, in v2.
Quoted 1 line
York
Regards,
Sriram
v2 cover Modified the errata A006261 according to endianness
In reply to Sriram DashModifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Applies the errata for P1010, P2041, P5040.
Removes the errata for T4160, T1040, T2080.
Sriram Dash (5):
mpc85xx/powerpc:cpu_init: Modified the errata A006261 according to
endianness
mpc85xx/powerpc:P1010: Apply errata A006261 for P1010 mpc85xx/powerpc: P2041: Apply errata A006261 for P2041 mpc85xx/powerpc: P5040: Apply errata A006261 for P5040 mpc85xx/powerpc: Do not apply errata A006261 for T4160, T1040, T2080
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
Signature · 1 line
2.1.0
PATCH v2 1/5 mpc85xx/powerpc:cpu_init: Modified the errata A006261 according to endianness
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
---
Changes in v2:
- Adds the errata number to title of patch
- Makes separate patch for addition of errata to specific Socs.
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/powerpc/cpu/mpc85xx/cpu_init.c +2 -2
@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }
Signature · 1 line
2.1.0
PATCH v2 2/5 mpc85xx/powerpc:P1010: Apply errata A006261 for P1010
In reply to Sriram DashApply USB errata A006261 for P1010.
--- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ 2 files changed, 3 insertions(+)
arch/powerpc/include/asm/config_mpc85xx.h +1 -0
@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE #define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10
arch/powerpc/include/asm/immap_85xx.h +2 -0
@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )
Signature · 1 line
2.1.0
PATCH v2 3/5 mpc85xx/powerpc: P2041: Apply errata A006261 for P2041
In reply to Sriram DashApply USB errata A006261 for P2041, P2040.
--- drivers/usb/common/fsl-errata.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/usb/common/fsl-errata.c +2 -1
@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
Signature · 1 line
2.1.0
PATCH v2 4/5 mpc85xx/powerpc: P5040: Apply errata A006261 for P5040
In reply to Sriram DashApply USB errata A006261 for P5040.
--- drivers/usb/common/fsl-errata.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/usb/common/fsl-errata.c +2 -1
@@ -73,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }
Signature · 1 line
2.1.0
PATCH v2 5/5 mpc85xx/powerpc: Do not apply errata A006261 for T4160, T1040, T2080
In reply to Sriram DashDo not apply errata A006261 for T4160 and T4080(rev 1.0, 2.0), T1040(rev 1.0), T2080(rev 1.0), T2081(rev 1.0).
--- arch/powerpc/include/asm/config_mpc85xx.h | 4 +--- drivers/usb/common/fsl-errata.c | 7 ------- 2 files changed, 1 insertion(+), 10 deletions(-)
arch/powerpc/include/asm/config_mpc85xx.h +1 -3
@@ -641,6 +641,7 @@#define CONFIG_SYS_NUM_FM2_DTSEC 8#define CONFIG_SYS_NUM_FM2_10GEC 2#define CONFIG_NUM_DDR_CONTROLLERS 3 +#define CONFIG_SYS_FSL_ERRATUM_A006261 #else #define CONFIG_SYS_NUM_FM1_DTSEC 6#define CONFIG_SYS_NUM_FM1_10GEC 1
@@ -682,7 +683,6 @@#define CONFIG_SYS_FSL_ERRATUM_A004468 #define CONFIG_SYS_FSL_ERRATUM_A_004934 #define CONFIG_SYS_FSL_ERRATUM_A005871 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006379 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006593
@@ -800,7 +800,6 @@ defined(CONFIG_PPC_T1020) || defined(CONFIG_PPC_T1022)#define CONFIG_SYS_FSL_PCIE_COMPAT "fsl,qoriq-pcie-v2.4"#define CONFIG_SYS_FSL_USB_DUAL_PHY_ENABLE #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_CCSRBAR_DEFAULT 0xfe000000#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE
@@ -908,7 +907,6 @@ defined(CONFIG_PPC_T1014) || defined(CONFIG_PPC_T1013)#define CONFIG_SYS_FSL_SFP_VER_3_0 #define CONFIG_SYS_FSL_ISBC_VER 2#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006593 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006379
drivers/usb/common/fsl-errata.c +0 -7
@@ -64,14 +64,7 @@ bool has_erratum_a006261(void)case SVR_P5021 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 );case SVR_T4240 : -case SVR_T4160 : -case SVR_T4080 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ); -case SVR_T1040 : -return IS_SVR_REV (svr,1 ,0 ); -case SVR_T2080 : -case SVR_T2081 : -return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );
Signature · 1 line
2.1.0
v2 cover Modified the errata A006261 according to endianness
In reply to Sriram DashQuoted 14 lines · Sriram Dash
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Applies the errata for P1010, P2041, P5040.
Removes the errata for T4160, T1040, T2080.Sriram Dash (5):
mpc85xx/powerpc:cpu_init: Modified the errata A006261 according to
endianness
mpc85xx/powerpc:P1010: Apply errata A006261 for P1010 mpc85xx/powerpc: P2041: Apply errata A006261 for P2041 mpc85xx/powerpc: P5040: Apply errata A006261 for P5040 mpc85xx/powerpc: Do not apply errata A006261 for T4160, T1040, T2080
Quoted 6 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
York, I expect a thorough review from you _and_ a full build test. I will apply it only after you perform such verification. Please do let me know when you're done.
Signature · 2 lines
Best regards, Marek Vasut
PATCH v2 1/5 mpc85xx/powerpc:cpu_init: Modified the errata A006261 according to endianness
In reply to Sriram DashOn 07/18/2016 05:47 AM, Sriram Dash wrote:
Can you please be consistent about the tag spacing in the subject ? Each : must be followed by space.
Quoted 33 lines
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>---
Changes in v2:
- Adds the errata number to title of patch
- Makes separate patch for addition of errata to specific Socs.arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)arch/powerpc/cpu/mpc85xx/cpu_init.c +2
-2@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }
Signature · 2 lines
Best regards, Marek Vasut
PATCH v2 3/5 mpc85xx/powerpc: P2041: Apply errata A006261 for P2041
In reply to Sriram DashQuoted 1 line · Sriram Dash
Apply USB errata A006261 for P2041, P2040.
The subject and the commit message say different things. Moreover, the errata is obviously already applied to P2040 and P2041. I am extremely annoyed by such crap patches, so I stop reviewing here.
Quoted 21 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- drivers/usb/common/fsl-errata.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/usb/common/fsl-errata.c +2
-1@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
Signature · 2 lines
Best regards, Marek Vasut
PATCH v2 1/5 mpc85xx/powerpc:cpu_init: Modified the errata A006261 according to endianness
In reply to Sriram DashSriram,
Please pay attention to the language. "errata" is the plural noun of "erratum". You are dealing with one erratum, aren't you? And you are modifying the workaround, not the erratum itself.
The tags in the subject should be separated by either "/", or ":", but not both. I don't believe "cpu_init" should be in the tag.
Quoted 3 lines · Sriram Dash
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
If your change is correct, can you explain why the original format didn't cause any harm before?
York
Quoted 30 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>---
Changes in v2:
- Adds the errata number to title of patch
- Makes separate patch for addition of errata to specific Socs.arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)arch/powerpc/cpu/mpc85xx/cpu_init.c +2
-2@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }
PATCH v2 2/5 mpc85xx/powerpc:P1010: Apply errata A006261 for P1010
In reply to Sriram DashSriram,
Same comment here, please fix the subject.
Quoted 1 line · Sriram Dash
Apply USB errata A006261 for P1010.
A006261 is already applied to P1010.
Quoted 13 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ 2 files changed, 3 insertions(+)arch/powerpc/include/asm/config_mpc85xx.h +0
-0
arch/powerpc/include/asm/config_mpc85xx.h line 165
Quoted 4 lines
arch/powerpc/include/asm/config_mpc85xx.h +1
-0@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE
This is not enabling A006261. Please rewrite the commit message.
arch/powerpc/include/asm/immap_85xx.h struct ccsr_pman { · line 2957
Quoted 13 lines
arch/powerpc/include/asm/config_mpc85xx.h +0
-0#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10arch/powerpc/include/asm/immap_85xx.h +2
-0@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100
This is not for the workaround.
York
Quoted 4 lines
arch/powerpc/include/asm/immap_85xx.h +0
-0#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )
PATCH v2 3/5 mpc85xx/powerpc: P2041: Apply errata A006261 for P2041
In reply to Sriram DashSame comment to the subject.
Quoted 13 lines · Sriram Dash
Apply USB errata A006261 for P2041, P2040.
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- drivers/usb/common/fsl-errata.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/usb/common/fsl-errata.c +0
-0
drivers/usb/common/fsl-errata.c bool has_erratum_a006261(void) · line 57
Quoted 6 lines
drivers/usb/common/fsl-errata.c +2
-1@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );
Please explain in the commit message why you replace rev 1.1 with rev 2.0.
York
Quoted 4 lines
drivers/usb/common/fsl-errata.c +0
-0case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
PATCH v2 4/5 mpc85xx/powerpc: P5040: Apply errata A006261 for P5040
In reply to Sriram DashSame comment to the subject line.
Quoted 1 line · Sriram Dash
Apply USB errata A006261 for P5040.
Please add explanation the same erratum applies to P5040 rev 2.0.
Quoted 12 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- drivers/usb/common/fsl-errata.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/usb/common/fsl-errata.c +0
-0
drivers/usb/common/fsl-errata.c bool has_erratum_a006261(void) · line 77
Quoted 6 lines
drivers/usb/common/fsl-errata.c +2
-1@@ -73,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );
Because the official document doesn't include these versions, please add a comment saying this erratum applies to affected revisions.
York
Quoted 4 lines
drivers/usb/common/fsl-errata.c +0
-0#endif }
PATCH v2 5/5 mpc85xx/powerpc: Do not apply errata A006261 for T4160, T1040, T2080
In reply to Sriram DashQuoted 2 lines · Sriram Dash
Do not apply errata A006261 for T4160 and
T4080(rev 1.0, 2.0), T1040(rev 1.0), T2080(rev 1.0), T2081(rev 1.0).
I don't see mentioning the revision numbers helps here. Your patch is removing the erratum from T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081. It would be much clear if you put all A006261 related patches into one, and list all the SoCs affected by this erratum since the official released document contradicts with your list.
York
Quoted 64 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/include/asm/config_mpc85xx.h | 4 +--- drivers/usb/common/fsl-errata.c | 7 ------- 2 files changed, 1 insertion(+), 10 deletions(-)arch/powerpc/include/asm/config_mpc85xx.h +1
-3@@ -641,6 +641,7 @@#define CONFIG_SYS_NUM_FM2_DTSEC 8#define CONFIG_SYS_NUM_FM2_10GEC 2#define CONFIG_NUM_DDR_CONTROLLERS 3 +#define CONFIG_SYS_FSL_ERRATUM_A006261 #else #define CONFIG_SYS_NUM_FM1_DTSEC 6#define CONFIG_SYS_NUM_FM1_10GEC 1@@ -682,7 +683,6 @@#define CONFIG_SYS_FSL_ERRATUM_A004468 #define CONFIG_SYS_FSL_ERRATUM_A_004934 #define CONFIG_SYS_FSL_ERRATUM_A005871 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006379 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006593 @@ -800,7 +800,6 @@ defined(CONFIG_PPC_T1020) || defined(CONFIG_PPC_T1022)#define CONFIG_SYS_FSL_PCIE_COMPAT "fsl,qoriq-pcie-v2.4"#define CONFIG_SYS_FSL_USB_DUAL_PHY_ENABLE #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_CCSRBAR_DEFAULT 0xfe000000#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE @@ -908,7 +907,6 @@ defined(CONFIG_PPC_T1014) || defined(CONFIG_PPC_T1013)#define CONFIG_SYS_FSL_SFP_VER_3_0 #define CONFIG_SYS_FSL_ISBC_VER 2#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006593 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006379 drivers/usb/common/fsl-errata.c +0
-7@@ -64,14 +64,7 @@ bool has_erratum_a006261(void)case SVR_P5021 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 );case SVR_T4240 : -case SVR_T4160 : -case SVR_T4080 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ); -case SVR_T1040 : -return IS_SVR_REV (svr,1 ,0 ); -case SVR_T2080 : -case SVR_T2081 : -return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );
v2 cover Modified the errata A006261 according to endianness
In reply to Marek VasutQuoted 21 lines · Marek Vasut
Quoted 14 lines · Sriram Dash
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Applies the errata for P1010, P2041, P5040.
Removes the errata for T4160, T1040, T2080.Sriram Dash (5):
mpc85xx/powerpc:cpu_init: Modified the errata A006261 according to
endianness
mpc85xx/powerpc:P1010: Apply errata A006261 for P1010 mpc85xx/powerpc: P2041: Apply errata A006261 for P2041 mpc85xx/powerpc: P5040: Apply errata A006261 for P5040 mpc85xx/powerpc: Do not apply errata A006261 for T4160, T1040, T2080Quoted 6 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
Quoted 4 lines
York, I expect a thorough review from you _and_ a full build test. I will apply it only after you perform such verification. Please do let me know when you're done.
NAK this set. Do not apply.
York
PATCH v2 1/5 mpc85xx/powerpc:cpu_init: Modified the errata A006261 according to endianness
In reply to york sunQuoted 11 lines
From: york sun
Sriram,
Please pay attention to the language. "errata" is the plural noun of "erratum". You are dealing with one erratum, aren't you? And you are modifying the workaround, not the erratum itself.
The tags in the subject should be separated by either "/", or ":", but not both. I don't believe "
cpu_init" should be in the tag.
Hello York,
Will take care from next time onwards. Will change in v3.
Quoted 11 lines · Sriram Dash
Quoted 3 lines
Modifies errata implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
If your change is correct, can you explain why the original format didn't cause any harm before?
York
If it is working due to SWAP most likely reason would be bit[9] of confige1 which might be getting mapped to HS Disconnect decrement by 50mV. Whereas Errata intends to increase the threshold by 100mV though bit C1[8:9] which map to C1[23:22] in BG. I mean in full swap, this value will have maximum impact, although complete write is expected to be done properly.
Quoted 36 lines
Quoted 9 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>---
Changes in v2:
- Adds the errata number to title of patch
- Makes separate patch for addition of errata to specific Socs.Review
Quoted 4 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)(quoted diff) +0
-0
b/arch/powerpc/cpu/mpc85xx/cpu_init.carch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct
Quoted 4 lines
index 61f5639..61dedfc 100644
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct
ccsr_usb_phy__iomem*usb_phy)arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)
Quoted 4 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-1setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct · line 117
Quoted 1 line
arch/powerpc/cpu/mpc85xx/cpu_init.c +1
-0+ temp = squelch_prog_rd_0_2 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)
Quoted 3 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-1out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3;arch/powerpc/cpu/mpc85xx/cpu_init.c void fsl_erratum_a006261_workaround(struct · line 120
Quoted 1 line
arch/powerpc/cpu/mpc85xx/cpu_init.c +1
-0+ temp = squelch_prog_rd_3_5 <<
CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0;Quoted 4 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c +0
-0out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }
PATCH v2 2/5 mpc85xx/powerpc:P1010: Apply errata A006261 for P1010
In reply to york sunQuoted 6 lines
From: york sun
Sriram,
Same comment here, please fix the subject.
Ok. Will modify patch title and commit message in v3.
Quoted 14 lines · Sriram Dash
Quoted 1 line
Apply USB errata A006261 for P1010.
A006261 is already applied to P1010.
Quoted 8 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ 2 files changed, 3 insertions(+)
Quoted 13 lines
Quoted 10 lines
arch/powerpc/include/asm/config_mpc85xx.h +0
-0@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define
CONFIG_SYS_FSL_ERRATUM_A007075
+#defineCONFIG_SYS_FSL_USB1_PHY_ENABLEThis is not enabling A006261. Please rewrite the commit message.
Ok. Will modify patch title and commit message in v3.
Quoted 17 lines
Quoted 9 lines
#define
CONFIG_SYS_FSL_ERRATUM_A006261#defineCONFIG_SYS_FSL_ERRATUM_A004477
#defineCONFIG_SYS_FSL_A004447_SVR_REV0x10arch/powerpc/include/asm/immap_85xx.h +0
-0arch/powerpc/include/asm/immap_85xx.h struct ccsr_pman { · line 2957
Quoted 5 lines
arch/powerpc/include/asm/immap_85xx.h +2
-0@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100This is not for the workaround.
Quoted 2 lines
York
Ok. Will modify patch title and commit message in v3.
Quoted 5 lines
Quoted 5 lines
arch/powerpc/include/asm/immap_85xx.h +0
-0#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )
PATCH v2 3/5 mpc85xx/powerpc: P2041: Apply errata A006261 for P2041
In reply to york sunQuoted 4 lines
From: york sun
Same comment to the subject.
Ok. Will modify patch title and commit message in v3.
Quoted 23 lines · Sriram Dash
Quoted 13 lines
Apply USB errata A006261 for P2041, P2040.
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- drivers/usb/common/fsl-errata.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)(quoted diff) +0
-0
b/drivers/usb/common/fsl-errata.cindex 183bf2b..122e17b 100644drivers/usb/common/fsl-errata.c bool has_erratum_a006261(void) · line 57
Quoted 6 lines
drivers/usb/common/fsl-errata.c +2
-1@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );Please explain in the commit message why you replace rev 1.1 with rev 2.0.
Quoted 2 lines
York
I have not removed the rev 1.1 support, only added the rev 2.0 support. Will modify patch title and commit message in v3.
Quoted 5 lines
Quoted 5 lines
drivers/usb/common/fsl-errata.c +0
-0case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
PATCH v2 4/5 mpc85xx/powerpc: P5040: Apply errata A006261 for P5040
In reply to york sunQuoted 4 lines
From: york sun
Same comment to the subject line.
Ok. Will modify patch title and commit message in v3.
Quoted 5 lines · Sriram Dash
Quoted 1 line
Apply USB errata A006261 for P5040.
Please add explanation the same erratum applies to P5040 rev 2.0.
Ok. Will modify patch title and commit message in v3.
Quoted 22 lines
Quoted 12 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- drivers/usb/common/fsl-errata.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)(quoted diff) +0
-0
b/drivers/usb/common/fsl-errata.cindex 122e17b..765b25a 100644drivers/usb/common/fsl-errata.c bool has_erratum_a006261(void) · line 77
Quoted 6 lines
drivers/usb/common/fsl-errata.c +2
-1@@ -73,7 +73,8 @@ bool has_erratum_a006261(void)case SVR_T2081 :return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );Because the official document doesn't include these versions, please add a comment saying this erratum applies to affected revisions.
Quoted 2 lines
York
Ok. Will modify patch title and commit message in v3.
Quoted 5 lines
Quoted 5 lines
drivers/usb/common/fsl-errata.c +0
-0#endif }
PATCH v2 5/5 mpc85xx/powerpc: Do not apply errata A006261 for T4160, T1040, T2080
In reply to york sunQuoted 5 lines
From: york sun
Quoted 2 lines · Sriram Dash
Do not apply errata A006261 for T4160 and
T4080(rev 1.0, 2.0), T1040(rev 1.0), T2080(rev 1.0), T2081(rev 1.0).
Quoted 8 lines
I don't see mentioning the revision numbers helps here. Your patch is removing the erratum from T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081. It would be much clear if you put all A006261 related patches into one, and list all the SoCs affected by this erratum since the official released document contradicts with your list.
York
Ok. I will divide the patchset into 3 patches. First patch for modifying the erratum. Second patch for enabling the init for P1010 so that erratum can be applied on it. Third patch to take care of the Socs addition and deletion.
Quoted 67 lines
Quoted 24 lines
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>--- arch/powerpc/include/asm/config_mpc85xx.h | 4 +--- drivers/usb/common/fsl-errata.c | 7 ------- 2 files changed, 1 insertion(+), 10 deletions(-)arch/powerpc/include/asm/config_mpc85xx.h +1
-0@@ -641,6 +641,7 @@#define CONFIG_SYS_NUM_FM2_DTSEC 8#define CONFIG_SYS_NUM_FM2_10GEC 2#define CONFIG_NUM_DDR_CONTROLLERS 3 +#define CONFIG_SYS_FSL_ERRATUM_A006261 #else #define CONFIG_SYS_NUM_FM1_DTSEC 6#define CONFIG_SYS_NUM_FM1_10GEC 1@@ -682,7 +683,6 @@#define CONFIG_SYS_FSL_ERRATUM_A004468 #defineQuoted 2 lines
CONFIG_SYS_FSL_ERRATUM_A_004934#defineCONFIG_SYS_FSL_ERRATUM_A005871-#define
CONFIG_SYS_FSL_ERRATUM_A006261Quoted 2 lines
#define
CONFIG_SYS_FSL_ERRATUM_A006379#defineCONFIG_SYS_FSL_ERRATUM_A007186#define
CONFIG_SYS_FSL_ERRATUM_A006593arch/powerpc/include/asm/config_mpc85xx.h defined(CONFIG_PPC_T1020) ||
Quoted 1 line
arch/powerpc/include/asm/config_mpc85xx.h +0
-0@@ -800,7 +800,6 @@ defined(CONFIG_PPC_T1020) ||
defined(CONFIG_PPC_T1022)Quoted 6 lines
arch/powerpc/include/asm/config_mpc85xx.h +0
-1#define CONFIG_SYS_FSL_PCIE_COMPAT "fsl,qoriq-pcie-v2.4"#define CONFIG_SYS_FSL_USB_DUAL_PHY_ENABLE #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_CCSRBAR_DEFAULT 0xfe000000#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 #defineQuoted 6 lines
ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE@@ -908,7 +907,6 @@defined(CONFIG_PPC_T1014)||defined(CONFIG_PPC_T1013)#defineCONFIG_SYS_FSL_SFP_VER_3_0
#defineCONFIG_SYS_FSL_ISBC_VER2
#defineCONFIG_SYS_FSL_ERRATUM_ESDHC111-#defineCONFIG_SYS_FSL_ERRATUM_A006261#define
CONFIG_SYS_FSL_ERRATUM_A006593Quoted 22 lines
#define
CONFIG_SYS_FSL_ERRATUM_A007186#defineCONFIG_SYS_FSL_ERRATUM_A006379diff --gita/drivers/usb/common/fsl-errata.cb/drivers/usb/common/fsl-errata.cindex 765b25a..972016c 100644drivers/usb/common/fsl-errata.c +0
-7@@ -64,14 +64,7 @@ bool has_erratum_a006261(void)case SVR_P5021 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 );case SVR_T4240 : -case SVR_T4160 : -case SVR_T4080 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ); -case SVR_T1040 : -return IS_SVR_REV (svr,1 ,0 ); -case SVR_T2080 : -case SVR_T2081 : -return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );
v3 cover Modifies the erratum A006261 according to endianness
In reply to Sriram DashFrom: Sriram Dash <[email protected]>
Modifies erratum A006261 implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Enables the Phy init settings for P1010 Soc.
Also, applies the erratum for P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1 and removes the erratum for T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081.
Sriram Dash (3):
mpc85xx: powerpc: usb: Modified the erratum A006261 according to
endianness
mpc85xx: powerpc: usb: Enable Usb phy initialisation settings for
P1010
mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum
A006261arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
Signature · 1 line
2.1.0
PATCH v3 1/3 mpc85xx: powerpc: usb: Modified the erratum A006261 according to endianness
From: Sriram Dash <[email protected]>
Modifies erratum implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
---
Changes in v3:
- Modify the commit message
- Modify the commit description
Changes in v2:
- Adds the errata number to title of patch
- Makes separate patch for addition of errata to specific Socs.
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/powerpc/cpu/mpc85xx/cpu_init.c +2 -2
@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }
Signature · 1 line
2.1.0
PATCH v3 2/3 mpc85xx: powerpc: usb: Enable Usb phy initialisation settings for P1010
In reply to y at lvd5587.freescale.comFrom: Sriram Dash <[email protected]>
CONFIG_SYS_FSL_USB1_PHY_ENABLE is set and the USB Phy offset are set to enable the initial setting of Usb Phy for P1010.
---
Changes in v3:
- Modify the commit message
- Modify the commit description
arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ 2 files changed, 3 insertions(+)
arch/powerpc/include/asm/config_mpc85xx.h +1 -0
@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE #define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10
arch/powerpc/include/asm/immap_85xx.h +2 -0
@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )
Signature · 1 line
2.1.0
PATCH v3 3/3 mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum A006261
In reply to y at lvd5587.freescale.comFrom: Sriram Dash <[email protected]>
Apply the erratum A006261 for the following Socs:
P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1
Do not apply erratum A006261 for the following Socs:
T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081
Erratum A006261 is applicable for the following Socs:P1010(1.0, 2.0), P2041(1.0, 1.1, 2.0, 2.1), P2040(1.0, 1.1, 2.0, 2.1), P3041(1.0, 1.1, 2.0, 2.1), P5010(1.0, 2.0), P5020(1.0, 2.0), P5021(1.0, 2.0), T4240(1.0, 2.0), P5040(1.0,2.0,2.1).
---
Changes in v3:
- Modify the commit message
- Modify the commit description
- Make a single patch for all the Socs getting affected by erratum A6261. Also, list the current Socs in description, for which erratum A006261 is applicable.
arch/powerpc/include/asm/config_mpc85xx.h | 4 +--- drivers/usb/common/fsl-errata.c | 13 ++++--------- 2 files changed, 5 insertions(+), 12 deletions(-)
arch/powerpc/include/asm/config_mpc85xx.h +1 -3
@@ -641,6 +641,7 @@#define CONFIG_SYS_NUM_FM2_DTSEC 8#define CONFIG_SYS_NUM_FM2_10GEC 2#define CONFIG_NUM_DDR_CONTROLLERS 3 +#define CONFIG_SYS_FSL_ERRATUM_A006261 #else #define CONFIG_SYS_NUM_FM1_DTSEC 6#define CONFIG_SYS_NUM_FM1_10GEC 1
@@ -682,7 +683,6 @@#define CONFIG_SYS_FSL_ERRATUM_A004468 #define CONFIG_SYS_FSL_ERRATUM_A_004934 #define CONFIG_SYS_FSL_ERRATUM_A005871 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006379 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006593
@@ -800,7 +800,6 @@ defined(CONFIG_PPC_T1020) || defined(CONFIG_PPC_T1022)#define CONFIG_SYS_FSL_PCIE_COMPAT "fsl,qoriq-pcie-v2.4"#define CONFIG_SYS_FSL_USB_DUAL_PHY_ENABLE #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_CCSRBAR_DEFAULT 0xfe000000#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE
@@ -908,7 +907,6 @@ defined(CONFIG_PPC_T1014) || defined(CONFIG_PPC_T1013)#define CONFIG_SYS_FSL_SFP_VER_3_0 #define CONFIG_SYS_FSL_ISBC_VER 2#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006593 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006379
drivers/usb/common/fsl-errata.c +4 -9
@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
@@ -63,16 +64,10 @@ bool has_erratum_a006261(void)case SVR_P5021 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 );case SVR_T4240 : -case SVR_T4160 : -case SVR_T4080 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ); -case SVR_T1040 : -return IS_SVR_REV (svr,1 ,0 ); -case SVR_T2080 : -case SVR_T2081 : -return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }
Signature · 1 line
2.1.0
v3 cover Modifies the erratum A006261 according to endianness
In reply to Sriram DashModifies erratum A006261 implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Enables the Phy init settings for P1010 Soc.
Also, applies the erratum for P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1 and removes the erratum for T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081.
Sriram Dash (3):
mpc85xx: powerpc: usb: Modified the erratum A006261 according to
endianness
mpc85xx: powerpc: usb: Enable Usb phy initialisation settings for
P1010
mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum
A006261arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
Signature · 1 line
2.1.0
PATCH v3 1/3 mpc85xx: powerpc: usb: Modified the erratum A006261 according to endianness
Modifies erratum implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
---
Changes in v3:
- Modify the commit message
- Modify the commit description
Changes in v2:
- Adds the errata number to title of patch
- Makes separate patch for addition of errata to specific Socs.
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
arch/powerpc/cpu/mpc85xx/cpu_init.c +2 -2
@@ -114,10 +114,10 @@ void fsl_erratum_a006261_workaround(struct ccsr_usb_phy __iomem *usb_phy)setbits_be32 (&usb_phy->config2,CONFIG_SYS_FSL_USB_RX_AUTO_CAL_RD_WR_SEL ); - temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ; + temp = squelch_prog_rd_0_2 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp); - temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_3 ; + temp = squelch_prog_rd_3_5 <<CONFIG_SYS_FSL_USB_SQUELCH_PROG_WR_0 ;out_be32 (&usb_phy->config2,in_be32 (&usb_phy->config2) | temp);#endif }
Signature · 1 line
2.1.0
PATCH v3 2/3 mpc85xx: powerpc: usb: Enable Usb phy initialisation settings for P1010
In reply to Sriram DashCONFIG_SYS_FSL_USB1_PHY_ENABLE is set and the USB Phy offset are set to enable the initial setting of Usb Phy for P1010.
---
Changes in v3:
- Modify the commit message
- Modify the commit description
arch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ 2 files changed, 3 insertions(+)
arch/powerpc/include/asm/config_mpc85xx.h +1 -0
@@ -162,6 +162,7 @@#define CONFIG_SYS_FSL_ERRATUM_I2C_A004447 #define CONFIG_SYS_FSL_ERRATUM_A004508 #define CONFIG_SYS_FSL_ERRATUM_A007075 +#define CONFIG_SYS_FSL_USB1_PHY_ENABLE #define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A004477 #define CONFIG_SYS_FSL_A004447_SVR_REV 0x10
arch/powerpc/include/asm/immap_85xx.h +2 -0
@@ -2953,6 +2953,8 @@ struct ccsr_pman {#define CONFIG_SYS_MPC85xx_DMA_OFFSET 0x21000#define CONFIG_SYS_MPC85xx_USB1_OFFSET 0x22000#define CONFIG_SYS_MPC85xx_USB2_OFFSET 0x23000 +#define CONFIG_SYS_MPC85xx_USB1_PHY_OFFSET 0xE5000 +#define CONFIG_SYS_MPC85xx_USB2_PHY_OFFSET 0xE5100#ifdef CONFIG_TSECV2 #define CONFIG_SYS_TSEC1_OFFSET 0xB0000#elif defined(CONFIG_TSECV2_1 )
Signature · 1 line
2.1.0
PATCH v3 3/3 mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum A006261
In reply to Sriram DashApply the erratum A006261 for the following Socs:
P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1
Do not apply erratum A006261 for the following Socs:
T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081
Erratum A006261 is applicable for the following Socs:P1010(1.0, 2.0), P2041(1.0, 1.1, 2.0, 2.1), P2040(1.0, 1.1, 2.0, 2.1), P3041(1.0, 1.1, 2.0, 2.1), P5010(1.0, 2.0), P5020(1.0, 2.0), P5021(1.0, 2.0), T4240(1.0, 2.0), P5040(1.0,2.0,2.1).
---
Changes in v3:
- Modify the commit message
- Modify the commit description
- Make a single patch for all the Socs getting affected by erratum A6261. Also, list the current Socs in description, for which erratum A006261 is applicable.
arch/powerpc/include/asm/config_mpc85xx.h | 4 +--- drivers/usb/common/fsl-errata.c | 13 ++++--------- 2 files changed, 5 insertions(+), 12 deletions(-)
arch/powerpc/include/asm/config_mpc85xx.h +1 -3
@@ -641,6 +641,7 @@#define CONFIG_SYS_NUM_FM2_DTSEC 8#define CONFIG_SYS_NUM_FM2_10GEC 2#define CONFIG_NUM_DDR_CONTROLLERS 3 +#define CONFIG_SYS_FSL_ERRATUM_A006261 #else #define CONFIG_SYS_NUM_FM1_DTSEC 6#define CONFIG_SYS_NUM_FM1_10GEC 1
@@ -682,7 +683,6 @@#define CONFIG_SYS_FSL_ERRATUM_A004468 #define CONFIG_SYS_FSL_ERRATUM_A_004934 #define CONFIG_SYS_FSL_ERRATUM_A005871 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006379 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006593
@@ -800,7 +800,6 @@ defined(CONFIG_PPC_T1020) || defined(CONFIG_PPC_T1022)#define CONFIG_SYS_FSL_PCIE_COMPAT "fsl,qoriq-pcie-v2.4"#define CONFIG_SYS_FSL_USB_DUAL_PHY_ENABLE #define CONFIG_SYS_FSL_USB_INTERNAL_UTMI_PHY -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_CCSRBAR_DEFAULT 0xfe000000#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 #define ESDHCI_QUIRK_BROKEN_TIMEOUT_VALUE
@@ -908,7 +907,6 @@ defined(CONFIG_PPC_T1014) || defined(CONFIG_PPC_T1013)#define CONFIG_SYS_FSL_SFP_VER_3_0 #define CONFIG_SYS_FSL_ISBC_VER 2#define CONFIG_SYS_FSL_ERRATUM_ESDHC111 -#define CONFIG_SYS_FSL_ERRATUM_A006261 #define CONFIG_SYS_FSL_ERRATUM_A006593 #define CONFIG_SYS_FSL_ERRATUM_A007186 #define CONFIG_SYS_FSL_ERRATUM_A006379
drivers/usb/common/fsl-errata.c +4 -9
@@ -53,7 +53,8 @@ bool has_erratum_a006261(void)case SVR_P2041 :case SVR_P2040 :return IS_SVR_REV (svr,1 ,0 ) || -IS_SVR_REV (svr,1 ,1 ) ||IS_SVR_REV (svr,2 ,1 ); +IS_SVR_REV (svr,1 ,1 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );case SVR_P3041 :return IS_SVR_REV (svr,1 ,0 ) || IS_SVR_REV(svr, 1, 1) ||
@@ -63,16 +64,10 @@ bool has_erratum_a006261(void)case SVR_P5021 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 );case SVR_T4240 : -case SVR_T4160 : -case SVR_T4080 :return IS_SVR_REV (svr,1 ,0 ) ||IS_SVR_REV (svr,2 ,0 ); -case SVR_T1040 : -return IS_SVR_REV (svr,1 ,0 ); -case SVR_T2080 : -case SVR_T2081 : -return IS_SVR_REV (svr,1 ,0 );case SVR_P5040 : -return IS_SVR_REV (svr,1 ,0 ); +return IS_SVR_REV (svr,1 ,0 ) || +IS_SVR_REV (svr,2 ,0 ) ||IS_SVR_REV (svr,2 ,1 );#endif }
Signature · 1 line
2.1.0
v3 cover Modifies the erratum A006261 according to endianness
In reply to Sriram DashQuoted 16 lines · Sriram Dash
Modifies erratum A006261 implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Enables the Phy init settings for P1010 Soc.
Also, applies the erratum for P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1 and removes the erratum for T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081.Sriram Dash (3):
mpc85xx: powerpc: usb: Modified the erratum A006261 according to
endianness
mpc85xx: powerpc: usb: Enable Usb phy initialisation settings forP1010 mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum A006261
Quoted 6 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
York, review, please.
Signature · 2 lines
Best regards, Marek Vasut
PATCH v3 1/3 mpc85xx: powerpc: usb: Modified the erratum A006261 according to endianness
In reply to Sriram DashQuoted 18 lines · Sriram Dash
Modifies erratum implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>---
Changes in v3:
- Modify the commit message
- Modify the commit descriptionChanges in v2:
- Adds the errata number to title of patch
- Makes separate patch for addition of errata to specific Socs.arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
<snip>
PATCH v3 2/3 mpc85xx: powerpc: usb: Enable Usb phy initialisation settings for P1010
In reply to Sriram DashQuoted 14 lines · Sriram Dash
CONFIG_SYS_FSL_USB1_PHY_ENABLEis set and the USB Phy offset are set to enable the initial setting of Usb Phy for P1010.Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>---
Changes in v3:
- Modify the commit message
- Modify the commit descriptionarch/powerpc/include/asm/config_mpc85xx.h | 1 + arch/powerpc/include/asm/immap_85xx.h | 2 ++ 2 files changed, 3 insertions(+)
<snip>
PATCH v3 3/3 mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum A006261
In reply to Sriram DashQuoted 22 lines · Sriram Dash
Apply the erratum A006261 for the following Socs:
P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1Do not apply erratum A006261 for the following Socs:
T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081Erratum A006261 is applicable for the following Socs:
P1010(1.0, 2.0),P2041(1.0, 1.1, 2.0, 2.1),P2040(1.0, 1.1, 2.0, 2.1),P3041(1.0, 1.1, 2.0, 2.1),P5010(1.0, 2.0),P5020(1.0, 2.0),P5021(1.0, 2.0),T4240(1.0, 2.0),P5040(1.0,2.0,2.1).Signed-off-by Sriram Dash <[email protected]>Signed-off-by Rajesh Bhagat <[email protected]>---
Changes in v3:
- Modify the commit message
- Modify the commit description
- Make a single patch for all the Socs getting affected by erratum A6261. Also, list the current Socs in description, for which erratum A006261 is applicable.
Quoted 4 lines
arch/powerpc/include/asm/config_mpc85xx.h | 4 +--- drivers/usb/common/fsl-errata.c | 13 ++++--------- 2 files changed, 5 insertions(+), 12 deletions(-)
v3 cover Modifies the erratum A006261 according to endianness
In reply to Marek VasutQuoted 17 lines · Marek Vasut
Quoted 16 lines · Sriram Dash
Modifies erratum A006261 implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Enables the Phy init settings for P1010 Soc.
Also, applies the erratum for P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1 and removes the erratum for T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081.Sriram Dash (3):
mpc85xx: powerpc: usb: Modified the erratum A006261 according to
endianness
mpc85xx: powerpc: usb: Enable Usb phy initialisation settings forP1010 mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum A006261
Quoted 9 lines
Quoted 6 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)York, review, please.
I gave my review comments. They passed compiling for powerpc. Do you want to take them in, or leave them to me?
York
v3 cover Modifies the erratum A006261 according to endianness
Quoted 25 lines · york sun
Quoted 24 lines · Marek Vasut
Quoted 22 lines · Sriram Dash
Modifies erratum A006261 implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Enables the Phy init settings for P1010 Soc.
Also, applies the erratum for P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1 and removes the erratum for T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081.Sriram Dash (3):
mpc85xx: powerpc: usb: Modified the erratum A006261 according to
endianness
mpc85xx: powerpc: usb: Enable Usb phy initialisation settings forP1010 mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum A006261arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
Quoted 5 lines
Quoted 2 lines
York, review, please.
I gave my review comments. They passed compiling for powerpc. Do you want to take them in, or leave them to me?
They're mostly arch code, so feel free to pick them, but for next please.
Signature · 2 lines
Best regards, Marek Vasut
v3 cover Modifies the erratum A006261 according to endianness
In reply to Sriram DashQuoted 16 lines · Sriram Dash
Modifies erratum A006261 implementation due to the fact that P3041, P5020, and P5040 are all big endian for the USB PHY registers, but they were specified little endian.
Enables the Phy init settings for P1010 Soc.
Also, applies the erratum for P2041 rev 2.0, P2040 rev 2.0, P5040 rev 2.0, 2.1 and removes the erratum for T4160, T4080, T1040, T1042, T1020, T1022, T2080, T2081.Sriram Dash (3):
mpc85xx: powerpc: usb: Modified the erratum A006261 according to
endianness
mpc85xx: powerpc: usb: Enable Usb phy initialisation settings forP1010 mpc85xx: powerpc: usb: Update the list of Socs afftected by erratum A006261
Quoted 6 lines
arch/powerpc/cpu/mpc85xx/cpu_init.c | 4 ++-- arch/powerpc/include/asm/config_mpc85xx.h | 5 ++--- arch/powerpc/include/asm/immap_85xx.h | 2 ++ drivers/usb/common/fsl-errata.c | 13 ++++--------- 4 files changed, 10 insertions(+), 14 deletions(-)
Applied to u-boot-85xx master, awaiting upstream. Thanks.
York