Commit Graph

100 Commits

Author SHA1 Message Date
gibbs
bb4314a0bc Add a define for the SCSI_QUEUE_FULL sense message 1995-02-22 01:44:21 +00:00
dg
905f17b4ab >From a week or two ago I got kernel panics as soon as I tried to access my
tape drive. I traced it to sys/scsi/scsi_base.c where some code were added
to print the return values of the sense command. My tape drive returned a
extended flags value of 0x20, so the key that is the lower 4 bits, is 0.
The code uses "key-1" to index into a table and then the kernel go to never-
never land.

Here is a fix for this. Will somebody please apply it?

Submitted by:	John Hay
1995-02-15 07:44:07 +00:00
phk
deaea2f54f YFfix. 1995-02-14 06:28:25 +00:00
phk
9221afecab YFfix. added
errval scsi_probe_busses __P(( int, int, int));
1995-02-14 06:17:23 +00:00
dufault
56d5749916 Split byte packing functions into signed and unsigned versions.
Left most current invocations as signed, though that could be wrong.
1995-01-31 11:41:47 +00:00
dufault
b94160430b 1. Reject obviously broken CDB command lengths
2. Use "uprintf" (instead of printf) to log the "tape not ready" message
1995-01-24 12:04:56 +00:00
ats
55a0d19bda Add the missing forward declaration of chopen. Reported in the
mailinglists some time ago.
1995-01-19 21:02:54 +00:00
dufault
e91ce4826b Remove dup biodone and no more SCSIUSER option. 1995-01-19 12:41:36 +00:00
dufault
25f76dccb4 Ensured all files have copyright and RCS ID variable. 1995-01-08 15:56:10 +00:00
ats
267b61143a Submitted by: Gerd Truschinski
Removed one semicolon, two are one to much :-). Found by the hc860 compiler
and Gerd Truschinski 8-).
1995-01-08 15:13:40 +00:00
dufault
f9dfd17603 Reviewed by: gibbs@estienne.CS.Berkeley.EDU
Reenabled "SCIOCOMAND" ioctl.
Restructured so low level drivers can easily request retries.
Added preliminary fixed SCSI devices (should be revisited before 2.1)
Added "ssc" device that can have its' (HBA, ID, LUN) set via ioctl.
1995-01-08 13:38:38 +00:00
bde
a46c3ece75 Fix the "wds" count stat. 1994-12-24 09:48:32 +00:00
bde
1fc0e7a59d Really fix the "byte" count stat. `wd's are actually blocks of 32 16-bit
words in dkstat-speak.  `ms's are seconds in dkstat-speak...
1994-12-24 09:19:00 +00:00
dg
2503434475 Revert last patch - it's wrong. 1994-12-23 23:03:32 +00:00
dg
4a0d37658b Fixed byte count stat.
Submitted by:	John Dyson
1994-12-23 22:44:55 +00:00
se
c3df81a4e0 Added SCSI_DATA_OUT to flags passed to the device driver in sd_dump()
since device drivers may decide not to accept a data out phase without
this flag present.
Submitted by:	Wolfgang Stanglmeier <wolf@dentaro.GUN.de>
1994-12-22 21:18:48 +00:00
phk
c2444f9b9b Make sure we allocate at least 8 scbus if we allocate any at all. 1994-12-18 18:48:39 +00:00
phk
66ae467761 Allocate all scsi-devices on the fly, not just CDs.
Reviewed by:	phk
Submitted by:	rgrimes
1994-12-16 06:03:28 +00:00
phk
ffd4888d41 added a missing '\n' in both files. 1994-12-03 22:52:57 +00:00
ats
04c6edcf64 Include "scbus.h" in scsiconfig.c to get the number NSCBUS from the
config file.
1994-11-27 23:30:48 +00:00
ats
63277aa442 Submitted by: Lawrence J. King ljking@ljk.OCUnix.On.Ca
Check the firmware revision for non-printing characters and replace them
question-marks if necessary. Problem is known with old Seagate ST296N
drives.
1994-11-17 23:22:22 +00:00
bde
7e9b352a5b Remove bogus and unused declaration and definition of Debugger(). 1994-11-15 14:49:56 +00:00
bde
2ea8e09a70 Remove unused definition of Debugger(). 1994-11-15 14:49:12 +00:00
bde
4cec7e4962 Remove bogus declaration of Debugger(). Change the macro for Debugger()
to call the function instead of doing nothing.
1994-11-15 14:47:49 +00:00
ats
f65593a86e scsiconf.h:
Change the sc_link structure from 8 targets with 8 lun's to
16 targets with 8 lun's. Wide scsi and the ncr 825 does support 16 targets.
scsiconf.c:
move the addition of the trailing NUL's out of a then clause, they are also
needed in the else clause for an unknown device.
1994-11-14 23:39:33 +00:00
ats
39cf57d59f Delete a bogus check that the SCSI_DELAY only works for the first
scsi adapter. Let it work on every adapter. Someone want to rewrite
this to be coupled with the adapter specification in the config file,
so that you can say which adapters need it ?
1994-11-12 17:13:23 +00:00
joerg
6286d596ef Avoid a division by zero if the actual sector size isn't known during the
device announcement; assume a sector size of 512 instead (likely to be
right at all).
This case happens when booting with a removable disk device attached
(e.g. an MOD), but no medium inserted.
1994-11-07 20:09:35 +00:00
joerg
4f1ef0fb5b |Both, the wd and the sd driver do not reject invalid request of odd
|sizes. They simply pass them to the disks, which usually causes
|fatal errors then.
1994-11-03 18:20:15 +00:00
phk
d729b2d813 Changed RAW_PART to RAWPART so it comes from disklabel.h.
Force RAW_PART to have the right size.
Set d_secperunit in the disklabel.
1994-10-31 23:45:40 +00:00
jkh
e0e2fa7134 Andreas Klemm's tape erase patches from 1.1.5.1
Submitted by:	andreas
1994-10-28 13:19:42 +00:00
jkh
7fc8f11c36 Julian Elischer's disklabel fixes. 1994-10-27 20:45:13 +00:00
wollman
b26d43dd93 Finished device configuration database work for all ISA devices (except `ze')
and all SCSI devices (except that it's not done quite the way I want).  New
information added includes:

-	A text description of the device
-	A ``state''---unknown, unconfigured, idle, or busy
-	A generic parent device (with support in the m.i. code)
-	An interrupt mask type field (which will hopefully go away) so that
.	  ``doconfig'' can be written

This requires a new version of the `lsdev' program as well (next commit).
1994-10-23 21:28:03 +00:00
wollman
8cdc5796fa Make my ALLDEVS kernel compile (basically, LINT minus a lot of options).
This involves fixing a few things I broke last time.
1994-10-21 01:19:28 +00:00
phk
60dba59038 Peter Dufaults comconsole changes.
Submitted by:	Peter Dufault
1994-10-20 00:08:31 +00:00
wollman
8baea41c30 Implement scsi_externalize(), again. (This was supposed to be committed in the
last batch of changes but somehow got lost in the shuffle.)
1994-10-19 20:34:15 +00:00
wollman
77069411f4 Define SCSI_EXTERNALLEN outside of #ifdef KERNEL, for lsdev. 1994-10-19 01:49:23 +00:00
wollman
95b9f4b030 Forgot to bring this file over from previous commit. 1994-10-19 01:20:44 +00:00
wollman
0195465203 all: register devices
cd.c sd.c: implement disk stats
1994-10-19 00:09:47 +00:00
phk
b56768ef73 Removed unused vars. Silenced gcc -Wall. Some of this stuff is virtually
type-less.  Everything is "u_int32" :-(
1994-10-08 22:26:40 +00:00
rgrimes
d655715898 In sd_get_params() the timeout for the MODE_SENSE command was too
short. I changed it from 2000 to 4000 and now my disk works fine.

Submitted by:	John Hay <jhay@mikom.csir.co.za>
1994-10-04 06:45:57 +00:00
rgrimes
bb4a6b1e84 Pull in 1.1.5.1 changes to sd.c from 1.23 to 1.27 (basically the fixes for
drives that return sector counts of 0 and cause division by 0 traps during
the probe).
Reviewed by:	Dave <root@hclb.demon.co.uk>
Obtained from:	FreeBSD 1.1.5.1
1994-10-04 06:39:27 +00:00
phk
d338130948 GCC cleanup.
Reviewed by:
Submitted by:
Obtained from:
1994-10-02 17:48:58 +00:00
se
ac04509563 Reviewed by: Julian Elischer / Jordan K. Hubbard
Changes are only effective, if NEW_SCSICONF is defined:

1) Added u_int16 quirks to struct scsi_link for device quirks.
2) Added void *devmodes to struct scsi_link for tape density modes.
3) Modified selectdev() to return first full match (with wildcard).

With this patch all device dependent configuration is done in one place
(scsiconf.c), while there were some specifications in st.c and some
hardware dependent drivers (ie. ncr.c) before.
1994-09-28 20:16:45 +00:00
se
1d53296b21 Changed CDOUTSTANDING back to a value of 2 (from 1), since this is now only
an upper limit, not a fixed value (ignoring the host adapter capabilities)
as before.
1994-09-16 23:43:28 +00:00
dg
c3ac4714bb Removed all vestiges of tlbflush(). Replaced them with calls to pmap_update().
Made pmap_update an inline assembly function.
1994-09-02 04:12:26 +00:00
se
3ef672a4d3 Reviewed by: Stefan Esser <se>
Calculation of 'cd->cmdscount' now as in 'sd.c' (required for ncr scsi).
CDOUTSTANDING defined as '1' (as the comment says), was '2' in fact ...
Debugger takes an (char*) argument, changed macro definition accordingly.
1994-08-31 22:50:08 +00:00
dg
4c605482d3 Rather than exclude bounce buffers support with NOBOUNCE, include it
with BOUNCE_BUFFERS. This is more intuitive, and is better for future
multiplatform support. Added BOUNCE_BUFFERS option to the GENERIC and
LINT kernel config files.
1994-08-31 06:17:49 +00:00
ache
551e28a51f Change RAW_PART back to 3, too early step right now, disklabels need more
work
Change hardcoded 3 value in several places to RAW_PART define
1994-08-30 14:31:38 +00:00
jkh
0fa5417289 Make decl/define for Debugger() match reality.
Submitted by:	jkh
1994-08-30 00:12:11 +00:00
ache
4d05b12da0 RAW_PART=2 1994-08-29 21:37:49 +00:00