Commit Graph

121285 Commits

Author SHA1 Message Date
Gleb Smirnoff
e5ed7bcc74 Skip format flags, when parsing ktr_desc. 2006-01-12 22:32:07 +00:00
Bruno Ducrot
ab033fa0e3 * fix bst.status. We mark some bits, but forgot to reset all of them
before.  The symptom is that the battery inform us its charge and discharge
  at the same time...

* fix bst.rate to correctly output the (dis)charging rate.  We'll use
  the current average over one minute command and not the at_rate command.
  Note that this method is not correct if the capacity_mode is set, but
  since we don't set it ourself, it is not a problem.

  The at_rate do not give the actual rate but is used to compute the
  estimated time for (dis)charging a battery.  We should actually
  write an estimation of the actual rate using at_rate cmd and then
  perform a read to the various estimators.

Approved by:	njl
MFC after:	2 days
2006-01-12 21:56:37 +00:00
Gleb Smirnoff
04b3fa1623 Do not force queueing on peer hooks. This was important only for
5.0-CURRENT. And it looks like this didn't work before Julian's
revamp of netgraph queue code.

Reviewed by:	julian
2006-01-12 21:09:12 +00:00
Andrew Thompson
54c427e0e2 Include the bridge interface itself in the special arp handling.
PR:		90973
MFC after:	1 week
2006-01-12 21:05:30 +00:00
Gleb Smirnoff
22b286280c Remove old debugging leftover.
Reviewed by:	julian
2006-01-12 21:03:09 +00:00
Brooks Davis
3d11d44ca1 Belated __FreeBSD_version bump for improvements to the Linux ldconfig
support in etc/rc.d/abi.
2006-01-12 20:27:35 +00:00
Gleb Smirnoff
3d9dddcd0f Mark appropriate commands with NGM_READONLY and NGM_HASREPLY and
bump type cookie.
2006-01-12 19:16:08 +00:00
Alfred Perlstein
7d7e053c21 Novel idea, don't print a string if it is NULL!
This protects people from loading _really_ old modules, like say from
5.x to a 6.x or 7.x system, like for instance right after an upgrade.
2006-01-12 19:15:14 +00:00
Gleb Smirnoff
2df050ad10 In the splnet(9) times netgraph(4) was synchronous and if a message
had been replied, the reply was always delivered to the originator
synchronously.

With introduction of netgraph item callbacks and a wait channel with
mutex in ng_socket(4), we have fixed the problem with ngctl(8) returning
earlier than the command has been proceeded by target node. But still
ngctl(8) can return prior to the reply has arrived to its node.

To fix this:
 - Introduce a new flag for netgraph(4) messages - NGM_HASREPLY.
   This flag is or'ed with message like NGM_READONLY.
 - In netgraph userland library if we have sent a message with
   NGM_HASREPLY flag, then select(2) until reply comes.
 - Mark appropriate generic commands with NGM_HASREPLY flag,
   gathering them into one enum {}. Bump generic cookie.
2006-01-12 19:14:40 +00:00
Jason Evans
352219015d Fix a bitwise logic error in posix_memalign().
Reported by:	glebius
2006-01-12 18:09:25 +00:00
Ruslan Ermilov
7a62fb4692 Remove releases now found in Groff sources. 2006-01-12 15:33:18 +00:00
Ruslan Ermilov
b281aca4ad Pull up from the FSF branch. 2006-01-12 15:31:41 +00:00
Ruslan Ermilov
401070f083 This commit was generated by cvs2svn to compensate for changes in r154258,
which included commits to RCS files with non-trunk default branches.
2006-01-12 15:26:11 +00:00
Ruslan Ermilov
b99439c39a Merge support for new BSD releases from upstream:
- Darwin 8.[0-3].0
- FreeBSD 4.11, 5.4, 6.0, 6.1
- NetBSD 3.0
2006-01-12 15:26:11 +00:00
Marius Strobl
e4846391da In moduledir_readhints() cast the value returned by sizeof() to ssize_t
when checking whether it's greater than a struct stat st_size in order
to also catch the case when st_size is -1. Previously this check didn't
trigger on sparc64 when st_size is -1 (as it's the case for a file on
a bzipfs, TFTP server etc.), causing the content of the linker hints
file to be copied to memory referenced by a null-pointer.

PR:		91231
MFC after:	1 week
2006-01-12 13:18:49 +00:00
Marius Strobl
a9f4f750ff - The inline asm in this file uses output operands before all input
operands are consumed so use the appropriate constraint modifier.
  Before this change GCC used one register for both an input and an
  unrelated output operand of in_addword(), causing the input to be
  overwritten before it was consumed and thus breaking in_addword().
  For in_cksum_hdr() and in_pseudo() this change is more or less
  cosmetic.
- Fix a misspelling in a nearby comment.

Reported & tested by:	yongari
MFC after:		1 week
2006-01-12 11:40:39 +00:00
Gleb Smirnoff
1be0418cbc Fix wording in last commit.
Submitted by:	julian
2006-01-12 10:15:51 +00:00
Jason Evans
43326ef72b Use posix_memalign() in valloc() rather than making assumptions about
the alignment of malloc()ed memory.

Approved by:	markm (mentor)
2006-01-12 09:29:38 +00:00
Jason Evans
609c1c6c22 Use posix_memalign() rather than assuming that malloc() provides adequate
alignment.

Approved by:	markm (mentor)
2006-01-12 08:01:38 +00:00
Jason Evans
b3d51d3afc Expose the posix_memalign() prototype, now that the function is implemented
by libc.
2006-01-12 07:58:59 +00:00
Hartmut Brandt
6c5d6ce3dd Fix build without -DNDEBUG.
Spotted by:	obrien
2006-01-12 07:44:40 +00:00
Jason Evans
52828c0e9c In preparation for a new malloc implementation:
* Add posix_memalign().

  * Move calloc() from calloc.c to malloc.c.  Add a calloc() implementation in
    rtld-elf in order to make the loader happy (even though calloc() isn't
    used in rtld-elf).

  * Add _malloc_prefork() and _malloc_postfork(), and use them instead of
    directly manipulating __malloc_lock.

Approved by:	phk, markm (mentor)
2006-01-12 07:28:21 +00:00
Ruslan Ermilov
0b61bced98 Build shared library on behalf of bsnmpd. 2006-01-12 07:26:57 +00:00
David E. O'Brien
d1682a2c99 assert(3) is not used here. 2006-01-12 02:53:42 +00:00
David E. O'Brien
f8ed1e340d Move linux support to the linux section. 2006-01-12 01:20:59 +00:00
Ariff Abdullah
1738f66243 Fix broken playback capabilities to prevent impending disaster.
The minimum / maximum speed was way too low / high!

minspeed =   2000 - is this for real ?
maxspeed = 767999 - is this for real ?????

Wrap everything into 8000 - 48000 boundary, just to be safe.

MFC after:	3 days
2006-01-11 23:22:57 +00:00
Doug Ambrisko
1cc59a99c0 Grab the media from the passed in structure to put it into the
global structure.

PR:	bin/91399
Submitted by:	Spencer Minear
2006-01-11 22:37:59 +00:00
Brooks Davis
8b1292ac52 Creating memory file systems with softupdates enabled is pointless,
don't do it.

PR:		conf/85558
Submitted by:	Ralf Wenk <RZ dash FreeBSD0605 at hs dash karlsruhe dot de>
MFC after:	5 days
2006-01-11 21:59:30 +00:00
Takanori Watanabe
b792c4fbed Grammar fix.
Submitted by: joel@
2006-01-11 21:46:15 +00:00
Brooks Davis
de3a554cd4 Be a little more read-only file system friendly when running the Linux
ldconfig.  Build the cache in a temporary directory and only install it
if it's actually different that the installed one.

Also, use "cat tmp > real" to install the temporary file in the real
location to allow the real location to be a symlink to a writable
directory such as /var/run (where the file actually belongs).

MFC After:	5 days
2006-01-11 21:30:41 +00:00
Maxim Konovalov
7b7f29d82a o Sort MLINKS. 2006-01-11 21:28:55 +00:00
Florent Thoumie
59d00daaff Ok, I've created a test suite to avoid such regressions. Sorry for the noise.
Approved by:	ssouhlal (implicit)
2006-01-11 16:51:21 +00:00
Florent Thoumie
6dd881af19 - Fix another bug, it seems sometimes mail is sent to cvs-all but not cvs-ports.
Approved by:	ssouhlal (implicit)
2006-01-11 16:22:24 +00:00
Florent Thoumie
6acd437b62 - Fix search.
- Fix author matching.

Approved by:	ssouhlal (implicit)
2006-01-11 16:00:38 +00:00
Jason Evans
06115e083a Add the RB_NFIND() macro, which is useful for red-black tree searches
for which there may not be an exact match.

Reviewed by:	glebius, julian
Approved by:	markm (mentor)
2006-01-11 15:48:36 +00:00
Gleb Smirnoff
3b33fbe7d4 Add ktr(9) hooks to easier tracing of the netgraph item flow through
netgraph.
2006-01-11 15:29:48 +00:00
Ceri Davies
a3df483296 I wrote getnetconfig where I meant getnetpath in the previous revision. 2006-01-11 13:57:15 +00:00
Takanori Watanabe
0fff54f0fe Add a mobile phone known to work. 2006-01-11 13:51:03 +00:00
Colin Percival
9ed97bee65 Correct insecure temporary file usage in texindex. [06:01]
Correct insecure temporary file usage in ee. [06:02]
Correct a race condition when setting file permissions, sanitize file
names by default, and fix a buffer overflow when handling files
larger than 4GB in cpio. [06:03]
Fix an error in the handling of IP fragments in ipfw which can cause
a kernel panic. [06:04]

Security:	FreeBSD-SA-06:01.texindex
Security:	FreeBSD-SA-06:02.ee
Security:	FreeBSD-SA-06:03.cpio
Security:	FreeBSD-SA-06:04.ipfw
2006-01-11 08:02:16 +00:00
Ariff Abdullah
40c012dd6d - Locking fixes. Release lock while chn_intr().
- Mark MPSAFE since most of the locking procedures already implemented.
- Turn on inverted external amplifier sense flag for selected boards.

Tested by:	bland
MFC after:	1 week
2006-01-11 08:02:15 +00:00
David Xu
07a263153e The thr_new sysscall was already in libc, don't generate it. 2006-01-11 06:10:05 +00:00
Brooks Davis
118b438d73 Get rid of the bogus IFP2FC() macro and use IFP2FWC(). IFP2FC()
attempted to cast a struct ifnet to a struct fw_com which resulted in
data corruption.

PR:		kern/91307
Submitted by:	Alex Semenyaka <alex at semenyaka do ru>
MFC After:	6 days
2006-01-11 05:37:21 +00:00
Florent Thoumie
9e28677ee3 - Remove netcat dependency by using fetch (not sure why i used nc
in the first place).
- Add some XXX lines as a TODO.
- Add a cvs diff command to the generated commit script.
- Add cdiff/colordiff to the list of optional dependencies.
- Fix a problem when giving the commit mail without the headers to
mfc.pl -f, it should now work correctly.
- Bump version.

Approved by:	ssouhlal (implicit)
2006-01-11 02:53:54 +00:00
Ian Dowse
d3ef345454 When deregistering a bus, attempt to flush out all outstanding
operations before returning. Point the bus at a dummy cam_sim
structure so that any CCBs will complete immediately with a
CAM_DEV_NOT_THERE status, and ensure that any xpt_schedule() calls
on the bus's devices will immediately call the peripheral's
periph_start() routine. Also repeat the async messages because
devices that were part of the way through being probed may appear
after the original AC_LOST_DEVICE was sent, and would otherwise
never go away.

These changes make it possible to deregister a bus and free the SIM
at most stages during bus probing without the usual crashes in
camisr(). In particular, plugging in a umass device and then
unplugging it as soon as the first probe messages appeared would
almost always result in a crash. Now the device just goes away with
a few CAM errors and all references to the CAM bus, target and
device are dropped correctly.
2006-01-11 02:06:08 +00:00
Scott Long
1c3a3b0bd0 The interlock in taskqueue_terminate() is completely wrong for taskqueues
that use spinlocks.  Remove it for now.
2006-01-11 00:37:13 +00:00
Scott Long
2ff7d1b635 Significant performance improvements for the if_em driver:
- Only update the rx ring consumer pointer after running through the rx loop,
  not with each iteration through the loop.
- If possible, use a fast interupt handler instead of an ithread handler.  Use
  the interrupt handler to check and squelch the interrupt, then schedule a
  taskqueue to do the actual work.  This has three benefits:
  - Eliminates the 'interrupt aliasing' problem found in many chipsets by
    allowing the driver to mask the interrupt in the NIC instead of the
    OS masking the interrupt in the APIC.
  - Allows the driver to control the amount of work done in the interrupt
    handler.  This results in what I call 'adaptive polling', where you get
    the latency benefits of a quick response to interrupts with the
    interrupt mitigation and work partitioning of polling.  Polling is still
    an option in the driver, but I consider it orthogonal to this work.
  - Don't hold the driver lock in the RX handler.  The handler and all data
    associated is effectively serialized already.  This eliminates the cost of
    dropping and reaquiring the lock for every receieved packet.  The result
    is much lower contention for the driver lock, resulting in lower CPU usage
    and lower latency for interactive workloads.

The amount of work done in the taskqueue is controlled by the sysctl
dev.em.N.rx_processing_limit

and tunable
hw.em.rx_process_limit

Setting these to -1 effectively removes the limit.

The fast interrupt and taskqueue can be disabled by defining NO_EM_FASTINTR.
This work has been shown to increase fast-forwarding from ~570 kpps to
~750 kpps (note that the same NIC hardware seems unable to transmit more than
800 kpps, so this increase appears to be limited almost solely by the
hardware).  Gains have been shown in other workloads, ranging from better
performance to elimination of over-saturation livelocks.

Thanks to Andre Opperman for his time and resources from his network
performance project in performing much of the testing.  Thanks to Gleb
Smirnoff and Danny Braniss for their help in testing also.
2006-01-11 00:30:25 +00:00
Greg Lehey
3b4c974228 Add references to fhopen, fhstat, getfh, lgetfh and fhstatfs.
Pointed out by: Antony Curtis <antony@mysql.com>
2006-01-10 23:24:47 +00:00
Scott Long
2ffb18fec1 Don't use the ALLOCNOW flag for tags that will only be used for static
allocations.
2006-01-10 22:55:35 +00:00
Jim Rees
85bfb1d55c add nfsclient/, nfs4client/, and rpc/ directories to the
top Makefile's rule to build a cscope database.

Submitted by:	cel@citi.umich.edu
Approved by:	alfred
2006-01-10 20:58:27 +00:00
Jens Schweikhardt
28c9ad2bf9 Correct two trivial grammos. 2006-01-10 18:55:24 +00:00