Commit Graph

19846 Commits

Author SHA1 Message Date
Kris Kennaway
8c6ac5e5a5 Reword warning to make it clearer (I read it as "remove block devices created
before 2000-06-01" which is obviously not what was intended :-)
2000-03-25 21:10:20 +00:00
Warner Losh
6ea2fbe9be More fully initialize cardbus bridges. We now call the new generic
cardbus bridge init routine for all cardbuses.  This routine attempts
to compensate for BIOSes that do not setup the cardbus bridge into
legacy mode.  Since this is becoming more common, and cardbus pci
cards have appeared on the market, this makes sense.

Do some TI113x specific initialization.  This came in as part of the
patch.  Report TI1[1234]XX specific config registers protected by
bootverbose.

Minor code cleanup while I'm here.  I've also removed the unused code
present in the original patches, and cleaned it up slightly in places
as well.

The original patches supported more than one card, but these patches
support just one.  We should likely revisit this in the future.

This makes the Compaq card that Walnut Creek CD purchased for me work
in my bouncer box.

This is a MFC candidate.  However, I'd like to get some airtime on
these patches on as many laptops as possible before doing the MFC.  It
does change things somewhat.  In theory, apart from the minor TI
tweaks, this shouldn't change anything if the bridge is in legacy mode
already.

Submitted by: sanpei@sanpei.org (MIHIRA Yoshiro)
2000-03-25 20:29:55 +00:00
Dag-Erling Smørgrav
c2c0fac9c9 Attempt to provide real values for meminfo. 2000-03-25 19:41:18 +00:00
Warner Losh
190701a53a Two new chips found in Steve Passe's Protoge' laptop:
Lucent 56Flex DVS LTMOTEM (winmodem and unsupported)
	Cinemaster C 3.0 DVD Decoder
2000-03-25 17:01:59 +00:00
Dag-Erling Smørgrav
8deca17b79 Linux /proc filesystem.
Submitted by:	pb
2000-03-25 13:23:02 +00:00
Warner Losh
fbeea60676 Regen 2000-03-25 04:05:16 +00:00
Warner Losh
23b295b874 Merge 1.60 to 1.85 of NetBSD's pcmciadevs into our database. 2000-03-25 04:04:24 +00:00
Warner Losh
be8bcd17eb More pnpids. 2000-03-25 03:24:43 +00:00
Warner Losh
2d268ca4c3 Make pcic module compile again for NEWCARD (not for old pccard). 2000-03-25 03:16:19 +00:00
Warner Losh
b9118590b8 Make this compile again and harmonize with GENERIC:
o added gif, faith, wx, ida, amr, mlw, INET6
o many comment nits
o Comment out all the compat shim devices, mostly so that I know what
  they are:
	amd, dpt, ncr, adv, tx, vx, fe, cs, lnc,
o Leave the following commented out:
	ie, le

NEWCARD now compiles again.  Back to testing...
2000-03-25 03:15:03 +00:00
Matthew N. Dodd
c9c222f749 Fix a problem that caused TCP fragments to be lost (among other things.) 2000-03-24 23:31:42 +00:00
John Baldwin
76b501da94 Update sysinstall to use struct uc_device instead of struct isa_device
for generating /boot/kernel.conf.  Since this structure is shared, move
its definition out to a header file, just as struct isa_device was defined
in a header file.  This fixes the sysinstall breakage in -current.
2000-03-24 22:24:09 +00:00
Jeroen Ruigrok van der Werven
53543772cb Fix spelling, slingly -> singly.
Submitted by:	nrahlstr
2000-03-24 21:02:14 +00:00
Bill Fumerola
a68c41beea Add Mach64-LB graphics accelerator
Submitted by:	Brandon Martus <bmartus@chc-chimes.com> (unwittingly)
Obtained from:	NetBSD (syssrc/sys/dev/pci/pcidevs)
2000-03-24 19:31:02 +00:00
Søren Schmidt
8c918526a5 Fix the panic occuring on non-changer devices. 2000-03-24 07:44:20 +00:00
Cameron Grant
6b4b88f7a2 don't check extended features on codecs known to hang. should fix neomagic
problems.
2000-03-24 03:14:35 +00:00
Matthew Dillon
f1924a54f8 Fix in-kernel infinite loop in pipe_write() when the reader goes away
at just the wrong time.
2000-03-24 00:47:37 +00:00
Bruce Evans
4a8d210268 Remove unused file. 2000-03-23 19:22:14 +00:00
Bruce Evans
83f7669eff Fixed most disordering (almost all except for i4b and targets with
complicated rules).
2000-03-23 19:08:49 +00:00
Bruce Evans
822dcb81d0 Fixed most disordering (all except for targets with complicated rules). 2000-03-23 19:03:26 +00:00
Matthew Dillon
84365e2bcb Fix parens in m_pullup() line in arp handling code. The code was
improperly doing the equivalent of (m = (function() == NULL)) instead
    of ((m = function()) == NULL).

    This fixes a NULL pointer dereference panic with runt arp packets.
2000-03-23 18:58:59 +00:00
Bruce Evans
ca04fd5f6f Fixed my breakage of SPLASSERT() in rev.1.15. There was a stray semicolon
after "if ()".
2000-03-23 18:46:44 +00:00
Mike Smith
9992d96f25 Fix detection of the card-ready-for-command state. Use an ultimate
timeout closer to the 1-second value that AMI use in their Linux
driver, and mark the mailbox structures as volatile so that gcc
doesn't over-optimise access to them.

This should fix the "controller wedged" bug.

Submitted by:	Brian Dean <brdean@unx.sas.com>
2000-03-23 18:33:19 +00:00
Jeroen Ruigrok van der Werven
000033d073 Document options HZ, place it in its own section `CLOCK OPTIONS' and
add the undocumented CLK_* options to that section as well.

Submitted by:	Mike Tancsa <mike@sentex.ca> (partially)
2000-03-23 16:22:50 +00:00
Bruce Evans
0784615675 Fixed clean rule for font.h. 2000-03-23 15:42:24 +00:00
David E. O'Brien
4c3ecb0f88 Switch to the new time counter code to follow the i386.
Assisted by:	phk
2000-03-23 10:22:52 +00:00
KATO Takenori
6eeafd696c Merged from sys/i386/isa/clock.c and sys/isa/sio.c revisions 1.150 and
1.292, respectively.
2000-03-23 08:55:45 +00:00
KATO Takenori
bef3dd268d Removed B_READ and B_WRITE. 2000-03-23 08:53:15 +00:00
KATO Takenori
aad7652706 Disable fdctl_wr_foo. This feature is not supported by PC98. 2000-03-23 08:50:56 +00:00
KATO Takenori
25d654e785 Merged from sys/conf/files.i386 revision 1.310 (re-activate K6-2
MTRR driver).
2000-03-23 08:13:32 +00:00
Poul-Henning Kamp
912e4ae9f7 Fix one place which knew that B_WRITE was zero.
Fix a stylistic mistake of mine while here.

Found by:	Stephen Hocking <shocking@prth.pgs.com>
2000-03-22 08:40:13 +00:00
Yoshihiro Takahashi
9d97e36cc4 Added the joy driver (commented out).
Submitted by:	chi@bd.mbn.or.jp (Chiharu Shibata)
2000-03-22 03:19:37 +00:00
Brian Feldman
333aa64d05 in6_pcb.c:
Remove a bogus (redundant, just weird, etc.) key_freeso(so).
	There are no consumers of it now, nor does it seem there
	ever will be.

in6?_pcb.c:
	Add an if (inp->in6?p_sp != NULL) before the call to
	ipsec[46]_delete_pcbpolicy(inp).  In low-memory conditions
	this can cause a crash because in6?_sp can be NULL...
2000-03-22 02:27:30 +00:00
Poul-Henning Kamp
e004067750 Whine at users who still have block devices in /dev, give them until
june 1st to fix their system.
2000-03-21 19:25:56 +00:00
Dan Moschuk
6ad9d70260 Include a space between hash ('#') and 'Berkeley packet filter' like
all the other comments have.
2000-03-21 17:00:58 +00:00
Bill Paul
b485fb175f Regenerate usbdevs files.
Also add device entry in if_kue.c for the LINKSYS USB10T adapter.

Also add calls to bpfdetach() in detach routines.
2000-03-21 15:20:41 +00:00
Bill Paul
695ddaa54a Add device ID for LinkSys USB10T ethernet adapter (0x2202). 2000-03-21 15:18:51 +00:00
Duncan Barclay
160be33b08 For version 0.9 change DNET output 2000-03-21 14:39:36 +00:00
Duncan Barclay
aa5eb84d3c Added user level updates and reading of parameters. 2000-03-21 14:27:46 +00:00
Duncan Barclay
f338b9dcb1 Typo. 2000-03-21 14:26:38 +00:00
Søren Schmidt
c481f1fa74 Make ATAPI CD changer devices work, hopefully better than before. 2000-03-21 13:26:54 +00:00
Paul Saab
e5a28db9f5 Add sysctl kern.coredump to enable/disable core dumps system wide. 2000-03-21 07:10:42 +00:00
Archie Cobbs
382379f8a8 Call bpfdetach() before going away. 2000-03-21 01:42:56 +00:00
Warner Losh
5431b20654 Bogusly returned zero always. Return 1 if we pass the checksum. 2000-03-20 23:29:27 +00:00
Masahide MAEKAWA
ae562b99a0 Regen. 2000-03-20 19:49:50 +00:00
Masahide MAEKAWA
91441023d8 Add 22 vendor IDs. 2000-03-20 19:49:20 +00:00
Masahide MAEKAWA
bdc8d7478e Regen. 2000-03-20 18:30:34 +00:00
Masahide MAEKAWA
3935d591c6 Add 80 vendor IDs. 2000-03-20 18:30:04 +00:00
Brian Feldman
16aae9cbc0 Split the logic of
static int setrootbyname(char *name);
out into
   dev_t getdiskbyname(char *name);

This makes it easy to create a new DDB command, which is the big reason
for the change.  You can now do the following in DDB:

Example rc.conf entry:
dumpdev="/dev/ad0s1b"   # Device name to crashdump to (if enabled).

db> show disk/ad0s1b
dev_t = 0xc0b7ea00
db> p *dumpdev
c0b7ea00
2000-03-20 16:28:35 +00:00
Cameron Grant
87374c3d7a toast warnings on i386 2000-03-20 15:50:08 +00:00
Cameron Grant
3252a47be9 make als120 cards which report dsp version 3.x whilst only supporting 4.x
and *not* 3.x commands work
2000-03-20 15:34:27 +00:00
Cameron Grant
39004e693d update the ac97 layer:
* add a callback for initialising the mixer interface
* support ac97 2.1 variable rate audio feature

fix ac97-using drivers for the above

add suspend/resume support for neomagic
2000-03-20 15:30:50 +00:00
Cameron Grant
a0b4946276 add a function to reinitialize the mixer, to be called by drivers on
resuming after suspend
2000-03-20 15:21:50 +00:00
Yoshihiro Takahashi
562039fa5b Fixed style bugs. 2000-03-20 14:50:48 +00:00
Poul-Henning Kamp
91266b96c4 Isolate the Timecounter internals in their own two files.
Make the public interface more systematically named.

Remove the alternate method, it doesn't do any good, only ruins performance.

Add counters to profile the usage of the 8 access functions.

Apply the beer-ware to my code.

The weird +/- counts are caused by two repocopies behind the scenes:
	kern/kern_clock.c -> kern/kern_tc.c
	sys/time.h -> sys/timetc.h
(thanks peter!)
2000-03-20 14:09:06 +00:00
Poul-Henning Kamp
ce6acbb664 diff, patch and cvs didn't like these three last time around, try again. 2000-03-20 12:34:21 +00:00
KATO Takenori
de6c289a4d Removed old boot loader. 2000-03-20 12:14:12 +00:00
Poul-Henning Kamp
b99c307a21 Rename the existing BUF_STRATEGY() to DEV_STRATEGY()
substitute BUF_WRITE(foo) for VOP_BWRITE(foo->b_vp, foo)

substitute BUF_STRATEGY(foo) for VOP_STRATEGY(foo->b_vp, foo)

This patch is machine generated except for the ccd.c and buf.h parts.
2000-03-20 11:29:10 +00:00
Poul-Henning Kamp
21144e3bf1 Remove B_READ, B_WRITE and B_FREEBUF and replace them with a new
field in struct buf: b_iocmd.  The b_iocmd is enforced to have
exactly one bit set.

B_WRITE was bogusly defined as zero giving rise to obvious coding
mistakes.

Also eliminate the redundant struct buf flag B_CALL, it can just
as efficiently be done by comparing b_iodone to NULL.

Should you get a panic or drop into the debugger, complaining about
"b_iocmd", don't continue.  It is likely to write on your disk
where it should have been reading.

This change is a step in the direction towards a stackable BIO capability.

A lot of this patch were machine generated (Thanks to style(9) compliance!)

Vinum users:  Greg has not had time to test this yet, be careful.
2000-03-20 10:44:49 +00:00
Martin Cracauer
cce9dd21c1 Exchange numerical values for FPE_INTDIV and FPE_INTOVF, so that they
are compatible with the older ones implemented in FreeBSD 3.x.

PR:		15488
2000-03-20 10:22:19 +00:00
Peter Wemm
9ac61e92ca Argh, fix cut/paste mistake. This contributed to LINT not building. 2000-03-20 10:17:13 +00:00
Peter Wemm
0ae2f9bf04 A fairly simple newbusification of if_de 2000-03-20 09:18:46 +00:00
Peter Wemm
d213a95368 Unused definitions. 2000-03-20 08:21:52 +00:00
Kazutaka YOKOTA
2886c99404 White-space-only change. The file originally had screwed indentation. 2000-03-20 08:18:00 +00:00
Peter Wemm
c4a75202fb This file was repo copied and I forgot to cvs rm this here. 2000-03-20 07:21:40 +00:00
Warner Losh
7d0548ce1c Noriyoshi Kawano-san reported in nomads another OUI for linksys. 4 is
too many, so I removed the checks for the valid OUIs.  We already do a
checksum of the entire ethernet address, so extra checking against the
OUI shouldn't be needed.
2000-03-20 07:09:32 +00:00
Peter Wemm
a063b13d98 Tag a warning on the isa compat shims at config time. 2000-03-20 04:47:40 +00:00
KATO Takenori
2f90f1f892 Increment number of retries before giving up. This may fix the
problem that some CD-ROM drives are not recognized if they are empty.

Submitted by:	Tomokazu HARADA <tkhara@osk4.3web.ne.jp>
2000-03-20 03:55:29 +00:00
Peter Wemm
9e0f2a9fb1 Use an intermediate file containing the module binary before converting
it into a ``shared'' .ko file.  This intermediate file can be directly
linked into a static kernel.  This isn't all that useful yet but will
become much more interesting shortly.
2000-03-20 01:29:59 +00:00
Peter Wemm
56dac036b6 Bandaid for src/sys/modules which broke world 2000-03-20 01:22:27 +00:00
Paul Richards
c4bf272b86 Update the copyright. Remove the advertising clause. 2000-03-20 00:53:46 +00:00
Larry Lile
b149dd6c66 o Replace most magic numbers related to token ring with #defines
from iso88025.h.

o Add minimal llc support to iso88025_input.

o Clean up most of the source routing code.

* Submitted by: Nikolai Saoukh <nms@otdel-1.org>
2000-03-19 21:34:39 +00:00
Brian Feldman
a3f7c5d143 Enable the K6-2 MTRR driver again, since there are reports of it working
with the applied change.

Submitted by:	 Coleman Kane <cokane@one.net>
2000-03-19 19:22:24 +00:00
Brian Feldman
c6e0c95d30 Set the bits in the mask from the left to the right, not backwards.
Submitted by:	 Coleman Kane <cokane@one.net>
2000-03-19 19:21:37 +00:00
KATO Takenori
bf8a6679dc Merged from sys/isa/fd.c. 2000-03-19 15:18:22 +00:00
Larry Lile
34b62638d9 o Fix typo in the RapidFire 3540 adapter name
4/16/100 -> 100/16/4 so that it matches all of the others.

o Since we went to all the trouble of getting the correct
  working memory size actually use it.

* Submitted by: Nikolai Saoukh <nms@otdel-1.org>
2000-03-19 15:08:39 +00:00
KATO Takenori
c892ec24d8 Define PC98 when MACHINE == pc98, because msdos_vfsops.c contains
`#ifdef PC98'.
2000-03-19 15:06:18 +00:00
Paul Saab
891c64630d Make SPLASSERT sysctl and boot time tunable with kern.splassertmode.
The following values are understood:  0 (ignore), 1 (log), and 2
(panic).

The default value is 1.

Reviewed by:	peter
2000-03-19 14:55:42 +00:00
KATO Takenori
7c0e7abcf9 Merged from sys/i386/i386/userconfig.c rev 1.178. 2000-03-19 14:46:22 +00:00
KATO Takenori
9b8b69aae4 Added COMPAT_OLDPCI and COMPAT_OLDISA options. 2000-03-19 14:42:52 +00:00
Peter Wemm
085beaf862 Add the COMPAT_OLDPCI option for the alpha so GENERIC compiles. 2000-03-19 13:57:09 +00:00
Peter Wemm
4e64b0d320 Document and supply COMPAT_OLDPCI and COMPAT_OLDISA so 'make release'
still works.
2000-03-19 13:33:26 +00:00
Peter Wemm
80060e8897 Connect the ISA and PCI compatability shims to an option. In this case
it's options COMPAT_OLDISA and COMPAT_OLDPCI.  This is meant to be a
fairly strong incentive to update the older drivers to newbus, but doesn't
(quite) leave anybody hanging with no hardware support.  I was talking with
a few folks and I was encouraged to simply break or disable the shims but
that was a bit too drastic for my liking.
2000-03-19 13:07:12 +00:00
Peter Wemm
1aef042634 Completely decouple userconfig from 'struct isa_device' and friends.
Userconfig was only using this for convenience since newbus, and even
then it was rather inconvenient.
2000-03-19 12:57:49 +00:00
Peter Wemm
c317f0727a Remove the old a.out-only boot loader, we don't use it any more.
The new boot1/boot2 can load a.out and elf kernels directly.
I think the sys/pc98 version can go too as the sys/boot/pc98 code
appears to be functional, but I'll leave that for the pc98 folks.

"There can be only one."
2000-03-19 11:42:34 +00:00
Paul Saab
ca27a8d4cf Add conditional splassert.
Reviewed by:	peter
2000-03-19 11:39:26 +00:00
Jeroen Ruigrok van der Werven
cb2116539c Add device isic to the ASUSCOM_IPAC entry.
Remove quotes around some i4b options to be consistent with the rest.
2000-03-19 10:19:23 +00:00
Brian Somers
9da582e318 Make _FindLinkIn() static and only define GetDestPort when
NO_FW_PUNCH isn't defined.
2000-03-19 09:11:05 +00:00
Robert Watson
081d19aecd Modify if_wi.c to call bpfdetach(ifp) before if_detach(ifp), so as to
prevent a page fault if the card is ejected while BPF is in use.  This
could happen if DHCP or tcpdump was in use on that interface during
ejection.  Other drivers may also require this modification.

Reviewed by:	wes
2000-03-19 05:46:50 +00:00
Robert Watson
de5d99354f The advent of if_detach, allowing interface removal at runtime, makes it
possible for a panic to occur if BPF is in use on the interface at the
time of the call to if_detach.  This happens because BPF maintains pointers
to the struct ifnet describing the interface, which is freed by if_detach.

To correct this problem, a new call, bpfdetach, is introduced.  bpfdetach
locates BPF descriptor references to the interface, and NULLs them.  Other
BPF code is modified so that discovery of a NULL interface results in
ENXIO (already implemented for some calls).  Processes blocked on a BPF
call will also be woken up so that they can receive ENXIO.

Interface drivers that invoke bpfattach and if_detach must be modified to
also call bpfattach(ifp) before calling if_detach(ifp).  This is relevant
for buses that support hot removal, such as pccard and usb.  Patches to
all effected devices will not be committed, only to if_wi.c, due to
testing limitations.  To reproduce the crash, load up tcpdump on you
favorite pccard ethernet card, and then eject the card.  As some pccard
drivers do not invoke if_detach(ifp), this bug will not manifest itself
for those drivers.

Reviewed by:	wes
2000-03-19 05:42:34 +00:00
Kazutaka YOKOTA
ea20901db7 Missing pieces of the last commit ;-( 2000-03-19 04:37:18 +00:00
Kazutaka YOKOTA
db3e34cb71 - Properly keep track of I/O port resources.
- Use bus_space_read/write() to access the ports.
2000-03-19 03:25:13 +00:00
Larry Lile
49ec367311 o Replace the old "oltr" driver with the completely re-written
new-bus Olicom driver, previously known as "ol".  The new
  driver unfortunately does not support ISA cards yet.

o Update the microcode files, interface library and include files
  to the latest PowerMACH works version.  Force even byte alignment
  of adapter microcode.

o Roll in some of the patches from Nikolai Saoukh <nms@ethereal.ru>.
2000-03-18 23:51:54 +00:00
Søren Schmidt
2a14fd50d9 Remove the old DSC code, it doesn't work anymore. 2000-03-18 22:42:45 +00:00
Justin T. Gibbs
ff58fb8420 o Correct the offsets into the syncrate table for paritcular
negotiation features (DT, ULTRA2, ULTRA, FAST).  The offsets
  where not properly updated when the DT entry was added and so
  the driver could attempt to negotiate a speed faster than that
  supported by the target device or even requested by the user
  via SCSI-Select settings. *

o Update the target mode incoming command queue kernel index value
  ever 128 commands instead of 32.  This means that the kernel will
  always try to keep its index (as seen on the card - the kernel may
  actually have cleared more space) 128 commands ahead of where the
  sequencer is adding entries.

o Use the HS_MAILBOX register instead of the KERNEL_TQINPOS location
  in SRAM to indicate the kernel's target queue possition on Ultra2
  cards.  This avoids the "pause bug" on these cards and also turns
  out to be much more efficient.

o When enabling or disabling a particular target id for target mode,
  make sure that the taret id in the SCSIID register does not
  reference an ID that is not to receive target selections.  This
  is only an issue on chips that support the multiple target id
  feature where the value in SCSIID will still affect selection
  behavior regardless of the values in the target id bit field
  registers.

o Remove some target mode debugging printfs.

o Make sure that the sense length reported in ATIO commands is
  always zero.  This driver does not, yet, report HBA generated
  sense information for accepted commands.

o Honor the CAM_TIME_INFINITY and CAM_TIME_DEFAULT values for
  the CCB timeout field.

o Make the driver compile with AHC_DEBUG again.

* Noticed by: Andrew Gallatin<gallatin@cs.duke.edu>
2000-03-18 22:28:20 +00:00
Jason Evans
603ed0f30d Use __alias__ instead of alias in the definition of __strong_reference().
Submitted by:	jdp
2000-03-18 22:26:54 +00:00
Justin T. Gibbs
c4b5781296 KNR -> ANSI function definition in two places. This matches the rest of
the code in this driver.
2000-03-18 22:15:00 +00:00
Justin T. Gibbs
a9e181db4a o clear the ccb_flags field before sending an accept target I/O ccb to
an HBA.  Garbage in this field confuses the driver in targdone().

o When completing a CCB on behalf of a user process, we need to
  *de-queue* the ccb from our pending ccb list, not queue it again.

o All continue target I/O operations need to have a timeout set.
  We use 5 seconds throughout this driver.

o Remove some logging printfs.

o During abort processing, remove ccbs that are on the pending queue
  from the pending queue, not the work queue.
2000-03-18 22:13:27 +00:00
Matt Jacob
39d3da3df7 Per Justin's request- remove his name from Copyright. 2000-03-18 22:03:41 +00:00
Jeroen Ruigrok van der Werven
1eeb917c9c Put ASUSCOM_IPAC in the section where it belongs, namely i4b. 2000-03-18 19:30:58 +00:00
Nick Hibma
e5399702e8 Print the PCI resources even if they are disabled. This shows more clearly
when the BIOS is forgetful about initialising the USB controllers.
2000-03-18 19:18:36 +00:00
Jeroen Ruigrok van der Werven
bc0e3a03b5 Put the undocumented options back at the bottom as per old
practice.

Place the debug options above the undocumented options.
2000-03-18 18:39:02 +00:00
Joerg Wunsch
5f830ea2cd Make the Y-E Data PCMCIA floppy of the Toshiba Libretto work under
-current.  It doesn't work yet as stable as the 3.x/PAO version of the
driver does, however, i get occasional `FDC direction bit not set' and
other weird messages, but it basically works at least.

The old (defunct) #ifdef FDC_YE stuff has been eliminated completely
now, PCMCIA-FDC specific functions have been implemented differently
where needed.

Unfortunately, due to the fact that the traditional PeeCee FDC with
its funny non-contiguous register space (one register for WD1003
harddisk controllers is interleaved into the FDC register set), and
Peter's subsequent changes involving two different bus space handles
for normal FDCs, the changes required for the Y-E stuff are more
complex than i'd love them to be.  I've done my best to keep the logic
for normal FDCs intact.

Since the Y-E FDC seems to lose interrupts after a FDC reset
sometimes, i've also replaced the timeout logic in fd_turnoff() to
generate an artificial pseudo interrupt in case of a timeout while the
drive has still outstanding transfers waiting.  This avoids the total
starvation of the driver that could be observed with highly damaged
media under 3.x/PAO.  This part of the patch has been revied by bde
previously.

I've fixed a number of occasions where previous commits have been
missing the encapuslation of ISA DMA related functions inside
FDC_NODMA checks.

I've added one call to SET_BCDR() during preparation of the format
floppy operation.  Floppy formatting has been totally broken before in
3.x/PAO (garbage ID fields have been written to the medium, causing
`wrong cylinder' errors upon media reading).  This is just black
magic, i don't have the slightes idea _why_ this needs to be but just
copied over the hack that has been used by the PAO folks in the normal
read/write case anyway.

The entired device_busy() stuff seems to be pointless to me.  In any
case, i had to add device_unbusy() calls symmetrical to the
device_busy() calls, otherwise the PCMCIA floppy driver could never be
deactivated.  (As it used to be, it caused a `mark the device busier
and busier' situation.)  IMHO, all block device drivers should be
marked busy based on active buffers still waiting for the driver, so
the device_unbusy() calls should probably go to biodone().  Only one
other driver (whose name escapes me at the moment) uses device_busy()
calls at all, so i question the value of all this...

I think this entire `device busy' logic simply doesn't fit for PCMCIA
&al.  It cannot be the decision of some piece of kernel software to
declare a device `busy by now, you can't remove it', when the actual
physical power of removing it is the user pulling the card.  The
kernel simply has to cope with the removal, however busy the device
might have been by the time of the removal, period.  Perhaps a force
flag needs to be added?

Upon inserting the card a second time, i get:

WARNING: "fd" is usurping "fd"'s cdevsw[]
WARNING: "fd" is usurping "fd"'s bmaj

I suspect this is related to the XXX comment at the call to
cdevsw_add().  Does anybody know what the correct way is to cleanup
this?
2000-03-18 18:27:01 +00:00
Nick Hibma
bc51947397 The completely rewritten USB Mass Storage driver. It supports the following
devices:

Tested:
   Zip 100 USB drive
   Y-E Data USB floppy drive

Untested: (let me know whether or not it works!)
   TEAC USB floppy drive
   Zip 250 USB drive
2000-03-18 17:33:41 +00:00
Jeroen Ruigrok van der Werven
5d6f1468bb Document three debug options: npx, bus and vfs locks debugging. 2000-03-18 17:30:12 +00:00
Kazutaka YOKOTA
02572fd86e - `Newbus'ified the mse driver. 2000-03-18 15:43:13 +00:00
Kazutaka YOKOTA
8c219e162a - Fix bugs when painting border and the mouse cursor in the raster
text mode.
2000-03-18 15:28:48 +00:00
Kazutaka YOKOTA
3346e881c1 - Add Support for the following PS/2 mice:
- Microsoft IntelliMouse Explorer: 2 buttons on top, 2 side buttons
    and a wheel which also acts as the middle button.  The mouse is
    recognized as "IntelliMouse Explorer".
  - Genius NetScroll Optical: 2 buttons on top, 2 side buttons and a
    wheel which also acts as the middle button.  The mouse is recognized
    as "NetMouse/NetScroll Optical".
  - MouseSystems SmartScroll Mouse (OEM from Genius?): 3 buttons on top,
    1 side button and a wheel.  The mouse is recognized as Genius
    "NetScroll".
  - IBM ScrollPoint: 2 buttons on top and a stick between the buttons.
    The stick can perform "horizontal scroll" in W*ndows environment.
    The horizontal movement of the stick is detected.  It is currently
    mapped to the Z axis movement in the same way as the first wheel.
    The mouse is recognized as "MouseMan+", as it is considered to be
    a variation of MouseMan.
  - A4 Tech 4D and 4D+ mice. These mice have two wheels! The movement
    of the second wheel is reported as the Z axis movement in the
    same way as the first wheel. These mice are recognized as "4D
    Mouse" and "4D+ Mouse".
  - Tweak IntelliMouse support code a bit so that less-than-compatible
    wheel mice can work properly with the psm driver.
- Add driver configuration flags which correspond to the kernel
  options PSM_HOOKRESUME and PSM_RESETAFTERSUSPEND, so that we don't
  need to recompile the kernel when we need these functions.
- Properly keep track of the irq resource.
- Add a watchdog timer in case interrupts are lost (experimental).
- Add `detach' function (experimental).
2000-03-18 15:21:40 +00:00
Kazutaka YOKOTA
6f6fe825bd - `Newbus'ified the driver.
- Properly keep track of resources (I/O ports and irq).
- Use bus_space_read/write() to access the ports.
- Add PnP IDs.
- Add a watchdog timer in case interrupts are lost (experimental).
- Add `detach' function (experimental).
2000-03-18 15:13:30 +00:00
Nick Hibma
31bfa89e41 Get rid of the last remnants of powerhook abuse. 2000-03-18 14:54:54 +00:00
Bill Fenner
95b2b777b5 Make sure to free the socket in soabort() if the protocol couldn't
free it (this could happen if the protocol already freed its part
 and we just kept the socket around to make sure accept(2) didn't block)
2000-03-18 08:56:56 +00:00
Matt Jacob
a4135b96f1 Alpha 8200: redo files arrangement for 8200 support. There sort of
still *is* a problem about how to get an mcclock attached w/o an
ISA declaration though.
2000-03-18 08:05:27 +00:00
Matt Jacob
d06b99eb3f Alpha 8200: remove the SIMOS usage of zs_cnattach- we have a real
zs_cnattach now.
2000-03-18 08:04:23 +00:00
Matt Jacob
c7790ceee2 Alpha 8200: Redo console attachment to be more 'normal'. Make sure the
halt function *stays* halted.
2000-03-18 08:03:48 +00:00
Matt Jacob
d0366c9108 Alpha 8200: redo prom console code to be more up to date, etc. This
is now a functional PROM console (previously broken). Do the correct
promcnatach && CONS_DRIVER dance.
2000-03-18 08:02:35 +00:00
Matt Jacob
583759a807 Alpha 8200: add DEC_KN8AE (TurboLaser) platform option. 2000-03-18 08:01:34 +00:00
Matt Jacob
e562365e1e Alpha 8200: Add prototype from promcnattach. 2000-03-18 08:00:51 +00:00
Matt Jacob
6499b39e60 Alpha 8200: Add in a dummy child of dwlpx so that we can make the leap
from DWLPX to PCI space. Just a methods holder such that we have a parent
which is a "pcib" and we create a child which is a "pci". Add the appropriate
ivar code (which is for a hose #).
2000-03-18 08:00:13 +00:00
Matt Jacob
9ca20275e0 Alpha 8200: Do some compilation cleanup. Conditionalize some IDE stuff
based upon presence/absence of ISA (there is no ISA bus on an 8200- okay,
well, there *could* be one in a DWLPX tray, but we don't support it)).

Most importantly change the interrupt resource map to cover a whole 16
bits. The 8200 uses 16 bit interrupt vectors which we construct that
contain the I/O-board, hose, an pci slot in them, and then we write these
vectors into the appropriate DWLPX registers. At any rate, a flat array
of 64 'IRQs' isn't enough.
2000-03-18 07:57:58 +00:00
Matt Jacob
8ad895a6a9 Alpha 8200: Reinsert licence from NetBSD that should have been there
to begin with. Redo newbus attachment code so that all the DMA mapping
and further pci attachment is done right. Insert config space functions
(jeez- how do you do type 1 cycles?). Do the interrupt setups, etc.
Basically, this is the core I/O module for 8200s, even though logically
it's the 3rd level down from the nominal principle backplane bus
(turbolaser). Still to be done here: S/G code isn't done yet, so we
better live with 2GB or less primary memory.
2000-03-18 07:54:11 +00:00
Matt Jacob
c6c4384666 Alpha 8200: Remove clause 3 of licence. Clean up code slightly. 2000-03-18 07:50:58 +00:00
Matt Jacob
6beeb2a4cd Alpha 8200: Remove clause 3 of licence. Redo KFTXX bus attachment
code (merge in progress made in NetBSD since the initial import to
FreeBSD). Create dwlpx as the child device. Of course, if we had
more h/w and time, we could find out whether the child device was
a FutureBus module, etc...Anyone ever actually seen one?
2000-03-18 07:49:53 +00:00
Matt Jacob
3c87339922 Alpha 8200: Remove clause 3 of licence and and some KFTXX defines. 2000-03-18 07:48:15 +00:00
Matt Jacob
9132772537 Alpha 8200: minor formatting tweaks; removal of clause 3 of licence. 2000-03-18 07:46:34 +00:00
Matt Jacob
eaef8d3ef1 Alpha 8200: Rework to get working properly with real h/w. This isn't a
clean MI/MD driver, but it *does* actually work at this time. Updated
to use new make_dev stuff. A CONS_DRIVER declaration is also put in
so that this can be the real console for the 8200s.
2000-03-18 07:46:05 +00:00
Matt Jacob
cf80414e14 Alpha 8200: Ooops on last delta- real changes include redoing bus attachment
code and interrupt mapping code.
2000-03-18 07:44:18 +00:00
Matt Jacob
db50341ca1 Alpha 8200: Some minor formatting tweaks and removal of clause 3 of licence. 2000-03-18 07:42:13 +00:00
Matt Jacob
34a2da7f9a Alpha 8200: add a dummy driver for TLSB CPU nodes. Not so dummy, actually,
as you have to hook a GBus into it.
2000-03-18 07:40:17 +00:00
Matt Jacob
23959069d6 Alpha 8200: Add in variables and defines for DWLPX PCI controllers. 2000-03-18 07:30:06 +00:00
Matt Jacob
67795722e9 Alpha8200: Update this stub memory board driver for using newbus. 2000-03-18 07:28:27 +00:00
Robert Watson
8ed3828c3b Introduce a new bd_seesent flag to the BPF descriptor, indicating whether or
not the current BPF device should report locally generated packets or not.
This allows sniffing applications to see only packets that are not generated
locally, which can be useful for debugging bridging problems, or other
situations where MAC addresses are not sufficient to identify locally
sourced packets.  Default to true for this flag, so as to provide existing
behavior by default.

Introduce two new ioctls, BIOCGSEESENT and BIOCSSEESENT, which may be used
to manipulate this flag from userland, given appropriate privilege.

Modify bpf.4 to document these two new ioctl arguments.

Reviewed by:	asmodai
2000-03-18 06:30:42 +00:00
Mike Smith
da8bb3a3bf Update to the latest development version of the Mylex driver. Changes in
this version include:

 - Support for version 2.x firmware (2.42 or later recommended).  This
   means we are the only open-source driver supporting these adapters.
   This code has only been tested on a Digital KZPCA adapter in an Alpha
   system, but is believed to be correct.  NOTE: EISA adapters are not
   yet supported.

 - Support the BIOS/Firmware initialisation handshake protocol.  This
   allows the driver to bring the card up to operational state even if
   the BIOS can't be run (eg. if it's an x86 BIOS in an Alpha system).

 - A working command pasthrough interface.  This allows a user-space
   configuration tool (under development) to issue arbitrary commands
   to the controller or to devices in the system.
2000-03-18 02:01:37 +00:00
Bill Paul
726fcd3955 Add another device/vendor code combination to support yet another
KLSI-based device (Skymaster DHU-0404).
2000-03-18 01:36:37 +00:00
Bill Paul
827a61b63d Update Tigon firmware yet again, this time to version 12.3.20. 2000-03-18 01:30:36 +00:00
Chris Costello
b081a64afb In vn_isdisk(), check whether vp->v_rdev is NULL. If it is, then
return ENXIO (Device not configured).  Without this, vn_isdisk()
could (and did in the case of lstat() under fdesc) pass a NULL pointer
to devsw(), which caused a page fault.

Reviewed by:	alfred
2000-03-18 01:27:44 +00:00
Poul-Henning Kamp
63909a9015 Newer ciscos have become more picky, and will not accept the MULTICAST bit
being set for unicast packets.
2000-03-17 17:06:33 +00:00
Yoshihiro Takahashi
1bb26f3a43 Fixed header file path and added necessary file. 2000-03-17 12:56:23 +00:00
Yoshihiro Takahashi
b0198bb46f Sync with sys/boot/i386/libi386/biosdisk.c revision 1.27 and 1.28.
Submitted by:	Kaho Toshikazu <kaho@elam.kais.kyoto-u.ac.jp>
2000-03-17 12:38:36 +00:00
Yoshihiro Takahashi
05f94cca19 Sync with sys/i386/i386/userconfig.c revision 1.175 and 1.176. 2000-03-17 12:24:59 +00:00
Yoshihiro Takahashi
54bfac8fdc Backed out ppc0 flags addtion. It isn't necessary without PPC_PROBE_CHIPSET
option.

Pointed out by:	peter
2000-03-17 11:37:03 +00:00
Kirk McKusick
584508a741 Use 64-bit math to calculate if we have hit our freespace limit.
Necessary for coherent results on filesystems bigger than 0.5Tb.
2000-03-17 03:44:47 +00:00
Yoshihiro Takahashi
2b60363d7f Fixed to probe extended memory for over 256M or under 64M.
Submitted by:   chi@bd.mbn.or.jp (Chiharu Shibata)
2000-03-16 12:14:00 +00:00
Yoshihiro Takahashi
49c57093b7 Changed key assign for PC-98.
shift+TAB  : BackTab
HELP       : End
STOP       : ScrollLock
shift+STOP : ScreenSaver
GRPH +STOP : Suspend(susp)
COPY       : NextScreen(nscr)
ctrl +COPY : Debug
NFER       : Meta

Submitted by:   chi@bd.mbn.or.jp (Chiharu Shibata)
2000-03-16 12:10:43 +00:00
Yoshihiro Takahashi
a97d495cb9 Fixed to support old parallel interface.
Submitted by:   chi@bd.mbn.or.jp (Chiharu Shibata)
2000-03-16 12:06:29 +00:00
Yoshihiro Takahashi
13b6f8f604 Added 'flags 0x40' to ppc0. 2000-03-16 12:03:36 +00:00
Yoshihiro Takahashi
1a9a318055 Changed sio1 flags to 0x12000010 to enable serial console.
Submitted by:   IMAI Takeshi <take-i@ceres.dti.ne.jp>
2000-03-16 11:53:16 +00:00
Nick Hibma
846664235c Instead of using the next unit available, use the first unit available.
This avoids the unit number from going up indefinitely when
diconnecting and connecting 2 devices alternately.

Noticed by: nsayer (quite a while ago)

And stop calling DEVICE_NOMATCH at probe repeatedly. This stops the
message on the PCI VGA board from being printed when loading a PCI driver.
2000-03-16 09:32:59 +00:00
Nick Hibma
e2dbd15f2e Please welcome the URio driver. Written by
Iwasa Kazmi <kzmi\@ca2.so-net.ne.jp>
2000-03-16 09:16:14 +00:00
Poul-Henning Kamp
db5f635acc Eliminate the undocumented, experimental, non-delivering and highly
dangerous MAX_PERF option.
2000-03-16 08:51:55 +00:00
Jason Evans
5968536749 Add the _POSIX_SEMAPHORES feature flag. 2000-03-16 02:26:00 +00:00
Matt Jacob
17d75f8ecb Alpha 8200 port: Until we fix things better, determine which alpha CPU
platform we're running on so we know how many bits to reserve at the top
end for the 'hose' value. It turns out that there's *just* enough room
to support all possible hoses on TurboLaser.
Reviewed by:	gallatin@freebsd.org, dfr@free3bsd.org
2000-03-15 23:50:31 +00:00
Nick Hibma
e96441b1ee Add a quirk entry for Y-E Data USB floppy drive.
Driver follows in the next few days.
2000-03-15 22:44:03 +00:00
Nick Hibma
e557a32190 Add the TD's to the hash when they are created not when they are used.
This makes it possible to handle the done queue even when the end of tail
TD has ended up on the done queue as well (the xfer in this case is NULL
but the next field is valid, so we simply skip that element.

Make sure we mark all the handled transfers as handled.

Stop using powerhooks. They are a NetBSD-ism.
2000-03-15 22:27:24 +00:00
Nick Hibma
d0ba6675ce Add an ID for the SiS 5571.
Remove the unnecessary use of parent.
2000-03-15 22:26:17 +00:00
Nick Hibma
330dc9152d powerhooks no longer used 2000-03-15 22:15:21 +00:00
Nick Hibma
49d89e0791 Make the makefile work properly. 2000-03-15 22:13:50 +00:00
Nick Hibma
8be178756c Do not use the powerhooks at all, instead of abusing and empty #define. 2000-03-15 22:12:47 +00:00
Nick Hibma
efb572af98 Spelling mistake 2000-03-15 22:11:00 +00:00
Nick Hibma
799c4480f9 Never stop the control pipe 2000-03-15 22:09:53 +00:00
Nick Hibma
fa55e6183a Add urio (143) 2000-03-15 22:06:01 +00:00
Nick Hibma
bf20c30848 Regen. 2000-03-15 22:04:01 +00:00
Peter Wemm
8af444f84f Remove stray pointers to wdc; it was removed a while back. 2000-03-15 21:58:58 +00:00
Peter Wemm
931fe729ca Remove left over pci_ide* after wd removal. 2000-03-15 21:58:27 +00:00
Nick Hibma
0cdabce076 Various typo's.
One minor nit. The speed was displayed wrong when below 1Mb/s.
2000-03-15 21:55:48 +00:00
Peter Wemm
645e837fbe Remove left over files from wd; Since pc98 still uses some of them those
were copied.  Some cleanup is still needed there, ie: unifdef -DPC98 etc.
2000-03-15 21:55:43 +00:00
Peter Wemm
2a72e5e1c1 Move the files.* references to wdc files to the pc98 location after the
repo copy.
2000-03-15 21:53:12 +00:00
Nick Hibma
c7c6f59635 Add Y-E Data floppy drive. 2000-03-15 21:53:09 +00:00
Nick Hibma
14a069312d Update the e-mail address to a valid one. 2000-03-15 21:50:41 +00:00
Mike Smith
0cb0254b78 Trim a couple of over-long strings
Submitted by:	des
2000-03-15 21:24:40 +00:00
Matt Jacob
0b69cead4d roll platform versions to 5.0 2000-03-15 18:49:44 +00:00
John Baldwin
7be31bb1b2 Remove some extra spammage that made it into this commit. This will be
revisited later with a better fix, or at least one that compiles. :)

Approved by:	dcs
2000-03-15 16:36:55 +00:00
Kirk McKusick
15e549f668 Bug fixes for currently harmless bugs that could rise to bite
the unwary if the code were called in slightly different ways.

1) In ufs_bmaparray() the code for calculating 'runb' will stop one block
short of the first entry in an indirect block. i.e. if an indirect block
contains N block numbers b[0]..b[N-1] then the code will never check if
b[0] and b[1] are sequential. For reference, compare with the equivalent
code that deals with direct blocks.

2) In ufs_lookup() there is an off-by-one error in the test that checks
if dp->i_diroff is outside the range of the the current directory size.
This is completely harmless, since the following while-loop condition
'dp->i_offset < endsearch' is never met, so the code immediately
does a second pass starting at dp->i_offset = 0.

3) Again in ufs_lookup(), the condition in a sanity check is wrong
for directories that are longer than one block. This bug means that
the sanity check is only effective for small directories.

Submitted by:	Ian Dowse <iedowse@maths.tcd.ie>
2000-03-15 07:18:15 +00:00
Kirk McKusick
9f043878d0 Use 64-bit math to decide if optimization needs to be changed.
Necessary for coherent results on filesystems bigger than 0.5Tb.

Submitted by:	Paul Saab <ps@yahoo-inc.com>
2000-03-15 07:08:36 +00:00
Brian Feldman
3841bf81f7 I _HATE_ crashes. The lptread() call needs to check LP_BYPASS, because
if one tries to use read() on an LP_BYPASS'd dev_t, the softc will be
initialized mainly with NULLs, so...
2000-03-15 03:23:04 +00:00
Daniel C. Sobral
7b12e51659 Pass an unit number to bcache_strategy, so it can flush the cache when
necessary. Pass an absolute block number too, instead of receiving a
relative one in realstrategy(), as bcache_strategy() requires this.

The fix is sligthly different from the one in the PR.

PR:		17098
Submitted by:	John Hood <jhood@sitaranetworks.com>
2000-03-15 01:58:45 +00:00
Daniel C. Sobral
a5686d2f66 bcache_strategy() now receives an unit number, and keep track of what
was the last unit number received. If it changes, it flushes the cache.
Add bcache_flash().

The actual fix is sligthly different from the one in the PR.

PR:		17098
Submitted by:	John Hood <jhood@sitaranetworks.com>
2000-03-15 01:56:12 +00:00
Daniel C. Sobral
fbc9fa5059 Pass unit number to bcache_strategy(), so that the cache can be
flushed if the unit changes. Compute the absolute offset before
bcache_strategy() instead of after.

The actual fix is sligthly different for the one in the PR.

PR:		17098
Submitted by:	John Hood <jhood@sitaranetworks.com>
2000-03-15 01:53:34 +00:00
Archie Cobbs
c64c1c76b4 Have MGETHDR() always initialize m->m_pkthdr.rcvif to NULL.
In the past, not doing this has caused several hard to find
networking bugs, and the minor slowdown is deemed worthwhile.

Reviewed by:	wollman
2000-03-14 20:49:27 +00:00
Jeroen Ruigrok van der Werven
5949020620 Remove further vestiges of wd.
Submitted by:	sos
2000-03-14 17:21:17 +00:00
Jeroen Ruigrok van der Werven
4a447c7023 Get rid of wdc.
Submitted by:	Damieon Stark <visigoth@telemere.net>
2000-03-14 17:01:03 +00:00
Søren Schmidt
000da71aa4 Fix the spelling, and some minor tweaks on the ata device... 2000-03-14 16:47:59 +00:00
Jun Kuriyama
dc76063419 Print "previous type" correctly when INVARIANTS is defined.
Reviewed by:	current@FreeBSD.org
2000-03-14 14:58:04 +00:00
Bruce Evans
05ecdd7037 Don't try so hard to make the lower 16 bits of fsids unique. It tended
to recycle full fsids after only 16 mount/unmount's.  This is probably
too often for exported fsids.  Now we recycle the full fsids only
after 2^16 mount/ umount's and only ensure uniqueness in the lower 16
bits if there have been <= 256 calls to vfs_getnewfsid() since the
system started.
2000-03-14 14:19:49 +00:00
Ruslan Ermilov
d137714f11 Fix reporting of src and dst IP addresses for ICMP and generic IP packets.
PR:		17319
Submitted by:	Mike Heffner <spock@techfour.net>
2000-03-14 14:11:53 +00:00
Jeroen Ruigrok van der Werven
612a914d90 Remove wd entries.
Reviewed by:	sos
Approved by:	sos, phk, peter
2000-03-14 13:23:10 +00:00
Jeroen Ruigrok van der Werven
b2381471b9 Remove the wd driver from the i386 kernel options. 2000-03-14 13:18:14 +00:00
Jeroen Ruigrok van der Werven
844a81a990 Remove unused options.
Reviewed by:	sos
Approved by:	sos, phk, peter
2000-03-14 12:55:23 +00:00
Brian S. Dean
56fc73ff9b In 'ipcperm()', only call 'suser()' if it is actually required.
Previously, it was being called whether it was needed or not and the
ASU flag was being set (as a side affect of calling 'suser()') in
cases where superuser privileges were not actually needed.  This was
all pointed out to me by Bruce Evans.

Reviewed by:	bde
2000-03-13 23:00:08 +00:00
Archie Cobbs
a7dc837919 - Document updates in iface netgraph node type functionality
- Remove makefile hacks for opt_inet.h, etc: the KLD now supports
  whatever address families your kernel was compiled with automagically
2000-03-13 19:19:48 +00:00
Archie Cobbs
15ba31b9ad Updates to the ng_iface(8) netgraph node type:
- Make iface nodes removable on shutdown since FreeBSD now supports
    removable interfaces
  - Simplify supporting new protocols using family_enqueue(); add a
    few new ones including IPv6
  - Add support for configurable interface mode using new
    NGM_IFACE_POINT2POINT and NGM_IFACE_BROADCAST control messages
  - Remove NGM_IFACE_GET_IFADDRS control message; it just duplicates
    the functionality of SIOCGIFCONF
2000-03-13 19:18:10 +00:00
Archie Cobbs
9a9a26fd5a Some minor prototype tweaks. 2000-03-13 19:05:11 +00:00
Archie Cobbs
af207f2160 Use snprintf() instead of sprintf(). 2000-03-13 18:54:10 +00:00
Archie Cobbs
c1b9e5f25b Fix typo: "ng_parse_fixedsstring_info" -> "ng_parse_fixedstring_info" 2000-03-13 18:50:38 +00:00
Bill Fumerola
1df05fbeab Welcome to 5.0-CURRENT. (__FreeBSD_version = 500000)
Approved by:	jkh, phk
2000-03-13 18:44:36 +00:00
Archie Cobbs
ef02c1e500 Fix typo.
Reported by:	Robert Swindells <swindellsr@genrad.co.uk>
2000-03-13 18:29:58 +00:00
Matt Jacob
6ca3a52f59 Don't do bus resets for ULTRA2 or later cards because what seems to
happen currently is that several commands issued *after* the bus reset are
then reported destroyed.
2000-03-13 16:30:00 +00:00
Bruce Evans
03e4dc0805 Fixed a spelling error that disabled the rc driver. 2000-03-13 15:29:47 +00:00
Nick Sayer
c36837a8d8 Fix some style bugs. The long line is in a chunk of code that's
being rewritten, though.

Submitted by:	bde
2000-03-13 15:27:19 +00:00
Bruce Evans
311b554beb Disabled the optimization of not doing an invltlb_1pg() when changing
pte's from zero.  The TLB is supposed to be invalidated when pte's are
changed _to_ zero, but this doesn't occur in all cases for global pages
(PG_G stops invltlb() from working, and invltlb_1pg() is not used
enough).

PR:		14141, 16568
Submitted by:	dillon
2000-03-13 14:47:46 +00:00
Matthew N. Dodd
01f1828bbb Add 'bootverbose' debug messages to assist with tracking down problems
some users have encountered.
2000-03-13 12:27:21 +00:00
Søren Schmidt
0d611a6c29 Cleanup sweep. 2000-03-13 12:27:11 +00:00
Matthew N. Dodd
c7a9e0529c Initial ifmedia support. Once I figure out autoselection I'll put the
rest of the code in (so changing media actually works.)

Add a few more register definitions for use with this and other new code.

Print a few details in the probe message; this should be useful in
bug reports and such but should not add to the clutter.
2000-03-13 12:23:32 +00:00
Søren Schmidt
cfb21bbb7d Enable disksort the right way both on ATA disks and ATAPI devices. 2000-03-13 12:04:58 +00:00
Matthew N. Dodd
958795f321 Copy how everyone else is doing packet transmission. (NetBSD mostly)
I've been running this for a month or so and have had no problems with it
and if I recall it was my last speed tweak.  Holler if this breaks anything.
2000-03-13 11:59:21 +00:00
Matthew N. Dodd
6629a1f812 Follow the docs a bit more in epstop() with respect to delays.
Trivial formatting.
2000-03-13 11:55:09 +00:00
Matthew N. Dodd
4a18218d69 Get rid of table lookup in favor of just subtracting. Everyone else
does it like this and I see no point in being different.
2000-03-13 11:51:44 +00:00
Matthew N. Dodd
d718250d48 Call epstop() in ep_attach(). While this shouldn't be necessary we'll
do it just in case.  (Actually, with PCMCIA cards we can get in a state
where it may be required.)
2000-03-13 11:48:03 +00:00
Matthew N. Dodd
4fa28dd1c6 Set the RF_SHAREABLE flage when we allocate an IRQ. 2000-03-13 11:43:53 +00:00
Ruslan Ermilov
ef61e9f97d Remove option MD5, it has been standardized almost two years ago. 2000-03-13 11:37:43 +00:00
Poul-Henning Kamp
4108e7b995 Remove #ifdef UVM stuff which will never be relevant. 2000-03-13 11:12:30 +00:00
Poul-Henning Kamp
7de472559c Remove unused 3rd argument from vsunlock() which abused B_WRITE. 2000-03-13 10:47:24 +00:00
Poul-Henning Kamp
d8b47cbb70 Stop isadma from abusing the B_READ, B_RAW and B_WRITE flags.
Define ISADMA_{READ,WRITE,RAW} macros with the same numeric
values as the B_{READ,WRITE,RAW} and use them instead throughout.
2000-03-13 10:19:32 +00:00
Yoshinobu Inoue
3f30603cfb Backout the previous change to __KAME_VERSION (FreeBSD4.x addition),
because this is now 5.0-current.
2000-03-13 10:07:30 +00:00
Warner Losh
02c988c53e Add another Linksys OUI.
PR:		16922
Submitted by:	takawata@shidahara1.planet.sci.kobe-u.ac.jp
2000-03-13 09:42:09 +00:00
Poul-Henning Kamp
5111e26e96 Updates for new FALC chips and other nits.
(And try to make it first post-freeze commit :-)
2000-03-13 09:13:36 +00:00
Jordan K. Hubbard
420e39abee Welcome to 5.0-current!
"First commit" claimed by:	jkh :)
2000-03-13 09:13:01 +00:00
Søren Schmidt
8048917432 Backout the previous fix, it is _not_ that easy too fix.
Leave it as is for 4.0 the real solution comes later.
2000-03-13 09:10:25 +00:00
Duncan Barclay
4ba3ca53cb * add the start_join_net - done
*	i needed it anyway
 * remove startccs and startcmd - done
 *	as those were used for the NetBSD start timeout
 * multicast - done but UNTESTED
 *	I don't have the ability/facilty to test this
 * rxlevel - done
 *	stats reported via raycontrol
 * getparams ioctl - done
 *	reported via raycontrol
 * start_join_done needs a restart in download_done - done
 *	now use netbsd style start up

removed spare timerh

implemented start_assoc in ray_ccs_done

bit more knfing
2000-03-12 22:54:29 +00:00
Duncan Barclay
2143635f71 structure for error counters added 2000-03-12 22:52:00 +00:00
Duncan Barclay
aadc434b25 Use ssid length from 80211.h
moved and extended ioctl's

added string and size definitions for raycontrol
2000-03-12 22:51:33 +00:00
Yoshinobu Inoue
eb7006c008 Change __KAME_VERSION value. Added the word "FreeBSD4.x" to identify the
system with other platform and/or other version of FreeBSD, which is also
integrated KAME code based on another date.

Approved by: jkh
2000-03-12 20:27:26 +00:00
Bruce Evans
61214975da Try harder to make the lower 16 bits of fsids unique. The vfs type
number was packed very wastefully, giving perfect non-uniqeness in
the lower 16 bits of fsids for filesystems with the same vfs type.
This made linux_stat() return perfectly non-unique (broken) 16-bit
st_dev's for nfs mount points, and effectively reduced mntid_base to
8 bits so that the vfs_getnewfsid() looped endlessly when there are
already 256 mounted filesystems with the required vfs type.

Approved by:	jkh
2000-03-12 14:23:21 +00:00
Søren Schmidt
4c435787ab Dont call ad_start unless the controller is idle.
This effectively nullified the usefullness of disksort().
2000-03-12 13:56:05 +00:00
KATO Takenori
5a9a82e820 Merged from sys/isa/sio.c revision 1.291. 2000-03-12 13:14:51 +00:00
Greg Lehey
b6c7afd32c sdio: If sd I/O fails because of an I/O error, set the sd state
correctly.

Reported-by:	phk
Approved-by:	jkh
2000-03-12 05:05:41 +00:00
Chris Piazza
4951dddb33 Recognize newer NVidia graphics cards. (GeForce and Quadro families)
Approved by:	jkh
2000-03-12 01:24:15 +00:00
Yoshinobu Inoue
820b57927e Disable IPv4 over IPv4 tunnel on the 6to4 interface for better security.
Approved by: jkh
2000-03-11 22:11:57 +00:00
Yoshinobu Inoue
dd251c3820 Forbid include of netinet6/ip6.h from user-land, and if included,
print an error message which say, "include netinet/ip6.h".
This is postponed to apply to avoid tcpdump compile error.
Now apply this because tcpdump has been already fixed.

Approved by: jkh

Obtained from: KAME project
2000-03-11 20:44:53 +00:00
Warner Losh
633f93bee5 Fix crashes on card eject for pccard modems. We check for NULL when
we get the com address.  If so, we go ahead and return.  Bruce thinks
there's a bug in the pccard layer that it terminates devices with
extreme prejustice rather than letting them deside for themselves when
to terminate (and he's likely right).  This fix doesn't change that,
but instead works around it by checking for NULL pointers at more
places than before.

The detach routine still calls functions at interrupt level that
aren't reentrant.  In theory this could cause a problem, but none
showed up in practice.  Future versions should correct this problem,
likely by making the detach process a thread/process at the pccard
level.  NEWCARD will do this, and the current pccard layer should
likely be modified to that as well, should it live long enough.

A few style nits of the same form that were in my original patch sent
off to bde were also fixed as part of this process.  Mostly use of
!ptr and return ENOPARENS.

This should prevent a crash on suspend with an active ppp link as
well, but that wasn't tested.

Reviewed by:	bde
Approved by:	jkh
2000-03-11 20:22:09 +00:00
Yoshinobu Inoue
8fca8c97c6 Replace m_pkthdr.rcvif with oif when oif is not NULL, to count
icmp6 error statistics based on sending interface.
This also prevent kernel panic when rcvif is not initialized after M_PKTHDR().
(The initialization issue also need to be fixed in the future.)

Approved by: jkh

Submitted by: k-sugyou@kame.net
2000-03-11 20:03:22 +00:00
Yoshinobu Inoue
19a938aa3d Fix sockaddr_storage related macro definition, as ss_family member type change.
(Currently, no effect but for future portability)

Approved by: jkh

Reviewed by: bde
2000-03-11 19:51:04 +00:00
Duncan Barclay
0f5987ecaf Remove old hand crafted version of start_join_net for download. 2000-03-11 13:34:13 +00:00
Duncan Barclay
ec1be5631b Start to use ray_start_join_net (my old code removed on next checkin)
requires current and desired network parameters, so I have created a network parameter structure and used two on them in the softc. This gives a bit of room of expansion. Re-wrote the update check in _net to work with this.

Tidyed up softc due to above.

Removed startccs and startcmd as they were only used by NetBSDs startup timeout.
2000-03-11 13:25:33 +00:00
Yoshinobu Inoue
4739b8076f IPv6 6to4 support.
Now most big problem of IPv6 is getting IPv6 address
   assignment.
   6to4 solve the problem. 6to4 addr is defined like below,

          2002: 4byte v4 addr : 2byte SLA ID : 8byte interface ID

   The most important point of the address format is that an IPv4 addr
   is embeded in it. So any user who has IPv4 addr can get IPv6 address
   block with 2byte subnet space. Also, the IPv4 addr is used for
   semi-automatic IPv6 over IPv4 tunneling.

   With 6to4, getting IPv6 addr become dramatically easy.
   The attached patch enable 6to4 extension, and confirmed to work,
   between "Richard Seaman, Jr." <dick@tar.com> and me.

Approved by: jkh

Reviewed by: itojun
2000-03-11 11:17:24 +00:00
Kazutaka YOKOTA
a68d00e3fe One more patch for the atkbd driver. It will make sure that the
keyboard port and interrupt is enabled and the driver is attached even
when the keyboard itself is not present when the system is booting.
(This has been the behavior through out 2.X and 3.X, but is somehow
broken in 4.0.)

# I certainly don't recommend people to `hot-plug' the AT keyboard,
# because the interface isn't designed for hot-plugging and such act
# will often break the keyboard controller.  But, so many people want to
# do that anyway...

Approved by: jkh
2000-03-11 07:44:10 +00:00
Mike Smith
510a809e64 Teach the 'dc' driver how to pick up settings left over by the
SRM on alpha systems.  This is an expedient if not entirely
elegant solution to the problem.

Submitted by:	gallatin
Approved by:	jkh
2000-03-11 05:20:56 +00:00
Robert Watson
76ec7b2f60 The function arpintr() incorrectly checks m->m_len to detect incomplete
ARP packets. This can incorrectly reject complete frames since the frame
could be stored in more than one mbuf.

The following patches fix the length comparisson, and add several
diagnostic log messages to the interrupt handler for out-of-the-norm ARP
packets. This should make ARP problems easier to detect, diagnose and
fix.

Submitted by:	C. Stephen Gunn <csg@waterspout.com>
Approved by:	jkh
Reviewed by:	rwatson
2000-03-11 00:24:29 +00:00
Søren Schmidt
924f6734a5 Cosmetics.. 2000-03-10 22:10:34 +00:00
Archie Cobbs
8081ce2ea7 Correct man page title. 2000-03-10 20:38:24 +00:00
Martin Cracauer
0c14a6606b Change the default FPU control word so that exceptions for new
processes are now masked until set by fpsetmask(3).

Submitted by:	bde
Approved by:	jkh, bde
2000-03-10 17:56:33 +00:00
KATO Takenori
e299a9db22 Merged from sys/isa/sio.c revisions 1.289 and 1.290. 2000-03-10 10:34:36 +00:00
Alan Cox
af25d10c91 shmat: If VM_PROT_READ_IS_EXEC is defined and prot includes VM_PROT_READ,
VM_PROT_EXECUTE must be added to prot before calling vm_map_find.

Without this change, an mprotect on a shmat'ed region fails (when
it shouldn't).  This bug was reported Feb 28 by Brooks Davis
<brooks@one-eyed-alien.net> on -hackers.

Reviewed by:	bde
Approved by:	jkh
2000-03-10 09:11:24 +00:00
Søren Schmidt
643b70ec9d Dont call make_dev until we are sure the device is there, this prevents
panic'ing when the device is tried accessed later.
2000-03-10 08:09:53 +00:00
Warner Losh
595166f0f7 Add support for PnP ISA cards, and some laptop PnP support:
o break out some of the probe routine the allocation of resources
  into an attach routine
o Recognize PnP ids
o Allocate IRQ per card rather than per system
o Better polling reporting
o Remove unneeded include files in slot.h
o store a pseudo unit number on each device we find.
o Pass a unit number to interrupt/timeout routine and use it for polling
  the hardware.

Tested on: My VAIO and with the Linksys pccard reader.
Approved by: jkh
2000-03-10 05:43:29 +00:00
Warner Losh
8663154bbc Correct PnP ids for pcic-like cards.
Approved by: jkh
2000-03-10 05:26:32 +00:00
Duncan Barclay
5a5368a86c Use the ccs update command mechanism for dowloading parameters on startup 2000-03-09 21:34:47 +00:00
Hellmuth Michaelis
17df19190a Fix a problem which caused i/o resource allocation conflict of this
particular ISDN card with the 2nd IDE controller and/or other cards
depending on configuration.

The amount of i/o ports allocated are reduced from 0x40 per range to
0x20 per range.

Submitted by:	Andrew Gordon <arg@arg1.demon.co.uk>
Approved by:	jkh
2000-03-09 20:57:47 +00:00
Robert Watson
c8cf61e182 Introduce ethernet bridge support for if_dc
Approved by:	jkh
2000-03-09 19:28:19 +00:00
Matthew Dillon
b39d4d2060 In the 'found' case for ufs_lookup() the underlying bp's data was
being accessed after the bp had been releaed.  A simple move of the
    brelse() solves the problem.

Approved by: jkh
Submitted by:  Ian Dowse <iedowse@maths.tcd.ie>
2000-03-09 18:54:59 +00:00
Marcel Moolenaar
3c1124cfdf Fix bug in linux_wait4 and linux_waitpid where garbage in the status
argument could panic the kernel.

Submitted by: Ian Dowse <iedowse@maths.tcd.ie>
Prompted by: jkh, gallatin
Approved by: prompters
2000-03-09 17:52:01 +00:00