[Info-vax] yet another sys$qiow question

Johnny Billquist bqt at softjar.se
Fri Aug 21 10:44:58 EDT 2015


On 2015-08-21 16:18, Craig A. Berry wrote:
> On 8/21/15 8:41 AM, Johnny Billquist wrote:
>
>> What is wrong with checking the IOSB before the I/O completes? There is
>> absolutely nothing wrong with that. And if it is non-zero, it means the
>> I/O already have completed, so there is no point in waiting, since it
>> will return immediately.
>
> Until the I/O completes, the status of the IOSB is undefined. Show me
> where there is a guarantee that if one longword of the IOSB has been
> written, that the other longword has also been written, i.e., that the
> entire IOSB is written atomically or in a single instruction. Without
> that guarantee, non-zero does not mean complete.

Until the I/O completes, I believe the IOSB is defined to have 0. That 
is documented as one of the things the OS does as a part of initiating 
the I/O. Of course, you should first of all check that the QIO was 
accepted at all, by checking R0, but once that indicates success, IOSB 
will be zero until the I/O operation completes.

Now you are asking about the consistency between the two longwords as 
such. That is a different story, which we can also discuss, if you want. 
But it is not relevant here. When the first longword of the IOSB is 
non-zero, you *know* that the I/O have completed. That is a defined and 
documented fact.

	Johnny




More information about the Info-vax mailing list