Commit Graph

111680 Commits

Author SHA1 Message Date
Sam Leffler
2c21ffc8f5 noop change so RUN->RUN transition isn't considered invalid
(it happens on ibss merge)
2005-01-24 20:39:29 +00:00
Sam Leffler
5a11fbca83 add macros to convert between txop's and usecs 2005-01-24 20:38:26 +00:00
Sam Leffler
d3be6f5b0c Fixup radiotap handling of FCS and QoS frames per discussion with David Young:
o mark rx frames including FCS in the payload with the
  IEEE80211_RADIOTAP_F_FCS flag
o remove hack to copy 802.11 headers with padding out of line; instead mark
  the frames with IEEE80211_RADIOTAP_F_DATAPAD and require applications to
  do the work
o split precalculated radiotap flags into tx+rx now that they can be different

Note the full usefulness of these changes depends on updates to applications
that process radiotap data.
2005-01-24 20:31:24 +00:00
Philippe Charnier
8a579692b2 spell "file system" correctly
Approved by:	ru
2005-01-24 20:06:16 +00:00
Sam Leffler
f818612b1b beacon handling fixups for adhoc mode:
o don't reclaim any previous beacon state in ath_beacon_alloc; do it
  explicitly in ath_newstate
o reference count the node held in the beacon frame state block
o process ibss merge more intelligently; let the state machine do the
  right thing instead of explicitly setting the new bssi id
o explicitly stop tx dma before doing beacon setup to handle the ibss
  merge case
2005-01-24 20:05:03 +00:00
Philippe Charnier
0257709b51 spell "file system" correctly
Approved by:	 ru
2005-01-24 20:01:28 +00:00
Philippe Charnier
440e84f59e spell "file system" correctly
Approved by:	ru
2005-01-24 19:58:05 +00:00
Sam Leffler
f9e6219b15 switch to use bus_dmamap_load_mbuf_sg 2005-01-24 19:51:59 +00:00
Sam Leffler
4bacf7c1f3 o correct beacon interval calculation; the internal setting is in TU's not ms
o replace the private macro to convert MS->TU with the common one
2005-01-24 19:45:59 +00:00
Sam Leffler
2ffc548f43 o clarify that beacon interval settings are in TU's, not ms
o add macros to convert between TU's and ms
2005-01-24 19:39:07 +00:00
Sam Leffler
acc4f7f50c statically allocate the station/neighbor node table; the deferred
allocation scheme introduced a race condition during device state
transitions
2005-01-24 19:32:10 +00:00
Warner Losh
7d98fccaf3 There have been a substantial number of changes to this file from the
NetBSD original, so add our copyright notice as well.
2005-01-24 19:13:47 +00:00
Bill Paul
df7b7cf4c3 Begin the first phase of trying to add IRP support (and ultimately
USB device support):

- Convert all of my locally chosen function names to their actual
  Windows equivalents, where applicable. This is a big no-op change
  since it doesn't affect functionality, but it helps avoid a bit
  of confusion (it's now a lot easier to see which functions are
  emulated Windows API routines and which are just locally defined).

- Turn ndis_buffer into an mdl, like it should have been. The structure
  is the same, but now it belongs to the subr_ntoskrnl module.

- Implement a bunch of MDL handling macros from Windows and use them where
  applicable.

- Correct the implementation of IoFreeMdl().

- Properly implement IoAllocateMdl() and MmBuildMdlForNonPagedPool().

- Add the definitions for struct irp and struct driver_object.

- Add IMPORT_FUNC() and IMPORT_FUNC_MAP() macros to make formatting
  the module function tables a little cleaner. (Should also help
  with AMD64 support later on.)

- Fix if_ndis.c to use KeRaiseIrql() and KeLowerIrql() instead of
  the previous calls to hal_raise_irql() and hal_lower_irql() which
  have been renamed.

The function renaming generated a lot of churn here, but there should
be very little operational effect.
2005-01-24 18:18:12 +00:00
Ruslan Ermilov
f000229472 Markup and grammar fixes. 2005-01-24 18:14:18 +00:00
Warner Losh
6c1b1bbc71 Add an entry for Magic Ram, Inc's ETHERNET PC CARD 933926 card I just
won on ebay.  Also, add a pointer to the PCMCIA's web site for the
registered tuples (== manufacturer ID's).
2005-01-24 17:59:59 +00:00
Maxim Konovalov
19beed5e2e o Reorganize the previous delta to make it more style(9) compliant.
Submitted by:	ru

o Reduce an amount of memory we ask in advance.
2005-01-24 17:01:48 +00:00
Robert Watson
ed41980cbb When "no_ccache" is set as an argument to the pam_krb5 module, don't
copy the acquired TGT from the in-memory cache to the on-disk cache
at login.  This was documented but un-implemented behavior.

MFC after:		1 week
PR:			bin/64464
Reported and tested by:	Eric van Gyzen <vangyzen at stat dot duke dot edu>
2005-01-24 16:49:50 +00:00
Yaroslav Tykhiy
cab574d841 Fix spelling in a comment. 2005-01-24 15:48:00 +00:00
Bruce M Simpson
a0fba9baed Fix NULL pointer dereference bug when parsing IPV6CP traffic.
This file is already off the vendor branch, and the fix will be
in future tcpdump.org vendor branch imports.

PR:		bin/76497
MFC after:	1 week
Obtained from:	tcpdump.org rev 1.89.2.4
Discussed with:	fenner, keramida
2005-01-24 14:56:48 +00:00
Poul-Henning Kamp
f6dc414a5c Save a line by unlocking before we test. 2005-01-24 14:13:24 +00:00
Poul-Henning Kamp
7c93282e42 Change vprint() to vn_printf() which takes varargs.
Add #define for vprint() to call vn_printf().
2005-01-24 13:58:08 +00:00
Gleb Smirnoff
19724144d6 Fix an evil typo.
Submitted by:	Roselyn Lee
MFC after:	3 days
2005-01-24 13:32:19 +00:00
Poul-Henning Kamp
94cd47b1ac Remove unused cred argument to ext2_reload() 2005-01-24 13:31:22 +00:00
Maxim Konovalov
66658902ed o Try hard to guess a buffer size for a fast growing routing table.
An approach taken from killall/killall.c.

PR:		bin/76075
Submitted by:	Dmitrij Tejblum
MFC after:	3 weeks
2005-01-24 13:27:24 +00:00
Poul-Henning Kamp
35764be39e Kill the VV_OBJBUF and test the v_object for NULL instead. 2005-01-24 13:13:57 +00:00
Poul-Henning Kamp
027b1f716c Fix a list corruption issue in cloning device management using the
western strategy ("allocate first, ask questions later") so we can
extend the devmtx coverage to the clone list.
2005-01-24 12:44:56 +00:00
Poul-Henning Kamp
d34dd851b8 Remove "register" keywords. 2005-01-24 12:37:51 +00:00
Poul-Henning Kamp
56dd36b1a6 Remove unused cred arg from nfs_vinvalbuf() and many bogus arguments
passed for it.
2005-01-24 12:31:06 +00:00
Gleb Smirnoff
90d52f2f21 - Convert so_qlen, so_incqlen, so_qlimit fields of struct socket from
short to unsigned short.
- Add SYSCTL_PROC() around somaxconn, not accepting values < 1 or > U_SHRTMAX.

Before this change setting somaxconn to smth above 32767 and calling
listen(fd, -1) lead to a socket, which doesn't accept connections at all.

Reviewed by:	rwatson
Reported by:	Igor Sysoev
2005-01-24 12:20:21 +00:00
Poul-Henning Kamp
091710ab22 Polish style. 2005-01-24 12:19:28 +00:00
Poul-Henning Kamp
a515233f47 Style: Remove the commented out vop_foo_args replicas. 2005-01-24 11:49:41 +00:00
George V. Neville-Neil
f579625397 Update man pages to be in line with guidelines for IPv6 in FreeBSD.
FreeBSD currently implements the most up to date IPv6 APIs for
option and route header parsing.   This checkin marks the older APIs
as deprecated and points the reader to the newer pages.

Reviewed by: Jun-ichiro Itojun
Approved by: rwatson (mentor)
2005-01-24 11:23:14 +00:00
Jeff Roberson
ccaba75608 - Somehow I mangled KTR_CRITICAL.
Spotted by:	ru
2005-01-24 10:52:32 +00:00
Jeff Roberson
e1279468ec - Regen for recent vfs syscall changes.
Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:50:42 +00:00
Jeff Roberson
29ed48fc6a - Change all VFS syscalls to MSTD as they all manually deal with giant
or the appropriate filesystem locks.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:49:26 +00:00
Jeff Roberson
ae51ff1127 - Remove GIANT_REQUIRED where giant is no longer required.
- Use VFS_LOCK_GIANT() rather than directly acquiring giant in places
   where giant is only held because vfs requires it.

Sponsored By:   Isilon Systems, Inc.
2005-01-24 10:48:29 +00:00
Jeff Roberson
e9f3e3f8ca - Don't acquire giant around calls to bufdone().
Sponsored By:   Isilon Systems, Inc.
2005-01-24 10:47:46 +00:00
Jeff Roberson
71ddd673b1 - Add CTR calls to trace the lifecycle of a buffer.
- Remove some KASSERTs which are invalid if the appropriate lock is
   not held.
 - Slightly restructure bremfree() so that it is more sane.
 - Change the flush code in bdwrite() to avoid acquiring a mutex
   whenever possible.
 - Change the flush code in bdwrite() to avoid holding the bufobj mutex
   while calling buf_countdeps().  This introduces a lock-order
   relationship with the softdep lock that can not otherwise be resolved.
 - Don't set B_DONE until bufdone() is complete, otherwise another
   processor may believe the buf is done before it is.
 - Only acquire Giant if the caller has set b_iodone.  Don't grab giant
   around normal bufdone() calls.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:47:04 +00:00
Jeff Roberson
d1fcf3bb31 - Add the tunable and sysctl for the mpsafevfs. It currently defaults
to off.
 - Protect access to mnt_kern_flag with the mointpoint mutex.
 - Remove some KASSERTs which are not legal checks without the appropriate
   locks held.
 - Use VCANRECYCLE() rather than rolling several slightly different
   checks together.
 - Return from vtryrecycle() with a recycled vnode rather than a locked
   vnode.  This simplifies some locking.
 - Remove several GIANT_REQUIRED lines.
 - Add a few KASSERTs to help with INACT debugging.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:41:01 +00:00
Jeff Roberson
49bc5dcea6 - Add a VCANRECYCLE() which performs all the checks required to ensure
that we are free to release a vnode.
2005-01-24 10:34:58 +00:00
Jeff Roberson
791625d853 - Remove GIANT_REQUIRED where giant is no longer required.
Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:33:46 +00:00
Jeff Roberson
82d1b24c70 - Remove GIANT_REQUIRED where it is no longer required.
Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:32:14 +00:00
Jeff Roberson
f50a2d5e2d - Remove GIANT_REQUIRED where giant is no longer required.
- Protect access to mnt_kern_flag with the mountpoint mutex.
 - Use the appropriate nd flags to deal with giant in vn_open_cred().
   We currently determine whether the caller is mpsafe by checking
   for a valid fdidx.  Any caller coming from user-space is now
   mpsafe and supplies a valid fd.  No kenrel callers have been
   converted to mpsafe, so this check is sufficient for now.
 - Use VFS_LOCK_GIANT instead of manual giant acquisition where
   appropriate.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:31:42 +00:00
Jeff Roberson
fc48b760ac - Protect mnt_kern_flag with the mountpoint's mutex. This is required
to make the suspend related functions mpsafe.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:28:41 +00:00
Jeff Roberson
22a960a69c - Acquire and release Giant as we enter and leave filesystems which
require it.
 - Track the status of Giant with the nd flag HASGIANT.
 - Release giant on return of namei() callers are not marked MPSAFE as
   they already own giant.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:27:05 +00:00
Jeff Roberson
94a9458501 - Change all vfs syscalls to use VFS_LOCK_GIANT(), and MPSAFE nds.
- Move Giant acquisition into the few vfs syscalls that weren't already
   directly acquiring it.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:25:44 +00:00
Jeff Roberson
799cc2dcee - Simplify the cache locking. The lock order relationship with the
vnode lock is much simpler than I originally thought it would be.
   Now, the cache lock is  always acquired before the vnode lock.
 - Provide some gotos in __getcwd() to simplify the unlocking a bit.
 - Move Giant acquisition down into __getcwd().

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:24:12 +00:00
Jeff Roberson
41bd6c15f2 - Do not use APAUSE if LK_INTERLOCK is set. We lose synchronization
if the lockmgr interlock is dropped after the caller's interlock
   is dropped.
 - Change some lockmgr KTRs to be slightly more helpful.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:20:59 +00:00
Jeff Roberson
66ca1b4878 - Use VFS_LOCK_GIANT() in place of mtx_lock(&giant), etc.
Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:19:31 +00:00
Jeff Roberson
08023360a0 - Convert the global LK lock to a mutex.
- Expand the scope of lk to cover not only interrupt races, but also
   top-half races, which includes many new uses over global top-half
   only data.
 - Get rid of interlocked_sleep() and use msleep or BUF_LOCK where
   appropriate.
 - Use the lk mutex in place of the various hand rolled semaphores.
 - Stop dropping the lk lock before we panic.
 - Fix getdirtybuf() callers so that they reacquire access to whatever
   softdep datastructure they were inxpecting in the failure/retry
   case.  Previously, sleeps in getdirtybuf() could leave us with
   pointers to bad memory.
 - Update handling of ffs to be compatible with ffs locking changes.

Sponsored By:	Isilon Systems, Inc.
2005-01-24 10:18:31 +00:00