Commit Graph

46 Commits

Author SHA1 Message Date
Paul Saab
817805d9c9 Fix a signed bug in the crashdump code for systems with > 2GB of ram.
Reviewed by:	peter
2001-11-13 01:08:54 +00:00
John Baldwin
282873e2c0 - Change the taskqueue locking to protect the necessary parts of a task
while it is on a queue with the queue lock and remove the per-task locks.
- Remove TASK_DESTROY now that it is no longer needed.
- Go back to inlining TASK_INIT now that it is short again.

Inspired by:	dfr
2001-10-26 18:46:48 +00:00
John Baldwin
1de1c550b1 Add locking to taskqueues. There is one mutex per task, one mutex per
queue, and a mutex to protect the global list of taskqueues.  The only
visible change is that a TASK_DESTROY() macro has been added to mirror
the TASK_INIT() macro to destroy a task before it is free'd.

Submitted by:	Andrew Reiter <awr@watson.org>
2001-10-26 06:32:21 +00:00
Julian Elischer
b40ce4165d KSE Milestone 2
Note ALL MODULES MUST BE RECOMPILED
make the kernel aware that there are smaller units of scheduling than the
process. (but only allow one thread per process at this time).
This is functionally equivalent to teh previousl -current except
that there is a thread associated with each process.

Sorry john! (your next MFC will be a doosie!)

Reviewed by: peter@freebsd.org, dillon@freebsd.org

X-MFC after:    ha ha ha ha
2001-09-12 08:38:13 +00:00
Scott Long
5e7e7ec92b Don't use a silly test to define INTR_ENTROPY.
Submitted by:	peter
2001-09-06 08:57:51 +00:00
Scott Long
914da7d0d3 Bring the aac driver *much* closer to style(9).
Reviewed by:	ken
2001-09-05 20:43:02 +00:00
Scott Long
f8185d5456 Sigh. There are actually two ioctls ranges that need to be watched on the
linux side.  This will all be over soon...
2001-09-03 07:50:14 +00:00
Scott Long
61fea38293 Work around a bug where the driver's copy of the disklabel gets corrupted
and causes diskerr() to panic.
2001-09-02 23:16:40 +00:00
Scott Long
3361abb7a7 Restrict the range of linux ioctls we will accept. 2001-09-02 23:15:26 +00:00
Scott Long
6965a4937d Doh! Fix a comma that disappeared along the way.
Pointy-hat by:	peter
2001-08-30 13:09:09 +00:00
Scott Long
36e0bf6e9c Mega update to the aac driver.
1.  Correctly handle commands initiated by the adapter.  These commands
    are defered to a kthread responsible for their processing, then are
    properly returned to the controller.
2.  Add/remove disk devices when notified by the card that a container was
    created/deleted/offline.
3.  Implement crashdump functionality.
4.  Support all ioctls needed for the management CLI to work.  The linux
    version of this app can be found at the Dell or HP website.  A native
    version will be forthcoming.

MFC-after:	4.4-RELEASE
2001-08-29 23:34:05 +00:00
Scott Long
33a375b754 Clarify the description string for one of the StrongARM based cards. 2001-08-17 20:59:49 +00:00
Scott Long
1a393b6188 Adding missing () in a KASSERT format string.
Submitted by:	brandt@fokus.gmd.de
2001-08-07 16:48:28 +00:00
Scott Long
d047ecf50b Make AAC_COMPAT_LINUX optional once again.
Submitted by:	julian
2001-08-06 19:40:47 +00:00
Scott Long
fb0c27d7e2 Put the linux compat ioctl interface on death row. Add FreeBSD
definitions of all of the ioctls, plus round out all ioctl definitions to
match what exists for linux.  Allow ioctls to be called through either the
native or linux interface, though no apps exist (yet) that can take
advantage of native calling.
2001-08-06 04:34:47 +00:00
Scott Long
74e818733c Missed this one in my 80-column sweep. 2001-08-06 03:52:40 +00:00
Scott Long
3d04a9d7e3 Once again throw out the calculation of si_iosize_max and set it to 64K.
Although it can go higher, it is not safe to so do on arrays with many
members.  Compromise by adding a tunable, "hw.aac.iosize_max" that can be
set at boottime.  Also document in the aac(4) manpage.

MFC after:	4 weeks
2001-08-05 07:26:31 +00:00
Scott Long
f6c4dd3f48 Bugfixes. Close a race and logic bug in the timeout handling, don't call the
interrupt handler from the upper half, etc.  This fixes some serious stability
problems that we were seeing on our production server.  These patches have
been tested for almost 6 months and are a highly recommended MFC candidate.

Reviewed by:	gibbs, merry, msmith
MFC after:	4 days
2001-08-05 06:20:13 +00:00
Scott Long
fadfef893f Fix a couple of copyright issues and an 80 column nit that I missed before 2001-08-05 06:15:00 +00:00
Scott Long
c6eafcf2c5 Reformat for 80 columns. Sorry, but I had to do it. 2001-08-03 00:50:30 +00:00
Scott Long
4aa620cdc6 Add /dev/hpn? as an alias to /dev/aac? so that the HP version of the CLI
utility will work, and document it in the manpage.

MFC after:	3 days
2001-07-25 22:36:17 +00:00
Mike Smith
0bc88fe1eb Add another Dell 3/Di PCI ID. You'd think they had enough of these
already...
2001-07-22 04:06:36 +00:00
Poul-Henning Kamp
079f2df393 Make the disk mini-layer check for and handle zero-length transfers
instead of the underlying drivers.
2001-05-06 21:55:22 +00:00
Mike Smith
ed1c82f450 More new Dell PCI IDs.
Submitted by:	"Marty Moll" <martym@arbor.edu>
2001-04-26 01:14:37 +00:00
Mike Smith
71665b0add The PERC 3/Di in the Dell PowerEdge 2250 has a new subdevice ID.
Submitted by:	Chris Csanady <cc@ameslab.gov>
2001-04-26 00:32:02 +00:00
Poul-Henning Kamp
f83880518b Send the remains (such as I have located) of "block major numbers" to
the bit-bucket.
2001-03-26 12:41:29 +00:00
Scott Long
157fbb2e83 Create /dev/afaN as a symlink to /dev/aacN. This allows the CLI tools from
Dell and HP to run.

Reviewed by:	msmith
2001-03-22 21:04:22 +00:00
Scott Long
d5fd2abf4f Back out rev 1.4. The advertised 64K limit on transfers only applies when
using 64bit S/G entries.  With this reverted, we are seeing >92MB/sec reads
and >42MB/sec writes on a RAID-5 container.
2001-03-21 21:53:09 +00:00
Justin T. Gibbs
da4c1ce305 This is an MFC candidate.
Add the AAC_DEBUG option to enable debugging in the aac driver.

Correct a race condition in the interrupt handler where the
controller may queue a fib to a response queue after the driver
has serviced the queue but before the interrupt is cleared.
This could leave a completed fib stranded in the response queue
unless another I/O completed and generated another interrupt.

Reviewed by:	msmith
2001-03-17 00:12:15 +00:00
Mike Smith
eeba0d1008 Fix a typo which would cause containers between 1GB and 2GB to have the wrong
geometry reported.

Submitted by:	mark tinguely <tinguely@web.cs.ndsu.NoDak.edu>
2001-03-16 21:43:32 +00:00
Scott Long
8ae73164ab Set si_iosize_max to 64K, even though the adapter seems to be able to do more.
This puts us safely in line with Adaptec documentation and shouldn't really
affect anything.

MFC candidate for 4.3
2001-03-07 08:37:49 +00:00
Mark Murray
ed34d0ade2 Turn on interrupt-entropy harvesting for all/any mass storage devices
I could find. I have no doubt missed a couple.

Interrupt entropy harvesting is still conditional on the
kern.random.sys.harvest_interrupt sysctl.
2001-03-01 17:09:09 +00:00
John Baldwin
65baa27ce6 Kill a warning by marking an unused function with __unused. 2001-01-23 21:43:47 +00:00
Mike Smith
ed5c5fb423 Remove a mismatched splbio() in aac_start (the called functions each protect
themselves correctly).

Submitted by:	ps
2001-01-10 11:43:02 +00:00
Mike Smith
0b94a66e3f Major bugfix and minor update. This should resolve the current issues
with the driver locking up under load.

 - Restructure so that we use a static pool of commands/FIBs, rather than
   allocating them in clusters.  The cluster allocation just made things
   more complicated, and allowed us to waste more memory in peak load
   situations.
 - Make queueing macros more like my other drivers.  This adds queue stats
   for free.  Add some debugging to take advantage of this.
 - Reimplement the periodic timeout scan.  Kick the interrupt handler
   and the start routine every scan as well, just to be safe.  Track busy
   commands properly.
 - Bring resource cleanup into line with resource allocation.  We should
   now clean up correctly after a failed probe/unload/etc.
 - Try to start new commands when old ones are completed.  We weren't doing
   this before, which could lead to deadlock when the controller was full.
 - Don't try to build a new command if we have found a deferred command.
   This could cause us to lose the deferred command.
 - Use diskerr() to report I/O errors.
 - Don't bail if the AdapterInfo structure is the wrong size.  Some variation
   seems to be normal.  We need to improve our handing of 2.x firmware sets.
 - Improve some comments in an attempt to try to make things clearer.
 - Restructure to avoid some warnings.
2000-12-27 13:14:56 +00:00
Scott Long
affec73ebd Disable calling timeout() when doing bio. It was causing more prolems than
solving.  This will be fixed for real soon.
2000-11-19 23:46:21 +00:00
David Malone
ca89ee278e Further use of M_ZERO.
Submitted by:	josh@zipperup.org
Submitted by:	Robert Drehmel <robd@gmx.net>
Approved by:	msmith
2000-11-18 15:21:22 +00:00
Mike Smith
e10f2ee576 Return -10 from the PCI probe to allow room for an updated driver to
override one built into the kernel.
2000-10-28 10:46:30 +00:00
Poul-Henning Kamp
46aa3347cb Convert all users of fldoff() to offsetof(). fldoff() is bad
because it only takes a struct tag which makes it impossible to
use unions, typedefs etc.

Define __offsetof() in <machine/ansi.h>

Define offsetof() in terms of __offsetof() in <stddef.h> and <sys/types.h>

Remove myriad of local offsetof() definitions.

Remove includes of <stddef.h> in kernel code.

NB: Kernelcode should *never* include from /usr/include !

Make <sys/queue.h> include <machine/ansi.h> to avoid polluting the API.

Deprecate <struct.h> with a warning.  The warning turns into an error on
01-12-2000 and the file gets removed entirely on 01-01-2001.

Paritials reviews by:   various.
Significant brucifications by:  bde
2000-10-27 11:45:49 +00:00
Scott Long
f38211c796 First attempt at timeouts for bio commands sent to the controller. No retry is
attempted right now; the failure is merely passed up.  This may help with the
mysterious lockups seen by some with Pablano controllers.
2000-10-22 09:21:19 +00:00
Poul-Henning Kamp
db7e3af111 Remove unneeded #include <machine/clock.h> 2000-10-15 14:19:01 +00:00
Mike Smith
84ad14e4a6 Fix up some more comments that were reversed.
Submitted by:	Niklas Hallqvist <niklas@appli.se>
2000-10-03 10:26:29 +00:00
Mike Smith
0791663f57 Fix reversed comments re: OISR/OIMR
Submitted by:	Niklas Hallqvist <niklas@appli.se>
2000-10-03 08:28:04 +00:00
Scott Long
bb9f4664e2 Fix compiling with AAC_DEBUG. 2000-09-30 13:41:04 +00:00
Mike Smith
30d57611e8 Include <sys/proc.h> so that we can dereference something in the proc
structure.  Looks like someone removed a nested include somewhere else.

Submitted by:	gallatin, dg
2000-09-19 00:35:03 +00:00
Mike Smith
358637397e A new driver for PCI:SCSI RAID controllers based on the Adaptec FSA
design.  This includes integrated Dell RAID controllers, the Dell
PERC 2/QC and the HP NetRAID-4M.
2000-09-13 03:20:35 +00:00