diff mbox

[U-Boot,v2,1/2] board: ge: bx50v3: fix AR8033 reset timing issue

Message ID 20170221015656.23555-1-yungching0725@gmail.com
State Accepted
Commit d42db16
Delegated to: Joe Hershberger
Headers show

Commit Message

Ken Lin Feb. 21, 2017, 1:56 a.m. UTC
Add the delay (10ms) to ensure the clock is stable and to meet the clock-to-reset(1ms) requirement recommended in the AR8033 datasheet

Signed-off-by: Ken Lin <yungching0725@gmail.com>
---
Changes from v1
- Fix the missing Signed-off-by issue

 board/ge/bx50v3/bx50v3.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

Comments

Stefano Babic Feb. 21, 2017, 3:30 p.m. UTC | #1
On 21/02/2017 02:56, Ken Lin wrote:
> Add the delay (10ms) to ensure the clock is stable and to meet the clock-to-reset(1ms) requirement recommended in the AR8033 datasheet
> 
> Signed-off-by: Ken Lin <yungching0725@gmail.com>
> ---
> Changes from v1
> - Fix the missing Signed-off-by issue
> 
>  board/ge/bx50v3/bx50v3.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
> 
> diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c
> index 2fc1144cda..80b4ba1b8b 100644
> --- a/board/ge/bx50v3/bx50v3.c
> +++ b/board/ge/bx50v3/bx50v3.c
> @@ -103,8 +103,9 @@ static void setup_iomux_enet(void)
>  
>  	/* Reset AR8033 PHY */
>  	gpio_direction_output(IMX_GPIO_NR(1, 28), 0);
> -	udelay(500);
> +	mdelay(10);
>  	gpio_set_value(IMX_GPIO_NR(1, 28), 1);
> +	mdelay(1);
>  }
>  
>  static iomux_v3_cfg_t const usdhc2_pads[] = {
> 

Reviewed-by: Stefano Babic <sbabic@denx.de>

Best regards,
Stefano Babic
Ian Ray March 21, 2017, 12:58 p.m. UTC | #2
On 21/02/17 17:31, Stefano Babic wrote:
>On 21/02/2017 02:56, Ken Lin wrote:
>> Add the delay (10ms) to ensure the clock is stable and to meet the clock-to-
>reset(1ms) requirement recommended in the AR8033 datasheet
>>
>> Signed-off-by: Ken Lin <yungching0725@gmail.com>
>> ---
>> Changes from v1
>> - Fix the missing Signed-off-by issue
>>
>>  board/ge/bx50v3/bx50v3.c | 3 ++-
>>  1 file changed, 2 insertions(+), 1 deletion(-)
>>
>> diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c
>> index 2fc1144cda..80b4ba1b8b 100644
>> --- a/board/ge/bx50v3/bx50v3.c
>> +++ b/board/ge/bx50v3/bx50v3.c
>> @@ -103,8 +103,9 @@ static void setup_iomux_enet(void)
>>
>>       /* Reset AR8033 PHY */
>>       gpio_direction_output(IMX_GPIO_NR(1, 28), 0);
>> -     udelay(500);
>> +     mdelay(10);
>>       gpio_set_value(IMX_GPIO_NR(1, 28), 1);
>> +     mdelay(1);
>>  }
>>
>>  static iomux_v3_cfg_t const usdhc2_pads[] = {
>>
>
>Reviewed-by: Stefano Babic <sbabic@denx.de>

Acked-by: Ian Ray <ian.ray@ge.com>

...
Joe Hershberger March 27, 2017, 4:51 p.m. UTC | #3
Hi Yung-Ching,

https://patchwork.ozlabs.org/patch/730331/ was applied to u-boot-net.git.

Thanks!
-Joe
diff mbox

Patch

diff --git a/board/ge/bx50v3/bx50v3.c b/board/ge/bx50v3/bx50v3.c
index 2fc1144cda..80b4ba1b8b 100644
--- a/board/ge/bx50v3/bx50v3.c
+++ b/board/ge/bx50v3/bx50v3.c
@@ -103,8 +103,9 @@  static void setup_iomux_enet(void)
 
 	/* Reset AR8033 PHY */
 	gpio_direction_output(IMX_GPIO_NR(1, 28), 0);
-	udelay(500);
+	mdelay(10);
 	gpio_set_value(IMX_GPIO_NR(1, 28), 1);
+	mdelay(1);
 }
 
 static iomux_v3_cfg_t const usdhc2_pads[] = {