they're base I/O ports, not really addresses. rather than using those
softc fields directly, assign local variables (asicbase, nicbase) to have
their values, and use those. (consistency, plus better optimization
potential in some cases.)
eventually. rename the probe functions for the various boards to 'find' for
consistency/correctness (but the generic8390 check is still a 'probe').
Add protos for ed_find(), ed_probe_generic8390(), ed_find_WD80x3(),
ed_find_3Com(), and ed_find_Novell(). Fix one minor space nit.
'flags 1' on the sb? kernel configuration file line (because it frobs a
noncontiguous IO port to configure the Jazz16 extensions).
Also, remove static sb_device structure and fill in user's buffer on
each request.
ends of lines, turn aligned blocks of eight spaces into tabs, name all
softc elements with the "sc_" prefix, and call the softc by the commonly
used name, "sc", when passing it around.
pcibus and pci.
(2) remove the #ifdef i386 from pci.c, and provide a machine-dependent
hook (pci_md_attach_hook()) to do any machine-dependent attachment
gunk, e.g. on the i386 printing out the configuration mode (if bus 0)
(3) don't pass max device number for a given bus in, use
PCI_MAX_DEVICE_NUMBER, which can be defined on a per-machine basis.
(defaults to 32. on i386, it's 32 if pci conf mode == 1, 16 if 2.)
assumes that pci_map_mem/pci_map_io provide interfaces which utilitize
bus_{io,mem}_handle_t's, or types which are compatible. This works on the
i386, and will change eventually anyway.)
for U_INT8, INT16, U_INT16 definitions. Convert structs and
definitions in ncr_reg.h (e.g. ncrcmd, the chip register layout, etc.)
to use these definitions.
Add INB_OFF, INL_OFF, and OUTL_OFF macros to access specified offsets into
I/O or memory space. Convert register dumps (etc.), and cache snoop
test to use these new macros, so that nothing accesses the device
I/O or memory space directly. (Register dumps now come from I/O space
if NCR_IOMAPPED. They used to bogusly use memory space.)
Add a new relocation type for script entries, RELOC_KVAR. Allow scripts
access to mono_time.tv_sec, mono_time, and ncr_cache via this
mechanism, and convert scripts to use it. An ncrcmd is only 32 bits
wide, and KVAs may be > 32 bits wide (e.g. on Alpha), leading to
linker problems. This is a safer way to do this anyway; relocation is
more deterministic this way, and doesn't rely on KVAs not looking like
other relocation types.
Panic if an unmatched relocation other than 'zero' is specified. That's
now a script bug. (This used to be used to convert KVAs of kernel
variables referenced in the script to PCI bus physical addresses,
and that is now handled by RELOC_KVAR relocations.)
Figure out and print the model of chip.
assumes that pci_map_mem/pci_map_io provide interfaces which utilitize
bus_{io,mem}_handle_t's, or types which are compatible. This works on the
i386, and will change eventually anyway.)
substantial reworking of the multi-port drivers, as they need to frob
bits in the io-port spaces of their children. As a result, the
commulti->com attachment interface is substantially more complex.
(This may be fixable in the future by making some of the code common,
but as long as io-port allocation checking is planned, it's necessary.)
macro where appropriate. No point in hard-coding numbers in multiple places.
At the very least, this makes the drivers slightly easier to diff/understand.
attaching, and to the devices when attaching them. #include <machine/bus.h>
to make this backward compatible with old #include requirements.
Also, clean up idempotency so that isa/eisa/pci "var.h" headers are
consistent (make them all idempotent).
and will probably work with Massbus adapters as well. (Not tested,
but it's the same code as for 11/780). Ubareset's may cause crashes
on 8600 also like 11/780, but they are more uncommon. No support
for console RL02 yet, but it's likely to come.
but unconfigured (or unsupported) devices printed at boot time.
The device list is woefully incomplete, because i didn't put much time
in it, and because i don't know good "human names" for many TC devices.
and attach the secondary pci bus as a 'pci' device. Note that this support
is incomplete and will not yet work for ports other than that i386. (The
i386 can rely on the PCI interrupt 'line' information to determine
interrupt mapping, which is not necessarily possible on other systems.)
planned changes in other sections of code.
(2) expands the use of config_found() in tcattach() in-line, so that
tcsubmatch can be invoked there, rather than being invoked by
individual drivers.
(3) tcbus_attach_args now includes a turbochannel speed flag.
(4) compare a string in tcbus_attach_args against tc bus driver name,
to better allow attachment of multiple busses to the same parent.
keep going.
Improve error messages to include device name.
use STATIC for function declarations/definitions so it's easier to get a
useful symbol table by flipping a switch.
fix semantics of AUDIO_WERROR (now returns a count).
Also repair audio driver back to "real-time mode" where user must
provide data quickly enough for real time audio or silence is played
until user catches up. Add optional "play all" mode (additional bit in
mode field) to play all samples provided, with silence when needed to
avoid buffer underrun.
* Snap the sample rate when setting it, and remember only the time constant.
* Set the time constant when changing between play/record.
* Always return the actual sample rate with AUDIO_GETINFO.
* Add more delays while writing registers.
* Replace sc_dma{in,out}_inprogress with sc_dmadir.
* Eliminate the need for sc_locked.
* Add more DPRINTF()s.
detatch everywhere else. Reverted to the english spelling.
Also fixed the rest of the prototype warnings while I was at it.
ic/ncr5380sbc.c: Don't declare Debugger()... I have to clean this
everywhere :-(
Rename the ioctl asic register and slot macros from ASIC_<xxx> to
IOASIC_<xxx>, to be compatible with the machine-indpendent names in
sys/dev/tc/ioasicvar.h. The pmax code still uses
sys/arch/pmax/pmax/asic.h, as some of the registers and offsets
defined there are not yet defined in sys/dev/tc/ioasicvar.h.
Rename the ioctl asic base-address pointer from `asic_base' to `ioasic_base'.
Use the device address in the attach_args structure, instead of
using the deprecated BUS_CVTADDR macro.
Change the Mach derived asc driver to use "SCSI_PHASE_xxx" instead of
"ASC_PHASE_xxx", as the latest version of the Mach driver does.
(1) remove the 'UNSUPP' keyword from the device list,
because it can't be reasonably used (becuase different
devices may be supported on different machines, for
good reason).
(2) enhance pci_devinfo so that class/subclass information
is optional (so pci_devinfo can be used by drivers that
match classes of devices, and want to look up the
devices' names easily).
(3) more known vendors and devices.
- controller calls scsi_done() with error XS_TIMEOUT
- scsi_done() calls sddone()
- sddone() calls disk_unbusy()
- scsi_done() calls controller to retry command (missing the
call to disk_busy())
- controller calls scsi_done()
- scsi_done() calls sddone()
- sddone() calls disk_busy(), which panics because of the imbalance.
Bug noticed by Leo Weppleman, who also suggested this fix; pass an additional
boolean argument ("complete") to the device's "done" routine, with a
value of `0' passed from the previous call to "done", and add an additional
call to "done" when the xfer resources are freed.
- New metrics handling. Metrics are now kept in the new
`struct disk'. Busy time is now stored as a timeval, and
transfer count in bytes.
- Storage for disklabels is now dynamically allocated, so that
the size of the disk structure is not machine-dependent.
- Several new functions for attaching and detaching disks, and
handling metrics calculation.
Old-style instrumentation is still supported in drivers that did it before.
However, old-style instrumentation is being deprecated, and will go away
once the userland utilities are updated for the new framework.
For usage and architectural details, see the forthcoming disk(9) manual
page.
if the CPP symbols LE_TINT_HOOK and LE_RINT_HOOK are defined, respectively.
The hooks are called by jumping though the sc_tint_hook and sc_rint_hook
members of the softc, and take the softc as an argument. Only ports which
need these hooks need to declare them in the softc.