Commit Graph

45 Commits

Author SHA1 Message Date
Rodney W. Grimes
9b2e535452 Remove trailing whitespace. 1995-05-30 08:16:23 +00:00
Peter Dufault
bc0cfeb0ce Add scsi target support. 1995-04-14 15:13:46 +00:00
Garrett Wollman
6c0081e92b Add a class field to devconf and mst drivers.
For those where it was easy, drivers were also fixed to call
dev_attach() during probe rather than attach (in keeping with the
new design articulated in a mail message five months ago).  For
a few that were really easy, correct state tracking was added as well.
The `fd' driver was fixed to correctly fill in the description.
The CPU identify code was fixed to attach a `cpu' device.  The code
was also massively reordered to fill in cpu_model with somethingremotely
resembling what identifycpu() prints out.  A few bytes saved by using
%b to format the features list rather than lots of ifs.
1995-04-12 20:48:13 +00:00
Bruce Evans
3aa12267a5 Add and move declarations to fix all of the warnings from `gcc -Wimplicit'
(except in netccitt, netiso and netns) that I didn't notice when I fixed
"all" such warnings before.
1995-03-28 07:58:53 +00:00
Peter Dufault
8be820d189 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
Peter Dufault
8d38e0afd0 Print out exactly what we think the board is, and for the latest
rev Adaptec boards enable data transfer length detection instead
of assuming requested amount of data is transferred.
1995-01-19 12:33:10 +00:00
Peter Dufault
081964045f Added residual length for 1542C only 1995-01-08 13:41:28 +00:00
Garrett Wollman
2f86936a07 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
Garrett Wollman
f1d8109335 Add support for devconf to a large number of device drivers, and do
the right thing in dev_goawayall() when kdc_goaway is null.
1994-10-19 01:59:11 +00:00
Poul-Henning Kamp
702c623a8a Cosmetics. Silence gcc -Wall. Much more to do here :-( 1994-10-10 01:12:27 +00:00
David Greenman
868424648b Fixed up a couple of comments. 1994-09-21 18:17:56 +00:00
David Greenman
8a129caed5 1) Changed ddb into a option rather than a pseudo-device (use options DDB
in your kernel config now).
2) Added ps ddb function from 1.1.5. Cleaned it up a bit and moved into its
   own file.
3) Added \r handing in db_printf.
4) Added missing memory usage stats to statclock().
5) Added dummy function to pseudo_set so it will be emitted if there
   are no other pseudo declarations.
1994-08-27 16:14:39 +00:00
Paul Richards
d091793974 Ran ft.c through ident.
Added a missing #ifdef INET wrapper in lpt.c

Main change:
	Removed the timeout_func_t casts from timeout calls and
	correctly defined the timeout routines to conform to
	the new format.
lpt.c doesn't have this change.

Reviewed by:
Submitted by:
1994-08-23 07:52:29 +00:00
David Greenman
7b42c960f8 1) cleaned up after Garrett - fixed more redundant declarations, changed
use of timeout_t -> timeout_func_t in aha1542 and aha1742 drivers.
2) fix a bug in the portalfs that was uncovered by better prototyping -
   specifically, the time must be converted from timeval to timespec
   before storing in va_atime.
3) fixed/added some miscellaneous prototypes
1994-08-20 03:49:02 +00:00
Andreas Schulz
a41bb423b1 Reviewed by:
Corrected a little typo in a comment.
Throw out the typedef timeout_t with an ifdef __FreeBSD__, it is already
defined in sys/systm.h .
1994-08-19 21:02:05 +00:00
Poul-Henning Kamp
11a9e878f3 Added {} around two initializers for spare[2] in some structs. This calms
down -Wall a little bit.
1994-08-18 23:36:40 +00:00
Andreas Schulz
5e687d014e Reviewed by:
Added code to check for an adaptec 1542B Version 3.20 Board. This was the
first board that supports >1Gb drives and has the extended bios. So we
need also to disable the exbios like it is done for the 1542C/CF boards.
1994-08-14 21:06:00 +00:00
Garrett Wollman
f540b1065a Change all #includes to follow the current Berkeley style. Some of these
``changes'' are actually not changes at all, but CVS sometimes has trouble
telling the difference.

This also includes support for second-directory compiles.  This is not
quite complete yet, as `config' doesn't yet do the right thing.  You can
still make it work trivially, however, by doing the following:

rm /sys/compile
mkdir /usr/obj/sys/compile
ln -s M-. /sys/compile
cd /sys/i386/conf
config MYKERNEL
cd ../../compile/MYKERNEL
ln -s /sys @
rm machine
ln -s @/i386/include machine
make depend
make
1994-08-13 03:50:34 +00:00
Rodney W. Grimes
26f9a76710 The big 4.4BSD Lite to FreeBSD 2.0.0 (Development) patch.
Reviewed by:	Rodney W. Grimes
Submitted by:	John Dyson and David Greenman
1994-05-25 09:21:21 +00:00
Andreas Schulz
fbfd001f7e Added a missing unit argument in a printf. 1994-05-14 13:12:14 +00:00
Rodney W. Grimes
8568be7ca9 >From BETA_1_1 branch:
----------------------------
revision 1.20.2.2
date: 1994/05/03 05:16:50;  author: rgrimes;  state: Exp;  lines: +39 -16
Do a board reset if the AHA_INQUIRE command fails.  This is needed for the
DTC3290.  Change the messages about the BT545 to be generic to non adaptec
boards, since it appears that most vendors do not implement the AHA_INQUIRE
command in thier compatibility mode.
----------------------------
1994-05-03 05:44:53 +00:00
Garrett Wollman
d139b2ddba Tell the user that we didn't try to set the bus speed, in case they're
used to NetBSD or older versions of the code that did do it.
Will document TUNE_1542 also.
1994-04-21 22:14:43 +00:00
David Greenman
d5e26ef0ef Bounce buffers. From John Dyson with help from me. 1994-03-23 09:16:04 +00:00
Garrett Wollman
9131cc8d54 Delete some references to sleep() that somehow crept in. 1994-03-20 00:30:04 +00:00
Andreas Schulz
3b25168637 Added the missing bzero after the malloc in aha1542.c that seems to
produce the mbox not free messages on many systems. Bug reported from
hd@world.std.com.
1994-03-01 16:06:37 +00:00
Rodney W. Grimes
136cc9d5ef More sane AHA_RESET_TIMEOUT, from some testing by
Todd Pfaff <todd@flex.eng.mcmaster.ca> who was the person to report the
original problem on a 1542C.
1994-01-22 21:54:10 +00:00
Rodney W. Grimes
cdd2062aac >From: julian@TFS.COM (Julian Elischer)
Date: Mon, 17 Jan 94 20:52:14 PST

As reported on the -bugs list by some one, and confirmed by Julian:

> I increased AHA_RESET_TIMEOUT in aha1542.c from 1000 to 10000
> and now my 1542C is found everytime.
1994-01-22 07:46:25 +00:00
Andreas Schulz
253a42c5fc I have a new adaptec 1542CF board bought, that has the board id of 0x45.
Added it to the list of known boards and put it into the the list for
the mailbox unlock. Maybe all board-ids over 0x42 should be in the
mailbox unlock part ?
1994-01-09 18:11:21 +00:00
Garrett Wollman
aaf08d94ca Make everything compile with -Wtraditional. Make it easier to distribute
a binary link-kit.  Make all non-optional options (pagers, procfs) standard,
and update LINT to reflect new symtab requirements.

NB: -Wtraditional will henceforth be forgotten.  This editing pass was
primarily intended to detect any constructions where the old code might
have been relying on traditional C semantics or syntax.  These were all
fixed, and the result of fixing some of them means that -Wall is now a
realistic possibility within a few weeks.
1993-12-19 00:55:01 +00:00
Garrett Wollman
381fe1aaf4 Make the LINT kernel compile with -W -Wreturn-type -Wcomment -Werror, and
add same (sans -Werror) to Makefile for future compilations.
1993-11-25 01:38:01 +00:00
Rodney W. Grimes
57bb0ee45f New version of scsi code from Julian 1993-11-18 05:03:27 +00:00
Garrett Wollman
35089dd415 Fixed comments that start within a comment, so code compiles cleanly with
-Wcomment.
1993-11-17 23:25:28 +00:00
Rodney W. Grimes
ce0dbe6e66 Fix for 1542C support, it turns out that the 0x8 extended bios flag is only
set when extended translation is turned on, thus we need to do the mailbox
unlock command no matter what value is in the extended bios flag byte as
the other extensions (ie, > 2 drive support) cause the same problems.

The code has been changed to ALWAYS unlock the mailbox interface on ALL
1542C class boards.
1993-10-28 02:38:36 +00:00
Rodney W. Grimes
8b80a85bb0 Disable the aha_set_speed code since it breaks more than it fixes. 1993-10-16 12:27:20 +00:00
Rodney W. Grimes
37378adeb5 Add detection code for what model of AHA154X/Z we are running on,
then use that information to fix the enhancemode features of the
1542C/CF boards by turning them off.

When doing this I found that the Buslogic 545S does NOT properly
mimic the 1542 families AHA_INQUIRE command.  It only returns 1
byte of information, when the adaptec manual clearly states that 4
bytes are to be returned.  I added a printf that explains the error
when we see a 545S for now, I tried to come up with a better solution,
but it involved to much work for now.
1993-10-15 09:43:51 +00:00
Rodney W. Grimes
b200ffec79 Increase the DELAY that supposedly makes the Bustek 545 work from
1ms to 10ms.  I have my doubts, but oh well.
1993-10-13 16:34:10 +00:00
Rodney W. Grimes
7a94ec038f Remove erronous definitions of PHYSTOKV, correct one is in param.h now. 1993-10-12 07:15:38 +00:00
Rodney W. Grimes
6526fb8330 Revised drivers from Julian. 1993-08-28 03:07:44 +00:00
Rodney W. Grimes
296cbdb15b Fixed printf's so that they announce them selfs correctly (ie aha%d: before
every error message and every probe message).
1993-08-21 20:01:59 +00:00
Rodney W. Grimes
b6105e6d2a Update scsi code to the latest from Julian. This code is now identical
to the last copy from Julian.  After this commit I will be commiting the
local fixes and makeing diffs to send back to Julian so he can update his
code.

----
>From julian@jules.DIALix.oz.au  Thu Aug  5 09:25:23 1993
To: hd@world.std.com, julian@jules.DIALix.oz.au
Cc: nate@bsd.coe.montana.edu
Subject: Re: new scsi

----
>From julian@jules.DIALix.oz.au  Sat Aug  7 04:13:17 1993
To: hd@world.std.com (HD Associates)
Cc: nate@bsd.coe.montana.edu
Subject: Re: timeout diffs

Here are the diffs to take the scsi stuff to my latest tree from what
Nate and you received..

the changes remove all the local timeout stuff and use (un)timeout(),

----
>From julian@jules.DIALix.oz.au  Sat Aug  7 04:13:45 1993
To: hd@world.std.com (HD Associates)
Cc: nate@bsd.coe.montana.edu, briggs@csugrad.cs.vt.edu

here is a fix for a silly bug in the scsiconf I just sent out
and a similar fix for st.c
1993-08-20 09:21:40 +00:00
Andrew Moore
7aed710168 added Bustek 545 support (patch from Christoph Robitschko):
*** aha1542.c~	Thu Aug 19 14:25:33 1993
--- aha1542.c	Thu Aug 19 14:25:49 1993
***************
*** 954,959 ****
--- 954,960 ----
  	printf("aha%d:",unit);
  #define	PRNT(x) printf(x)
  #endif	__386BSD__
+ 	DELAY(1000);	/* for Bustek 545 */
  	aha_cmd(unit,0, sizeof(conf), 0 ,&conf, AHA_CONF_GET);
  	switch(conf.chan)
  	{
1993-08-19 21:32:59 +00:00
Rodney W. Grimes
2ea3f75bd2 Fixed **probing for scsi devices** message to have a controller and unit
message on the begining of it:
aha0: **probing for scsi devices**
1993-08-06 11:59:06 +00:00
Nate Williams
02e451a8a9 Syncing our sources back with Julian's, and removing PATCHKIT headers.
Large Bustek changes, most everything else is minimal.
1993-07-29 11:55:37 +00:00
David Greenman
2a6c898016 Modified attach printf's so that the output is compatible with the "new"
way of doing things. There still remain several drivers that need to
be updated.  Also added a compile-time option to pccons to switch the
control and caps-lock keys (REVERSE_CAPS_CTRL) - added for my personal
sanity.
1993-07-15 17:53:14 +00:00
Rodney W. Grimes
5b81b6b301 Initial import, 0.1 + pk 0.2.4-B1 1993-06-12 14:58:17 +00:00