lkml.org 
[lkml]   [2014]   [Jun]   [2]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH] stmmac: add DMA initialization delay to device tree
From
From: Alexey Brodkin <Alexey.Brodkin@synopsys.com>
Date: Mon, 2 Jun 2014 19:14:09 +0000

> I understand that putting everything in DT is not a way to go.
> But a rationale for this particular patch is as follows: as I may see up
> until now everybody was happy with 100 milliseconds, but on my
> particular board connected to Gbit network I see that more than a second
> is required for DMA to initialize. If I connect the same board to 100
> Mbit network then initialization delay could be up to 2.5 seconds.
>
> So I may definitely bump the delay to say 3 seconds, but what if another
> user needs even more?
>
> On the other hand those who are happy now with 100 msec delay may be be
> disappointed in case of failure and frozen for N seconds board waiting
> for timeout.
>
> If you think that delay for a few seconds in case of initialization
> failure is acceptable then I will submit a patch that increases delay to
> 3 seconds (personally I haven't seen longer init times).

Stop right there.

We are doing synchronous delays here, without sleeping, and if that takes
seconds it is totally unacceptable.

You'll first have to convert this code to use msleep() or similar.

Second, if the chip hangs nobody cares if there is a 3 second pause, it's
error recovery.



\
 
 \ /
  Last update: 2014-06-03 00:21    [W:0.052 / U:0.320 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site