Commit Graph

133095 Commits

Author SHA1 Message Date
des
aac7a2ca82 Fix stupid braino in previous commit. 2007-05-23 10:06:03 +00:00
rwatson
799e37dd6b No need to force __inline__ of currecord(), as the compiler will usefully
inline it when needed already, and the symbol is also required outside of
audit.c.  This silences a new gcc warning on the topic of using __inline__
instead of __inline.

MFC after:	3 days
2007-05-23 09:32:30 +00:00
kib
cdee790df9 Move futex support code from <arch>/support.s into linux compat directory.
Implement all futex atomic operations in assembler to not depend on the
fuword() that does not allow to distinguish between -1 and failure return.
Correctly return 0 from atomic operations on success.

In collaboration with:	rdivacky
Tested by:	Scot Hetzel <swhetzel gmail com>, Milos Vyletel <mvyletel mzm cz>
Sponsored by:	Google SoC 2007
2007-05-23 08:33:06 +00:00
des
253a9fb8b6 If (flags & O_TRUNC), don't truncate the file until we've successfully
locked it.

MFC after:	3 weeks
2007-05-23 08:12:34 +00:00
kmacy
ba07e2634f Add some early diagnostics under bootverbose
bootverbose is not getting set early enough so hardcode for the moment
2007-05-23 05:22:58 +00:00
thompsa
dc97594a94 Do not attempt to load the kernel module when checking if an interface exists.
This would cause pseudo network modules to be reloaded again when trying to
unload the first time if any cloned interfaces exist.

MFC after:	2 weeks
2007-05-23 00:18:44 +00:00
pjd
641a216a63 - Remove redundant initialization.
- Compare pointer with NULL.
2007-05-22 23:05:48 +00:00
pjd
4a15a486c9 Lock vnode on lookup. This fixes ZIL replay for rmdir/unlink/rename.
Reported by:	des
2007-05-22 21:22:25 +00:00
simon
fbc9e81620 Fix runtime crash in OpenSSL with "Illegal instruction" by making some
casts a bit less evil.

This was e.g. seen when using portsnap as:

  Fetching snapshot tag from portsnap3.FreeBSD.org... Illegal instruction

Note the patch is slightly different from kan's original patch to
match style in the OpenSSL source files a bit better.

Submitted by:	kan
Tested by:	many
2007-05-22 20:28:19 +00:00
jkim
120998d9c2 Remove an empty line. 2007-05-22 20:24:07 +00:00
jkim
5a606c9586 Remove BCM5704S specific tunable (hw.bge.fake_autoneg) and
auto-detect the condition.
2007-05-22 19:35:34 +00:00
jkim
33d961a28a Rearrange DMA read/write control register settings based on document snippet
provided by davidch via glebius.

PR:		kern/96806
2007-05-22 19:22:58 +00:00
jkim
6bf263ddc5 Remove stale alpha support code. 2007-05-22 19:11:39 +00:00
jkim
79e5bf3b37 Fix time out check in EEPROM read and move delays to give some settle time.
Submitted by:	mjacob
2007-05-22 18:51:05 +00:00
jkim
01e1047367 Add delays in MI communication register R/W loops. 2007-05-22 18:16:23 +00:00
brueffer
3a70a1c7a4 Fix typos. 2007-05-22 18:14:35 +00:00
thompsa
fca21956cb Add the -n flag for disabling automatic module loading, this will be used by
rc.d to stop it reloading the network module on unload.
2007-05-22 17:41:09 +00:00
glebius
d3faad3720 Some minor cleanups:
- In rt_check() remove the senderr() macro and the "bad" label. They
  used to simplify code, but now aren't.
- Remove extra RT_LOCK_ASSERT() in rt_setgate(). The RT_REMREF macro
  does this.
- In rtfree() convert panics to KASSERTs.
- Strict the routing API: rtfree() should be called only in a case
  when we are completely sure we've got the last reference on the
  rtentry. In all other cases RTFREE_LOCKED() macro should be used.
  If the reference isn't the last one spit out a warning printf.
  Correct the only(?) case for this in rt_check().
- Fix typos in comments.
2007-05-22 16:17:31 +00:00
gallatin
eeec783554 mxge cleanups:
- Remove code to use the special wc_fifo.  It has been disabled by default
  in our other drivers as it actually slows down transmit by a small amount

- Dynamically determine the amount of space required for the rx_done
  ring rather than hardcoding it.

- Compute the number of tx descriptors we are willing to transmit per
  frame as the minimum of 128 or 1/4 the tx ring size.

- Fix a typo in the tx dma tag setup which could lead to unnecessary
  defragging of TSO packets (and potentially even dropping TSO packets
  due to EFBIG being returned).

- Add a counter to keep track of how many times we've needed to
  defragment a frame.  It should always be zero.

- Export new extended f/w counters via sysctl

Sponsored by: Myricom, Inc.
2007-05-22 15:57:49 +00:00
cperciva
00c45ba7c0 Replace "sizeof(struct bucket[cache_size])" with
"cache_size * sizeof(struct bucket)".  The former is valid in C99 but can
confuse earlier compilers, while the latter is a standard idiom which all
C compilers understand.

Approved by:	kientzle
2007-05-22 15:37:58 +00:00
gallatin
4c4fb12e78 Hook mxge_lro.c to the build so that the if_mxge.ko module
will load.
2007-05-22 14:38:17 +00:00
rse
5d5ff0e937 backout filter of Nil UUID as the boot loader code already filters out Nil UUIDs (see src/sys/boot/i386/libi386/smbios.c:smbios_setuuid for details) 2007-05-22 13:53:59 +00:00
mav
e8130fb9e7 Add support for setmode and settarget messages.
Approved by:	glebius (mentor)
2007-05-22 12:23:39 +00:00
mav
519a3dd7a9 Allow node to bypass traffic while no alias address defined.
Approved by:	glebius (mentor)
2007-05-22 12:14:43 +00:00
mav
ef7aa6f3c1 Return back NETGRAPH_MPPC_COMPRESSION depends.
Reviewed by:	ru, julian
Approved by:	glebius (mentor)
2007-05-22 12:00:31 +00:00
nyan
a4c64455ab Remove the restore and chroot command to avoid disk-full error. 2007-05-22 11:32:55 +00:00
dds
56b5e53094 Set .PATH before referring to the corresponding sources. 2007-05-22 10:49:42 +00:00
ru
59fb918e03 Don't forget to clean generated ssp.h. 2007-05-22 10:40:58 +00:00
ru
05dcdedaca Don't want a stray systrace_args.c in objdir. 2007-05-22 10:36:12 +00:00
rse
3817f11e34 Remove the ugly csh(1) based UUID lower-case translation hack from
/etc/rc.d/hostid now that we switched the origin of the UUID (variable
smbios.system.uuid as provided by the i386 BIOS code) to already provide
a standard conforming lower-case UUID text representation.
2007-05-22 10:22:24 +00:00
dds
9ed27d1038 Increase precision of time values in the process accounting
structure, while maintaining backward compatibility with legacy
file and record formats.
2007-05-22 06:51:38 +00:00
dds
b6fc65f3b5 Regression tests for sparc64 record formats.
Submitted by:	Carl Johan Gustavsson
2007-05-22 06:34:20 +00:00
dds
cc71cb59cc Regression tests for amd64 file and record formats.
Submitted by:	Larry Rosenman (who also provided access to a testing host)
2007-05-22 06:30:48 +00:00
dds
9f0427dc0e Regression tests for the new and legacy process accounting formats. 2007-05-22 06:21:20 +00:00
kmacy
d0b2a29b69 restore interrupts to working order after INTR_THREAD changes
- ithread_wrapper was being treated as a wrapper for fast interrupts when
  in fact it was intended for ithread interrupts
2007-05-22 06:17:55 +00:00
dds
45f681d588 Document the .in .out file naming conventions adopted in commit_prep.pl's
exclusions list for header checking.
2007-05-22 06:11:44 +00:00
dds
3fe54a3836 Test the integer-arithmetic float conversions encode_timeval and encode_long
in kern_acct.c.
2007-05-22 05:52:04 +00:00
jon
50945671cb Backout 1.5 as requested by deischen 2007-05-22 05:28:40 +00:00
alc
08b2128056 Eliminate the reactivation of cached pages in vm_fault_prefault() and
vm_map_pmap_enter() unless the caller is madvise(MADV_WILLNEED).  With
the exception of calls to vm_map_pmap_enter() from
madvise(MADV_WILLNEED), vm_fault_prefault() and vm_map_pmap_enter()
are both used to create speculative mappings.  Thus, always
reactivating cached pages is a mistake.  In principle, cached pages
should only be reactivated by an actual access.  Otherwise, the
following misbehavior can occur.  On a hard fault for a text page the
clustering algorithm fetches not only the required page but also
several of the adjacent pages.  Now, suppose that one or more of the
adjacent pages are never accessed.  Ultimately, these unused pages
become cached pages through the efforts of the page daemon.  However,
the next activation of the executable reactivates and maps these
unused pages.  Consequently, they are never replaced.  In effect, they
become pinned in memory.
2007-05-22 04:45:59 +00:00
cperciva
e4c186657b In the error handling path, don't call close(fd) if the error we're
handling is that fd = open(foo) is -1.  This bug is harmless since
close(-1) just returns an error (which the code ignores).

Found by:	Coverity Prevent(tm)
CID:		1503 (in userland test run)
2007-05-22 04:21:00 +00:00
jon
f4c0271704 __cleanup() is needed for ports/devel/valgrind, export it. 2007-05-22 03:03:28 +00:00
kan
4c2d706212 Allow FreeBSD's native ELF image activators to execute shared libraries the
same way it was enabled for Linux binares in linuxulator.

This allows binaries built with -pie. Many ports auto-detect -fPIE support
in GCC 4.2 and build binaries FreeBSD was unable to run.
2007-05-22 02:22:58 +00:00
keramida
2049c78bad Remove duplicate ' 2' manpage section number.
Submitted by:	 Rui Paulo
MFC after:	 3 days
2007-05-21 20:33:51 +00:00
dhartmei
b84c57b21a From OpenBSD, rev. 1.379
Document how 'allow-opts' applies to routing headers in IPv6.

MFC after:	1 week
Discussed with:	mlaier
2007-05-21 20:12:35 +00:00
dhartmei
f33636c0a2 From OpenBSD, rev. 1.524, 1.528, 1.529
Deal with IPv6 routing headers (see FreeBSD-SA-07:03.ipv6 for background)
Block IPv6 packets with routing headers by default, unless 'allow-opts'
is specified. Block RH0 unconditionally. Deal with ip6_plen 0.

MFC after:	1 week
Discussed with:	mlaier
2007-05-21 20:08:59 +00:00
jkim
92efd303a0 Use lower cases for UUID string to conform RFC4122 and ISO/IEC-9834-8:2005. 2007-05-21 18:48:18 +00:00
brueffer
19ef55a73f Forgot to add hptiop(4) here. 2007-05-21 18:35:40 +00:00
gallatin
03b25c7049 Improve mxge receive performance:
- Update to the latest (1.4.18) f/w.  This f/w introduces a new
  receive mode which allows us to use FreeBSD's physically discontinuous
  MJUM9BYTES clusters.

- Switch the driver from chaining MJUMPAGESIZE clusters to using
  MJUM9BYTES clusters to avoid mbuf chaining overheads.  Due to this
  change, people running obsolete f/w images will be limited to an MTU of
  PAGE_SIZE - 16.

- Add (disabled by default) support for Large Receive Offload.

Sponsored by: Myricom, Inc.
2007-05-21 18:32:27 +00:00
rwatson
843ae548c7 Make pointer argument to kread_string() const since the kernel structure
field is const, and then employ __DECONST before getting into the kvm
code.  This eliminates a gcc 4.2 warning about losing constification.

__DECONST advice from:	sam
2007-05-21 18:16:04 +00:00
ru
85d6f8f56c Fix markup. 2007-05-21 15:29:42 +00:00