cgd
3a7bbb1acd
lip service to making ISA support machine-independent. This is the first
...
round: moving the drivers into a machine-independent directory.
Some drivers (e.g. fd.c) not moved because they use other pc features (e.g.
CMOS settings), and none of the non-driver files moved, because they're
still pretty much PC specific. eventually (when other ports with ISA
busses really start using this code), more 'high-level' ISA support will
live here.
1995-01-29 07:36:54 +00:00
mycroft
1e5cd9212d
(Almost) allow sector sizes other than 512 bytes. Reduce some expensive operations.
1995-01-13 12:30:59 +00:00
mycroft
7650bd97fc
Always boundary check I/O.
1995-01-13 10:46:32 +00:00
mycroft
0033c975c6
Fix another bug in the DMA code.
1995-01-13 10:22:58 +00:00
mycroft
4abdb375bc
Minor rearrangement.
1995-01-13 09:40:21 +00:00
mycroft
c2bc310a37
Change the way sc_skip is used. Fix a bug in the (incomplete) DMA code. Add a
...
new sc_blkno (which will be useful later).
1995-01-13 08:58:16 +00:00
mycroft
d4f91d51a9
Fix a race condition between normal I/O and wd_get_parms().
1995-01-07 03:07:22 +00:00
mycroft
b5cf1b5ddd
Add interrupt sharing types.
1995-01-03 01:30:14 +00:00
mycroft
ca65f2ce5d
Remove dkbad.h.
1994-12-14 15:17:22 +00:00
mycroft
211b002017
Ignore ERR during diagnostics.
1994-12-01 10:45:26 +00:00
mycroft
867ebf1d84
Clear the controller active flag after a timeout.
1994-11-30 02:32:03 +00:00
mycroft
0649f37219
Officially credit Onno.
1994-11-23 22:00:08 +00:00
mycroft
cc44b4600c
There's no point in bothering to unlock what we didn't lock.
1994-11-23 07:54:15 +00:00
mycroft
6dda55519e
Fix an outdated comment.
1994-11-23 03:11:01 +00:00
mycroft
a3fc466734
Use logical block addressing if available. Be a little more careful about
...
maintaining timeouts. Clean up wddump() a bit.
1994-11-23 01:35:43 +00:00
mycroft
525fc36e19
Implement 32-bit reads and writes, but for now assume 16-bit mode.
1994-11-22 10:20:16 +00:00
mycroft
3a99ddf172
Add a missing newline in some error messages.
1994-11-22 09:36:56 +00:00
mycroft
db3bde9525
Implement EIDE multi-sector PIO and DMA modes, based on code from Onno van
...
der Linden. Also, various structural cleanup, and fix two bogons that crept
in, and remove all of the old clustering nonsense.
1994-11-22 09:33:59 +00:00
mycroft
1e01855683
Minor fix to debugging code.
1994-11-22 05:50:48 +00:00
mycroft
85826f0fbe
Fudge a couple more fields for ancient disks.
1994-11-22 05:39:16 +00:00
mycroft
e1a7bac628
Change some constant names, etc., to better match the ATA spec.
1994-11-22 05:34:49 +00:00
mycroft
95edd299b0
Add still more locking.
1994-11-22 03:23:49 +00:00
mycroft
5bd4115690
Add some missing locking, and some general cleanup.
1994-11-20 22:36:43 +00:00
mycroft
35cdd801e6
Convert port, IRQ, and DRQ numbers to ints.
1994-11-18 21:57:40 +00:00
mycroft
2a9b6f7959
Fix stupid bug in last change.
1994-11-04 23:30:15 +00:00
mycroft
4ec6774e12
Add a simplified version of wdcommand() that can be used in some cases.
...
Avoid needing a wd_softc inside wdprobe().
1994-11-04 23:18:06 +00:00
mycroft
b7acf321cd
No longer needs icu.h.
1994-11-04 18:59:34 +00:00
mycroft
19fc9d55c8
*intr() arg does not need to be void*.
1994-11-03 23:23:38 +00:00
mycroft
d23d1e83dc
Use indirect config for subdevices, and add dkdrivers where missing.
1994-11-03 22:55:58 +00:00
cgd
6ac2bbfc35
be more careful with types, also pull in headers where necessary.
1994-10-30 21:43:03 +00:00
cgd
022ee8f7fe
new RCS ID format.
1994-10-27 04:14:23 +00:00
mycroft
3e30a415ae
Be careful not to stack multiple timeouts.
1994-10-20 19:22:01 +00:00
mycroft
4d072c5435
Remove the local timeout mechanism, and just use explicit timeout()/untimeout()
...
calls.
1994-10-20 18:37:45 +00:00
mycroft
c11a06cbc2
Always set d_secsize to 512 for now.
1994-10-20 17:03:09 +00:00
mycroft
0862d07daf
Don't switch to single-sector mode just because we got a corrected error.
1994-10-20 16:36:21 +00:00
mycroft
d4153fff4d
Rearrange wdcstart() in a more logical fashion, and eliminate many redundant
...
calculations. Also, speed up bad block searching a little.
1994-10-20 16:19:08 +00:00
mycroft
cd66683989
openpart -> openmask
1994-10-20 14:08:07 +00:00
mycroft
cae71ba91d
Various changes:
...
* Add a dkdevice; move sc_*openpart, sc_label, and sc_cpulabel into it.
* Turn sc_wlabel into a flag, and don't set it automatically in DIOCWLABEL.
* If there is no label, disallow all I/O except to the raw partition.
* Don't allow I/O to `unused' partitions.
* Beginnings of support for block sizes other than 512 bytes.
Other minor changes.
1994-10-20 13:44:46 +00:00
cgd
49c34d3337
move arch dependence to archs. clean up a bit. deal with weird MAXPARTITONS.
1994-10-14 18:26:22 +00:00
mycroft
236f105ccd
Remove unneeded #includes.
1994-10-09 15:06:23 +00:00
mycroft
b90985ee3d
Don't poll the BUSY bit until the SDH register is set.
1994-10-07 11:34:52 +00:00
mycroft
8dd2c63b08
Turn off the delay debugging messages again.
1994-09-12 20:29:08 +00:00
mycroft
5f27568164
Eliminate struct pte and struct pde.
1994-08-15 14:46:45 +00:00
mycroft
36975ff354
Don't use altsts. Sigh.
1994-08-15 08:22:20 +00:00
mycroft
b5ce4d0cdd
Normalize label handling.
1994-07-26 19:36:06 +00:00
mycroft
1c46c460ee
Return EINVAL if the requested transfer size is weird.
1994-07-21 23:44:16 +00:00
mycroft
a69dd750a2
b_un.b_addr -> b_data
1994-06-16 01:07:30 +00:00
pk
ff9c5cdde5
Set `uio_procp' field in case we ever need it.
1994-06-09 20:00:13 +00:00
mycroft
5f478330e8
Remove now-bogus casts.
1994-05-05 08:31:00 +00:00
cgd
a0a7429482
lots of changes: prototype migration, move lots of variables, definitions,
...
and structure elements around. kill some unnecessary type and macro
definitions. standardize clock handling. More changes than you'd want.
1994-05-05 05:35:42 +00:00
mycroft
0e689f0375
Fix uninitialized pointer, pointed out by Michael VanLoon.
1994-04-25 03:16:03 +00:00
mycroft
84752ce046
Don't need isa.h.
1994-04-24 01:29:56 +00:00
mycroft
893be926ec
Use TAILQ_*() to maintain the drive activation queues.
1994-04-20 07:23:52 +00:00
mycroft
cabd481fa9
Don't print a duplicate message about stray interrupts.
1994-04-09 03:43:36 +00:00
mycroft
3f5e4f423f
Implement dynamic IRQ configuration and IRQ sharing. Inline spl*() calls.
...
Reorganize and clean up the relevant code.
1994-04-07 06:48:19 +00:00
mycroft
8ccc7bdffb
Turn off the timeout debugging info by default.
1994-03-30 04:58:32 +00:00
mycroft
592ec61b17
Updates for new autoconfig.
1994-03-29 04:35:37 +00:00
mycroft
fe3d0b99c3
Prefix the busy-wait messages with `ignore this:' so people stop reporting
...
it as a bug.
1994-03-12 22:36:40 +00:00
mycroft
9ab5683dc7
Fix problem with reading the disk label if it's not at the beginning of the
...
disk.
1994-03-12 22:32:48 +00:00
mycroft
15d758c39a
Remove backward compatibility hacks for config(8), as they are no longer
...
useful.
1994-03-12 03:45:03 +00:00
mycroft
d884f7c425
Update to match config(8).
1994-03-12 03:34:02 +00:00
mycroft
119f3ea688
Various:
...
Put WDF_ERROR in the wdc_softc, to avoid gratuitously forcing non-active drives
into single-sector mode on the next transfer. Arrange to wait for an interrupt
after wdsetctlr(); this avoids long busy-wait delays, and gets rid of the
`extra interrupt' messages (except for one immediately after autoconfig on some
machines). Replace some uses of wdsetctlr() with simply lowering wd->sc_state;
no point in forcing this immediately. Allow control operations to time out.
Enable the warnings for long busy-wait delays by default. Some other minor
things not worth mentioning.
1994-03-11 23:29:12 +00:00
mycroft
99dbc0692d
Add a heuristic for detecting old config(8)s. This is very temporary.
1994-03-10 22:30:06 +00:00
mycroft
390f5990bb
Now that the disk probe routines are actually called, they need to return
...
something.
1994-03-10 21:52:07 +00:00
mycroft
0c19458c6f
More updates for new config.
1994-03-10 20:05:30 +00:00
mycroft
aa45779df7
Update for new config.
1994-03-10 19:57:20 +00:00
mycroft
e4102b8797
Cleanup to fit standard coding conventions, and *many* bugs fixed.
1994-03-10 05:18:33 +00:00
mycroft
5a17003403
Some changes inspired by Bruce Evans's driver:
...
Consolidate error reporting in one function. Actually use the dk_status and
dk_error fields, and pass around only the error bit to avoid lots of unneeded
assignments and tests. No functional differences.
1994-03-07 05:54:44 +00:00
mycroft
991225bfc8
Remove DKFL_QUIET.
1994-03-07 03:18:35 +00:00
mycroft
0c082bcaf8
DELAY() --> delay(). This is not a macro.
1994-03-06 17:18:43 +00:00
mycroft
87ed28e74e
Move the drive select and various other things into wdcommand(), to avoid
...
duplicating code.
1994-03-05 08:17:06 +00:00
mycroft
3e02952c52
Make sure we clear the interrupt when necessary. Why this isn't needed on
...
my hardware is a mystery.
1994-03-04 23:43:14 +00:00
mycroft
652712272f
Add another missing splx().
1994-03-04 17:51:10 +00:00
mycroft
0f92f76ceb
Remember to splx() on some error conditions.
1994-03-04 17:45:22 +00:00
mycroft
ef3c1bf7e6
Start the timeout loop *after* we've decided there is a disk there.
1994-03-04 04:15:24 +00:00
mycroft
220512c2a8
De-ANSIfy. Move the timeout counter into struct disk. Remove unneeded args
...
to wd[gs]etctlr(). Other minor changes.
1994-03-04 03:43:48 +00:00
mycroft
fa396ad402
Watch `seek complete' bit per IBM documentation. Clean up wdioctl(). Other
...
minor cleanup.
1994-03-03 01:58:21 +00:00
mycroft
7b734f94ec
Be more careful about clearing the controller and drive active flags.
1994-03-02 23:27:13 +00:00
mycroft
21118b1bc4
Don't busy-wait for read or write completion.
1994-03-02 22:07:00 +00:00
mycroft
e9326b3ba7
Make wdc_wait() do an implicit wait_for_unbusy(). Pass structure pointers
...
rahter than unit numbers where appropriate. Fix conflict if two drives have
I/O pending at the same time. Add some more sanity checks. Some other minor
cleanup.
1994-03-02 21:42:31 +00:00
mycroft
8ba740e6ab
Get the residual count right.
1994-02-26 19:49:25 +00:00
mycroft
060ee7dbab
Clean up busy-wait code a little, and we need a special disksort() to skip
...
over bufs in a combined transfer.
1994-02-26 19:00:51 +00:00
mycroft
969cea2357
Fix bug from 1.43 correctly.
1994-02-26 17:59:46 +00:00
mycroft
4299a2baec
Fix typo.
1994-02-26 17:13:44 +00:00
mycroft
aeae0fd5e3
Various cleanup, and fix last night's bug.
1994-02-26 17:10:12 +00:00
mycroft
fa83b6f469
Fix typo.
1994-02-26 00:08:01 +00:00
mycroft
a7cdc040ec
Some more stylistic cleanup.
1994-02-26 00:00:17 +00:00
mycroft
7f6bce365b
Fix an obvious bug that could stall the queue.
1994-02-25 18:30:37 +00:00
mycroft
2c3b28e0f9
Remove some redundant code.
1994-02-25 18:17:30 +00:00
mycroft
7e6ee0b562
Increase polling delay.
1994-02-25 18:08:21 +00:00
mycroft
9091e07409
Generalize busy-wait loops.
1994-02-25 17:45:28 +00:00
mycroft
faf08f7262
Don't bother #ifdefing things that are needed and always enabled.
1994-02-25 16:54:41 +00:00
mycroft
f6cee22427
Don't reimplement disksort().
1994-02-25 16:43:48 +00:00
mycroft
373782a3af
`We are the KNF. You will be assimilated.'
1994-02-25 16:40:47 +00:00
mycroft
2f62d06c05
Back pointers are not useful for disksort().
1994-02-10 15:17:34 +00:00
mycroft
bbb3e7618c
All ioctl routines take a struct proc * now.
1994-02-09 21:06:46 +00:00
mycroft
57892d4faf
Remove another use of b_actl.
1994-02-06 17:39:48 +00:00
mycroft
adeebc448e
Use b_actf, not av_forw.
1994-02-06 10:00:30 +00:00
mycroft
664f968d53
Inline all the [lr]cr[023]() `functions' in cpufunc.h.
1994-01-03 16:23:06 +00:00
mycroft
c0e772492e
Inline all the [lr]cr[023]() `functions' in cpufunc.h.
1994-01-03 16:21:48 +00:00