Commit Graph

2909 Commits

Author SHA1 Message Date
des
0b52d3d97f Oops, I flipped LDNS_UTILS but forgot to update the description. 2013-02-15 13:57:51 +00:00
des
e6d4c5218f Import LDNS and build it as an internal library. 2013-02-15 13:44:18 +00:00
pluknet
ac15ee1b8d Major update for unix_cmsg from Andrey Simonenko.
Quoting the submitter:
- Added tests for SCM_BINTIME, LOCAL_PEERCRED, cmsghdr.cmsg_len
- Code that checks correctness of groups was corrected (getgroups(2) change)
- unix_cmsg.c was completely redesigned and simplified
- Use less timeout value in unix_cmsg.c for faster work
- Added support for not sending data in a message, not sending data and
  data array associated with a cmsghdr structure in a message
- Existent tests were improved
- unix_cmsg.t was redesigned and simplified

Correctness of unix_cmsg verified on 7.1-STABLE, 9.1-STABLE and 10-CURRENT.

PR:		bin/131567
Submitted by:	Andrey Simonenko <simon@comsys.ntu-kpi.kiev.ua>
MFC after:	2 weeks
2013-02-11 12:56:23 +00:00
adrian
ade04b56f7 Teach athalq about the recent if_ath_alq timestamp format change. 2013-02-11 02:54:24 +00:00
dim
491c27dc04 Add missing src.conf(5) fragments for WITHOUT_LIBCPLUSPLUS and WITH_GPL_DTC. 2013-02-02 22:42:46 +00:00
dim
70538df621 Pull in r170135 from upstream clang trunk:
Dont use/link ARCMT, StaticAnalyzer and Rewriter to clang when the user
  specifies not to. Dont build ASTMatchers with Rewriter disabled and
  StaticAnalyzer when it's disabled.

  Without all those three, the clang binary shrinks (x86_64) from ~36MB
  to ~32MB (unstripped).

To disable these clang components, and get a smaller clang binary built
and installed, set WITHOUT_CLANG_FULL in src.conf(5).  During the
initial stages of buildworld, those extra components are already
disabled automatically, to save some build time.

MFC after:	1 week
2013-02-02 22:28:29 +00:00
gahr
a3f8831b82 - Fix more style(9)-related issues (copyright header, spaces after function
names, unnecessary casts)
- Change type of boolean variable from char to bool

Suggested by:	jhb, zont, jmallett
Reviewed by:	cognet
Approved by:	cognet
2013-02-01 13:04:06 +00:00
gahr
3706909a83 - Remove underscores from the internal structure name, as it doesn't collide
with the user's namespace.

- Correct size and position variables type from long to size_t.

- Do not set errno to ENOMEM on malloc failure, as malloc already does so.

- Implement the concept of "buffer data length", which mandates what SEEK_END
  refers to and the allowed extent for a read.

- Use NULL as read-callback if the buffer is opened in write-only mode.
  Conversely, use NULL as write-callback when opened in read-only mode.

- Implement the handling of the ``b'' character in the mode argument. A binary
  buffer differs from a text buffer (default mode if ``b'' is omitted) in that
  NULL bytes are never appended to writes and that the "buffer data length"
  equals to the size of the buffer.

- Remove shall from the man page. Use indicative instead. Also, specify that
  the ``b'' flag does not conform with POSIX but is supported by glibc.

- Update the regression test so that the ``b'' functionality and the "buffer
  data length" concepts are tested.

- Minor style(9) corrections.

Suggested by:	jilles
Reviewed by:	cognet
Approved by:	cognet
2013-01-31 16:39:50 +00:00
gahr
e7ca48d15b Add fmemopen(3), an interface to get a FILE * from a buffer in memory, along
with the respective regression test.
See http://pubs.opengroup.org/onlinepubs/9699919799/functions/fmemopen.html

Reviewed by:	cognet
Approved by:	cognet
2013-01-30 14:59:26 +00:00
kib
7b6927c4af Rework the handling of the children for the pthread_vfork_test. The
trivial handler for SIGCHLD is installed, and SIGCHLD is blocked, to
not abandon our zombies to init(8). This way, the zombies are around
slightly longer, allowing to actually exercise the logic for p_pwait
use by the test.

MFC after:	1 week
2013-01-30 13:14:34 +00:00
gabor
d992e3eb2a - Add a BSD-licensed patch, ported by Pedro F. Giffuni (pfg) from
DragonflyBSD and install it as bsdpatch.  WITH_BSD_PATCH makes it
  default and installs GNU patch as gnupatch.

Submitted by:	pfg
Obtained from:	The DragonflyBSD Project
2013-01-29 17:03:18 +00:00
brooks
aaba5893d6 Use = not == in test arguments.
Submitted by:	Christoph Mallon <christoph.mallon@gmx.de>
2013-01-24 20:47:37 +00:00
emaste
344c251409 Restore Python 2.6+ compatibility
SVN r245536 ported this to Python 3.  The major change was the use of the
print function.  Unfortunately this is incompatible with Python 2, which
is still the default version in the ports tree.

Use a __future__ import to make this compatible with Python 2.6 and later.
2013-01-22 18:02:48 +00:00
brooks
af380cc2bf Implement the -l option using ln(1) to facilitate boostrapping.
Ignore the new options -D, -h, -T, and -U.  Adjust -M support to ignore
an argument.

Sponsored by:	DARPA, AFRL
Reviewed by:	ian, ray, rpaulo
2013-01-21 22:32:00 +00:00
eadler
b42e95f726 Add option to make pc-sysinstall optional
Approved by:	cperciva
2013-01-18 15:57:09 +00:00
adrian
465afdcd27 Add extra debugging fields. 2013-01-17 17:12:44 +00:00
andrew
9b858bb6f0 Add compiler support for the ARM EABI.
ARM EABI support is disabled by default and can be enabled by setting
WITH_ARM_EABI when building, however only the kernel-toolchain target will
work with this flag until the rest of the support is added.
2013-01-17 05:56:28 +00:00
eadler
9d3b679901 Convert to Python 3
Approved by:	cperciva
2013-01-17 04:20:53 +00:00
bz
a3df209122 Add a src.conf(5) option to allow users to compile in the "NONE cipher",
which, only after authentication, disables crypto, and only for sessions
without a terminal.

Submitted by:	Jeremy Chadwick (freebsd jdc.parodius.com)
PR:		bin/163095
MFC after:	10 days
2013-01-17 01:51:04 +00:00
np
980736a6d7 Allow "ivlan" (inner VLAN) to be used as an alias for "vlan" when
specifying match criteria.  "vlan" continues to be valid here, and it
continues to be valid when deleting, rewriting, inserting, or stacking
an 802.1q tag to a matching packet.

MFC after:	3 days
2013-01-17 00:21:45 +00:00
brooks
3386d88ffd Remember the . in .\" in the WITH_NMTREE file and regenerate the output.
Reported by:	joeld
2013-01-14 20:38:32 +00:00
jilles
d139340997 sh: Pass $? to command substitution containing compound/multiple commands.
Example:
  false; echo $(echo $?; :)
2013-01-14 12:20:55 +00:00
jilles
adc48be9c2 sh: Add testcase that $? is preserved into a simple command substitution.
The test builtins/trap6.0 already uses this but having it separate eases
diagnosis if this would break.
2013-01-13 22:35:51 +00:00
jilles
84e42b7805 sh: Add some testcases related to subshells.
These failed in earlier attempts to execute more subshells without forking.
The patches are uncommitted.
2013-01-13 19:39:13 +00:00
jilles
b479a582c3 sh: Fix crash when parsing '{ } &'.
MFC after:	1 week
2013-01-13 19:26:33 +00:00
jilles
1af5c5cc5f sh: Don't lose $? when backquoted command ends with semicolon or newline.
An empty simple command was added and overwrote the exit status with 0.

This affects `...` but not $(...).

Example:
  v=`false;`; echo $?
2013-01-13 19:19:40 +00:00
brooks
f96c808001 Add pwcache(3) and vis(3) to libegacy as install(1) is about to grow a
dependency on them.

Sponsored by:	DARPA, AFRL
2013-01-11 20:51:02 +00:00
brooks
8ab7717e28 Always install our mtree as /usr/sbin/fmtree and link it as
/usr/sbin/mtree by default.

Add a src.conf option WITH_NMTREE that causes NetBSD's mtree to be linked
as /usr/sbin/mtree as well as /usr/sbin/nmtree.
2013-01-09 21:07:08 +00:00
adrian
fc044aacf6 Add the "enable at reset" functionality to trigger spectral scan upon
a channel change/reset.
2013-01-09 18:50:06 +00:00
obrien
8aa5aba1d5 Following r226271, allow disabling lzma support with "WITHOUT_LZMA_SUPPORT".
Correct r226271 which should have used WITHOUT_BZIP2_SUPPORT per r166255.

Obtained from:	Juniper Networks
2013-01-08 18:37:12 +00:00
adrian
c7de6a7866 Disable clang for athstats for now. 2013-01-02 18:49:40 +00:00
adrian
462f8d2008 Add missing err() format string. 2013-01-02 18:33:48 +00:00
adrian
19180edbd9 Fix missing err() format string. 2013-01-02 18:29:54 +00:00
adrian
48278ccb60 Fix some conversions to keep clang happy. 2013-01-02 18:29:11 +00:00
adrian
c3f438d7f8 Fix some clang warnings! 2013-01-02 18:26:32 +00:00
adrian
e2599129bc Fix up some warnings from clang.
This still triggers a bug in clang..
2013-01-02 18:21:24 +00:00
adrian
b01e424a2b Add missing err() format strings.
Thanks to: clang
2013-01-02 18:14:26 +00:00
adrian
61df60ab89 * Add missing err() string formats;
* Fix up a printf() type mismatch.

Thanks to: clang
2013-01-02 18:12:06 +00:00
adrian
0e8a98ac71 * Add missing format specifier for err()
* add missing exit(0)
* Fix some operator evaluation complaints.

Thanks to: clang
2013-01-02 18:09:30 +00:00
adrian
edb42d2f96 Fix some printf() formats.
Found by:	clang
2013-01-02 18:05:31 +00:00
adrian
8ca6035013 Fix incorrect format string. 2013-01-02 18:03:19 +00:00
adrian
6c49683490 Add a very skeletal spectral scan control application.
The main use for this is to manually trigger spectral scan operations
(athspectral -i athX start) whilst doing debugging.
2013-01-02 04:02:27 +00:00
luigi
eb65fddc45 use nanosecond resolution, make sure gettimeofday
is called at most every 100 packets.
2012-12-27 09:15:21 +00:00
luigi
ae04020c93 various connections to last commit 2012-12-25 07:29:25 +00:00
luigi
da7a626830 small cleanup of the code, and add support for running multiple
threads on each socket.
2012-12-23 23:03:45 +00:00
bapt
7bb46ae3c4 Add etc/periodic/daily/220.backup-pkgdb to OptionalObsoleteFiles.inc 2012-12-20 22:07:47 +00:00
eadler
1588d05c32 Add an additional regression tests for other cases to ensure these do not get fixed by accident. 2012-12-18 21:42:45 +00:00
eadler
0c8af40857 POSIX requires that non-existent or null arguments be treated as if a
zero argument were supplied.

Add a regression test to catch this case as well.

PR:		bin/174521
Submitted by:	Daniel Shahaf <danielsh@elego.de> (pr)
Submitted by:	Mark Johnston <markjdb@gmail.com> (initial patch)
Reviewed by:	jilles
Approved by:	cperciva (implicit)
MFC after:	3 weeks
2012-12-18 21:02:38 +00:00
phk
c103698618 Update to the new and brighter pkg world 2012-12-15 17:54:29 +00:00
jilles
e5dd01ef24 sh: Detect and flag write errors on stdout in builtins.
If there is a write error on stdout, a message will be printed (to stderr)
and the exit status will be changed to 2 if it would have been 0 or 1.

PR:		bin/158206
2012-12-12 22:01:10 +00:00
eadler
9860195389 A number of places in the source tree still reference cuad.* after
sio(4) was deprecated by uart(4).

s/cuad/cuau/g/

PR:		docs/171533
Reviewed by:	imp
Approved by:	cperciva (implicit)
MFC after:	3 weeks
2012-12-08 22:16:36 +00:00
jilles
eae7439d0b libc: Add a missing header to a test program.
Usage of dup(), mkstemp() and unlink() needs <unistd.h>.
2012-12-08 19:42:15 +00:00
dim
b4ddb922b1 Upgrade our copy of llvm/clang to r168974, from upstream's release_32
branch.  This is effectively llvm/clang 3.2 RC2; the 3.2 release is
coming soon.
2012-12-03 19:24:08 +00:00
dim
056abd2059 Vendor import of clang release_32 branch r168974 (effectively, 3.2 RC2):
http://llvm.org/svn/llvm-project/cfe/branches/release_32@168974
2012-12-02 13:20:44 +00:00
dim
6de2c08bc4 Vendor import of llvm release_32 branch r168974 (effectively, 3.2 RC2):
http://llvm.org/svn/llvm-project/llvm/branches/release_32@168974
2012-12-02 13:10:19 +00:00
adrian
518d1f1f8f Add in a totally hacked up copy of the AR5416 descriptor decoding stuff,
as well as TDMA related things.

I used this to debug TDMA related issues in -HEAD.
2012-11-27 02:28:42 +00:00
emaste
3c42bc6af3 Non-void function should return a value.
Found by: clang
2012-11-20 19:23:44 +00:00
emaste
854774d3a5 Remove unused variable. 2012-11-20 01:42:18 +00:00
emaste
7f1a5459c2 Use '%zu' and '%zd' as appropriate for size_t / ssize_t. 2012-11-19 23:07:38 +00:00
emaste
250448df7d Zero the whole struct not just the size of a pointer.
Found by: clang
2012-11-19 22:56:51 +00:00
emaste
a2abcf1a7a Use '%zd' format specifier for ssize_t
Found by: clang
2012-11-19 22:53:57 +00:00
emaste
2125cd9a35 Use '%zd' printf format for ssize_t. 2012-11-19 22:46:17 +00:00
jilles
1ecaf6c6d9 sh: Apply rlimits to parser/alias10.0 so it fails fast.
Requested by:	uqs
2012-11-18 23:15:22 +00:00
adrian
5e172688c7 Make this a flag. 2012-11-17 02:38:36 +00:00
adrian
be4e4a5c0f Implement AR5210 descriptor decoding. 2012-11-17 02:37:25 +00:00
adrian
3865e7424a Add AR5211 descriptor decoding support. 2012-11-17 02:14:50 +00:00
adrian
f4a353a947 Add AR5212 frame decoding support. 2012-11-17 01:57:45 +00:00
adrian
c070d0185a Implement a basic data decoder for the data produced by if_ath_alq.
This decodes the AR5416 family 11n TX and RX descriptors.
2012-11-17 01:11:00 +00:00
marcel
a8f2df570f Don't install atf.test.mk if MK_ATF == no.
Submitted by:	Garrett Cooper <yanegomi@gmail.com>
2012-11-15 04:39:23 +00:00
jilles
5acb236703 sh: Add tests for modifying an alias (r242766).
Note: parser/alias10.0 will eat a lot of memory/cpu time when it fails (with
the old sh).
2012-11-08 13:36:19 +00:00
jilles
5e3407ce46 sh: Test that a redefined alias works. 2012-11-07 23:15:36 +00:00
brooks
41399856f6 Add a description of WITHOUT_CLANG_IS_CC. 2012-11-05 21:53:23 +00:00
obrien
bdeb3f5a20 Test both active and non-active cases. 2012-10-26 20:14:40 +00:00
obrien
f3ec0567c4 Iterate rather than use recursion. We can blow out the kernel stack if there
is a long chain of fork(2)s.
2012-10-26 15:44:29 +00:00
eadler
3f7a414911 remove duplicate semicolons where possible.
Approved by:	cperciva
MFC after:	1 week
2012-10-22 03:00:37 +00:00
eadler
b08b5fd4fa Covert regression test to python 3
Approved by:	cperciva
MFC after:	3 days
2012-10-22 02:29:44 +00:00
eadler
90e13cd2eb Finish migration of MAINTAINER entries
Approved by:	cperciva
MFC after:	3 days
2012-10-22 02:12:11 +00:00
eadler
fb692da397 Covert to python 3
Approved by:	cperciva
MFC after:	3 days
2012-10-22 02:12:02 +00:00
marcel
8412efbea8 Add ATF to the build. This is may be a bit rought around the egdes,
but committing it helps to get everyone on the same page and makes
sure we make progress.

Tinderbox breakages that are the result of this commit are entirely
the committer's fault -- in other words: buildworld testing on amd64
only.

Credits follow:

Submitted by:	Garrett Cooper <yanegomi@gmail.com>
Sponsored by:	Isilon Systems
Based on work by:	keramida@
Thanks to:	gnn@, mdf@, mlaier@, sjg@
Special thanks to:	keramida@
2012-10-22 01:18:41 +00:00
andreast
75529c7de3 Remove the netncp and nwfs files from here. They will be moved to the
ObsoleteFiles.inc file later.

Discussed with: attilio
2012-10-17 19:21:52 +00:00
gabor
7595cc54ef - Remove GNU sort and the WITH_GNU_SORT knob 2012-10-13 18:40:39 +00:00
emaste
f0db6be72a Make local function static. 2012-10-11 21:24:07 +00:00
np
d69f5fddc1 Add a "clearstats" subcommand to cxgbetool that lets you clear the
MAC statistics for any port.

For example:
# cxgbetool t4nex0 clearstats 0

Submitted by:	gnn@
MFC after:	3 days
2012-10-10 20:09:19 +00:00
np
6764c20438 Add an "i2c" subcommand to cxgbetool. You can use this to read
information from the transceivers connected to the ports of a
cxgbe(4) based card.

# cxgbetool t4nex0 i2c <port_id> <dev_addr> <addr> [<count>]

For example:
# cxgbetool t4nex0 i2c 0 0xa0 3
0x10 [16]

(As per SFF-8472 the SFP+ module is at 0xa0 and bit 4 in the value at
address 3 indicates it's a 10Gbase-SR module, which it is.)
2012-10-10 17:29:51 +00:00
kevlo
ceb08698f2 Revert previous commit...
Pointyhat to:	kevlo (myself)
2012-10-10 08:36:38 +00:00
kevlo
8747a46991 Prefer NULL over 0 for pointers 2012-10-09 08:27:40 +00:00
marcel
52e7fd7c54 Add support for bmake. This includes:
1.  Don't do upgrade_checks when using bmake. As long as we have WITH_BMAKE,
    there's a bootstrap complication in ths respect. Avoid it. Make the
    necessary changes to have upgrade_checks work wth bmake anyway.
2.  Remove the use of -E. It's not needed in our build because we use ?= for
    the respective variables, which means that we'll take the environment
    value (if any) anyway.
3.  Properly declare phony targets as phony as bmake is a lot smarter (and
    thus agressive) about build avoidance.
4.  Make sure CLEANFILES is complete and use it on .NOPATH. bmake is a lot
    smarter about build avoidance and should not find files we generate in
    the source tree. We should not have files in the repository we want to
    generate, but this is an easier way to cross this hurdle.
5.  Have behavior under bmake the same as it is under make with respect to
    halting when sub-commands fail. Add "set -e" to compound commands so
    that bmake is informed when sub-commands fail.
6.  Make sure crunchgen uses the same make as the rest of the build. This
    is important when the make utility isn't called make (but bmake for
    example).
7.  While here, add support for using MAKEOBJDIR to set the object tree
    location. It's the second alternative bmake looks for when determining
    the actual object directory (= .OBJDIR).

Submitted by:	Simon Gerraty <sjg@juniper.net>
Submitted by:	John Van Horne <jvanhorne@juniper.net>
2012-10-06 20:01:05 +00:00
marcel
bd137de2db Add bmake to the build and allow it to be installed as make(1) instead
of FreeBSD's make by setting WITH_BMAKE.  The WITH_BMAKE build makes it
easy for people to switch while working out the kinks -- think ports
tree here.  The option will be removed in due time.

Submitted by:	Simon Gerraty (sjg@juniper.net)
2012-10-06 19:19:21 +00:00
emaste
3caceded2a Clean up compiler warnings.
More work is needed here but this now builds with WARNS=6.

Sponsored by: ADARA Networks
MFC after: 2 weeks
2012-10-03 22:02:16 +00:00
emaste
db806db21d Add regression test for kern/172075.
Sponsored by:	ADARA Networks
PR:		kern/172075
2012-09-26 00:25:09 +00:00
jilles
c0470c839d sh: Add some tests for aliasing a utility to itself. 2012-09-22 12:52:41 +00:00
zeising
ebc127bf11 Add documentation for the WITHOUT_KDUMP switch.
This swtich was introduced in r240404

Approved by:	joel (mentor)
2012-09-19 11:38:37 +00:00
eadler
8600cbb5b6 Correct double "the the"
Approved by:	cperciva
MFC after:	3 days
2012-09-14 21:28:56 +00:00
eadler
777230d53d Remove scripts and tools which only functioned when src was using CVS
Approved by:	cperciva
MFC after:	1 week
2012-09-13 17:49:11 +00:00
obrien
7b9a39e571 r235638 is not the clean way to add support for building on ancient FreeBSD
versions.  Instead use Imp's good work on "legacy" and follow the outcome
of the previous TRB discussions on this topic.

Now use the libc getline() if it exists, and only where it doesn't
create a bootstraping version.
2012-09-11 22:38:33 +00:00
fabient
886e70314c Add SOFT as a possible section to exclude from counter list. 2012-09-10 16:32:28 +00:00
adrian
dc0b46fdc3 Add some colour to make it easy (well, easier) to see what the current
selected rates and current sample rates are.

(Note: when run under high traffic and with -s 0.1 the display becomes very
mesmerising.  You've been warned.)
2012-09-10 06:07:28 +00:00
adrian
7f13a2e391 Add a '-s <timeout>' option which will display live rate control
statistics.
2012-09-08 01:14:13 +00:00
adrian
652b16f79f Tidy up the output quite substantially, making it fit well within
80 columns.

This makes it much easier to use in a shell script, to display a "top"
style output with live rate control data.
2012-09-07 06:02:40 +00:00
adrian
ec006196aa Make this build again! 2012-09-07 06:02:01 +00:00
emaste
78d26d09cb Failure to open netmap device is unrecoverable.
There's no reason to "fail later" since there's nothing this tool can do in
netmap mode without /dev/netmap open.
2012-09-04 20:51:25 +00:00
gnn
618d9246d7 Add a reasonable error message telling the caller to specify a program
to be executed under hwpmc.  If there is no program to run then
exit.
2012-09-04 20:14:37 +00:00
joel
d666707f2a Minor mdoc fix. 2012-09-01 07:11:25 +00:00
des
7bb834a124 The error syntax has changed. 2012-08-30 22:56:32 +00:00
adrian
714dc451ce Do a bunch of fixing and refactoring.
Fix up gzip to crunch right.

Add kenv, although I'm not yet sure why it isn't working on my MIPS
boards (reading kenv always returns blank.)
2012-08-29 22:55:50 +00:00
adrian
41ab51583c Disable fsck_ffs for now, 4MB target size issues. 2012-08-29 22:54:39 +00:00
adrian
7dbe059b5b Disable building textproc for now, it doesn't fit on my 4MB flash
partition.

Add -lcrypt as a dynamic target.
2012-08-29 22:54:27 +00:00
adrian
4a4898787c For now, disable building wpa_supplicant.
My 4MB flash builds can't handle the bloat.
2012-08-29 22:53:54 +00:00
dim
a4812d49a1 Add libc++ and libcxxrt related files to OptionalObsoleteFiles.inc.
MFC after:	1 week
2012-08-26 14:30:14 +00:00
dim
ddcb543796 Add three additional clang intrinsics headers, which I missed in the
previous import.
2012-08-20 20:56:40 +00:00
dim
ea718b0e08 Upgrade our copy of llvm/clang to trunk r162107. With thanks to
Benjamin Kramer and Joerg Sonnenberger for their input and fixes.
2012-08-20 18:33:03 +00:00
dim
554bcb69c2 Vendor import of clang trunk r161861:
http://llvm.org/svn/llvm-project/cfe/trunk@161861
2012-08-15 20:02:54 +00:00
dim
721c201bd5 Vendor import of llvm trunk r161861:
http://llvm.org/svn/llvm-project/llvm/trunk@161861
2012-08-15 19:34:23 +00:00
adrian
cebcfc8500 Add a missing HAL_DMA_ADDR definition. 2012-08-09 23:08:22 +00:00
adrian
bfe847db64 Add HAL_DMA_ADDR. 2012-08-09 23:04:20 +00:00
jilles
4d961f95f8 nftw(): POSIX says directories causing loops should be silently skipped.
Formerly, loops caused nftw() to abort the traversal with ELOOP.
2012-08-09 22:05:40 +00:00
emaste
e3d2617c9b Be more descriptive about poll error / timeout when transmitting. 2012-08-08 19:15:01 +00:00
emaste
0e7adfb291 Round displayed pps (instead of truncating) 2012-08-08 13:54:26 +00:00
ae
798113957d Add to the debug output the offset from the parent partitioning scheme. 2012-08-06 08:39:29 +00:00
ae
23e8ad15ba Add simple test program that uses the partition tables handling code.
It is useful to test and debug how boot loader handles partition tables
metadata.
2012-08-05 15:40:16 +00:00
adrian
6a9b72c2bc Break out the parsing code from main() and modularise things a little.
The eventual aim will be to support listing "one" and "all" stations for
the given ath device.
2012-07-30 01:42:22 +00:00
dim
32ec1fa0f5 When WITHOUT_CLANG is being used, also clean out the clang 3.1 headers
in OptionalObsoleteFiles.inc.

PR:		misc/169902
Submitted by:	Thomas Eberhardt <sneakywumpus@googlemail.com>
MFC after:	3 days
2012-07-23 16:36:13 +00:00
phk
e4dd41f394 Derive FREEBSD_PART from /etc/fstab, and make it full device name.
Give suggestion for next steps when done.

Inspired by patches from:	Flemming "F3" Jacobsen
2012-07-22 20:55:42 +00:00
phk
5f88891912 Replace hardcoded /mnt with ${SBMNT} which defaults to /mnt.sysbuild
Submitted by:	Flemming "F3" Jacobsen
2012-07-22 19:32:27 +00:00
adrian
555bfe85d8 Add a needed #include due to my recent change. 2012-07-20 07:49:26 +00:00
adrian
64ddb429bd Add missing SRCS. 2012-07-20 07:38:11 +00:00
adrian
a42011453b Add the new athratestats tool. 2012-07-20 07:17:24 +00:00
adrian
1303e3bf5c Tidy things up substantially:
* remove some debugging;
* introduce command line arguments;
* introduce support for non-ath0 interfaces.
2012-07-20 06:11:26 +00:00
adrian
a343cd6779 Use the rate control table to display the rate rather than the rix,
making the output of this program much more meaningful.
2012-07-20 02:18:47 +00:00
adrian
6618076433 Implement a first cut of the 'sample' rate statistics userland utility.
This outputs almost exactly the same information as the kernel sysctl does,
however the rix -> rate mapping isn't yet available as a TLV.
2012-07-20 01:38:03 +00:00
jilles
6e014f4c11 sh: Add a simple test for the "local" builtin. 2012-07-15 10:22:13 +00:00
jilles
689774f8e7 sh: Expand assignment-like words specially for export/readonly/local.
Examples:
  export x=~
now expands the tilde
  local y=$1
is now safe, even if $1 contains IFS characters or metacharacters.

For a word to "look like an assignment", it must start with a name followed
by an equals sign, none of which may be quoted.

The special treatment applies when the first word (potentially after
"command") is "export", "readonly" or "local". There may be quoting
characters but no expansions. If "local" is overridden with a function there
is no special treatment ("export" and "readonly" cannot be overridden with a
function).

If things like
  local arr=(1 2 3)
are ever allowed in the future, they cannot call a "local" function. This
would either be a run-time error or it would call the builtin.

This matches Austin Group bug #351, planned for the next issue of POSIX.1.

PR:		bin/166771
2012-07-15 10:19:43 +00:00
zeising
b0fedc4f6d Change language in WITH_BSDCONFIG to match other options, and regen
src.conf(5), which was missed in r238438.

Approved by:	joel (mentor)
2012-07-14 10:17:47 +00:00
dteske
3981b9b76a Import bsdconfig(8) as a replacement for the post-install abilities of
deprecated sysinstall(8). NOTE: WITH_BSDCONFIG is currently required.

Submitted by:	Devin Teske (dteske), Ron McDowell <rcm@fuzzwad.org>
Reviewed by:	Ron McDowell <rcm@fuzzwad.org>
Approved by:	Ed Maste (emaste)
2012-07-14 03:16:57 +00:00
jilles
5bce107d09 sh: Add tests where "export" does not parse differently.
It is planned to expand variable assignments as assignments (no word
splitting, different tilde expansion) when they follow a "declaration
utility" (export, readonly or local). However, a quoted character cannot be
part of a "name" so things like \v=~ are not assignments, and the existing
behaviour applies.
2012-07-13 22:29:02 +00:00
jhb
2b8d56f3cf The etcupdate utility is a tool for managing updates to files that are
not updated as part of `make installworld' such as files in /etc.  It
manages updates by doing a three-way merge of changes made to these files
against the local versions.  It is also designed to minimize the amount
of user intervention with the goal of simplifying upgrades for clusters
of machines.

The primary difference from mergemaster is that etcupdate requires less
manual work.  The primary difference from etcmerge is that etcupdate
updates files in-place similar to mergemaster rather than building a
separate /etc tree.

Requested by:	obrien, kib, theraven, joeld (among others)
2012-07-13 13:23:48 +00:00
kib
003ccf85fa Add a test program, written by Stephan Uphoff, which demonstrates the
deadlock due to i/o performed over the buffers backed by file mappings.

MFC after:	2 weeks
Approved by:	ups
2012-07-11 19:12:10 +00:00
emaste
66fc945ab8 Allow continuous packet transmission (via -t 0)
Also add a missing check for the cancel flag while waiting for the first
packet in receive mode.
2012-07-06 17:03:43 +00:00
emaste
5d3526c6d6 Also report tx bandwidth with Ethernet overhead 2012-07-06 15:36:39 +00:00
emaste
2b188d4ec4 Allow threads to finish up when terminated by user
Set a flag and allow worker threads to finish upon ^C, instead of
immediately cancelling them, so that final packet count and rate
stats can be displayed.
2012-07-06 13:21:23 +00:00
obrien
a4e243117e Remove the "funny targets" make check. We no longer need embedded :: targets
to build FreeBSD (they are used in Perl man pages).  We never needed embedded
"!" in targets that I can find.

We got this from OpenBSD and I cannot find any other make that supports
such things -- contrary to their commit message claim: "This behaviour
is also consistent with other versions of make.".
2012-07-05 18:23:36 +00:00
pjd
36219ba107 Recognize 'none' or '0' as no flags. 2012-07-04 17:31:53 +00:00
emaste
0bbce8e0d2 Update comment to reflect function's actual operation 2012-07-03 17:50:44 +00:00
marcel
71a3fb9c45 A cross-reference takes a man page section as well. Assume pkg(1),
based on pkg_add(1).
2012-07-02 20:26:11 +00:00
marcel
9a9eba4d36 Add description for INSTALL_AS_USER 2012-07-02 20:24:01 +00:00
marcel
3841b875ad Fix typo in option description file (using svn move). 2012-07-02 20:01:48 +00:00
bapt
1903f68f13 New build KNOB: WITHOUT_PKGBOOTSTRAP to condition building of usr.sbin/pkg
Do not condition usr.sbin/pkg building on WITHOUT_PKGTOOLS anymore, so that users can
remove the old pkg_* tools without removing the pkgng boostrap

Approved by:	des (mentor)
MFC after:	1 month
2012-07-02 15:28:50 +00:00
adrian
525ad8cc08 Bump this up - that way the AR9300 and later MACs get covered (for now)
by the AR5416 register map.
2012-06-30 01:40:29 +00:00
obrien
b257ff8e05 Support also running a 32-bit test on 64-bit platforms. 2012-06-29 15:54:07 +00:00
emaste
897cc95908 Fix ioctl type for compiling with clang 2012-06-28 20:10:43 +00:00
kib
8710f3e284 Add a test for number of CPUs configured/online.
MFC after:	1 week
2012-06-27 20:34:29 +00:00
gabor
c7fbb67362 - Switch to BSD sort as default sort. GNU sort will still be installed as
"gnusort".  Most of the BSD sort development work was done by
  Oleg Moskalenko <oleg.moskalenko@citrix.com>.
- GNU grep can be set to default by setting WITH_GNU_GREP.  It will cause
  BSD sort to be installed as "bsdsort".

Portbuild tested by:    linimon
2012-06-27 05:59:01 +00:00
kevlo
8473fac955 Correct sizeof usage
Obtained from:	DragonFly
2012-06-25 05:41:16 +00:00
obrien
d7c61f6b4f Provide a mechanism to not clear out the work and output dirs when
developing tests.
2012-06-20 21:38:16 +00:00
adrian
ba79261a63 Convert athdebug to use the 64 bit dev.ath.X.debug sysctl. 2012-06-15 20:08:13 +00:00
adrian
968a30af3f Add the AMPDU BAR TX statistics to the "ampdu" tag. 2012-06-15 08:37:46 +00:00
obrien
262e4e322b Add a test for the :tl & :tu modifiers. 2012-06-12 23:16:00 +00:00
adrian
811b2c62cc Add athaggrstats to the ath(4) tools build. 2012-06-10 06:44:19 +00:00
adrian
7abe396bf0 Flesh out 'athaggrstats', a utility which will display the aggregation
specific statistics for ath(4).
2012-06-10 06:44:04 +00:00
jilles
ccb8c35eab sh: Do not assume that SIGPIPE will only kill a subshell in builtins/wait3.0
test.

POSIX says that SIGPIPE affects a process and therefore a SIGPIPE caused and
received by a subshell environment may or may not affect the parent shell
environment.

The change assumes that ${SH} is executed in a new process. This must be the
case if it contains a slash and everyone appears to do so anyway even though
POSIX might permit otherwise.

This change makes builtins/wait3.0 work in ksh93.
2012-06-08 22:54:25 +00:00
bz
2983f3f053 TinyBSD now seems to be hosted elsewhere. 2012-06-07 09:14:28 +00:00
kib
e086dc93a3 Do not execute a needed statement with side-effect in assert().
MFC after:	3 days
2012-06-06 17:26:52 +00:00
kib
b911315e84 Add gettimeofday() test.
MFC after:	3 days
2012-06-06 16:26:55 +00:00
emax
17a0246939 Fix license
Pointed by:	brueffer
2012-06-05 22:02:27 +00:00
emax
80cdbfd6e9 Add a very simple debug tool that would dump list of interfaces,
addresses on each interface, and, associated refcounter. I found
it handy to check for address refcounter leaks.
2012-06-05 21:35:47 +00:00
obrien
5bfb5484b9 Correct examples to the latest version I had. 2012-06-05 17:36:28 +00:00
obrien
3d92a0e1be Add a regression test for filemon(4) [r236592]. 2012-06-04 22:59:33 +00:00
obrien
ffd816d2cd Add regression test for '-V' command line option (requires r236346). 2012-05-31 01:07:52 +00:00
obrien
c7adc0ccb4 make it easier to check newly-built make 2012-05-30 22:27:34 +00:00
obrien
2c3aca1390 make it easier to test newly-built make. 2012-05-30 22:26:16 +00:00
gjb
6cc346a016 Add '-width Pa' to src.conf.5 for mdoc(7) style consistency.
MFC after:	3 days
2012-05-30 02:37:20 +00:00
dim
2b2816e083 Vendor import of llvm release_31 r156863 (the actual 3.1 release):
http://llvm.org/svn/llvm-project/llvm/branches/release_31@156863
2012-05-23 21:37:39 +00:00
bapt
913116490c Import byacc from invisible island, it brings us lots of compatibilities with
bison, keeping full compatibility with our previous yacc implementation.

Also bring the ability to create reentrant parser

This fix bin/140309 [1]

PR:		bin/140309 [1]
Submitted by:	Philippe Pepiot <ksh@philpep.org> [1]
Approved by:	des (mentor)
MFC after:	1 month
2012-05-21 13:31:26 +00:00
kevlo
8be39d9fef According to shared memory man pages, advice including <sys/types.h>
instead of <sys/param.h>
2012-05-21 07:52:46 +00:00
marcel
6be3c8be38 Document the ED_CRYPTO and LS_COLORS options.
Obtained from:	Juniper Networks, Inc.
2012-05-19 20:05:27 +00:00
gber
6f7c735300 Import work done under project/nand (@235533) into head.
The NAND Flash environment consists of several distinct components:
  - NAND framework (drivers harness for NAND controllers and NAND chips)
  - NAND simulator (NANDsim)
  - NAND file system (NAND FS)
  - Companion tools and utilities
  - Documentation (manual pages)

This work is still experimental. Please use with caution.

Obtained from: Semihalf
Supported by:  FreeBSD Foundation, Juniper Networks
2012-05-17 10:11:18 +00:00
avg
05e1e5ec45 zfsboottest: update for the recent zfs boot code changes
MFC after:	1 month
2012-05-13 09:27:08 +00:00
gjb
9507326d1f Regenerate src.conf(5) for mdoc(7) and typo corrections.
PR:		167804
Submitted by:	Nobuyuki Koganemaru (kogane!jp.freebsd.org)
MFC after:	3 days
2012-05-12 16:12:36 +00:00
gabor
3a49188aec - Add regression tests for BSD sort 2012-05-11 16:04:55 +00:00
gabor
52bc32b6b5 - Hook up BSD sort to the build. By default, it will be installed as
"bsdsort" and GNU sort will be the default "sort".  When WITH_BSD_SORT
  is set, BSD sort will be the default "sort" and GNU sort will be installed
  as "gnusort".
2012-05-11 12:47:21 +00:00
eadler
bcf9dd59e8 Add some missing files to OLD_FILES
PR:		conf/166460
Submitted by:	Jeremy Chadwick <freebsd@jdc.parodius.com>
Reviewed by:	stable@
Approved by:	cperciva
MFC after:	2 weeks
2012-05-09 17:30:44 +00:00
avg
4b75b9fd05 zfsboottest.sh: correctly check and suggest value of vfs.root.mountfrom
... it was missing "zfs:" prefix.

Reported by:	theraven
MFC after:	10 days
2012-05-07 15:06:07 +00:00
avg
21b948097d zfsboottest.sh: gracefully handle default value of bootfs property
Reported by:	theraven
MFC after:	10 days
2012-05-07 15:03:42 +00:00
luigi
a742cb5d54 indicate the time per packet in nanoseconds. 2012-05-03 21:03:21 +00:00
luigi
72d6cdcd97 add support for pcap receive statistics (used by net-mgmt/darkstat) 2012-05-03 17:08:40 +00:00
dim
822bde9df5 Vendor import of clang release_31 branch r155985:
http://llvm.org/svn/llvm-project/cfe/branches/release_31@155985
2012-05-03 16:53:59 +00:00
dim
2c5e9d71ab Vendor import of llvm release_31 branch r155985:
http://llvm.org/svn/llvm-project/llvm/branches/release_31@155985
2012-05-03 16:50:55 +00:00
luigi
3a0d4ba309 add some performance data 2012-05-03 16:09:44 +00:00
luigi
5561327018 - add code to run pkt-gen on top of libpcap so we can see the
difference from a native API

- add some testing options, such as conditional prefetching and
  packet copy.
2012-05-03 15:37:05 +00:00
luigi
5bceb861dc - correct a bug in pcap_dispatch(): a count of 0 means infinity.
- in pcap_dispatch(), issue a prefetch on the buffer before the
  callback, this may save a little bit of time if the client
  is very fast.

- in pcap_inject(), use a fast copy routine, which also helps
  saving a few nanoseconds with fast clients.
2012-05-03 15:34:44 +00:00
bapt
4f1c723060 Import m4 regression tests from OpenBSD
Obtained from:	OpenBSD
Approved by:	des (mentor)
2012-04-30 22:00:34 +00:00
kib
ddc9116307 Add src.conf option WITH_SHARED_TOOLCHAIN to enable building the
toolchain binaries as dynamically linked.  Option is disabled by
default.

Reviewed by:	ru (previous version)
MFC after:	2 weeks
2012-04-29 09:32:44 +00:00
adrian
c88e10dea8 Change cc -> bc : "bc" is "busy count", which is the % of time the channel
is considered "busy but not doing any active TX or frame RX."

Just keep in mind that "frame RX" is "decoding what looks like a wifi
signal", not necessarily "frame successfully decoded for this particular
device."
2012-04-28 23:13:09 +00:00
adrian
ebcc237b86 Add a tool to print out min, average and max channel survey information
from the current channel.

There seem to be some occasional issues with the extension channel
counters reporting more than 100% of use.  I'll investigate that
soon.
2012-04-28 08:17:19 +00:00
dim
05711779ce Add files and directories to be cleaned up if WITHOUT_GCC is in effect
to OptionalObsoleteFiles.inc.

MFC after:	1 week
2012-04-14 16:42:17 +00:00
dim
50b7331731 Vendor import of clang trunk r154661:
http://llvm.org/svn/llvm-project/cfe/trunk@r154661
2012-04-14 14:01:31 +00:00
dim
1fc08f5e9e Vendor import of llvm trunk r154661:
http://llvm.org/svn/llvm-project/llvm/trunk@r154661
2012-04-14 13:54:10 +00:00
luigi
39cda1ca43 A bit of cleanup in the names of fields of netmap-related structures.
Use the name 'ring' instead of 'queue' in all fields.
Bump NETMAP_API.
2012-04-13 16:03:07 +00:00
luigi
db2e5d995b use getopt to parse options, add one option to set
the wait time for link-up events
2012-04-12 08:38:56 +00:00
adrian
78124cfe1d Teach wlanstats about the new BAR TX statistics. 2012-04-08 04:51:43 +00:00
adrian
ba0f3fb560 Add AR_ISR_S5 and AR_ISR_S5_S. 2012-04-08 04:42:53 +00:00
das
311b105c66 Add some tests from PR 166463. Also make sure that all of the tests,
old and new, check the sign bits of both the remainder and the
quotient.
2012-04-07 04:00:30 +00:00
luigi
5133fa4702 we need to specify a NETMAP_API version or the ioctl() will fail. 2012-04-06 14:26:05 +00:00
adrian
a544afcdc9 Add a threadid to the ah_decode API.
This adds the current thread ID to each logged register and mark entry,
allowing for easier debugging of concurrent/overlapping NIC operations.
2012-04-04 20:46:20 +00:00
eadler
1ef5fe44d3 Remove trailing whitespace per mdoc lint warning
Disussed with:	gavin
No objection from:	doc
Approved by:	joel
MFC after:	3 days
2012-03-29 05:02:12 +00:00
stas
d07544c6a7 - Add new kerberos libraries to the list of optional obsolete files. 2012-03-23 03:43:04 +00:00
stas
97dfa7c7ff - Do not build libcom_err and compile_et when kerberos is disabled. They
depends on several heimdal libraries and not used by anything but kerberos
  tools.
2012-03-23 03:16:35 +00:00
stas
e7e0b34988 - Update FreeBSD Heimdal distribution to version 1.5.1. This also brings
several new kerberos related libraries and applications to FreeBSD:
  o kgetcred(1) allows one to manually get a ticket for a particular service.
  o kf(1) securily forwards ticket to another host through an authenticated
    and encrypted stream.
  o kcc(1) is an umbrella program around klist(1), kswitch(1), kgetcred(1)
    and other user kerberos operations. klist and kswitch are just symlinks
    to kcc(1) now.
  o kswitch(1) allows you to easily switch between kerberos credentials if
    you're running KCM.
  o hxtool(1) is a certificate management tool to use with PKINIT.
  o string2key(1) maps a password into key.
  o kdigest(8) is a userland tool to access the KDC's digest interface.
  o kimpersonate(8) creates a "fake" ticket for a service.

  We also now install manpages for some lirbaries that were not installed
  before, libheimntlm and libhx509.

- The new HEIMDAL version no longer supports Kerberos 4.  All users are
  recommended to switch to Kerberos 5.

- Weak ciphers are now disabled by default.  To enable DES support (used
  by telnet(8)), use "allow_weak_crypto" option in krb5.conf.

- libtelnet, pam_ksu and pam_krb5 are now compiled with error on warnings
  disabled due to the function they use (krb5_get_err_text(3)) being
  deprecated.  I plan to work on this next.

- Heimdal's KDC now require sqlite to operate.  We use the bundled version
  and install it as libheimsqlite.  If some other FreeBSD components will
  require it in the future we can rename it to libbsdsqlite and use for these
  components as well.

- This is not a latest Heimdal version, the new one was released while I was
  working on the update.  I will update it to 1.5.2 soon, as it fixes some
  important bugs and security issues.
2012-03-22 08:48:42 +00:00
hselasky
de7d9eb7a3 Use new -n option when executing kldload, to
not warn about already loaded module(s).

MFC after:	1 week
2012-03-18 09:47:27 +00:00
adrian
7a4c65ea4e Add a BINDIR so "make install" works. 2012-03-13 20:30:23 +00:00
jilles
6fb55612a3 sh: Add a test for variables with underscores in arithmetic.
Things like $((_x+1)) are broken in stable/8 sh but work in stable/9 and
head.
2012-03-11 22:12:05 +00:00
adrian
fc612b6d8b Stop some of the output from wrapping at 80 characters. 2012-03-11 02:00:59 +00:00
bz
45db1d7f59 Use = rather than == for expressions to test(1) builtin(1) in sh(1) to
comply with standards.

On modern branches there is an undocumented alias (see r219084) but on
stable/7 this is still an error.

Sponsored by:	Cisco Systems, Inc.
MFC after:	3 days
2012-03-06 14:19:36 +00:00
hselasky
24261e9a52 Add regression test for USB enumeration.
MFC after:	1 week
2012-03-01 20:45:17 +00:00
dim
2a09710001 Add a WITH_CLANG_IS_CC option for src.conf(5), disabled by default, that
installs clang as /usr/bin/cc, /usr/bin/c++ and /usr/bin/cpp.

Note this does *not* disable building and installing gcc, which will
still be available as /usr/bin/gcc, /usr/bin/g++ and /usr/bin/gcpp.  If
you want to disable gcc completely, you must use WITHOUT_GCC.

MFC after:	2 weeks
2012-02-29 22:58:51 +00:00
brueffer
8d8452be93 Fix order of arguments to lseek().
PR:		160867
Submitted by:	Henning Petersen <henning.petersen@t-online.de>
MFC after:	1 week
2012-02-29 19:50:49 +00:00
adrian
8323b562af Add is_beacon_bad.
PR:		kern/165517
2012-02-28 04:06:42 +00:00
luigi
3ac0fcfb97 A bunch of netmap fixes:
USERSPACE:
1. add support for devices with different number of rx and tx queues;

2. add better support for zero-copy operation, adding an extra field
   to the netmap ring to indicate how many buffers we have already processed
   but not yet released (with help from Eddie Kohler);

3. The two changes above unfortunately require an API change, so while
   at it add a version field and some spares to the ioctl() argument
   to help detect mismatches.

4. update the manual page for the two changes above;

5. update sample applications in tools/tools/netmap

KERNEL:

1. simplify the internal structures moving the global wait queues
   to the 'struct netmap_adapter';

2. simplify the functions that map kring<->nic ring indexes

3. normalize device-specific code, helps mainteinance;

4. start exploring the impact of micro-optimizations (prefetch etc.)
   in the ixgbe driver.
   Use 'legacy' descriptors on the tx ring and prefetch slots gives
   about 20% speedup at 900 MHz. Another 7-10% would come from removing
   the explict calls to bus_dmamap* in the core (they are effectively
   NOPs in this case, but it takes expensive load of the per-buffer
   dma maps to figure out that they are all NULL.

   Rx performance not investigated.

I am postponing the MFC so i can import a few more improvements
before merging.
2012-02-27 19:05:01 +00:00
jilles
e3b7e38d11 Check fchmod()/fchown() in fifo_misc test. 2012-02-26 15:32:02 +00:00
bz
88597370a0 Update scripts to work around two sh(1) bugs found in stable/8:
1) _x=$((_x + 1)) does not work while x=$((x + 1)) does.
2) Parameter Expansion, esp. "${x%%bar}" does not work if quoted.

Correct typos and improve some details forwarding.sh already
had in initiator, esp. related to ipfw accepting if the default
is deny.

Add an extra stat call to the "delay" function in addition to the
touch which together is still a lot faster than sleep 1 but seems
to help a lot more to mitigate the unrelated kernel race seen.

Sponsored by:   Cisco Systems, Inc.
2012-02-24 14:13:06 +00:00
jilles
197e5df6a8 libc: Add some tests for fmtmsg(). 2012-02-21 23:46:41 +00:00
adrian
470ebe5c9e Fix up this local copy of statfoo to support > 128 statistics.
This allows all of the athstats statistics to work again.

Specifics:

* The previous code used chars < 0x80 as printable, and chars >= 0x80
  as "statistics"
* .. which meant any statistic above 127 would wrap around to 0;
* .. so once I added the 802.11n TX/RX statistics to athstats, the tail
  end of the statistics list weren't accessible.

This patch:

* adds a define which represents the magic character, rather than a hard
  coded one
* the statistic in question is little endian encoded after the magic
  character.

Notes:

* statfoo is useful enough to possibly warrant turning into a library API.
2012-02-17 08:24:58 +00:00
bz
a20fde632a Add regression tests scripts for multi-IP FIBs exercising the send,
receive and forward path tagging packets with both the ifconfig fib
option or using ipfw, running ICMP6, TCP/v6 and UDP/v6 tests and
testing both setfib(2) as well as the SO_SETFIB socket option.

At 16 FIBs a total of over 64k return codes/replies/stati are checked,
sometimes multiple times (in different ways, e.g. the reflected request
as well as ipfw counter values).

The scripts need two or three machines to run and are thus not added
to the tools/regression framework but only to tools/test.

Sponsored by:	Cisco Systems, Inc.
2012-02-17 04:26:24 +00:00
bz
df4d2c12bb Add regression tests for the setsockopt(2) SO_SETFIB socket option.
Check that the expected domain(9) families all handle the socket option
correctly and do proper bounds checks.  This would catch bugs as fixed
in (r230938,)r230981.

Sponsored by:	Cisco Systems, Inc.
2012-02-17 03:25:26 +00:00
adrian
19d9144e50 Add some missing radar config parameters. 2012-02-14 20:08:50 +00:00
gnn
5fed2daf28 Remove UCP from the list of counters 2012-02-14 18:57:10 +00:00
gnn
30bbceb660 Add options for program (-p) and to turn off waiting (-w) which is now
on by default.

The default is to wait after each counter is tested.  Since the prompt
would go to stdout you won't see it if you're redirecting the output
of the executed sub-program to /dev/null, so just press return to
continue or Ctrl-D to stop.
2012-02-14 18:51:21 +00:00
gnn
6562553391 Add a rudimentary test to run through all the available counters on a
system and then execute a program with pmcstat in counting mode.

The program will verify that all counters fire and that the code neither
panics the system nor locks it up.  This should be considered a first pass
conformance test for new sets of counters being added to hwpmc(4).
2012-02-14 04:18:59 +00:00
fjoe
4475fc98c1 Include target names in diagnostic output.
Submitted by:	Garrett Cooper
2012-02-12 05:34:01 +00:00
jilles
0458d57ea3 sh: Make 'hash' return 1 if at least one utility is not found.
Reported by:	lme
2012-02-11 21:06:45 +00:00
ed
6d383df7bb Replace utxrm(8) by utx(8).
At first, I added a utility called utxrm(8) to remove stale entries from
the user accounting database. It seems there are cases in which we need
to perform different operations on the database as well. Simply rename
utxrm(8) to utx(8) and place the old code under the "rm" command.

In addition to "rm", this tool supports "boot" and "shutdown", which are
going to be used by an rc-script which I am going to commit separately.
2012-02-11 20:28:42 +00:00
kib
290f0204ae Add a test program for recently added ptrace(2) interfaces.
MFC after:	1 week
2012-02-10 21:33:12 +00:00
luigi
0290a0c2f7 - change the buffer size from a constant to a
TUNABLE variable (hw.netmap.buf_size) so we can experiment
  with values different from 2048 which may give better cache performance.

- rearrange the memory allocation code so it will be easier
  to replace it with a different implementation. The current code
  relies on a single large contiguous chunk of memory obtained through
  contigmalloc.
  The new implementation (not committed yet) uses multiple
  smaller chunks which are easier to fit in a fragmented address
  space.
2012-02-08 11:43:29 +00:00
ed
e53a6745b5 Add a `fix' for another whitespace bug.
If the sentence starts with a multiple of eight spaces, the sentence
should in almost all practical cases have started with tabs instead.
Replace these spaces by tabs.
2012-02-06 18:52:40 +00:00
ed
e6c6bd0894 Add fixwhite(1).
This small utility can be used to `sanitize' the whitespace in source
code. It does the following things:

Global:
- Remove empty lines at the beginning and the end of a file.
- Merge successive empty lines into a single empty line.

Per-line:
- Remove trailing whitespace.
- Merge spaces preceeding tabs into the tabs.

It operated on stdin/stdout. This means that if you use vi(1), you can
just run :%!fixwhite to reorganize the file.
2012-02-06 10:23:11 +00:00
dim
eb8951e7f7 Add a WITH_CLANG_EXTRAS option for src.conf(5), disabled by default,
that builds the following additional llvm/clang tools:

- bugpoint
- llc
- lli
- llvm-ar
- llvm-as
- llvm-bcanalyzer
- llvm-diff
- llvm-dis
- llvm-extract
- llvm-ld
- llvm-link
- llvm-mc
- llvm-nm
- llvm-objdump
- llvm-prof
- llvm-ranlib
- llvm-rtdyld
- llvm-stub
- macho-dump
- opt

These tools are mainly useful for people that want to manipulate llvm
bitcode (.bc) and llvm assembly language (.ll) files, or want to tinker
with llvm and clang themselves.

MFC after:	2 weeks
2012-02-05 23:56:22 +00:00
rmh
b5b4042f4a Add MK_SOURCELESS build option. Setting MK_SOURCELESS to "no" will disable
kernel modules that include binary-only code.

More fine-grained control is provided via MK_SOURCELESS_HOST (for native code
that runs on host CPU) and MK_SOURCELESS_UCODE (for microcode).

Reviewed by:	julian, delphij, freebsd-arch
Approved by:	kib (mentor)
MFC after:	2 weeks
2012-02-04 00:54:43 +00:00
adrian
69e5da13cc Add some missing radar config parameters to athradar. 2012-02-02 21:04:24 +00:00
netchild
651caac6f4 - remove non-existent input directories from the configs
- add the target-arch to the project name where applicable (arch dependend code)
- fix comment for __FreeBSD__ [1]

Noticed by:	bz	[1]
2012-02-01 10:59:19 +00:00
trasz
7b6e352dc6 More mdconfig(8) tests. 2012-01-26 18:16:16 +00:00
trasz
7832dcf6ca Move mdconfig(8) tests under regression/sbin/, where they belong.
Submitted by:	jh@
2012-01-25 10:11:54 +00:00
netchild
bedff26e9c Just define __FreeBSD__ to 1 instead of doing what the compiler does.
The kernel is supposed to DTRT based upon the __FreeBSD_version value,
not the value of __FreeBSD__.

Discussed with:	bz
2012-01-24 15:13:55 +00:00
trasz
4c40db42c1 Add some basic regression tests for mdconfig(8). 2012-01-24 13:23:52 +00:00
netchild
0d3cd12243 We are in FreeBSD 10 now: define __FreeBSD__ to 10. 2012-01-24 11:06:22 +00:00
netchild
328a5e4f1a Mechanically add a config for all missing drivers.
No cross-referencing was added to the configs, so no
automatic linking to the documentation of other subsystems.

Drivers which already contain doxygen markup:
agp ath bktr bxe cxgb cxgbe dpt drm e1000 iir
ixgbe mwl nxge ofw pccard siba wpi xen
2012-01-23 11:37:40 +00:00
jilles
ae59680813 sh: Fix $? in the first command of a 'for'.
In the first command of a 'for', $? should be the exit status of the last
pipeline (command substitution in the word list or command before 'for'),
not always 0.
2012-01-22 14:00:33 +00:00
adrian
6bf53cf3c1 Bring over the visibility control tool for Monthadar's wtap project.
This allows basic control over which wtap nodes can see which other
wtap nodes.
2012-01-22 04:51:00 +00:00
das
4f141c7da6 These tests check whether the compiler evaluates floating-point
expressions properly.  Some of the tests depend on the compiler
implementing C99's FENV_ACCESS pragma, and only commercial compilers
do; those tests are currently skipped.  If any of the enabled tests
fail, then odds are the libm regression tests will fail also.
This should make it easier to diagnose reported problems on platforms
I don't have.

Currently, gcc passes all the tests that don't depend on FENV_ACCESS
on amd64 and sparc64.  Clang fails a few on amd64 (see clang bug
11406).  Both gcc and clang fare poorly on i386, which has well-known
issues.
2012-01-20 06:57:21 +00:00
dumbbell
8b387a2d35 sh: Fix execution of multiple statements in a trap when evalskip is set
Before this fix, only the first statement of the trap was executed if
evalskip was set. This is for example the case when:
    o  "-e" is set for this shell
    o  a trap is set on EXIT
    o  a function returns 1 and causes the script to abort

Reviewed by:	jilles
MFC after:	2 weeks
2012-01-16 11:07:46 +00:00
dumbbell
4e22d62dd6 sh: Test EXIT trap with multiple statements in it
Reviewed by:	jilles
MFC after:	2 weeks
2012-01-16 10:59:44 +00:00