Xref: utzoo comp.unix.aix:727 comp.periphs.scsi:158 Path: utzoo!attcan!uunet!zds-ux!bjstaff From: bjstaff@zds-ux.UUCP (Brad Staff) Newsgroups: comp.unix.aix,comp.periphs.scsi Subject: Re: SCSI hiding geometry Summary: What's all the fuss about? Message-ID: <219@zds-ux.UUCP> Date: 14 Mar 90 14:33:39 GMT References: <1660@aber-cs.UUCP> <51507@sgi.sgi.com> <132788@sun.Eng.Sun.COM> <1990Mar12.194630.28869@Solbourne.COM> Followup-To: poster Organization: Zenith Data Systems Lines: 22 What critical item did I miss in the discussion about SCSI-2 devices sorting their work lists? As near as I can tell, disk drivers (System V/386 3.2 at least) do this all the time. In fact, the System V kernel provides a routine, disksort(), for this very purpose! After looking around in os/bio.c, I found three routines the kernel uses for writing buffers to disk: bwrite(), bdwrite(), and bawrite(). bwrite() initiates the write by calling strategy() on the buffer, and then waits for the write to complete by calling iowait() on the buffer. bdwrite() sets the B_DELWRI and B_DONE flags in the buffer and then releases it. It will be written out at some later time. bawrite() initiates the write by calling strategy() on the buffer, but doesn't wait for the write to complete. When the System V kernel really cares about the order of writes, it uses bwrite(). Otherwise, it might use bdwrite() or bawrite(). I don't see any problem here. -- Brad Staff | Zenith Data Systems | "A government that can forbid certain 616-982-5791 | psychoactive drugs can mandate others." ...!uunet!zds-ux!bjstaff | - Russell Turpin