Commit Graph

117 Commits

Author SHA1 Message Date
Søren Schmidt
468fe0fdf1 Finally commit some of the minor things I've collected over the last month(s):
Add tagged queueing support for new IBM drives.

Add support for Yet Another Promise ATA 100 chip.

Flush disk cache on close.

Dont flush the disk cache on BIO_ORDERED anymore.

Cleanup the tests for DMA on ATAPI devices.

Allow to share ALL irq's even the std irg 14 & 15.

Fix calculation bug in end of media code on CD's.

Add REZERO on opening a CDR/CDRW.

Cleanup ataioctl a bit.
2001-08-21 11:35:47 +00:00
John Baldwin
8ec48c6dbf - Remove asleep(), await(), and M_ASLEEP.
- Callers of asleep() and await() have been converted to calling tsleep().
  The only caller outside of M_ASLEEP was the ata driver, which called both
  asleep() and await() with spl-raised, so there was no need for the
  asleep() and await() pair.  M_ASLEEP was unused.

Reviewed by:	jasone, peter
2001-08-10 06:37:05 +00:00
Søren Schmidt
2c68839222 Update to use the changed ioctl interface. 2001-05-17 10:29:30 +00:00
Søren Schmidt
ae2e8ffad0 Add new flag ATPR_F_QUIET to atapi_request.
Cleanup error handling.
2001-04-05 11:15:24 +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
Søren Schmidt
7154fc7c7b Do not change/get mode on a nonexisting device. 2001-03-21 11:44:58 +00:00
Søren Schmidt
895fd69a76 Only allow root to attach/detach/etc ATA/ATAPI devices. 2001-03-19 11:55:13 +00:00
Søren Schmidt
6eee1a1c12 Add sysctls for reading the tunables as suggested by des.
Minor cleanups plus checks of the ->active state.
Cosmetics.
2001-03-19 08:04:54 +00:00
Søren Schmidt
a2dca80a1d Provide the interface to atacontrol and associated logic.
see atacontrol(8) for more.

Also the ATA_ENABLE_ATAPI_DMA, ATA_ENABLE_WC and ATA_ENABLE_TAGS
options are gone, use the tuneables listed in ata.4 instead from
the loader (this makes it possible to switch off DMA before the
driver has to touch the devices on broken hardware).
2001-03-15 15:36:25 +00:00
Søren Schmidt
6c2cfc9203 Minor cleanup to the previous commit:
Print what devices went away and which arrived.

Avoid timeout loop on missing status.
2001-03-14 14:00:09 +00:00
Søren Schmidt
8ea3ce2aac Refine the detach/attach code.
Proberly fail outstanding bio requests on devices that are detached.

This makes it possible to change between disk/cdrom/dvd/whathaveyou
in a notebook, just by suspending it, changing the device in the
bay (or what you model calls it), unsuspend and the ATA driver
will figure out what disappeared and properly fail those, and attach
any new devices found.
2001-03-14 12:05:44 +00:00
Søren Schmidt
331c488d69 Split out the ata probes in seperate files for each bus type. 2001-03-06 21:43:46 +00:00
Mark Murray
7547eefdf3 Set the interrupt-harvesting bit for those hardware items that I
can actually test.

Nothing will happen until the sysadmin turns on intr-harvesting
on her computer.
2001-02-18 18:02:15 +00:00
Søren Schmidt
df17ff7fa5 Oops, its no longer NISA its DEV_ISA, sigh.... 2001-02-12 14:29:13 +00:00
Søren Schmidt
7dd6c38875 Dont rely on isa includes to get at the std port adresses. 2001-02-12 10:18:59 +00:00
Søren Schmidt
b6268bb5e2 Properly report the VIA '586 type. 2001-02-12 08:33:28 +00:00
Søren Schmidt
32565eb8c5 Fix a memory leak.
Pointed out by: Asmodai
2001-02-08 21:59:27 +00:00
Søren Schmidt
b17f7a1aa5 Introduce busspace instead of the good old in/out instructions.
Not pretty but it works (I hope)...
2001-02-06 16:44:25 +00:00
Søren Schmidt
dbb5bf4bf6 Damn! that was the wrong patch! get it right this time.... 2001-02-06 12:49:33 +00:00
Søren Schmidt
06a519dfc9 Fix the clone functionality in atapi-cd, it didn't work for
devs other than the first, and allowed to clone a nonexistent
device..
2001-02-06 12:41:53 +00:00
Peter Wemm
358f1800c0 Convert ata and atapi #if NATA* > 0 to options instead. Stop config
trying to count the number of ata* devs since they were not used anyway.
2001-01-29 10:01:11 +00:00
Peter Wemm
03927d3c33 Send "#if NISA > 0" to the bit-bucket and replace it with an option.
These were compile-time "is the isa code present?" tests and not
'how many isa busses' tests.
2001-01-29 09:38:39 +00:00
Søren Schmidt
af152621e5 Add first cut support for the ATA100 capable VIA82c686b. 2001-01-17 09:22:13 +00:00
Søren Schmidt
3ce9aa9100 Use prober atomic operations when test&set'ing ->active.
This turns some of my lockups under SMP into spontanious reboots...
2001-01-14 19:36:20 +00:00
Søren Schmidt
95eaffae1b Add session argument to *close_disk, allowing to set session type on fixate.
Add support for different blank/erase types.

Update headers.
2001-01-10 19:19:47 +00:00
Søren Schmidt
6cf4911dd6 Use M_ZERO flag on malloc when approbiate. 2000-12-26 12:05:49 +00:00
Søren Schmidt
43a181118f Proberly back down DMA modes on the Acer Aladdin. 2000-12-19 10:37:03 +00:00
Poul-Henning Kamp
959b7375ed Staticize some malloc M_ instances. 2000-12-08 20:09:00 +00:00
Søren Schmidt
374940a184 Fix a braino .. 2000-11-18 12:14:35 +00:00
Søren Schmidt
18434d5214 Put the probe verboseness behind bootverbose 2000-11-16 10:52:00 +00:00
Søren Schmidt
a9c1b0e23a Hopefully fix the probing problems that caused lost slaves etc.. 2000-11-12 20:40:05 +00:00
Søren Schmidt
1716750c65 Rearrange the timeouts in the reset code a bit, some ATAPI devices
are picky about this.
2000-11-08 21:25:43 +00:00
Søren Schmidt
30a777baa8 Hopefully solve the lost slave problem. 2000-11-08 19:31:39 +00:00
Søren Schmidt
4ce977b412 Fix breakage on some ATA chips that dont have busmastering set.
Tidy up the probe a bit..
2000-11-03 17:09:34 +00:00
Søren Schmidt
afaa0eb776 Try a bit harder to test for ATA/ATAPI HW to probe, this is to avoid
some of the false comrades some devices fakes...
2000-10-30 20:45:24 +00:00
Søren Schmidt
0dbc12d8ca Fix the PCCARD ATA breakage..
This is due to a bug that has been in there since Warneer did the
PCCARD stuff, the altioaddr is not offset 8 its offset 14 from
the base address.
Also only probe the master device, no known PCCARD ATA thingies
has a slave AFAIK..
2000-10-30 09:36:40 +00:00
Søren Schmidt
7f7e251f51 Fix the problem with DMA mode not working on Aladdin chips.
Amasing in how many ways Acer has screwed up that chip.
2000-10-24 13:50:22 +00:00
Søren Schmidt
d29f653d3a Up the reset pulse to 100ms in ata_reset, some drives especially
DVD drives need this to reset proberly.

Remove some verboseness..
2000-10-22 12:16:00 +00:00
Søren Schmidt
550abec2a0 Minor changes to the ATA RAID support code, remove some verbosity
and put some under bootverbose..
2000-10-18 18:49:42 +00:00
Poul-Henning Kamp
db7e3af111 Remove unneeded #include <machine/clock.h> 2000-10-15 14:19:01 +00:00
Søren Schmidt
8d8f318a08 Fix ISA only systems. 2000-10-13 12:09:23 +00:00
Søren Schmidt
2c483f9eb5 Get rid of the ivars entirely. 2000-10-13 11:21:27 +00:00
John Baldwin
1931cf940a - Heavyweight interrupt threads on the alpha for device I/O interrupts.
- Make softinterrupts (SWI's) almost completely MI, and divorce them
  completely from the x86 hardware interrupt code.
  - The ihandlers array is now gone.  Instead, there is a MI shandlers array
    that just contains SWI handlers.
  - Most of the former machine/ipl.h files have moved to a new sys/ipl.h.
- Stub out all the spl*() functions on all architectures.

Submitted by:	dfr
2000-10-05 23:09:57 +00:00
Søren Schmidt
11b944d47a Cleanup the chipset specific interrupt code a bit. 2000-10-05 08:28:06 +00:00
Søren Schmidt
9b09a33635 Fix the MASTERDEV breakage the caused the PIIX controllers to get
missed in the probe. This might break the CMD chips again, more
testing is needed on that, but we need the mainstream chips to
work again ...
2000-10-04 08:28:37 +00:00
Søren Schmidt
162080b465 Add support for ServerWorks ROSB4 ATA33 chipset.
Add support for CMD 648 ATA66 & CMD 649 ATA100 chipsets.

Fix the "resource already allocated" panic with the CMD and other
braindead controllers.

Add options ATA_ENABLE_TAGS, without this option tagged queuing will
not be attempted.
2000-10-03 13:12:36 +00:00
Doug Rabson
f6174366bf Make the alpha hacks dependant on __alpha__ instead of !__i386__. 2000-09-29 16:50:31 +00:00
Søren Schmidt
511e9e7251 Fix the breakage that snatched the ioports from the fdc device.
Fix promise support.
2000-09-24 18:19:43 +00:00
Søren Schmidt
c50cf4ac06 Remove unneeded includes
Pointed out by: phk
2000-09-20 07:00:24 +00:00
Søren Schmidt
8563f77dc9 Add support for tagged queuing on ATA drives. There is only support for
IBM's DPTA and DTLA series of drives (no other disk vendors are known
to support this) on non-Promise controllers (promise controllers lockup
when given the tagged queuing specific commands).
It gives especially master/slave comboes about 5% better performance.

Add support for the Promise ATA100 OEM chip (pdc20265)

Add support for the Cyrix 5530

Change the way status is read from the drives, use the alternate
status reg when possible.

Better support for DEVFS, the acdXtY devices are now created when needed.

Lots of little cleanups.
2000-09-19 11:08:39 +00:00