(1) fix a printf format (%x to print int, not %lx).
(2) fix probe of 4th chip/16th channel (used to tell whether or not the
board is a 16- or 32-port board) by removing an incorrect offset so
that the code matched its comments. (!!!)
(3) fix storage of chip number in per-channel structure so that it actually
stores the chip number, rather than the chip offset. This allows the
driver to work with more than the first four channels (i.e. with chips
other than chip number 0, which happens to have an offset of zero). (!!!)
MESSAGE_REJECT in response to SDTR or WDTR. Because of this, the
printfs that indicate refusal of sync/wide negotiation are unneeded
in normal operation. In the __NetBSD__ case, disable them by default.
They, like the other extra-verbose ahc driver boot messages, may be
reenabled with "options DEBUG". The behavior in the !__NetBSD__ case
is unchanged.
after synch negotation during device probes, the 53C94 stops with the target
reqesting more command data. The fifo appears to still contain a couple of
bytes, so transfer them. If the target still wants command data after that,
do a transfer pad. The target seems to function normally after this. A
much better solution thant simply rebooting!
Also fix a problem when compiling with DIAGNOSTIC - a mismatch between using
DIAGNOSTIC and MACH_DIAGNOSTIC caused the compile to fail.
Try to start another target and a device disconnects.
- Add NetBSD autoconfiguration support.
- Rearrange code slightly to minimize the number of #ifdefs.
- Don't use a structure to access CSRs. Use macros that DTRT for
the NetBSD and FreeBSD cases.
- Deal with alignment contraint on Alpha - add 2-byte padding at the
beginning of the RFA, so that the data will be 4-byte aligned, after
the 14-byte Ethernet header.
Thanks to Matthias Drochner for the testing, and David Greenman for
the feedback on the changes.
cast if it isn't. (These casts aren't necessarily safe, because of
alignment issues, but they allow the code to compile with prototyped versions
of bus_space_{read,write}_multi_2().)
if VOP_BMAP() does not produce a translation.
IO_SYNC is used to prevent dirty file cache buffers. On a ffs filesystem,
once a hole is filled, subsequent vnd accesses find will find valid
VOP_BMAP() translations.
Concerns:
* is the assumed semantics correct for all filesystems?
* do we actually want the automagic extension on the VND
backing store..
initiated by vnd_strategy(). This allows for more natural error handling
and solves two bugs:
* vnd can disk_unbusy without disk_busy (PR#2657)
* b_resid is set correctly on the external at the end
of a transfer in case of an error.
mark mulaw as emulated (it's done via a mapping table)
use GUS query encoding routine, even on GUS max, since the encoding
stuff is handled by the GF1.
XXX might not be right for recording, but it's correct for playback.
Set the encoding parameters slightly differently.
Remove the SW encoding/decodinf functions from this interface
and move them to the audio_parameter struct; this is both more efficient
and flexible.
This allows the front end to override the default DCR (byte-wide DMA,
x86 byte order, 8-byte FIFO) with different transfer size, byte order, DMA
parameters, and FIFO threshhold. If the loopback select bit is not set for
normal operation, the default is used instead.
Inspired by thoughts from Bernd Ernesti.
* epinit() had both explicit xcvr selection for 3c589 and a call
to epsetmedia(). The first is redundant; delete it, and EP_COAX_DEFAULT.
* Update comments to reflect 3c589 and 3c509B fixes. Fix typos.
- Determine and remember if we are a floppy.
- Workaround for what is apparently a firmware bug - ignore the sector
size returned by the device. On my Firepower's floppy, block-size
is the same as max-transfer, which causes Lossage.
- Don't read the disklabel on a floppy; do what the ISA floppy driver
does, which is assign the entire disk to each "partition", although
we do not deal with the density stuff.
- FIREPOWERBUGS -> FIRMWORKSBUGS
- Some general cleanup.
by default if it's usable, but falling back to I/O space if mem isn't usable.
If NCR_IOMAPPED is defined (default on the x86), prefer I/O space
then fall back to mem. Also, clean up the various memory consistency checks
so that they can deal with run-time determination of whether or not the
device is to be memory- or I/O-mapped.
by default if it's usable, but falling back to I/O space if mem isn't usable.
If TULIP_IOMAPPED is defined (default on the x86), prefer I/O space
then fall back to mem.
mapping register, maps it, and returns all of the relevant information.
deprecate use of pci_{io,mem}_find(), but leave them around (for a while)
for backward compatibility with third-party drivers.
arguments, so that a device can tell if its memory and I/O spaces are
enabled. The flags are cleared, depending on the contents of devices CSR
registers, in the machine-independent PCI bus code.
this code makes equal sense for memory and I/O space, prefer to map
the PCI front end via memory space (conditionalized on a patchable kernel
variable), and do a bit of other random NetBSD-specific cleanup. (These
changes were sent to Justin Gibbs on March 28.)
This can be disabled (to save a bit of space) with the NO_KERNEL_RCSIDS
options, which is present but commented out in the ALPHA config file.
In ELF-format kernels, these strings are present in the kernel binary but
are not loaded into memory. (In ECOFF-format kernels, there's no easy way
to keep them from being loaded, so they _are_ loaded into memory.)
* Don't print DMA_OUT message in the `normal' case of a 16-byte residual.
* ioasic-connected 53c94 devices are always clocked at 25MHz even on
machines with 12.5MHz TurboChannel.
in reset. If none there, try and get from the bus/platform specific code.
If a nonzero value for either, set the clock rate. This is why the PCI
card versions weren't working- they need to be set at 60MHZ, rather than
the default 40MHZ (which worked fine for the internal ISP chips on the
Alpha 8X00).
B) If a isp_poll returns failure (command never completed) to the caller
and no error is set in the xs struct, set XS_SELTIMEOUT. And then call...
C) Added isp_lostcmd function to try and ask the ISP chip about it's current
state as well as the state of commands for a particular target/lun. This is
going along to try and figure out why the very first command to the ISP always
seems to get swallowed up.
byte comparisons. Compare the ethernet addresses backwards on the
assumption that address number byte 6 has the most random distribution,
so packets not for us spend the least time in here.
is called *after* the driver `done' routine. This fixes disk I/O statistics
on SCSI devices.
Also, calling the `done' routine with a `complete' argument of 0 and actually
having it do anything meaningful loses in at least 3 ways, so just nuke the
argument altogether and don't call it this way. If the driver needs to do
some error handling, that's what `err_handler' is for.
we return from the driver expecting to come back due to an
interrupt, because the interrupt might not happen...
Do the untimeout in ncr53c9x_done instead of just before
almost every call to ncr53c9x_done as was done previously.
Make ncr53c9x_sense schedule its own timeout for the new
command it is starting (request sense), separate from the
timeout for the command that just completed.
- new MD variable: sc_initmodemedia, 79c960 cards can select
between two ports, but this needs to be done in the MI init mode page
- new defines for PCnet-ISA cards (79c960)
- new MD variable: sc_initmodemedia, 79c960 cards can select
between two ports, but this needs to be done in the MI init mode page
- new defines for PCnet-ISA cards (79c960)
- new MD variable: sc_initmodemedia, 79c960 cards can select
between two ports, but this needs to be done in the MI init mode page
- new defines for PCnet-ISA cards (79c960)
particularly older ones, don't do a SAVE DATA POINTER before disconnecting.
When the driver reconnects, it does an implicit RESTORE POINTERS, and
restores the data pointer from *before* the last transfer. If the driver
calculates the residual using the data pointer and doesn't account for
this, the residual will be wrong.
What we do is test for the SDEV_AUTOSAVE quirk when we see a disconnect
message, falling through to do a SAVE DATA POINTER if the quirk applies
to this target.
The workaround was suggested by Mycroft, who also provided the explanation
of the problem. Actual code was (mostly) ripped off from the 53C9x driver.
Anne Hutton <hutton@isi.edu>]:
- add support for Adaptec 155 PCI ATM cards (e.g. ANA-5940)
- add sc->is_adaptec to handle differences between cards.
- break out MID_MK_TXQ/MID_MK_RXQ seperate macros to handle
the new Adaptec format TXQ/RXQ.
- adjust en_dqneed to return 1 on ADP (since the Adaptec can
DMA anything in one DRQ/DTQ!)
- add hook for a bus specific reset function (adaptec has
a seperate reset register that needs to be hit when
resettting the midway).
- adjust DMA test to not worry about burst sizes on the
adaptec (since it handles it all for us!) and to handle
the new DTQ/DRQ format.
- add Adaptec DMA support to en_txlaunch() and en_service()
BUG FIXES:
- fixed receiver panic under heavy load ("lost mbuf in slot 0!").
when the reassembly buffer overflows, the T-bit is set in
the RDB and the data field is empty. en_service() sets up
a 4-byte (RDB size) dummy DMA without IF_ENQUEUE. but the
recv intr handling in en_intr() always does IF_DEQUEUE.
as a result, a successive recv intr loses its mbuf and
leads to a panic. the solution is to only IF_DEQUEUE if
the interrupt has non-zero length (indicating that there
is an mbuf to get). in order for this to work, EN_DQ_MK
must always be non-zero. we do this by or'ing in an unused
bit (0x80000).
reported by: Kenjiro Cho <kjc@csl.sony.co.jp>
- fix setting of transmit channel when txspeed[] is non-zero
(e.g. traffic shaping). the old scheme didn't work
properly (it allowed the same VCI to use multiple tx channels
thus defeating the txspeed[] parameter). the new scheme
statically assigns a VC to a channel when txspeed[] is set.
[note that the code to set txspeed[] isn't in the driver right
now since a MI interface to do this hasn't been made yet]
we add sc->txvc2slot[] and sc->txslot[n].nref for this.
reported by: Kenjiro Cho <kjc@csl.sony.co.jp>,
Milind M Buddihikot <milind@ccrc.wustl.edu>,
Dong Lin <dong@eecs.harvard.edu>
- when doing SRAM copies, be sure to round up the length to the next
largest word (otherwise the driver will try to do a byte clean
up DMA and then get an ID error interrupt).
MINOR CLEANUPS:
- clean up loops in DMA test
contributed by: Kenjiro Cho <kjc@csl.sony.co.jp>
- restructure and cleanup of en_read/en_write macros/inlines
- clean up some byte ordering stuff so that we are consistant throughout
the driver
correspond to the ANA numbers... certainly includes ANA-5940.
- add Efficient Nets product 0x0000. according to linux pci.h
the 0x0000 is an FPGA version of the midway card and the 0x0002
is the ASIC version.
into 8 bits generate (bogus) warnings on some architectures, but the
change to pad on "scsi inquiry" is no longer needed, apparently.
Thanks to Matthias Pfaller for pointing the latter out to me.
- Deal with devices that ignore the length specified in the
inquiry command.
- Allow asynchronous requests without using a buf (key off NOSLEEP instead).
Thanks to Michael Smith for reporting, Jason Thorpe for pointing to the
report, doing a quick workaround which pointed me to the right code part and
for testing the final fix.
does not supply media types, default to the "manual" type.
- Clean up the ETHER_CMP stuff slightly.
- Keep track of our carrier status, for media status requests.
Some of the stuff (e.g., rarpd, bootpd, dhcpd etc., libsa) still will
only support Ethernet. Tcpdump itself should be ok, but libpcap needs
lot of work.
For the detailed change history, look at the commit log entries for
the is-newarp branch.
the base address. This allows for a more flexible layout of buffers
in the Lance's memory.
- Add a new element 'sc_saved_csr0' to am7990_softc. It's value is or-ed
with the current csr0 value in the am7990_intr() function. This allowes
for a 'deferred' interrupt sceme.
- Implement a simple quirks framework for changers.
- Add a quirk for the Spectra 9000 8mm tape library; it requires a
slightly-longer-than-1-minute delay to take tape inventory. Many
thanks to David Webster at Cygnus Solutions for testing this for me.