[U-Boot] [PATCH] mmc/dwmmc: remove recursive FIFO threshold setup

Alexey Brodkin Alexey.Brodkin at synopsys.com
Wed Nov 27 13:30:13 CET 2013


Hi Pantelis,

Indeed this is bogus. What is the reset value of the fifoth register?
> Below is a description for the register in question with default
values specified.
----------------------------------------------
FIFO Threshold Watermark Register
----------------------------------------------
x - reserved
 000 - Burst size of multiple transaction
    yyyyyyyyyyy - Rx watermark = (FIFO_DEPTH - 1)
               xxxx - reserved
                   000000000000 - Tx watermark
----------------------------------------------

Also databook says:
----------------------------------------------
During end of packet, request is generated regardless of threshold
programming in order to complete any remaining data.
----------------------------------------------
So it's safe to leave watermark = 0.

Instead of reading the register, and doing the weird calculations, just
> use the reset value of the register as if out of power on reset. 
> 
In other words both Rx and Tx watermarks should be sane for usage as
they are on power-on.

> So why we need this functionality (unclear reconfiguration) if default
> > register value works flawlessly in majority of cases and for some
corner
> > cases users may specify their custom value that will simply override
> > default value.
> > 
> 
> Beats me. Let's fix this properly.
> 
So I'll submit v2 shortly.

-Alexey


More information about the U-Boot mailing list