[PATCH 1/2] imx6-mmdc: Work around ERR050070

John Watts contact at jookia.org
Tue Jan 24 03:48:09 PST 2023


On Tue, Jan 24, 2023 at 09:27:42AM +0100, Ahmad Fatoum wrote:
> > +static bool wlcalib_failed(void __iomem *ips)
> > +{
> > +	int i;
> > +
> > +	for (i = 0; i < 4; ++i) {
> > +		if (readb(P0_IPS + MPWLHWERR + i) == 0)
> 
> s/P0_OPS/ips/ ?

Oops, good catch! Will fix in V2.

> 
> Also does it need to be bytewise reads? If not, you could rewrite
> as return readl(ips + MPWLHWERR) == 0;

The MPWHLHWERR register contains 4 bytes giving some status for each lane,
that would only fail if all lanes fail which is different behaviour to
the existing behaviour fails if any lanes fail at calibrating.

> 
> > +			return true;
> 
> Write level calibration has failed when MPWLHWERR == 0 and succeeded
> when there is some other value? That sounds odd.

It is odd, but that's what the data sheet says, the errata says and what
and what seem. Maybe I should note it down?



More information about the barebox mailing list