Re: [PATCH 2/2] imx6-mmdc: Revert calibration configuration on failure

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

 



On Tue, Jan 24, 2023 at 09:29:02AM +0100, Ahmad Fatoum wrote:
> >  int mmdc_do_write_level_calibration(void)
> >  {
> > +	u32 ldectrl[4] = {0};
> 
> Initial value never read back.
> 

Remove the = {0}?

> >  	/* check for any errors on both PHYs */
> > -	if (wlcalib_failed(P0_IPS) || wlcalib_failed(P1_IPS))
> > +	if (wlcalib_failed(P0_IPS) || wlcalib_failed(P1_IPS)) {
> > +		pr_debug("Calibration failed, rolling back calibration data\n");
> 
> Still you only restore P0 calibration data, even if it succeeded,
> but P1 failed. Is this intended?

Not quite sure what you mean. I restore both P0 and P1 calibration data I
think?

If you're asking whether it is correct behaviour to REVERT all calibration
data, instead of for each channel, I'm not sure. It seems like the safest
thing to do to me since it's unclear why the calibration process has failed.

This is the behaviour U-Boot does and seems to work in the wild.

John.




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

  Powered by Linux