Commit graph

8731 commits

Author SHA1 Message Date
Hidetoshi Shimokawa 6f99c2ff52 Remove debug message. 2003-02-07 09:46:30 +00:00
Paul Saab ff2387cb57 Update to new crashdump API 2003-02-07 06:58:32 +00:00
Paul Saab 98c779ea35 Update to new crashdump api 2003-02-07 02:36:20 +00:00
Scott Long ff1e67ab93 Fix the mly driver! If card resources became unavailable, the driver would
correctly tell CAM to requeue the command and then freeze it's queue.  The
problem was that when resources became available again, it wouldn't tell
CAM to unfreeze it's queue, so no more commands would ever be delivered.
This is simialr to the bug that was fixed in the cciss driver last year.
This is a bug in 4-STABLE also, but is probably masked by the OS being
fast enough to drain the completion queue before it fills up.
Also add some diagnostics avaialble when compiled with MLY_DEBUG.
Thanks very much to LSI Corp for donating equipment to track this down,
and Vaidus Damosevicius for pestering me long enough to get it fixed.
2003-02-06 23:46:32 +00:00
Orion Hodson 63679b6573 Fix comment typo.
Sync with userland test framework which now deals better with pcm feeder kobj
emulation.

Reduce max rate from 96kHz to 48kHz as userland tests found a few bad
points about 90kHz and we don't care about operating up there for now.
2003-02-06 17:32:02 +00:00
Hidetoshi Shimokawa d3539e9792 Fix memory leak. 2003-02-06 17:23:01 +00:00
Scott Long ddb8683e59 Teach the CAM module how to deregister itself so it can be unloaded. 2003-02-06 03:31:02 +00:00
Scott Long a761a1ca60 Free the container and sim objects on detach. Convert several uses of
MALLOC to malloc.
2003-02-06 00:37:37 +00:00
Scott Long 5f54d52203 Don't include aac_cam.h, since it was nuked in the last commit.
Deregister the shutdown eventhandler on unload.
2003-02-06 00:07:12 +00:00
Scott Long 70545d1a1f Various cleanups:
- Move the command timeout check from a separate repeating timeout to the
   kthread since the kthread is already running periodically.
 - Move printing the hardware print buffer to the kthread.
 - Properly shut down the kernel thread on detach.
 - Detach the child array devices on detach.
 - Don't issue a controller halt command on detach.  Doing so requires a PCI
   reset to wake the controller back up.  The driver can now be unloaded as
   long as CAM support is not enabled.
2003-02-05 23:24:25 +00:00
Martin Blapp 028a849180 Move the DC_SETBIT to the attach function.
Reviewed by:		phk
2003-02-05 21:21:26 +00:00
Joerg Wunsch e1df235292 Finally make vinum ready for the root filesystem in FreeBSD 5.x. (A
similar patch has been in 4.x for a while, but is more hacky there.)

For this to work, vinum has to be loaded early (e. g. from
boot/loader), for obvious reasons.  If the kernel env variable
(aka. loader variable) "vinum.autostart" is set, vinum then asks the
sysctl kern.disks for all available disks in the system, and scans
them for possible vinum headers.

For statically compiled kernels, this behaviour can be obtained even
without boot/loader by using "options VINUM_AUTOSTART" (though this is
not the recommended way).

Alternatively, the 4.x way to specify "vinum.drives" is also supported.

No further hacks (like the 4.x "vinum.root" variable) are needed,
since in 5.x, mountroot() asks back at the drivers to have them
resolve the name of the root FS into a dev_t (using the dev_clone
eventhandler).

(The MFC reminder below is for a partial MFC for vinum.autostart, the
rest is already there in 4.x.)

Timed out on:	grog
MFC after:	2 weeks
2003-02-05 21:02:56 +00:00
Hidetoshi Shimokawa 5db3899d2e Fix for fwmem write part.
- fix typo
- don't need to check receive buffer.
- don't forget to free xfer on errer.
2003-02-05 17:19:34 +00:00
Andrey A. Chernov 952b6153de Remove srandom():
1) It is already called in init_main.c:proc0_post()
2) It is called each time read_random_phony() called, because "initialized"
variable is never set to 1.

Approved by:    markm
2003-02-05 15:56:04 +00:00
Philippe Charnier c0f44a5927 Spelling. 2003-02-05 14:03:55 +00:00
Paul Saab 41abcc1b62 Obtain the media type from the shared memory and only use the eeprom
as a fallback.
2003-02-05 08:54:36 +00:00
Paul Saab 440baa08c3 Properly get the drive geometry from the controller. This should
fix booting off of volumes > 255GB.
2003-02-05 08:43:46 +00:00
Paul Saab e010b6bc46 Close a memory leak when rescanning the bus. 2003-02-05 07:46:08 +00:00
Doug Ambrisko 01de2955e4 Support for suspend/resume in laptops. Loosely based on the wi(4) patches
but not quite.  The memory descriptors and most of the card parameters
need to be writen to the card.

MFC in:		3 days
2003-02-05 03:37:42 +00:00
Hidetoshi Shimokawa 8a45d99b2a - Implement write part.
- Use quad access for aligned 4 byte access.
2003-02-04 17:09:59 +00:00
Hidetoshi Shimokawa a487c0f261 - Improve recovery after timeout.
* reset agent first then reset target.
	* untimeout all ccbs.
- Try reconnect first if the device has been seen.
- Fix for ORB_FUN_ATA.
2003-02-04 17:08:45 +00:00
MIHIRA Sanpei Yoshiro 8541fbec79 Fix `umass0: BBB bulk-in clear stall failed, IOERROR' problem with
some USB devices.  (Make sure to set xfer data length when we force
a short inquiry.)

Obtained from: NetBSD(sys/dev/usb/umass_scsipi.c rev.1.8)
Original idea from: Shingo WATANABE <nabe@nabechan.org>
2003-02-04 13:45:41 +00:00
MIHIRA Sanpei Yoshiro ab0a90de0a Remove duplicated entry
Put the Trek Smart Thumbdrives (8MB model) entry in the right place.
(Entries are sorted by vendor id).
2003-02-04 13:36:32 +00:00
Orion Hodson 14908c43ac Remove unintended growth of bt848_card_signature. 2003-02-03 18:59:12 +00:00
Orion Hodson faea679930 Avoid zero padding when feeding read channels. chn_rdfeed has no way
of knowing data size transformations of feeder chain and in some cases
this means too much data is pulled through chain, eg converting input
stream from 16bits to 8bits on 16bit only h/w.

PR: kern/37831
Submitted by: Harti Brandt <brandt@fokus.fraunhofer.de>
2003-02-03 15:02:28 +00:00
Hidetoshi Shimokawa beb19fc5dd Remove unnecessary M_NOWAIT. 2003-02-03 09:41:42 +00:00
Hidetoshi Shimokawa 62dae95462 Add missing 'static'. 2003-02-03 08:10:50 +00:00
Hidetoshi Shimokawa 48249fe0c8 - Take malloc type as an argument in fw_xfer_alloc().
- Fix overwrite problem of freed buffers. It was rare but could happen
	when fwohci_arcv() is called before fwohci_txd() is called for
	the transcation.
- Drain AT queues and pend AR queues on SID receive rather than BUS reset to
	make sure DMA actually stops.
- Do agent reset in sbp_timeout().
2003-02-03 07:33:31 +00:00
Orion Hodson ac224567bf Remove mono encodings from vchan format and mixer description. Fixes
mono formats at 44.1kHz playing at double speed when vchans are
enabled.
2003-02-03 03:20:27 +00:00
Orion Hodson a825c6e59e Print ac97 name/id on normal boot.
Fix typo reported in pr misc/47794.
2003-02-03 01:38:43 +00:00
Doug Ambrisko e61838b128 Some small enhancments
-	Implement TX power control with hints to code in Linux driver
	by Douglas S. J. De Couto <decouto@lcs.mit.edu>
      -	Update ifmedia support to use ieee80211_rate2media and
	ieee80211_media2rate.  Note doesn't work with stock ifconfig
	since there seems to be an issue with the setmedia code.
	"ancontrol -t" works now, before it did nothing.
      -	Fix spelling error in header.
2003-02-02 22:49:31 +00:00
Poul-Henning Kamp 6607b68526 Set si_drv1 to our softc for all the six dev_t's we create for a serial port. 2003-02-02 21:25:22 +00:00
Orion Hodson f77f2ccb90 Add BCTV3/PCI entry.
Rename functions bctv_* to bctv2_* and macros BCTV_* to BCTV2_* for
coexistance of BCTV2 and BCTV3.

Rename CARD_IO_GV to CARD_TO_BCTV2.

Add auto recognition of BCTV3/PCI.

PR:             i386/43879
Submitted by:   MOROHOSHI Akihiko <moro@remus.dti.ne.jp>
Approved by:    roger
MFC after:      6 days
2003-02-02 17:46:00 +00:00
Alfred Perlstein b7f305981e chase more of the MIN/MAX mess. *sigh* 2003-02-02 13:52:25 +00:00
Alfred Perlstein 04738e99b5 Catch more uses of MIN(). 2003-02-02 13:30:00 +00:00
Alfred Perlstein c023201af1 remove MIN now that it's a standard kernel define 2003-02-02 13:21:05 +00:00
Alfred Perlstein 8deebb0160 Consolidate MIN/MAX macros into one place (param.h).
Submitted by: Hiten Pandya <hiten@unixdaemons.com>
2003-02-02 13:17:30 +00:00
Warner Losh 1a972e076a Unlock the mutex in the error case in wi_init. Otherwise we can return
from an ioctl with the lock held.

Submitted by: iedowse (by way of sam)
2003-02-02 06:35:46 +00:00
Marcel Moolenaar a3909515f4 Regenerate after fixing duplicate device entries. 2003-02-02 01:58:28 +00:00
Marcel Moolenaar 7c125c1c6a Unbreak kernel builds caused by what appears to be a merge conflict.
This change has been tested.
2003-02-02 01:57:31 +00:00
MIHIRA Sanpei Yoshiro c799e00130 Regen 2003-02-01 23:09:33 +00:00
MIHIRA Sanpei Yoshiro a9451985f7 Add Genesys Logic products
- GL650 HUB
	- GL641USB CompactFlash Card Reade
	- GL641USB USB-IDE Bridge
Add MELCO product
	- USB-IDE Bridge: DUB-PxxG
2003-02-01 22:50:50 +00:00
Hidetoshi Shimokawa 5166f1df39 Define new malloc type M_FW and use it. 2003-02-01 15:04:33 +00:00
Hidetoshi Shimokawa 0981f5f00e - replace timeout with callout_*.
- replace TAILQ with STAILQ for device list.
- some clean up.
2003-02-01 14:42:49 +00:00
Hidetoshi Shimokawa 3c62126d84 Check status FIFO more closely to report error. 2003-02-01 12:06:57 +00:00
Poul-Henning Kamp 806d5cfff0 Eliminate the sc_openmask, ccdopen() and ccdclose() functions, we
can use the flag maintained by geom_disk.c

Having only a strategy method to intialize, don't waste space using
a cdevsw structure to do so.
2003-02-01 11:17:22 +00:00
Hidetoshi Shimokawa 0db3d1635c Add basic support for device wiring down to specific (CAM)
target id. It still needs to be hard-coded now but will
be changed to be configured by tunables or device hints.
2003-02-01 08:55:33 +00:00
Benno Rice 0faf0e2a30 MacIO frontend for the zs driver.
Many thanks to jake for doing the initial driver and for helping me in making
this work.
2003-02-01 07:23:47 +00:00
Hidetoshi Shimokawa 4230e8de2f Sort device list by eui64 in acendent order correctly. 2003-02-01 06:34:36 +00:00
Takeshi Shibagaki 2fd866e6b2 Regen. 2003-02-01 04:47:51 +00:00
Takeshi Shibagaki 57b42a754d Allied Telesis WR211PCM(wi) and Corega PCC-T(ed) have
same manufacture id and product id. So use CIS info
(PCCARD_CISTPL_VERS_1).

reported by HONDA Yasuhiro <yasu@yasu.org>
2003-02-01 04:47:29 +00:00
Mike Silbersack 1a984aad84 Add deviceids for 6105 and 6105M chips. Further changes will be necessary
to fully support these new chips, but preliminary evidence suggests that
they work acceptable with our present driver.

MFC after:	1 week
2003-02-01 01:27:05 +00:00
Mike Silbersack 97e6eca55d Switch the if_vr driver from using our generic MII routines over to
using the Rhine's internal shift registers which are designed
for the job.  This reduces the amount of time we wait around shifting
bits, and seems to work better with some chips.

Also, provide a workaround for some newer cards which report fake PHYs
at multiple addresses.  (As more cards are ID'd, I'm sure this part
of the code will have to be expanded to cover more cases.)

Submitted by:	Thomas Nystrom <thn@saeab.se>
MFC after:	1 week
2003-02-01 01:18:26 +00:00
Poul-Henning Kamp 1b1cf40164 Add PCI id for Quatech SSCLP-200/300 lowprofile single-port RS422/485 card. 2003-01-31 21:11:20 +00:00
Orion Hodson 9aa75ee251 Add tuner code for WinTV Go FM (Hauppauge Model 44811 C133). Patch
supplied by Ross Finlayson <finlayson@live.com>.
2003-01-31 15:23:40 +00:00
Hidetoshi Shimokawa ba3129cb87 function name change. 2003-01-31 14:14:45 +00:00
Hidetoshi Shimokawa 64cf5240a9 SBP related changes.
- Issue LOGOUT command on detach and shutdown.
- Rename some functions.
2003-01-31 14:11:22 +00:00
Mike Silbersack b72d483eb5 Fixes from Thomas Nystrom to fix hanging problems experienced by vr cards
under load.

This patch has been tested by Thomas and other for more than a month now,
and all (known) hangs seem to be solved.

Thomas's explanation of the patch:

*  Fix the problem with the printing of the RX-error.

*  Code from if_fet do better deal with the RX-recovery including a
   timeout of the RX-turnoff.

*  The call to vr_rxeof before vr_rxeoc have been moved to a point
   where the RX-part of the chip is turned off. Otherwise there is a
   window where new data could have been written to the buffer chain
   before the RX-part is turned off. If this happens the chip will see
   a busy rx-buffer. I have no evidence that this have occured but
   god knows what the chip will do in this case!

*  I have added a timeout of the TX-turnoff. I have checked and in
   my 900 MHz system the flags for turnoff (both RX & TX) is seen at
   the first check in the loop.

*  I could see that I got the VR_ISR_DROPPED interrupt sometimes and
   started to thinking about this. I then realized that no recovery is
   needed for this case and therefore I only count it as an rxerror
   (which was not done before).

*  Finally I have changed the FIFO RX threshhold to 128 bytes. When I
   did this the VR_ISR_DROPPED interrupt went away. Theory: The chip
   will receive a complete frame before it tries to write it out to
   memory then the RX threshold is set to store'n'forward. IF the frame
   is large AND the next rx frame also is large AND the bus is busy
   transfering a TX frame to the TX fifo THEN the second received
   frame wont fit in the FIFO and is then dropped. By having the RX
   threshold set to 128 the RX fifo is emptied faster.

MFC after:	5 days
2003-01-31 07:37:06 +00:00
Hidetoshi Shimokawa 9bb3ca0305 SBP related changes.
- Set dual phase retry BUSY_TIMEOUT.
- Let users to know serial bus error.
2003-01-31 03:09:13 +00:00
Poul-Henning Kamp 1686ac18f9 NO_GEOM cleanup: retire disk_invalidate() 2003-01-30 19:43:50 +00:00
Tom Rhodes 40cbf25dbb Add support for the Trek Thumbdrive 8MB USB Drive.
PR:		46004
Submitted by:	Brian J. McGovern <mcgovern@tick.beta.com> (original version)
2003-01-30 18:33:01 +00:00
Orion Hodson 456922d5f2 o Constrain inputs to 25Hz granularity so interpolator can operate
between any pair of values in range 4-96kHz.  Thanks to Ken Marks for
discovering there were problems with the previous version.

o Use a non-recursive gcd routine.
2003-01-30 16:32:56 +00:00
Max Khon 6b58184eb0 - bpf is now working (tested with tcpdump)
- fix promiscious mode

MFC after:	3 days
2003-01-30 15:55:02 +00:00
Doug Ambrisko 0738490650 Fix some style and incorrect indentation level bugs.
Questioned by:	phk (for the indentation problem)
2003-01-30 15:01:17 +00:00
Poul-Henning Kamp 5777c5b989 NO_GEOM cleanup: unifdef 2003-01-30 13:12:31 +00:00
Hidetoshi Shimokawa 958c774916 Restart cycle master after bus manager election.
This should fix the IR(and maybe IT) problem when
the host becames the bus manager.
- rename fw_noderesolve() to fw_noderesolve_eui64() and add
	fw_noderesolve_nodeid().
2003-01-30 05:18:35 +00:00
Hidetoshi Shimokawa 449e559cdb - Handle SCSI_STATUS_BUSY case. 2003-01-30 05:12:56 +00:00
Hidetoshi Shimokawa 7054e8482e - Probe number of IT/IR DMA contexts as specified in OHCI spec. 2003-01-29 15:32:35 +00:00
Joerg Wunsch 501901c61d The Xircom hardware always delivers received packets with the FCS appended.
Thus, mark the M_HASFCS flag so the generic ethernet layers will account
for this.
2003-01-29 15:19:20 +00:00
Benno Rice a42a7e2f13 Set the termios speed based on the tty speed. This allows consoles to work at
speeds other than TTYDEF_SPEED.

Approved by:	jake
2003-01-29 02:43:35 +00:00
Hidetoshi Shimokawa 878db8920f - Fix build on alpha.
- Add a missing newline in printf.
2003-01-29 02:13:31 +00:00
Hidetoshi Shimokawa c3e9e25542 - Allow multiple packets read/write for IR/IT to reduce system call.
- Remove unused variables.
2003-01-28 15:09:07 +00:00
Jake Burkholder a68a96aad7 Add the sabtty children devices as unordered. Use the unit numbr of
the sabtty device to create its description so that they will be
unique for machines with multiple sab chips.

This fixes a panic on machines with an rsc card.

Tested by:	obrien (e250)
2003-01-27 18:39:09 +00:00
MIHIRA Sanpei Yoshiro 4bfecf88f4 Add PCI id for fxp(Intel Pro/100 M Mobile Connection).
PR:	i386/41915
Submitted by:	Ross A. Lippert <ripper@eskimo.com>
MFC after:	1 week
2003-01-27 14:31:32 +00:00
Josef Karthauser 4de19bd9c8 Put the Perfection 1660 scanner entry in the right place. (Entries
are sorted by product id).
2003-01-27 09:43:24 +00:00
Søren Schmidt 33ede9b3e7 Update the code that deals with disk enclosures:
Properly handle the newer Promise SuperSwap 1000 enclosures.
Print out what kind of enclosure was found in the probe.
Misc cleanups in the enclosure handling code.

Sponsored by: Advanis Inc.
2003-01-27 09:04:29 +00:00
Poul-Henning Kamp 16bcbe8cf7 Implement MDIOCLIST which returns the unit numbers of configured md(4)
devices.

We use the md_pad[] array and if there are more units than its size the
last returned unit number will be -1, but the number of units returned
is correct.
2003-01-27 07:58:18 +00:00
Warner Losh 66e390feb6 MFp4:
u_int*_t -> uint*_t to conform more closely with C99.
2003-01-27 05:47:01 +00:00
Jake Burkholder 984e265523 Change ofwcons to use the output-device property from the firmware for the
name of the device that it creates.  Update /etc/ttys accordingly.

An alias is created for the old name so that old /etc/ttys will continue to
work, but due to aliases being implemented as symlinks in devfs you cannot
login as root when using the alias device.

Discussed with:	grehan
2003-01-27 04:42:17 +00:00
Hidetoshi Shimokawa 53f1eb8620 - Split db.desc.cmd into desc.control and desc.reqcount.
- remove unncessary descriptor updates.
2003-01-26 18:38:06 +00:00
Hidetoshi Shimokawa 5a7ba74dc4 - Improve IT/IR DMA queue management.
- Improve debug message for mbuf handling.
- Wait 1 sec for DMA stop in fwohci_i{t,r}x_disable() before freeing buffers.
2003-01-26 15:39:04 +00:00
Poul-Henning Kamp e70e846243 Put use of DIOCWLABEL under #ifdef NO_GEOM 2003-01-26 11:28:56 +00:00
Orion Hodson cb4458e030 Disable DRA to fix problems with recording. 2003-01-26 04:23:23 +00:00
Jake Burkholder 6c5b0e25a0 Allow defaulting the console to ttya when it sets to screen and keyboard
in the prom but no keyboard is plugged in.
2003-01-26 01:56:20 +00:00
Warner Losh 7f7ff631be Add INTEL EEPRO100
Submitted by: joerg
2003-01-25 23:18:01 +00:00
Orion Hodson f9eb140935 Add ac97_patch.[ch] that provide space for ac97 codec specific patches. 2003-01-25 16:54:05 +00:00
Hidetoshi Shimokawa c547b896f5 Change API of FW_GDEVLST ioctl.
- include information about itself.
- define struct fw_devinfo and use it in struct fw_devlstreq.
- unify EUI64 representation using struct fw_eui64.
2003-01-25 14:47:33 +00:00
Hidetoshi Shimokawa 9190691bd0 Remove FW_SSTDV ioctl. It is not used anymore. 2003-01-24 13:03:19 +00:00
Hidetoshi Shimokawa e715bfae6c Merge little and big endian case. 2003-01-24 12:45:19 +00:00
Max Khon 6cdcc15976 - add support for IPX (tested with mount -t nwfs and mars_nwe),
IP fast forwarding, SIOCGIFADDR, setting hardware address (not currently
enabled in cm driver), multicasts (experimental)
- add ARC_MAX_DATA, use IF_HANDOFF, remove arc_sprintf() and some unused
variables
- if_simloop logic is made more similar to ethernet
- drop not ours packets early (if we are not in promiscous mode)

Submitted by:	mark tinguely (partially)
2003-01-24 01:32:20 +00:00
Matthew N. Dodd 3648042ae9 - The 'aux' field isn't around any longer.
- Add missing splnet()/splx()
2003-01-24 00:37:10 +00:00
Nate Lawson a40f20c791 More useful announce message containing current speed of CPU 2003-01-23 22:18:14 +00:00
Hidetoshi Shimokawa 16e0f48443 - Add sysctl knob for bus manager. (hw.firewire.try_bmr)
- Check invalid SID length.
- Add some debug messages.
2003-01-23 13:34:40 +00:00
Scott Long 128aa5a022 Hack around a bug in the 2200 and 2120 controllers that connot DMA
commands from below the first 8K of physical memory.  A better fix
is to modify the busdma api to allow either inclusion ranges or
multiple exclusion ranges, but that debate is for another day.

MFC After:	2 days
2003-01-23 01:01:44 +00:00
Marcel Moolenaar 19ad245042 YAM: This id is found in a Sony Vaio GRX-670. When will this end?
Submitted by: Chuck McCrobie <mccrobie2000@yahoo.com>
2003-01-22 22:02:09 +00:00
Justin T. Gibbs a02f9953f0 Revert AHD_TIMER_MAX_US to its original definition now that the
ahc and ahd modules have correct dependencies on the assembler.
2003-01-22 22:00:07 +00:00
Joerg Wunsch d50ea522c1 Make the arguments to d_close() match the arguments to d_open(), since
otherwise the close operation is void, and the underlying device remains
marked as being busy.

Thanks to phk for finding this.

MFC after:	3 days
2003-01-22 14:06:46 +00:00
Jeffrey Hsu 033aebebc4 Add yet another Sony Vaio PS/2 mouse ID. This one is found on a VX88.
Submitted by:	marcel
2003-01-22 03:31:08 +00:00
Thomas Moestl 3437dbef6d Free resources when failing to set up the interrupt. 2003-01-21 17:28:36 +00:00
Thomas Moestl aaa160f357 bus_dmamap_sync() overhaul:
- Remove NetBSD-style or-ed together BUS_DMASYNC operations, in some
  cases relaxing the (intended) syncing operation a bit.
- Add syncs before reading the descriptor rings.
- Try to combine syncs where possible to avoid overhead.
- Sync all maps before unloading them.
2003-01-21 17:22:52 +00:00