Re: SCSI QLA not working on latest *-mm SN2

Jesse Barnes
2004-09-17T23:11:32Z

On Friday, September 17, 2004 3:55 pm, Andrew Vasquez wrote:
> On Thursday, September 16, 2004 4:14 PM, Jeremy Higdon wrote:
> > On Thu, Sep 16, 2004 at 01:56:50PM -0700, Andrew Vasquez wrote:
> > > Interesting, the only changes in reset_chip() are for PCI posting
> > > issues. Relevant diff attached.
> >
> > Are all of those reads really necessary? Generally the only reason
> > for doing a read to flush a posted write is for timing issues (in
> > which the read may not be good enough, according to a thread I saw
> > from Grant Grundler), or to enforce ordering before releasing a lock
> > (sleeping or spinning).
>
> The reads are there to ensure ordering of the writes at each stage of
> the reset (in qla_init.c) and fw dumps (qla_dbg.c). After speaking
> with the hardware and firmware folks, the readw() after the
> soft-reset in qla_init.c was probably what triggered the MCA. Seems
> we will have to settle for some sort of udelay() as what was done in
> reset_chip().

Typically you'll only need the reads right before your code leaves a critical
section that's done writes. If hardware reorders the writes in a single
threaded section, it's likely buggy, and I don't think we should code for
that. IOW, I think a majority of the reads in the patch are superfluous (not
really harmful aside from the one, just slows things down).

> > Have you run into platforms in which two I/O writes from one CPU are
> > retired out of order?
>
> Again, only for completeness.

Please check out the doc I pointed you at to see if it makes sense.

Thanks,
Jesse