]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
13 years agoMK_GPIO changed its default; reflect.
ru [Fri, 6 May 2011 19:14:06 +0000 (19:14 +0000)]
MK_GPIO changed its default; reflect.

13 years agoRemoved trailing whitespace.
ru [Fri, 6 May 2011 19:13:03 +0000 (19:13 +0000)]
Removed trailing whitespace.

13 years agoTidy up formatting.
ru [Fri, 6 May 2011 19:10:27 +0000 (19:10 +0000)]
Tidy up formatting.

13 years agoSet the initial value of maxfilesize to OFF_MAX in the
rmacklem [Fri, 6 May 2011 17:51:00 +0000 (17:51 +0000)]
Set the initial value of maxfilesize to OFF_MAX in the
new NFS client. It will then be reduced to whatever the
server says it can support. There might be an argument
that this could be one block larger, but since NFS is
a byte granular system, I chose not to do that.

Suggested by: Matt Dillon
Tested by: Daniel Braniss (earlier version)
MFC after: 2 weeks

13 years agoSimplify this code somewhat by only writing a 512-byte-sector APM map.
nwhitehorn [Fri, 6 May 2011 15:40:58 +0000 (15:40 +0000)]
Simplify this code somewhat by only writing a 512-byte-sector APM map.
All firmwares can read it, we need to write one anyway for old OF
versions, and if a 512-byte one is present, OS X ignores the 2048-byte one
in favor of it.

13 years agoAdd a function which enables or disables RX RIFS searching, and migrate
adrian [Fri, 6 May 2011 15:33:56 +0000 (15:33 +0000)]
Add a function which enables or disables RX RIFS searching, and migrate
the code which does this into it.

13 years agoUpdate to a 6-May-2011 release (upstreamed some of our changes).
ru [Fri, 6 May 2011 14:21:46 +0000 (14:21 +0000)]
Update to a 6-May-2011 release (upstreamed some of our changes).

13 years agoprepare code that does topology detection for amd cpus for bulldozer
avg [Fri, 6 May 2011 13:51:54 +0000 (13:51 +0000)]
prepare code that does topology detection for amd cpus for bulldozer

This also introduces a new detection path for family 10h and newer
pre-bulldozer cpus, pre-10h hardware should not be affected.

Tested by: Gary Jennejohn <gljennjohn@googlemail.com>
(with pre-10h hardware)
MFC after: 2 weeks

13 years agoRetire isa_setup_intr() and isa_teardown_intr() and use the generic bus
jhb [Fri, 6 May 2011 13:48:53 +0000 (13:48 +0000)]
Retire isa_setup_intr() and isa_teardown_intr() and use the generic bus
versions instead.  They were never needed as bus_generic_intr() and
bus_teardown_intr() had been changed to pass the original child device up
in 42734, but the ISA bus was not converted to new-bus until 45720.

13 years agoIncrease NFS_TICKINTVL value from 10 to 500. Now that callout does useful
mav [Fri, 6 May 2011 13:11:50 +0000 (13:11 +0000)]
Increase NFS_TICKINTVL value from 10 to 500. Now that callout does useful
things only once per second, so other 99 calls per second were useless and
just don't allow idle system to sleep properly.

Reviewed by: rmacklem

13 years agoConvert delay parameter back to ms when reporting to user.
ae [Fri, 6 May 2011 07:13:34 +0000 (07:13 +0000)]
Convert delay parameter back to ms when reporting to user.

PR: 156838
MFC after: 1 week

13 years agoDo not use Open Firmware to open the device and instead program its start
nwhitehorn [Fri, 6 May 2011 03:26:24 +0000 (03:26 +0000)]
Do not use Open Firmware to open the device and instead program its start
on our own. This prevents hangs at boot when using a bm(4) NIC where the
cable is not plugged in at boot time.

Obtained from: NetBSD
MFC after: 1 week

13 years agoFix GPIO_MAXPINS calculation for the AR71xx, AR724x, AR913x SoC.
adrian [Fri, 6 May 2011 02:45:02 +0000 (02:45 +0000)]
Fix GPIO_MAXPINS calculation for the AR71xx, AR724x, AR913x SoC.

Submitted by: Luiz Otavio O Souza <loos.br@gmail.com>

13 years agoChange the new NFS server so that it returns 0 when the f_bavail
rmacklem [Fri, 6 May 2011 01:29:14 +0000 (01:29 +0000)]
Change the new NFS server so that it returns 0 when the f_bavail
or f_ffree fields of "struct statfs" are negative, since the
values that go on the wire are unsigned and will appear to be
very large positive values otherwise. This makes the handling
of a negative f_bavail compatible with the old/regular NFS server.

MFC after: 2 weeks

13 years agoBump up the number of egress queues that the driver is allowed to use.
np [Thu, 5 May 2011 23:09:17 +0000 (23:09 +0000)]
Bump up the number of egress queues that the driver is allowed to use.

MFC after: 3 days

13 years agosh: Add $'quoting' (C-style escape sequences).
jilles [Thu, 5 May 2011 20:55:55 +0000 (20:55 +0000)]
sh: Add $'quoting' (C-style escape sequences).

A string between $' and ' may contain backslash escape sequences similar to
the ones in a C string constant (except that a single-quote must be escaped
and a double-quote need not be). Details are in the sh(1) man page.

This construct is useful to include unprintable characters, tabs and
newlines in strings; while this can be done with a command substitution
containing a printf command, that needs ugly workarounds if the result is to
end with a newline as command substitution removes all trailing newlines.

The construct may also be useful in future to describe unprintable
characters without needing to write those characters themselves in 'set -x',
'export -p' and the like.

The implementation attempts to comply to the proposal for the next issue of
the POSIX specification. Because this construct is not in POSIX.1-2008,
using it in scripts intended to be portable is unwise.

Matching the minimal locale support in the rest of sh, the \u and \U
sequences are currently not useful.

Exp-run done by: pav (with some other sh(1) changes)

13 years ago* Update copyright notice.
tuexen [Thu, 5 May 2011 19:49:27 +0000 (19:49 +0000)]
* Update copyright notice.
* Cleanup usage of iov's.
* Add support for SCTP_TIMEOUTS socketoption.
* Fix a bug in sctp_recvmsg(): return the msg_flags in case of an error.
* Fix a bug in the error handling of sctp_peeloff(): return the -1.

13 years agoSimplify this script somewhat, following excellent suggestions from
nwhitehorn [Thu, 5 May 2011 19:17:55 +0000 (19:17 +0000)]
Simplify this script somewhat, following excellent suggestions from
Ed Schouten.

13 years agoDetect and set Atom's Tj(max) to 90 if it's not the 45nm D400/D500/N400
delphij [Thu, 5 May 2011 19:15:15 +0000 (19:15 +0000)]
Detect and set Atom's Tj(max) to 90 if it's not the 45nm D400/D500/N400
series.

MFC after: 2 weeks

13 years agoSome changes around LAPIC timer programming.
mav [Thu, 5 May 2011 18:56:48 +0000 (18:56 +0000)]
Some changes around LAPIC timer programming.

This fixes heavy interrupt storm and resulting system freeze when using
LAPIC timer in one-shot mode under Xen HVM. There, unlike real hardware,
programming timer with zero period almost immediately causes interrupt.

13 years agoFine-tune llvm optimization for sys/boot/i386/boot2, which shaves off
dim [Thu, 5 May 2011 18:47:24 +0000 (18:47 +0000)]
Fine-tune llvm optimization for sys/boot/i386/boot2, which shaves off
some more bytes from the final boot2 image.

Submitted by: rdivacky

13 years agoAdd an initialization to the error variable, without
jfv [Thu, 5 May 2011 17:28:45 +0000 (17:28 +0000)]
Add an initialization to the error variable, without
this there is a rare return path that bogusly appears
to fail when it should not.  Also white space correction.

Thanks to Arnaud Lacombe for noticing the problem.

13 years agoAdd PCI ID for Marvell 88SE9182 -- PCIe 2.x x2 relative of the 88SE912x.
mav [Thu, 5 May 2011 17:11:26 +0000 (17:11 +0000)]
Add PCI ID for Marvell 88SE9182 -- PCIe 2.x x2 relative of the 88SE912x.

Submitted by: dchagin
MFC after: 1 week

13 years agoMake cross-compiling using clang work better, by respecting the
dim [Thu, 5 May 2011 16:14:13 +0000 (16:14 +0000)]
Make cross-compiling using clang work better, by respecting the
LLVM_HOSTTRIPLE that is defined during the cross-tools stage.

Using clang, you can now build amd64 world and kernel on i386, and vice
versa.  Other arches still need work.

13 years agoDon't duplicate define the stdint types.
obrien [Thu, 5 May 2011 14:45:24 +0000 (14:45 +0000)]
Don't duplicate define the stdint types.

13 years agoAdd a manpage for geom_map(4).
adrian [Thu, 5 May 2011 14:43:35 +0000 (14:43 +0000)]
Add a manpage for geom_map(4).

Submitted by: ray@dlink.ua

13 years agoUpdates to geom_map from the author.
adrian [Thu, 5 May 2011 14:43:09 +0000 (14:43 +0000)]
Updates to geom_map from the author.

The major update here is to support 64 bit size/offsets.
There's also style related changes.

Submitted by:  ray@dlink.ua

13 years agoConvert IA64 ISO script to use makefs instead of mkisofs.
nwhitehorn [Thu, 5 May 2011 14:16:40 +0000 (14:16 +0000)]
Convert IA64 ISO script to use makefs instead of mkisofs.

13 years agoAdd make_dev_alias_p to MLINKS.
ae [Thu, 5 May 2011 14:13:08 +0000 (14:13 +0000)]
Add make_dev_alias_p to MLINKS.

Pointed out by: pjd
MFC after: 2 weeks

13 years agoGarbage collect some unused variables and stray debug code.
nwhitehorn [Thu, 5 May 2011 13:55:43 +0000 (13:55 +0000)]
Garbage collect some unused variables and stray debug code.

Submitted by: marius

13 years ago- Add a forgotten -o to usage().
ru [Thu, 5 May 2011 10:17:49 +0000 (10:17 +0000)]
- Add a forgotten -o to usage().
- Sync usage() with manpage's SYNOPSIS.

13 years ago[mdoc] remove a hard sentence break.
ru [Thu, 5 May 2011 10:17:08 +0000 (10:17 +0000)]
[mdoc] remove a hard sentence break.

13 years agoFormatting fixes:
ae [Thu, 5 May 2011 09:55:55 +0000 (09:55 +0000)]
Formatting fixes:
 o Fix date
 o Break sentences
 o Remove trailing whitespaces
 o Sort xrefs by section number

Requested by: ru
MFC after: 2 weeks

13 years agoAdd nvram2env (untested) and geom_map (tested) to PB92.
adrian [Thu, 5 May 2011 09:04:49 +0000 (09:04 +0000)]
Add nvram2env (untested) and geom_map (tested) to PB92.

13 years agoDon't perform NF calibration for radio chains which aren't in use:
adrian [Thu, 5 May 2011 08:11:22 +0000 (08:11 +0000)]
Don't perform NF calibration for radio chains which aren't in use:

Quoting the ath9k commit message:

At present the noise floor calibration is processed in supported
control and extension chains rather than required chains.
Unnccesarily doing nfcal in all supported chains leads to
invalid nf readings on extn chains and these invalid values
got updated into history buffer. While loading those values
from history buffer is moving the chip to deaf state.

This issue was observed in AR9002/AR9003 chips while doing
associate/dissociate in HT40 mode and interface up/down
in iterative manner. After some iterations, the chip was moved
to deaf state. Somehow the pci devices are recovered by poll work
after chip reset. Raading the nf values in all supported extension chains
when the hw is not yet configured in HT40 mode results invalid values.

Reference: https://patchwork.kernel.org/patch/753862/

Obtained from: Linux ath9k

13 years agoMerge two upstream patches from vendor branch. No functional changes.
des [Thu, 5 May 2011 08:08:18 +0000 (08:08 +0000)]
Merge two upstream patches from vendor branch.  No functional changes.

13 years agoAnother Howl (AR9130) fix.
adrian [Thu, 5 May 2011 04:43:05 +0000 (04:43 +0000)]
Another Howl (AR9130) fix.

I haven't seen a 5ghz AR9130 based board yet though!

Obtained from: Atheros

13 years agoFix up the chipset checks for the AR5416 and later silicon.
adrian [Thu, 5 May 2011 03:42:04 +0000 (03:42 +0000)]
Fix up the chipset checks for the AR5416 and later silicon.

The checks should function as follows:

* AR_SREV_<silicon> : check macVersion matches that version id
* AR_SREV_<silicon>_<revision> : check macVersion and macRevision match
    the version / revision respectively

* AR_SREV_<silicon>_<revision>_OR_LATER: check that
  + if the chip silicon version == macVersion, enforce revision >= macRevision
  + if the chip silicon version > macVersion, allow it.

For example, AR_SREV_MERLIN() only matches AR9280 (any revision),
AR_SREV_MERLIN_10() would only match AR9280 version 1.0, but
AR_SREV_MERLIN_20_OR_LATER() matches AR9280 version >= 2.0 _AND_
any subsequent MAC (So AR9285, AR9287, etc.)

The specific fixes which may impact users:

* if there is Merlin hardware > revision 2.0, it'll now be correctly
  matched by AR_SREV_MERLIN_20_OR_LATER() - the older code simply
  would match on either Merlin 2.0 or a subsequent MAC (AR9285, AR9287, etc.)

* Kite version 1.1/1.2 should now correctly match. As these macros
  are used in the AR9285 reset/attach path, and it's assumed that the
  hardware is kite anyway, the behaviour shouldn't change. It'll only
  change if these macros are used in other codepaths shared with
  older silicon.

Obtained from: Linux ath9k, Atheros

13 years agoImport some HOWL (AR9130) related fixes from Atheros.
adrian [Thu, 5 May 2011 02:59:31 +0000 (02:59 +0000)]
Import some HOWL (AR9130) related fixes from Atheros.

Obtained from: Atheros

13 years agoT4 packet timestamps.
np [Thu, 5 May 2011 02:38:08 +0000 (02:38 +0000)]
T4 packet timestamps.

Reference code that shows how to get a packet's timestamp out of
cxgbe(4).  Disabled by default because we don't have a standard way
today to pass this information up the stack.

The timestamp is 60 bits wide and each increment represents 1 tick of
the T4's core clock.  As an example, the timestamp granularity is ~4.4ns
for this card:

# sysctl dev.t4nex.0.core_clock
dev.t4nex.0.core_clock: 228125

MFC after: 1 week

13 years agoGuard ptrdiff_t.
obrien [Thu, 5 May 2011 02:35:25 +0000 (02:35 +0000)]
Guard ptrdiff_t.

13 years ago1. If PKG_DBDIR cannot be determined from make, set the default
dougb [Thu, 5 May 2011 02:35:11 +0000 (02:35 +0000)]
1. If PKG_DBDIR cannot be determined from make, set the default
2. Add the -H flag to tar in case /var/db/pkg itself is a symlink
3. Direct stderr to /dev/null to suppress the leading slash warning [1]

PR: ports/156810 [1]
Submitted by: Jeremy Chadwick <freebsd@jdc.parodius.com> [1]

13 years agoT4 packet filtering/steering.
np [Thu, 5 May 2011 02:04:56 +0000 (02:04 +0000)]
T4 packet filtering/steering.

- Enable 5-tuple and every-packet lookup.

- Setup the default filter mode to allow filtering/steering based on IP
  protocol, ingress port, inner VLAN ID, IP frag, FCoE, and MPS match
  type; all combined together.  You can also filter based on MAC index,
  Ethernet type, IP TOS/IPv6 Traffic Class, and outer VLAN ID but you'll
  have to modify the default filter mode and exclude some of the
  match-fields in it.

  IPv4 and IPv6 SIP/DIP/SPORT/DPORT are always available in all filter
  rules.

- Add driver ioctls to get/set the global filter mode.

- Add driver ioctls to program and delete hardware filters.  A couple of
  the "switch" actions that rewrite Ethernet and VLAN information and
  switch the packet out of another port may not work as the L2 code is not
  yet in place.  Everything else, including all "drop" and "pass" rules
  with RSS or absolute qid, should work.

Obtained from:  Chelsio Communications

13 years agoModify the NFS nfssvc(2) syscall so that it allows
rmacklem [Thu, 5 May 2011 02:00:53 +0000 (02:00 +0000)]
Modify the NFS nfssvc(2) syscall so that it allows
anyone to get the statistics for the new NFS subsystem.

MFC after: 2 weeks

13 years agolibarchive is mixing libmd and libcrypto -- correct to use one or the other.
obrien [Thu, 5 May 2011 01:16:06 +0000 (01:16 +0000)]
libarchive is mixing libmd and libcrypto -- correct to use one or the other.
[mixing the two can be quite bad -- they define the same context structures,
 but with differing structure members (and sizes)]

Update the hash function support comments, and update config_freebsd.h
to match.

Approved by: kientzle

13 years agos/shaN_crypt/crypt_shaN/g to be a more consistent with the existing naming.
obrien [Thu, 5 May 2011 01:09:42 +0000 (01:09 +0000)]
s/shaN_crypt/crypt_shaN/g to be a more consistent with the existing naming.

Reviewed by: markm

13 years agoFix boot on old machines (e.g. blue and white G3s) by synthesizing a
nwhitehorn [Thu, 5 May 2011 00:52:19 +0000 (00:52 +0000)]
Fix boot on old machines (e.g. blue and white G3s) by synthesizing a
512-byte sector map instead unused space in the first 2048-byte sector.

13 years agoCorrect the kernel config name printed out during install.
obrien [Thu, 5 May 2011 00:43:55 +0000 (00:43 +0000)]
Correct the kernel config name printed out during install.

PR: 156579
Submitted by: dhw

13 years agoEnable Ethernet@WireSpeed for BCM5718/BCM57765 family. While I'm
yongari [Thu, 5 May 2011 00:43:40 +0000 (00:43 +0000)]
Enable Ethernet@WireSpeed for BCM5718/BCM57765 family. While I'm
here inverse meaning of PHY flag as Ethernet@WireSpeed is enabled
for most PHYs.

13 years agoFix the new NFS client so that it handles the 64bit fields
rmacklem [Thu, 5 May 2011 00:11:09 +0000 (00:11 +0000)]
Fix the new NFS client so that it handles the 64bit fields
that are now in "struct statfs" for NFSv3 and NFSv4. Since
the ffiles value is uint64_t on the wire, I clip the value
to INT64_MAX to avoid setting f_ffree negative.

Tested by: kib
MFC after: 2 weeks

13 years agoRepair release CD generation on PC98 and sun4v after release building
nwhitehorn [Wed, 4 May 2011 23:41:11 +0000 (23:41 +0000)]
Repair release CD generation on PC98 and sun4v after release building
changes, and backport the new logic (ISO images are TARGET dependant, not
TARGET_CPUARCH dependant) to Makefile.sysinstall. While modifying ISO
image scripts, change several archs to use makefs (from base) instead of
mkisofs (from ports) which makes release CD generation both faster and
self-hosting.

13 years agoChange the way powerpc bootable CDs are generated to work around a bug
nwhitehorn [Wed, 4 May 2011 23:34:10 +0000 (23:34 +0000)]
Change the way powerpc bootable CDs are generated to work around a bug
in hybrid image generation in cdrtools. This produces a small HFS partition
containing loader, mapped in by an oddly-formed APM table using a new
feature in makefs. This does not appear to work yet on early-model G3
systems, which will be fixed later, but produces bootable CDs on
everything else.

13 years agoAlways re-arm an iq's interrupt before leaving the handler.
np [Wed, 4 May 2011 23:07:30 +0000 (23:07 +0000)]
Always re-arm an iq's interrupt before leaving the handler.

MFC after: 1 week

13 years agosh: Apply set -u to variables in arithmetic.
jilles [Wed, 4 May 2011 22:12:22 +0000 (22:12 +0000)]
sh: Apply set -u to variables in arithmetic.

Note that this only applies to variables that are actually used.
Things like (0 && unsetvar) do not cause an error.

Exp-run done by: pav (with some other sh(1) changes)

13 years agoAdd a comment noting that the NFS code assumes that the
rmacklem [Wed, 4 May 2011 22:02:33 +0000 (22:02 +0000)]
Add a comment noting that the NFS code assumes that the
values of error numbers in sys/errno.h will be the same
as the ones specified by the NFS RFCs and that the code
needs to be fixed if error numbers are changed in sys/errno.h.

Suggested by: Peter Jeremy
MFC after: 2 weeks

13 years agosh: Detect an error for ${#var<GARBAGE>}.
jilles [Wed, 4 May 2011 21:49:34 +0000 (21:49 +0000)]
sh: Detect an error for ${#var<GARBAGE>}.

In particular, this makes things like ${#foo[0]} and ${#foo[@]} errors
rather than silent equivalents of ${#foo}.

PR: bin/151720
Submitted by: Mark Johnston
Exp-run done by: pav (with some other sh(1) changes)

13 years agoImplement Resource Pooling V2 and an MPTCP like congestion
tuexen [Wed, 4 May 2011 21:27:05 +0000 (21:27 +0000)]
Implement Resource Pooling V2 and an MPTCP like congestion
control.
Based on a patch received from Martin Becke.

MFC after: 2 weeks.

13 years agoUpdate nfsstat.1 to reflect the changes done to nfsstat(1)
rmacklem [Wed, 4 May 2011 20:28:06 +0000 (20:28 +0000)]
Update nfsstat.1 to reflect the changes done to nfsstat(1)
by r221455. This includes a new "-o" option for displaying
statistics from the old NFS client/server and a slightly
different description for the "-e" option.
This is a content change.

13 years agoModify nfsstat(1) so that it reports statistics for the
rmacklem [Wed, 4 May 2011 20:13:26 +0000 (20:13 +0000)]
Modify nfsstat(1) so that it reports statistics for the
new NFS client/server by default, in a format compatible
with the old NFS client/server. Also add a "-o" flag that
forces nfsstat(1) to get statistics for the old NFS
client/server.

13 years agoModify nfsstat(1) so that it prints out the buffer cache
rmacklem [Wed, 4 May 2011 19:28:44 +0000 (19:28 +0000)]
Modify nfsstat(1) so that it prints out the buffer cache
stats in the same way for the new client as the old one.

MFC after: 2 weeks

13 years agoRemove unneeded code.
ae [Wed, 4 May 2011 18:41:26 +0000 (18:41 +0000)]
Remove unneeded code.

MFC after: 1 week

13 years agoRemove unneeded code.
ae [Wed, 4 May 2011 18:26:45 +0000 (18:26 +0000)]
Remove unneeded code.

MFC after: 1 week

13 years agoRemove unneeded code.
ae [Wed, 4 May 2011 18:17:21 +0000 (18:17 +0000)]
Remove unneeded code.

MFC after: 1 week

13 years agoRemove unneeded tab after .Ed to make manlint happy.
gjb [Wed, 4 May 2011 18:16:05 +0000 (18:16 +0000)]
Remove unneeded tab after .Ed to make manlint happy.

Reported by: manlint

13 years agoRemoved KASSERT, g_new_providerf() can not fail.
ae [Wed, 4 May 2011 18:06:40 +0000 (18:06 +0000)]
Removed KASSERT, g_new_providerf() can not fail.

MFC after: 1 week

13 years agoEncode horizontal scroll events (AC Pan) as button presses (bit 5 and 6)
emax [Wed, 4 May 2011 17:58:15 +0000 (17:58 +0000)]
Encode horizontal scroll events (AC Pan) as button presses (bit 5 and 6)

Submitted by: David Demelier demelier dot david at gmail dot com
MFC after: 1 week

13 years agoRemove "for a moment" assignment. struct g_geom zeroed when allocated.
ae [Wed, 4 May 2011 17:56:53 +0000 (17:56 +0000)]
Remove "for a moment" assignment. struct g_geom zeroed when allocated.

MFC after: 1 week

13 years agoRemove unneeded checks, g_new_xxx functions can not fail.
ae [Wed, 4 May 2011 17:37:37 +0000 (17:37 +0000)]
Remove unneeded checks, g_new_xxx functions can not fail.

MFC after: 1 week

13 years agoAdd initial BCM57765 family support. The BCM57765 family seems to
yongari [Wed, 4 May 2011 17:04:31 +0000 (17:04 +0000)]
Add initial BCM57765 family support. The BCM57765 family seems to
have similar hardware features of BCM5718 family except the number
of receive return ring is 4. The BCM57765 family is known to
support IEEE 802.3az EEE(Energy Efficient Ethernet) but this change
does not include EEE support code. I hope EEE is implemented in
near future.
This change will support BCM57761, BCM57765, BCM57781, BCM57785,
BCM57791 and BCM57795. All hardware offloading features are
supported and suspend/resume also should work.
Many thanks to Broadcom for continuing support of FreeBSD.

Tested by: Paul Thornton (prt <> prt dot org)
HW donated by: Broadcom

13 years agoRevert by accident r221441.
attilio [Wed, 4 May 2011 14:52:17 +0000 (14:52 +0000)]
Revert by accident r221441.

13 years agoRemove the previously added comment.
attilio [Wed, 4 May 2011 14:37:01 +0000 (14:37 +0000)]
Remove the previously added comment.
Probabilly me is the only one who didn't know userland and kerneland sizes
were mismatching.

13 years agoFix nfsstat.c so that the "-z" option works for the new
rmacklem [Wed, 4 May 2011 13:50:37 +0000 (13:50 +0000)]
Fix nfsstat.c so that the "-z" option works for the new
NFS subsystem.

MFC after: 2 weeks

13 years agoAdd kernel support for NFSSVC_ZEROCLTSTATS and NFSSVC_ZEROSRVSTATS
rmacklem [Wed, 4 May 2011 13:36:18 +0000 (13:36 +0000)]
Add kernel support for NFSSVC_ZEROCLTSTATS and NFSSVC_ZEROSRVSTATS
so that they can be used by nfsstat(1) to implement the "-z" option
for the new NFS subsystem.

MFC after: 2 weeks

13 years agoRevert r221306, since NFSSVC_ZEROSTATS zero'd both client and
rmacklem [Wed, 4 May 2011 13:30:38 +0000 (13:30 +0000)]
Revert r221306, since NFSSVC_ZEROSTATS zero'd both client and
server stats, when separate modifiers for NFSSVC_GETSTATS for
each of client and server stats is what it required by nfsstat(1).

13 years agoImplemented a mount option "nocto" that disables cache coherency
ru [Wed, 4 May 2011 13:27:45 +0000 (13:27 +0000)]
Implemented a mount option "nocto" that disables cache coherency
checking at open time.  It may improve performance for read-only
NFS mounts.  Use deliberately.

MFC after: 1 week
Reviewed by: rmacklem, jhb (earlier version)

13 years agoRevert r221308, since it incorrectly zero'd both client and
rmacklem [Wed, 4 May 2011 13:20:44 +0000 (13:20 +0000)]
Revert r221308, since it incorrectly zero'd both client and
server stats when "-c" or "-s" was specified.

13 years agoCommit the missing linux_videdev2_compat.h (lost somewhere between
netchild [Wed, 4 May 2011 13:09:20 +0000 (13:09 +0000)]
Commit the missing linux_videdev2_compat.h (lost somewhere between
commit tree patch generation -> successful compile tree build test -> commmit).

Pointy hat to: netchild

13 years agoWhen checking existence of providers skip those which are orphaned.
ae [Wed, 4 May 2011 12:59:11 +0000 (12:59 +0000)]
When checking existence of providers skip those which are orphaned.

PR: kern/132273
MFC after: 2 week

13 years agoThe security run requests unmaskable output, even if the only output is to
netchild [Wed, 4 May 2011 12:48:02 +0000 (12:48 +0000)]
The security run requests unmaskable output, even if the only output is to
tell that there is a separate email or that the output is logged to a file.

This commit changes the return code for the non-inline case to tell that
this message is not important enough and can be masked if necessary. The
messages from the security checks themself are not affected by this and
show up as before in the periodic security email/file.

The inline case still requests to not mask the output, as with the current
way of handling this there is no easy way to handle this.

PR: 138692
Analysis/patch atch by: Chris Cowart <ccowart@timesinks.net>
X-MFC after: on request

13 years agoRegression tests for Capsicum capability mode.
jonathan [Wed, 4 May 2011 12:44:46 +0000 (12:44 +0000)]
Regression tests for Capsicum capability mode.

Ensure that system calls that access global namespaces, e.g. open(2), are not permitted, and that whitelisted sysctls like kern.osreldate are.

Approved by: rwatson
Sponsored by: Google, Inc.

13 years agoUse proper return codes (valuable output, invalid config, problems).
netchild [Wed, 4 May 2011 12:37:10 +0000 (12:37 +0000)]
Use proper return codes (valuable output, invalid config, problems).

MFC after: 1 week

13 years agoIn ncl_printf(), call vprintf() instead of printf().
ru [Wed, 4 May 2011 11:22:52 +0000 (11:22 +0000)]
In ncl_printf(), call vprintf() instead of printf().

MFC after: 3 days

13 years agoAdd FEATURE macros for v4l and v4l2 to the linuxulator.
netchild [Wed, 4 May 2011 09:52:34 +0000 (09:52 +0000)]
Add FEATURE macros for v4l and v4l2 to the linuxulator.

Suggested by: ae

13 years agoRemove this useless bit of code for Kite. The RIFS register value is overriden
adrian [Wed, 4 May 2011 09:26:33 +0000 (09:26 +0000)]
Remove this useless bit of code for Kite. The RIFS register value is overriden
by the initvals, so disabling RIFS before calling writeIni() effectively does
nothing.

13 years agoThis is v4l2 support for the linuxulator. This allows to access FreeBSD
netchild [Wed, 4 May 2011 09:05:39 +0000 (09:05 +0000)]
This is v4l2 support for the linuxulator. This allows to access FreeBSD
native devices which support the v4l2 API from processes running within
the linuxulator, e.g. skype or flash can access the multimedia/pwcbsd
or multimedia/webcamd supplied drivers.

Submitted by: nox
MFC after: 1 month

13 years agoFix typo in comment, improve comment.
netchild [Wed, 4 May 2011 08:42:31 +0000 (08:42 +0000)]
Fix typo in comment, improve comment.

13 years agoAdd explanation about the use-permission and FreeBSDify it.
netchild [Wed, 4 May 2011 08:41:55 +0000 (08:41 +0000)]
Add explanation about the use-permission and FreeBSDify it.

13 years agoCopy the v4l2 header unchanged from the vendor branch.
netchild [Wed, 4 May 2011 08:31:58 +0000 (08:31 +0000)]
Copy the v4l2 header unchanged from the vendor branch.

13 years agoAdd the v4l2 header now that we have an use case for it.
netchild [Wed, 4 May 2011 08:21:24 +0000 (08:21 +0000)]
Add the v4l2 header now that we have an use case for it.

13 years agoUpgrade to OpenSSH 5.8p2.
des [Wed, 4 May 2011 07:34:44 +0000 (07:34 +0000)]
Upgrade to OpenSSH 5.8p2.

13 years agoMake sure to run make obj before release. Trying to run them in one step
nwhitehorn [Wed, 4 May 2011 02:52:41 +0000 (02:52 +0000)]
Make sure to run make obj before release. Trying to run them in one step
doesn't always work reliably.

13 years agoFix some corner cases in the net80211 sequence number retransmission
adrian [Wed, 4 May 2011 02:23:59 +0000 (02:23 +0000)]
Fix some corner cases in the net80211 sequence number retransmission
handling.

The current sequence number code does a few things incorrectly:

* It didn't try eliminating duplications from HT nodes. I guess it's assumed
  that out of order / retransmission handling would be handled by the AMPDU RX
  routines. If a HT node isn't doing AMPDU RX, then retransmissions need to
  be eliminated. Since most of my debugging is based on this (as AMPDU TX
  software packet aggregation isn't yet handled), handle this corner case.

* When a sequence number of 4095 was received, any subsequent sequence number
  is going to be (by definition) less than 4095. So if the following sequence
  number (0) doesn't initially occur and the retransmit is received, it's
  incorrectly eliminated by the IEEE80211_FC1_RETRY && SEQ_LEQ() check.
  Try to handle this better.

This almost completely eliminates out of order TCP statistics showing up during
iperf testing for the 11a, 11g and non-aggregate 11n AMPDU RX case. The only
other packet loss conditions leading to this are due to baseband resets or
heavy interference.

13 years agoRemove code with any effect.
tuexen [Tue, 3 May 2011 20:34:02 +0000 (20:34 +0000)]
Remove code with any effect.

13 years agoAdd a missing break. This bug was introduced in r221249.
tuexen [Tue, 3 May 2011 20:32:21 +0000 (20:32 +0000)]
Add a missing break. This bug was introduced in r221249.

MFC after: 1 week

13 years agoConvert the last use of xcopyout() to ddi_copyout() and remove the now
marius [Tue, 3 May 2011 20:13:27 +0000 (20:13 +0000)]
Convert the last use of xcopyout() to ddi_copyout() and remove the now
unused xcopyin() as well as xcopyout().
MFC together with r219089.

Approved by: mm

13 years ago- Remove attempts to implement setting of BMCR_LOOP/MIIF_NOLOOP
marius [Tue, 3 May 2011 19:51:29 +0000 (19:51 +0000)]
- Remove attempts to implement setting of BMCR_LOOP/MIIF_NOLOOP
  (reporting IFM_LOOP based on BMCR_LOOP is left in place though as
  it might provide useful for debugging). For most mii(4) drivers it
  was unclear whether the PHYs driven by them actually support
  loopback or not. Moreover, typically loopback mode also needs to
  be activated on the MAC, which none of the Ethernet drivers using
  mii(4) implements. Given that loopback media has no real use (and
  obviously hardly had a chance to actually work) besides for driver
  development (which just loopback mode should be sufficient for
  though, i.e one doesn't necessary need support for loopback media)
  support for it is just dropped as both NetBSD and OpenBSD already
  did quite some time ago.
- Let mii_phy_add_media() also announce the support of IFM_NONE.
- Restructure the PHY entry points to use a structure of entry points
  instead of discrete function pointers, and extend this to include
  a "reset" entry point. Make sure any PHY-specific reset routine is
  always used, and provide one for lxtphy(4) which disables MII
  interrupts (as is done for a few other PHYs we have drivers for).
  This includes changing NIC drivers which previously just called the
  generic mii_phy_reset() to now actually call the PHY-specific reset
  routine, which might be crucial in some cases. While at it, the
  redundant checks in these NIC drivers for mii->mii_instance not being
  zero before calling the reset routines were removed because as soon
  as one PHY driver attaches mii->mii_instance is incremented and we
  hardly can end up in their media change callbacks etc if no PHY driver
  has attached as mii_attach() would have failed in that case and not
  attach a miibus(4) instance.
  Consequently, NIC drivers now no longer should call mii_phy_reset()
  directly, so it was removed from EXPORT_SYMS.
- Add a mii_phy_dev_attach() as a companion helper to mii_phy_dev_probe().
  The purpose of that function is to perform the common steps to attach
  a PHY driver instance and to hook it up to the miibus(4) instance and to
  optionally also handle the probing, addition and initialization of the
  supported media. So all a PHY driver without any special requirements
  has to do in its bus attach method is to call mii_phy_dev_attach()
  along with PHY-specific MIIF_* flags, a pointer to its PHY functions
  and the add_media set to one. All PHY drivers were updated to take
  advantage of mii_phy_dev_attach() as appropriate. Along with these
  changes the capability mask was added to the mii_softc structure so
  PHY drivers taking advantage of mii_phy_dev_attach() but still
  handling media on their own do not need to fiddle with the MII attach
  arguments anyway.
- Keep track of the PHY offset in the mii_softc structure. This is done
  for compatibility with NetBSD/OpenBSD.
- Keep track of the PHY's OUI, model and revision in the mii_softc
  structure. Several PHY drivers require this information also after
  attaching and previously had to wrap their own softc around mii_softc.
  NetBSD/OpenBSD also keep track of the model and revision on their
  mii_softc structure. All PHY drivers were updated to take advantage
  as appropriate.
- Convert the mebers of the MII data structure to unsigned where
  appropriate. This is partly inspired by NetBSD/OpenBSD.
- According to IEEE 802.3-2002 the bits actually have to be reversed
  when mapping an OUI to the MII ID registers. All PHY drivers and
  miidevs where changed as necessary. Actually this now again allows to
  largely share miidevs with NetBSD, which fixed this problem already
  9 years ago. Consequently miidevs was synced as far as possible.
- Add MIIF_NOMANPAUSE and mii_phy_flowstatus() calls to drivers that
  weren't explicitly converted to support flow control before. It's
  unclear whether flow control actually works with these but typically
  it should and their net behavior should be more correct with these
  changes in place than without if the MAC driver sets MIIF_DOPAUSE.

Obtained from: NetBSD (partially)
Reviewed by: yongari (earlier version), silence on arch@ and net@

13 years agoFix prototype for ffsll(3) and fls(3).
delphij [Tue, 3 May 2011 19:33:06 +0000 (19:33 +0000)]
Fix prototype for ffsll(3) and fls(3).

PR: docs/156796
Submitted by: Jean-Yves Migeon <jeanyves.migeon free.fr>
MFC after: 3 days

13 years agoUse make_dev_alias_p() added in r221397 to create alias dev entry.
mav [Tue, 3 May 2011 19:12:42 +0000 (19:12 +0000)]
Use make_dev_alias_p() added in r221397 to create alias dev entry.
It removes panic in case if alias name is already busy for some reason.

13 years agoDocument make_dev_alias_p().
ae [Tue, 3 May 2011 18:55:16 +0000 (18:55 +0000)]
Document make_dev_alias_p().

MFC after: 2 weeks

13 years agoAdd make_dev_alias_p() function. It is similar to make_dev_alias(),
ae [Tue, 3 May 2011 18:54:18 +0000 (18:54 +0000)]
Add make_dev_alias_p() function. It is similar to make_dev_alias(),
but it may return an error like make_dev_p() does.

Reviewed by: kib (previous version)
MFC after: 2 weeks