]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
19 years agoAdd a boatload of new device ids, gleaned from the pcmcia-cs-3.2.8
imp [Sun, 10 Jul 2005 02:00:35 +0000 (02:00 +0000)]
Add a boatload of new device ids, gleaned from the pcmcia-cs-3.2.8
distribution.  Add the appropriate devices to the man pages.

Obtained from: pcmcia-cs
Approved by: re (scottl)

19 years agoremove driver-private key allocators; use the default one instead
sam [Sun, 10 Jul 2005 00:17:05 +0000 (00:17 +0000)]
remove driver-private  key allocators; use the default one instead
so wpa keys are handled properly

Reviewed by: avatar
Approved by: re (scottl)

19 years agoChange default key allocation method to do the right thing for
sam [Sat, 9 Jul 2005 23:15:30 +0000 (23:15 +0000)]
Change default key allocation method to do the right thing for
legacy parts (i.e. those that have 4 global key slots).  We
blindly assign unicast keys to key slot 0.  Devices that need
alternate allocation logic must override this method.

Reviewed by: avatar
Approved by: re (scottl)

19 years ago- Grammar fixes
markus [Sat, 9 Jul 2005 19:04:43 +0000 (19:04 +0000)]
- Grammar fixes
- s/spdcontrol/sdpcontrol/

Approved by: re (hrs, rwatson), brueffer
MFC after: 3 days

19 years agoRepair this:
cracauer [Sat, 9 Jul 2005 18:30:31 +0000 (18:30 +0000)]
Repair this:

ext2fs fails to set the device in the stat(2) system call.

Subsequently, that makes fts(3) fail, which goes as far as make ls(1)
fail (which uses fts) on ext2fs.

Approved by: re (Robert Watson <rwatson@FreeBSD.org>)

19 years agosys/dev/hwpmc/hwpmc_{amd,piv,ppro}.c:
jkoshy [Sat, 9 Jul 2005 17:29:36 +0000 (17:29 +0000)]
sys/dev/hwpmc/hwpmc_{amd,piv,ppro}.c:
- Update driver interrupt statistics correctly.

sys/sys/pmc.h, sys/dev/hwpmc/hwpmc_mod.c:
- Fix a bug affecting debug printfs.
- Move the 'stalled' flag from being in a bit in the
  'pm_flags' field of a 'struct pmc' to a field of its own in the
  same structure.  This flag is updated from the NMI handler and
  keeping it separate makes it easier to avoid races with other
  parts of the code.

sys/dev/hwpmc/hwpmc_logging.c:
- Do arithmetic with 'uintptr_t' types rather that casting
  to and from 'char *'.

Approved by: re (scottl)

19 years agoNew release notes:
hrs [Sat, 9 Jul 2005 17:26:10 +0000 (17:26 +0000)]
New release notes:
amd64/i386 ELF kernel crash dump,
snd_csa(4) suspend/resume support,
ste(4) ALTQ support,
address family check of routing table added,
env(1) -v, -S, and -P options added,
libkvm crash dump support improvement:
ELF format, >4GB on 32-bit arch, and PAE,
$jail_<name>_flags for rc.d/jail added, and
new manual pages: central(4), clkbrd(4), creator(4),
ebus(4), eeprom(4), fhc(4),  machfb(4), ofw.console(4),
openfirm(4), openprom(4), rtc(4), and sbus(4).

Update release notes:
Use &man.ofw.console.4;.

Approved by: re (implicitly)

19 years agoHave the NMI handler call the C language trap() routine and directly
jkoshy [Sat, 9 Jul 2005 17:19:46 +0000 (17:19 +0000)]
Have the NMI handler call the C language trap() routine and directly
exit via 'doreti_exit'.

Since the NMI interrupt may be taken at any time, including when
the processor has masked external interrupts, it is not safe to
call ast() as is done for normal interrupts.

Approved by: re (scottl)

19 years agoFix a bug in pmclog_read() that causes it to return with a false
jkoshy [Sat, 9 Jul 2005 17:12:30 +0000 (17:12 +0000)]
Fix a bug in pmclog_read() that causes it to return with a false
error when a log record crosses an internal buffer boundary.

Approved by: re (scottl)

19 years agoFix a bug that affected on-the-fly gmon.out file generation.
jkoshy [Sat, 9 Jul 2005 17:08:46 +0000 (17:08 +0000)]
Fix a bug that affected on-the-fly gmon.out file generation.

Approved by: re (scottl)

19 years agoUse m_length (m, NULL) instead of m->m_pkthdr.len.
rik [Sat, 9 Jul 2005 16:14:05 +0000 (16:14 +0000)]
Use m_length (m, NULL) instead of m->m_pkthdr.len.

Problems reported by: strijar at urai dot ru
Approved by: re (scottl)

19 years agoLost cx_mpsafenet check.
rik [Sat, 9 Jul 2005 14:31:48 +0000 (14:31 +0000)]
Lost cx_mpsafenet check.

Pointy hat: me
Approved by: re (scottl)

19 years agoLost t_oproc() callback assignment.
rik [Sat, 9 Jul 2005 14:27:35 +0000 (14:27 +0000)]
Lost t_oproc() callback assignment.

Pointyhats: phk (who lost it), me (who didn't notice that)
Approved by: re (scottl)

19 years agoLost CX_UNLOCK().
rik [Sat, 9 Jul 2005 14:23:42 +0000 (14:23 +0000)]
Lost CX_UNLOCK().

Pointy hat: me
Approved by: re (scottl)

19 years agoProtect from partially initialized channels.
rik [Sat, 9 Jul 2005 14:03:02 +0000 (14:03 +0000)]
Protect from partially initialized channels.

Approved by: re (scottl)

19 years agoRegrab dvp only when ISDOTDOT.
tanimura [Sat, 9 Jul 2005 13:52:49 +0000 (13:52 +0000)]
Regrab dvp only when ISDOTDOT.

Approved by: re (scottl)

19 years agoSpace & alignment nits.
rik [Sat, 9 Jul 2005 13:44:36 +0000 (13:44 +0000)]
Space & alignment nits.

Approved by: re (scottl)

19 years agoSome cleanups and tweaks to some of the atomic.h files in preparation for
jhb [Sat, 9 Jul 2005 12:38:53 +0000 (12:38 +0000)]
Some cleanups and tweaks to some of the atomic.h files in preparation for
further changes and fixes in the future:
- Use aliases via macros rather than duplicated inlines wherever possible.
- Move all the aliases to the bottom of these files and the inline
  functions to the top.
- Add various comments.
- On alpha, drop atomic_{load_acq,store_rel}_{8,char,16,short}().
- On i386 and amd64, don't duplicate the extern declarations for functions
  in the two non-inline cases (KLD_MODULE and compiler doesn't do inlines),
  instead, consolidate those two cases.
- Some whitespace fixes.

Approved by: re (scottl)

19 years agoAdd Giant around linux_getcwd_common() in linux_getcwd().
jhb [Sat, 9 Jul 2005 12:34:49 +0000 (12:34 +0000)]
Add Giant around linux_getcwd_common() in linux_getcwd().

Approved by: re (scottl)

19 years agoAdd missing locking to linux_connect() so that it can be marked MP safe:
jhb [Sat, 9 Jul 2005 12:26:22 +0000 (12:26 +0000)]
Add missing locking to linux_connect() so that it can be marked MP safe:
- Conditionally grab Giant around the EISCONN hack at the end based on
  debug.mpsafenet.
- Protect access to so_emuldata via SOCK_LOCK.

Reviewed by: rwatson
Approved by: re (scottl)

19 years agoDocument that SOCK_LOCK is used to protect so_emuldata.
jhb [Sat, 9 Jul 2005 12:24:40 +0000 (12:24 +0000)]
Document that SOCK_LOCK is used to protect so_emuldata.

Approved by: re (scottl)

19 years ago The nsegs parameter to bus_dmamap_load_mbuf_sg is not required to
grehan [Sat, 9 Jul 2005 06:53:52 +0000 (06:53 +0000)]
 The nsegs parameter to bus_dmamap_load_mbuf_sg is not required to
be set to 0 on input. This caused a panic in an an MP test version
of the GEM driver from Marius, and from inspection of other PCI
drivers, the same problem would happen there.
 Fix by explicitly setting to 0.

Approved by:   re

19 years agoFix the build. The SMC_8020BT define doesn't exist yet.
scottl [Sat, 9 Jul 2005 05:14:32 +0000 (05:14 +0000)]
Fix the build.  The SMC_8020BT define doesn't exist yet.

Approved by: re (implicit)

19 years agoAdd Farrallon EtherMac PC Card to the list of supported cards.
imp [Sat, 9 Jul 2005 01:44:54 +0000 (01:44 +0000)]
Add Farrallon EtherMac PC Card to the list of supported cards.
Fix XJack card description to reflect the actual model that we support
(I've never seen a CC-10BT and I've been looking).
List the specific chipsets supported.
Bump date.

Approved by: re (scottl, indirectly due to driver approval)

19 years agoNoticed that NetBSD's sm driver has the PSION GOLDCARD listed, so list
imp [Sat, 9 Jul 2005 01:30:32 +0000 (01:30 +0000)]
Noticed that NetBSD's sm driver has the PSION GOLDCARD listed, so list
that since I can't test it directly.  The driver also lists the EM1144
as being supported, but in reality it isn't.  The EM1144-T,
{XJ,CC}{3288,3336} have the SMC chips in them, but aren't conformant MFC
cards, so they need their own driver.

Also, it does little harm to list the 8020BT, so remove #if 0.

Approved by: re (scottl)

19 years agocorrect check for high priority wme traffic
sam [Fri, 8 Jul 2005 22:49:26 +0000 (22:49 +0000)]
correct check for high priority wme traffic

Noticed by: Ralf Assmann
Reviewed by: apatti
Approved by: re (scottl)

19 years agoSync which ggate changes.
pjd [Fri, 8 Jul 2005 21:29:17 +0000 (21:29 +0000)]
Sync which ggate changes.

Approved by: re (scottl)

19 years agoReimplement ggatec/ggated applications.
pjd [Fri, 8 Jul 2005 21:28:26 +0000 (21:28 +0000)]
Reimplement ggatec/ggated applications.

Change communication protocol to be much more resistant on network
problems and to allow for much better performance.

Better performance is achieved by creating two connections between
ggatec and ggated one for sending the data and one for receiving it.
Every connection is handled by separeted thread, so there is no more
synchronous data flow (send and wait for response), now one threads
sends all requests and another receives the data.

Use two threads in ggatec(8):
- sendtd, which takes I/O requests from the kernel and sends them to the
  ggated daemon on the other end;
- recvtd, which waits for ggated responses and forwards them to the kernel.

Use three threads in ggated(8):
- recvtd, which waits for I/O requests and puts them onto incoming queue;
- disktd, which takes requests from the incoming queue, does disk operations
  and puts finished requests onto outgoing queue;
- sendtd, which takes finished requests from the outgoing queue and sends
  responses back to ggatec.

Because there were major changes in communication protocol, there is no
backward compatibility, from now on, both client and server has to run
on 5.x or 6.x (or at least ggated should be from the same FreeBSD version
on which ggatec is running).

For Gbit networks some buffers need to be increased. I use those settings:
kern.ipc.maxsockbuf=16777216
net.inet.tcp.sendspace=8388608
net.inet.tcp.recvspace=8388608
and I use '-S 4194304 -R 4194304' options for both, ggatec and ggated.

Approved by: re (scottl)

19 years agoAdd CANCEL command which allows to remove one request from the queue or
pjd [Fri, 8 Jul 2005 21:08:53 +0000 (21:08 +0000)]
Add CANCEL command which allows to remove one request from the queue or
all requests from the queue if request number is not given.

Bump version number.

Approved by: re (scottl)

19 years agooops ... forgot to declare sc in my previous commit. unbreak build.
damien [Fri, 8 Jul 2005 19:33:42 +0000 (19:33 +0000)]
oops ... forgot to declare sc in my previous commit.  unbreak build.

Approved by: re (scottl)

19 years agofix allocation of rx dma buffers. buffers must be contiguous.
damien [Fri, 8 Jul 2005 19:30:29 +0000 (19:30 +0000)]
fix allocation of rx dma buffers.  buffers must be contiguous.

Approved by: re (scottl)

19 years agodocument ENABLE_WPA_SUPPLICANT_EAPOL
sam [Fri, 8 Jul 2005 19:26:55 +0000 (19:26 +0000)]
document ENABLE_WPA_SUPPLICANT_EAPOL

Approved by: re (scottl)

19 years agoMake sure that all the necessary USB endpoints are found during device
damien [Fri, 8 Jul 2005 19:19:06 +0000 (19:19 +0000)]
Make sure that all the necessary USB endpoints are found during device
attachment.

Reviewed by: silby (mentor)
Approved by: re (scottl)

19 years agoral_init() takes a struct ral_softc as parameter not a struct ifnet.
damien [Fri, 8 Jul 2005 19:13:49 +0000 (19:13 +0000)]
ral_init() takes a struct ral_softc as parameter not a struct ifnet.
Fixes a panic that occured when setting the interface parameters while
the interface was associated.

Approved by: re (scottl)

19 years agoUse implicit type cast for ->k_lock to fix compilation of ndis
rik [Fri, 8 Jul 2005 18:36:59 +0000 (18:36 +0000)]
Use implicit type cast for ->k_lock to fix compilation of ndis
as a part of the GENERIC kernel with INVARIANT* and WITNESS*
turned off.
(For non GENERIC kernel KTR and MUTEX_PROFILING should be also
off).

Submitted by: Eygene A. Ryabinkin <rea at rea dot mbslab dot kiae dot ru>
Approved by: re (scottl)
PR: 81767

19 years agofix another instance of the MORE_DATA bit handling for frames on the
sam [Fri, 8 Jul 2005 16:36:02 +0000 (16:36 +0000)]
fix another instance of the MORE_DATA bit handling for frames on the
power save queue (missed in previous commit)

Submitted by: Bruno Randolf
Approved by: re (scottl)

19 years agohandle RTM_IFINFO events so we terminate when an interface is
sam [Fri, 8 Jul 2005 16:33:52 +0000 (16:33 +0000)]
handle RTM_IFINFO events so we terminate when an interface is
marked down

Reviewed by: brooks, avatar
Approved by: re (scottl)

19 years agoreclaim node reference when ieee80211_encap fails
sam [Fri, 8 Jul 2005 16:31:19 +0000 (16:31 +0000)]
reclaim node reference when ieee80211_encap fails

Reviewed by: avatar
Approved by: re (scottl)

19 years agoupdate ural ids
sam [Fri, 8 Jul 2005 16:28:24 +0000 (16:28 +0000)]
update ural ids

Reviewed by: damien
Approved by: re (scottl)
Obtained from: openbsd

19 years agoRegen.
jhb [Fri, 8 Jul 2005 15:06:58 +0000 (15:06 +0000)]
Regen.

Approved by: re (scottl)

19 years agoMark second instance of lchown() MP safe just like the first.
jhb [Fri, 8 Jul 2005 15:01:13 +0000 (15:01 +0000)]
Mark second instance of lchown() MP safe just like the first.

Approved by: re (scottl)

19 years agoMissed one piece of the cluster's quirk. Need to override WARNS because
kensmith [Fri, 8 Jul 2005 14:53:45 +0000 (14:53 +0000)]
Missed one piece of the cluster's quirk.  Need to override WARNS because
if _FREEFALL_CONFIG is set gcc bails since pam_sm_setcred() in pam_krb5.c
no longer uses any of its parameters.

Pointy hat: kensmith
Approved by: re (scottl)

19 years agoMerge the following from the English version:
den [Fri, 8 Jul 2005 14:34:10 +0000 (14:34 +0000)]
Merge the following from the English version:

   1.879 -> 1.880 new.sgml

Obtained from:  The FreeBSD Russian Documentation Project
Approved by:    re (scottl)

19 years agoALTQify ste(4).
mlaier [Fri, 8 Jul 2005 13:05:59 +0000 (13:05 +0000)]
ALTQify ste(4).

Requested and tested by: <nike_d at cytexbg dot com>
Approved by: re (scottl)

19 years agoThis commit was generated by cvs2svn to compensate for changes in r147824,
obrien [Thu, 7 Jul 2005 22:06:54 +0000 (22:06 +0000)]
This commit was generated by cvs2svn to compensate for changes in r147824,
which included commits to RCS files with non-trunk default branches.

19 years agoFix bogus fmov* SPARC opcodes.
obrien [Thu, 7 Jul 2005 22:06:54 +0000 (22:06 +0000)]
Fix bogus fmov* SPARC opcodes.
(Note this makes the vendor branch not represent Binutils in the vendor's
CVS repository at any point in time.  Portmgr did not like the state of
Binutils on Sparc that represented the point in time the vendor fixed this
issue.  I'd rather have fixed this on RELENG_6.)

Approved by: re

19 years agoPatch the freebsd spec file for PowerPC so that PIC code builds correctly.
scottl [Thu, 7 Jul 2005 21:40:37 +0000 (21:40 +0000)]
Patch the freebsd spec file for PowerPC so that PIC code builds correctly.
This allows FreeBSD/PPC to build and run out of stock CVS sources.  This
also takes the file off of the vendor branch.

Submitted by: kan, grehan
Approved by: re, kan

19 years agoLock Giant around a call to userland_sysctl() in ibcs2_sysi86().
jhb [Thu, 7 Jul 2005 19:30:30 +0000 (19:30 +0000)]
Lock Giant around a call to userland_sysctl() in ibcs2_sysi86().

Approved by: re (scottl)

19 years agoRemove an extra call to read() in ibcs2_read() that can never be reached.
jhb [Thu, 7 Jul 2005 19:29:42 +0000 (19:29 +0000)]
Remove an extra call to read() in ibcs2_read() that can never be reached.
(It's already called a few lines earlier.)

Approved by: re (scottl)

19 years agoConditionally acquire Giant around the ISC and Xenix system calls based
jhb [Thu, 7 Jul 2005 19:28:55 +0000 (19:28 +0000)]
Conditionally acquire Giant around the ISC and Xenix system calls based
on the SYF_MPSAFE flag in the wrapper system calls for the ISC and Xenix
system call vectors.

Approved by: re (scottl)

19 years agoLock Giant in svr4_add_socket() so that the various svr4_*stat() calls
jhb [Thu, 7 Jul 2005 19:27:29 +0000 (19:27 +0000)]
Lock Giant in svr4_add_socket() so that the various svr4_*stat() calls
can be marked MP safe as this is the only part of them that is not
already MP safe.

Approved by: re (scottl)

19 years agoRemove an unused syscallarg() macro leftover from this code's origins in
jhb [Thu, 7 Jul 2005 19:26:43 +0000 (19:26 +0000)]
Remove an unused syscallarg() macro leftover from this code's origins in
NetBSD.

Approved by: re (scottl)

19 years agoRototill this file so that it actually compiles. It doesn't do anything
jhb [Thu, 7 Jul 2005 19:25:47 +0000 (19:25 +0000)]
Rototill this file so that it actually compiles.  It doesn't do anything
in the build still due to some #undef's in svr4.h, but if you hack around
that and add some missing entries to syscalls.master, then this file will
now compile.  The changes involved proc -> thread, using FreeBSD syscall
names instead of NetBSD, and axeing syscallarg() and retval arguments.

Approved by: re (scottl)

19 years agoFix the computation of uptime for linux_sysinfo(). Before it was returning
jhb [Thu, 7 Jul 2005 19:17:55 +0000 (19:17 +0000)]
Fix the computation of uptime for linux_sysinfo().  Before it was returning
the uptime in seconds mod 60 which wasn't very useful.

Approved by: re (scottl)

19 years ago- Remove spl's from osf1_usleep_thread().
jhb [Thu, 7 Jul 2005 19:16:30 +0000 (19:16 +0000)]
- Remove spl's from osf1_usleep_thread().
- Fix the calculation of the 'slept' timeval returned by
  osf1_usleep_thread() which has been broken since 1.1.

Approved by: re (scottl)

19 years agoRegenerate.
jhb [Thu, 7 Jul 2005 18:20:38 +0000 (18:20 +0000)]
Regenerate.

Approved by: re (scottl)

19 years ago- Add two new system calls: preadv() and pwritev() which are like readv()
jhb [Thu, 7 Jul 2005 18:17:55 +0000 (18:17 +0000)]
- Add two new system calls: preadv() and pwritev() which are like readv()
  and writev() except that they take an additional offset argument and do
  not change the current file position.  In SAT speak:
  preadv:readv::pread:read and pwritev:writev::pwrite:write.
- Try to reduce code duplication some by merging most of the old
  kern_foov() and dofilefoo() functions into new dofilefoo() functions
  that are called by kern_foov() and kern_pfoov().  The non-v functions
  now all generate a simple uio on the stack from the passed in arguments
  and then call kern_foov().  For example, read() now just builds a uio and
  calls kern_readv() and pwrite() just builds a uio and calls kern_pwritev().

PR: kern/80362
Submitted by: Marc Olzheim marcolz at stack dot nl (1)
Approved by: re (scottl)
MFC after: 1 week

19 years agoFix a bug when shell expansion is done against dangling symlinks, by
delphij [Thu, 7 Jul 2005 18:10:33 +0000 (18:10 +0000)]
Fix a bug when shell expansion is done against dangling symlinks, by
converting the stat() call to a lstat() call, which will cover the
situation.  One can exercise this bug by referring a dangling link with
something like */the-link.

Approved by: re (scottl)
Submitted by: Simon 'corecode' Schubert [corecode fs ei tum de]
Obtained from: NetBSD via DragonFlyBSD (NetBSD rev. 1.51 and DragonFly
rev. 1.6)
MFC After: 3 days

19 years agoFix ptsname(3) by converting it to use devname(3) to obtain the name of
marcus [Thu, 7 Jul 2005 17:48:40 +0000 (17:48 +0000)]
Fix ptsname(3) by converting it to use devname(3) to obtain the name of
a tty device instead of the legacy minor number approach.  This is known to
fix gnome-vfs' sftp module as well as kio_sftp and kdesu on -CURRENT.

Thanks to scottl for the snprintf() approach idea.

Reviewed by: phk
Tested by: pav
mich
Approved by: re (scottl)

19 years agoThis is sort of an MFS. Peter made these changes to the RELENG_*
kensmith [Thu, 7 Jul 2005 14:16:38 +0000 (14:16 +0000)]
This is sort of an MFS.  Peter made these changes to the RELENG_*
branches but missed HEAD.  This patch extends his a little bit,
setting it up via the Makefiles so that adding _FREEFALL_CONFIG
to /etc/make.conf is the only thing needed to cluster-ize things
(current setup also requires overriding CFLAGS).

From Peter's commit to the RELENG_* branches:
> Add the freebsd.org custer's source modifications under #ifdefs to aid
> keeping things in sync.  For ksu:
> * install suid-root by default
> * don't fall back to asking for a unix password (ie: be pure kerberos)
> * allow custom user instances for things like www and not just root

The Makefile tweaks will be MFC-ed, the rest is already done.

MFC after:      3 days
Approved by:    re (dwhite)

19 years ago - Since we don't hold a usecount in pfs_exit we have to get a holdcnt
jeff [Thu, 7 Jul 2005 07:33:10 +0000 (07:33 +0000)]
 - Since we don't hold a usecount in pfs_exit we have to get a holdcnt
   prior to calling vgone() to prevent any races.

Sponsored by: Isilon Systems, Inc.
Approved by: re (vfs blanket)

19 years ago`net.inet.ipf.fr_running' can be a negative value, which was introduced by
jkim [Thu, 7 Jul 2005 05:59:44 +0000 (05:59 +0000)]
`net.inet.ipf.fr_running' can be a negative value, which was introduced by
recent ipfilter import.

Approved by: re (scottl), anholt (mentor)

19 years agoadd myself as a new committer
jkim [Thu, 7 Jul 2005 05:48:37 +0000 (05:48 +0000)]
add myself as a new committer

Reviewed by: anholt (mentor)
Approved by: re (scottl)

19 years agoreclaim mbuf when ieee80211_crypto_encap fails
sam [Thu, 7 Jul 2005 02:55:04 +0000 (02:55 +0000)]
reclaim mbuf when ieee80211_crypto_encap fails

Approved by: re (scottl)
Obtained from: netbsd

19 years agoFix ifnet fallout in if_ti.
scottl [Thu, 7 Jul 2005 01:05:45 +0000 (01:05 +0000)]
Fix ifnet fallout in if_ti.

Reviewed by: brooks
Approved by: re

19 years agoExclude build32 target from the list of toolchain and kernel-toolchain
kan [Thu, 7 Jul 2005 00:58:41 +0000 (00:58 +0000)]
Exclude build32 target from the list of toolchain and kernel-toolchain
dependencies. We do not need to build 32bit compat tools to compile
a kernel.

Approved by: re (scottl)
Reported by: jhb

19 years agoonly invoke ath_rate_tx_complete to update rate control state when the
sam [Thu, 7 Jul 2005 00:04:50 +0000 (00:04 +0000)]
only invoke ath_rate_tx_complete to update rate control state when the
frame being sent is to be ack'd and hasn't been filtered by the h/w;
this insures we don't pass in tx descriptors that have no meaningful
state (e.g. mcast/bcast frames are not acked and so have no tx retry
counts)

Approved by: re (scottl)
Obtained from: Atheros

19 years agoThis commit was generated by cvs2svn to compensate for changes in r147801,
sam [Wed, 6 Jul 2005 22:06:27 +0000 (22:06 +0000)]
This commit was generated by cvs2svn to compensate for changes in r147801,
which included commits to RCS files with non-trunk default branches.

19 years agoclr ptr after freeing state to avoid subsequent null ptr deref
sam [Wed, 6 Jul 2005 22:06:27 +0000 (22:06 +0000)]
clr ptr after freeing state to avoid subsequent null ptr deref
(on vendor branch since this change already exists in Jouni's cvs).

Approved by: re (scottl)

19 years agoAdd support for Farallon EtherMAC PC Card.
imp [Wed, 6 Jul 2005 15:59:47 +0000 (15:59 +0000)]
Add support for Farallon EtherMAC PC Card.
Move ethernet MAC address setting into pccard attachment
Fix panic from IFP2ENADDR() use prior to if_alloc
Remove OLDCARD compat support.  This should work still on oldcard, however.
sn_attach now requires that the resources be activated now, so adjust.

Approved by: re (scottl)

19 years agoAdd device entry for a Farallon EtherMac PC Card that I won on ebay. This
imp [Wed, 6 Jul 2005 15:56:16 +0000 (15:56 +0000)]
Add device entry for a Farallon EtherMac PC Card that I won on ebay.  This
one is supported by the sn driver.

Approved by: re (scottl)

19 years agoadd pureg/-pureg parameter for controlling pureg ap mode support
sam [Wed, 6 Jul 2005 15:39:11 +0000 (15:39 +0000)]
add pureg/-pureg parameter for controlling pureg ap mode support

Reviewed by: avatar
Approved by: re (scottl)

19 years agoadd "pureg" mode for ap operation: reject association requests from
sam [Wed, 6 Jul 2005 15:38:27 +0000 (15:38 +0000)]
add "pureg" mode for ap operation: reject association requests from
11b-only stations when operating in 11g

Reviewed by: avatar
Approved by: re (scottl)

19 years agoCorrect a buffer overflow which occurred in the handling of some
cperciva [Wed, 6 Jul 2005 14:00:52 +0000 (14:00 +0000)]
Correct a buffer overflow which occurred in the handling of some
particularly corrupt deflated data streams.

Security: FreeBSD-SA-05:16.zlib
Approved by: re (security blanket)

19 years agoFix handling of data frames queued for a station in power save mode:
sam [Wed, 6 Jul 2005 01:55:17 +0000 (01:55 +0000)]
Fix handling of data frames queued for a station in power save mode:
don't mark the MORE_DATA bit when taking it off the ps queue, there's
no 802.11 header then; we must wait to do this at encap time so
mark the mbuf instead.

Reviewed by: avatar
Approved by: re (scottl)
Obtained from: Atheros

19 years agoFix race condition in handling node reference counts for authenticating
sam [Wed, 6 Jul 2005 01:51:44 +0000 (01:51 +0000)]
Fix race condition in handling node reference counts for authenticating
stations in ap mode.  Track when a node's first auth frame is
received and use this to decide whether or not to bump the refcnt.
This insures we only ever bump the refcnt once.

Reviewed by: avatar
Approved by: re (scottl)

19 years agoOnly update the scan entry state based on newly received frames.
avatar [Wed, 6 Jul 2005 01:31:34 +0000 (01:31 +0000)]
Only update the scan entry state based on newly received frames.
This fixes duplicative BSS entries(memory leaks as well) listed in
"ifconfig dev list scan" when a station fails to associate with an AP.

Reviewed by: sam
Approved by: re (scottl)

19 years ago- Previously when broadcasting to N number of interfaces we would run pfil
thompsa [Wed, 6 Jul 2005 01:24:45 +0000 (01:24 +0000)]
- Previously when broadcasting to N number of interfaces we would run pfil
  hooks for each outgoing interface but also run pfil hooks _N times_ on the
  bridge interface. This is changed so pfil hooks are run once for the bridge
  interface (bridge0) and then only on the outgoing interfaces in the broadcast
  loop.

- Simplify bridge_enqueue() by moving bridge_pfil() to the callers.

- Check (inet6_pfil_hook.ph_busy_count >= 0), it may be possible to have a
  packet filter hooked for only ipv6 but we were only checking if ipv4 hooks
  were busy.

- Minor optimisation for null mbuf check after bridge_pfil(), move it into the
  if-block as it couldnt possibly be null outside.

Prodded by: mlaier
Approved by: re (scottl), mlaier (mentor)

19 years agoEliminate MAC entry point mac_create_mbuf_from_mbuf(), which is
rwatson [Tue, 5 Jul 2005 23:39:51 +0000 (23:39 +0000)]
Eliminate MAC entry point mac_create_mbuf_from_mbuf(), which is
redundant with respect to existing mbuf copy label routines.  Expose
a new mac_copy_mbuf() routine at the top end of the Framework and
use that; use the existing mpo_copy_mbuf_label() routine on the
bottom end.

Obtained from: TrustedBSD Project
Sponsored by: SPARTA, SPAWAR
Approved by: re (scottl)

19 years agoAdd MAC Framework and MAC policy entry point mac_check_socket_create(),
rwatson [Tue, 5 Jul 2005 22:49:10 +0000 (22:49 +0000)]
Add MAC Framework and MAC policy entry point mac_check_socket_create(),
which is invoked from socket() and socketpair(), permitting MAC
policy modules to control the creation of sockets by domain, type, and
protocol.

Obtained from: TrustedBSD Project
Sponsored by: SPARTA, SPAWAR
Approved by: re (scottl)
Requested by: SCC

19 years agoRemove a || 1 that crept into the i8254 commit and was subsequently
jhb [Tue, 5 Jul 2005 20:13:12 +0000 (20:13 +0000)]
Remove a || 1 that crept into the i8254 commit and was subsequently
copied and pasted.  I had actually tested without this change in my
trees as had the other testers.

Reported by: bde, Rostislav Krasny rosti dot bsd at gmail dot com
Approved by: re (scottl)
Pointy hat to: jhb

19 years agoFix for a bug in newreno partial ack handling where if a large amount
ps [Tue, 5 Jul 2005 19:23:02 +0000 (19:23 +0000)]
Fix for a bug in newreno partial ack handling where if a large amount
of data is partial acked, snd_cwnd underflows, causing a burst.

Found, Submitted by: Noritoshi Demizu
Approved by: re

19 years agoUse the correct login class when setting a new password.
des [Tue, 5 Jul 2005 18:42:18 +0000 (18:42 +0000)]
Use the correct login class when setting a new password.

PR: 65557, 72949
Submitted by: Stephen P. Cravey <clists@gotbrains.org>
Approved by: re (scottl)
MFC after: 2 weeks

19 years agoremove auto-add of IEEE80211_KEY_GROUP; all the apps that need to
sam [Tue, 5 Jul 2005 18:05:25 +0000 (18:05 +0000)]
remove auto-add of IEEE80211_KEY_GROUP; all the apps that need to
set it have been fixed

Reviewed by: avatar
Approved by: re (scottl)

19 years agoRemove obsoleted sysctl interface for switching between standard and 3Com
glebius [Tue, 5 Jul 2005 17:51:02 +0000 (17:51 +0000)]
Remove obsoleted sysctl interface for switching between standard and 3Com
PPPoE modes. The interface was declared obsoleted before 5.3-RELEASE.

When running as access concentrator ng_pppoe(4) supports both modes
simultanously. When running as client mode can be swicthed in ppp(8)
configuration.

Approved by: re (scottl)

19 years agoexplicitly set IEEE80211_KEY_GROUP instead of depending on kernel kludge
sam [Tue, 5 Jul 2005 17:42:27 +0000 (17:42 +0000)]
explicitly set IEEE80211_KEY_GROUP instead of depending on kernel kludge

Reviewed by: avatar
Approved by: re (scottl)

19 years agoUpdate key handling:
sam [Tue, 5 Jul 2005 17:41:42 +0000 (17:41 +0000)]
Update key handling:
o use proper api for setting/deleting keys instead of depending
  on key indices
o check mac address to decide whether a key is unicast or group/global
o check set_tx on key set to decide whether a group/global key should
  also be marked as default
o explicitly set IEEE80211_KEY_GROUP flag for group keys instead of
  depending on kernel auto-add kludge

With the above changes static wep key handling works.

Reviewed by: avatar
Approved by: re (scottl)

19 years agoo when setting a wpa key, hold a ref on the bss node;
sam [Tue, 5 Jul 2005 17:35:35 +0000 (17:35 +0000)]
o when setting a wpa key, hold a ref on the bss node;
  fixes a ref cnt leak
o make unicast key handling on delete identical to set
o change legacy wep key api to reset the 802.11 state
  machine for backwards compatibility

Reviewed by: avatar
Approved by: re (scottl)

19 years agoIn the splnet times, netgraph was functional and synchronous. Nowadays,
glebius [Tue, 5 Jul 2005 17:35:20 +0000 (17:35 +0000)]
In the splnet times, netgraph was functional and synchronous. Nowadays,
an item may be queued and processed later. While this is OK for mbufs,
this is a problem for control messages.

In the framework:
- Add optional callback function pointer to an item. When item gets
  applied the callback is executed from ng_apply_item().
- Add new flag NG_PROGRESS. If this flag is supplied, then return
  EINPROGRESS instead of 0 in case if item failed to deliver
  synchronously and was queued.
- Honor NG_PROGRESS in ng_snd_item().

In ng_socket:
- When userland sends control message add callback to the item.
- If ng_snd_item() returns EINPROGRESS, then sleep.

This change fixes possible races in ngctl(8) scripts.

Reviewed by: julian
Approved by: re (scottl)

19 years agoEnhance ia64_flush_dirty() to handle the case in which td != curthread.
marcel [Tue, 5 Jul 2005 17:12:18 +0000 (17:12 +0000)]
Enhance ia64_flush_dirty() to handle the case in which td != curthread.
This case is triggered with ptrace(2) and the PT_SETREGS function.
Change the return type of the function to int so that errors can be
passed on to the caller.

Approved by: re (scottl)

19 years agoFix one "wrong b_bufobj" panic in reassignbuf() by moving VI_UNLOCK(vp)
pjd [Tue, 5 Jul 2005 15:57:55 +0000 (15:57 +0000)]
Fix one "wrong b_bufobj" panic in reassignbuf() by moving VI_UNLOCK(vp)
below KASSERT()s, which means there was no real problem here, we just
needed better locking for assertions.

OK'ed by: jeff
Approved by: re (scottl)

19 years agoUpdate for Bulletin C number 30:
phk [Tue, 5 Jul 2005 15:48:53 +0000 (15:48 +0000)]
Update for Bulletin C number 30:

There will be a leapsecond at the end of 2005.

Approved by: re@

19 years agoUpdate hardcoded postfix version number to the current postfix version
simon [Mon, 4 Jul 2005 07:53:35 +0000 (07:53 +0000)]
Update hardcoded postfix version number to the current postfix version
2.2.x.

PR: i386/82030
Prodded by: matteo
MFC after: 1 week
Approved by: re (scottl)

19 years agoHandle .Li macro's with quoted arguments, which is used in the ath(4)
simon [Mon, 4 Jul 2005 07:48:02 +0000 (07:48 +0000)]
Handle .Li macro's with quoted arguments, which is used in the ath(4)
manual page.

Noticed by: brueffer (long ago)
Approved by: re (hrs)

19 years agowhen operating in ap mode, explicitly drop associated/authenticated
sam [Mon, 4 Jul 2005 01:29:41 +0000 (01:29 +0000)]
when operating in ap mode, explicitly drop associated/authenticated
stations when transitioning to INIT state (e.g. as a result of
changing state at the 802.11 level)

Approved by: re (scottl)

19 years agoAdd support for IODATA USB-RSAQ3 USB-Serial Adapter.
hrs [Sun, 3 Jul 2005 23:51:16 +0000 (23:51 +0000)]
Add support for IODATA USB-RSAQ3 USB-Serial Adapter.

Reported by: Tomokazu Hirai
Approved by: re (scottl)
MFC after: 3 days

19 years agoCheck the alignment of the IP header before passing the packet up to the
thompsa [Sun, 3 Jul 2005 18:24:03 +0000 (18:24 +0000)]
Check the alignment of the IP header before passing the packet up to the
packet filter. This would cause a panic on architectures that require strict
alignment such as sparc64, ia64 and ppc.

This uses the code block from if_bridge and the newly added macro
IP_HDR_ALIGNED_P().

This /might/ be a temporary messure before all NIC drivers are educated
to align the header themself.

PR: ia64/81284
Obtained from: NetBSD (if_bridge)
Approved by: re (dwhite), mlaier (mentor)

19 years ago- Update the CPU version check to recognize P4/EMT64 CPUs. [1]
jkoshy [Sun, 3 Jul 2005 16:33:22 +0000 (16:33 +0000)]
- Update the CPU version check to recognize P4/EMT64 CPUs. [1]
- Allow libpmc(3) to support P4/EMT64 PMCs on the amd64 architecture
  and AMD K8 PMCs on the i386. [2]

Submitted by: ps [1]
Pointy hat: myself [2]
Approved by: re (scottl)

19 years agoRemove ambiguity from hlen. IPv4 is now indicated by is_ipv4 and we need a
mlaier [Sun, 3 Jul 2005 15:42:22 +0000 (15:42 +0000)]
Remove ambiguity from hlen.  IPv4 is now indicated by is_ipv4 and we need a
proper hlen value for IPv6 to implement O_REJECT and O_LOG.

Reviewed by: glebius, brooks, gnn
Approved by: re (scottl)

19 years agoo Make ipw(4) more robust against frames received with a bad length.
damien [Sun, 3 Jul 2005 15:42:18 +0000 (15:42 +0000)]
o Make ipw(4) more robust against frames received with a bad length.
o Minor consistency tweaks.

Reviewed by: silby (mentor)
Approved by: re (scottl)