Re: [PATCH] lib/xymodem: Decrease read block timeout

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Dec 10, 2018 at 5:27 AM Lucas Stach <l.stach@xxxxxxxxxxxxxx> wrote:
>
> From: Andrey Smirnov <andrew.smirnov@xxxxxxxxx>
>
> When operating at hight baudrates (> 1Mbaud) on a system that perfoms
> several polling tasks, it is often the case that xy_read_block()
> errors out due to the fact that incoming data overran serial FIFO and
> some of the payload got lost. For those kind of situations it is not
> very beneficital to wait for 3 seconds for every block lost this way,
> and decreasing it in order to force a quick NAK to the host is
> beneficial to overall throughput.
>
> This patch changes the timeout to be the bigger of 50ms or 10 times
> the about of time it'd take to transfer a single payload block for a
> given baudrate.
>
> Signed-off-by: Andrey Smirnov <andrew.smirnov@xxxxxxxxx>
> Signed-off-by: Lucas Stach <l.stach@xxxxxxxxxxxxxx>

I don't think this patch is really needed anymore. It was initially
created to alleviate problems there were encountered when doing X/Y
modem transfers on a system with a serdev driver running, but the
final version of the serdev code that landed in the tree allows
polling to be temporarily disabled by setting polling interval to 0:

https://git.pengutronix.de/cgit/barebox/tree/common/serdev.c#n78

IMHO, in light of that, a user would be better off disabling polling,
performing X/Y modem and re-enabling polling back rather than relying
on a faster failed transfer recovery due to this patch.

Thanks,
Andrey Smirnov

_______________________________________________
barebox mailing list
barebox@xxxxxxxxxxxxxxxxxxx
http://lists.infradead.org/mailman/listinfo/barebox



[Index of Archives]     [Linux Embedded]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux