Subject: Re: problems with ahc vs. format command
To: Manuel Bouyer <>
From: Robert Elz <kre@munnari.OZ.AU>
List: tech-kern
Date: 06/12/2001 23:47:29
    Date:        Tue, 12 Jun 2001 18:36:13 +0200
    From:        Manuel Bouyer <>
    Message-ID:  <>

  | The question is whenever the test is really less expansive than the
  | 64bit computation. I think on some platforms it may be more expensive.

Absolutely, it will be.  On some.  That's why ...

  | Anyway scsipi should really provide a macro or inline function for this;
  | I'll look at this some day ...

this is the right way really.  And the macro (or whatever) needs to be MD
not MI, so it can be tailored to whatever works best.

I didn't notice before I sent my first message, but when I looked at your
patches again, I noticed that the ncr driver actually had the test there
already (just outside the function call, instead of inside) and so should
never have had any problems with overflow (unless someone asked for a timeout
bigger than could be represented anyway).    That is, the patches there
would never have achieved anything, and so if Chuck did his test of them on
the ncr controller, it is no surprise that nothing changed.   Some kind
of patch looks like it is needed for the ahc however.