-convert submatch() style functions (passed to config_search() or
config_found_sm()) to the locator passing variants
-pass interface attributes in some cases
-make submatch() functions look uniformly as far as possible
-avoid macros which just hide cfdata members, and reduce dependencies
on "locators.h"
ata_channel.
- Add and use a CHAN_TO_WDC_REGS() macro to get the wdc_regs from an
ata_channel.
- Add and use a CHAN_TO_PCIIDE() macro to get the pciide_softc from an
ata_channel.
- Add and use a CHAN_TO_PCHAN() macro to get the pciide_channel from an
ata_channel. (This one just hides a cast, and is really just for
consistency with the others.)
functions.
For later rescans (eg after a driver LKM was loaded) to make sense,
don't consider it an error if no driver was attached on the initial
bus scan.
Someone who understands the enable/disable/powerup/down stuff please
review this.
wdc_regs structure, and array of which (indexed per channel) is pointed
to by struct wdc_softc.
- Move the resulting wdc_channel structure to atavar.h and rename it to
ata_channel. Rename the corresponding flags.
- Add a "ch_ndrive" member to struct ata_channel, which indicates the
maximum number of drives that can be present on the channel. For now,
this is always 2. Add an ATA_MAXDRIVES constant that places an upper
limit on this value, also currently 2.
which just gets it from the config entry for the function it's enabling.
Multifunction cards are defined to be of type I/O on every function, so there
is no possibility of accidentally switching.
Use tsleep() rather than delay(). XXX Most of these are probably unnecessary
anyway. In particular, I believe that what xi_full_reset() does is totally
gratuitous after power-cycling the socket; it should only be necessary if we
want to use power-saving mode.
implement the hackish/stupid test for the AX88190 by just checking whether
the IOBASE is available in the CCR.
This is unspeakably wrong, but it leaves the code doing ~the same thing it
did before.
can't really rely on multifunction devices having a CIS that reflects this --
e.g. some cards use a combined Ethernet+modem chip, but only actually serve
one of the functions. (We have to assume the configuration index reflects the
bits needed to enable the function.)
The memory window is not actually activate in I/O card configurations. It was
transparently falling back to 16-bit I/O mode.
Implement "memory card" mode correctly, with polling.
any interrupts, and therefore wedge on any access. However, there is another
memory mode that gives us a memory-mapped data register, which we can use.
Also set the new "DATA1K" flag to tell the wdc backend that we have a large
data area to read from -- this can be used with the region methods.
instead have a call down from the PCMCIA mid-layer to set it. Use this from
pcmcia_function_enable(). (Currently the policy is the same, but this would
allow for more flexibility in deciding which mode to use.)
Now it is safe to hold the socket enabled during attach, so do that. Only
one enable/disable cycle to attach a card now!
count there is (for SCSI, adapt_refcnt) to 1 and call the appropriate
"delref" function afterwards to disable the controller. This is a bit
simpler.
In a couple of cases, just remove the state machine, because it wasn't
really necessary.