home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / periphs / scsi / 5487 < prev    next >
Encoding:
Internet Message Format  |  1992-11-17  |  2.9 KB

  1. Xref: sparky comp.periphs.scsi:5487 comp.unix.bsd:8951
  2. Newsgroups: comp.periphs.scsi,comp.unix.bsd
  3. Path: sparky!uunet!stanford.edu!ames!pasteur!cory.Berkeley.EDU!sim
  4. From: sim@cory.Berkeley.EDU (Peng-Toh Sim)
  5. Subject: Re: Buslogic SCSI controllers
  6. Message-ID: <1992Nov16.204938.11966@pasteur.Berkeley.EDU>
  7. Keywords: scsi,Adaptec,1542B,wahtever,customer , service,support
  8. Sender: nntp@pasteur.Berkeley.EDU (NNTP Poster)
  9. Nntp-Posting-Host: cory.berkeley.edu
  10. Organization: University of California, at Berkeley
  11. References: <BxK6o8.16o@brunel.ac.uk> <1992Nov12.155817.15875@gumby.dsd.trw.com> <Bxrw7o.K4n@csi.compuserve.com>
  12. Distribution: usa
  13. Date: Mon, 16 Nov 1992 20:49:38 GMT
  14. Lines: 46
  15.  
  16. Hi
  17.  
  18. I'm using a BusTek 542B (don't know the new name for this) under
  19. 386BSD using the default 1542B device driver that comes with
  20. 386BSD.  Is this board supposed to be a total AHA 1542B clone?
  21. Well, I'm programming this thing using a AHA 1542B technical reference.
  22. According to the manual, a CCB command 04H is a Scatter/Gather with
  23. residual data length returned.  The Data Length should contain the
  24. number of bytes in the Data Segment list (which is NOT equal to
  25. the actual number of bytes of for the operation requested.)
  26. Suppose I have a file on tape of length 512 (tape block size
  27. on Archive Viper 2150S), and I request a read of 8192 bytes
  28. using read() from a user program.  This becomes a 04H operation
  29. with two segments of 4096 bytes (memory pages) and the Data Length
  30. is 12.  According to the manual, the opeation should succeed and
  31. set the Data length to the "difference between the original Data Length
  32. ...and the actual number of bytes transferred across the SCSI bus...For
  33. Operation Code 04H, the original Data Length is the sum of all
  34. segment Data Lengths" (residual data length).
  35. In this case, the sum of segment Data
  36. lengths is 8192, so 8192-512 should be put into the Data Length
  37. field of the CCB.  BUT, instead, I get a value of 12, ie.
  38. which means it does not look at the data lengths in the segments.
  39. This "12" means both segments "failed" and read no data.
  40. If the file on the tape was 4096 bytes instead, the
  41. a residue length data of 6 is returned, saying the first segment
  42. is succeeded but the second failed.
  43. This is clearly NOT what the manual says (I know, wrong manual :)
  44. Furthermore, if a read of 512 bytes of done after this, it will
  45. still not pick up the remaining 512 bytes because the tape
  46. drive thinks the data is already read.  So there is no
  47. workaround and it makes the Scatter/Gather operation useless for tape
  48. drives because you always lose the end unless you use segments
  49. of exactly tape block size lengths.
  50. So, who screwed up?  BusLogic?  Or did *their* manual specify
  51. the latter operation which is incompatible with the AHA 1542B?
  52. If so, it is not so compatible after all.  In any case, I think
  53. this is a bug.  Or does the AHA1542B work the same way?
  54.  
  55. Many people have programmed these boards before, so what
  56. do you think?
  57. Thanks.
  58.  
  59. PT
  60. sim@cory.berkeley.edu
  61.  
  62.