]> CyberLeo.Net >> Repos - FreeBSD/stable/9.git/log
FreeBSD/stable/9.git
12 years agoMFC r226594:
das [Mon, 9 Jan 2012 04:57:06 +0000 (04:57 +0000)]
MFC r226594:
  Bugfix: feenableexcept() and fedisableexcept() should just return the
  old exception mask, not mask | ~FE_ALL_EXCEPT.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229841 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC various fma{,f,l} improvements:
das [Mon, 9 Jan 2012 04:55:52 +0000 (04:55 +0000)]
MFC various fma{,f,l} improvements:

r226245 - refactoring
r226371 - fix double-rounding bug
r226373 - new math_private.h macros
r226601 - fix nit in r226371

git-svn-id: svn://svn.freebsd.org/base/stable/9@229839 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229353:
gjb [Mon, 9 Jan 2012 01:59:17 +0000 (01:59 +0000)]
MFC r229353:

 - Trivial standardization to a few comments in kern.pre.mk.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229833 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228233:
eadler [Mon, 9 Jan 2012 01:02:37 +0000 (01:02 +0000)]
MFC r228233:
- Fix typos s/(more|less) then|\1 than/

Approved by: brucec

git-svn-id: svn://svn.freebsd.org/base/stable/9@229832 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd relnotes items:
hrs [Sun, 8 Jan 2012 23:11:03 +0000 (23:11 +0000)]
Add relnotes items:
DTrace systrace support for freebsd32 and linux32 on am64,
loader(8) pre-boot virtual memory support on ia64,
bxe(4) for BCM57710, BCM57711, BCM57711E added,
cbrtl(3) (cube root) added,
pam_group(8) ruser and luser options,
tzdata2011d.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229829 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r228560
rmacklem [Sun, 8 Jan 2012 23:05:36 +0000 (23:05 +0000)]
MFC: r228560
Patch the new NFS server in a manner analagous to r228520 for the
old NFS server, so that it correctly handles a count == 0 argument
for Commit.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229827 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd relnotes items:
hrs [Sun, 8 Jan 2012 22:23:19 +0000 (22:23 +0000)]
Add relnotes items:
{get,set}loginclass(2) added,
machdep.disable_tsc tunable added,
ng_netflow(4) now supports NetFlow v9,
cexp(3) and cexpf(3) added,
gpart(8) show -p flag added,
hashd(8) checksum algo selection in a resource section,
hashd(8) compression algo selection in a resource section,
ps(1) -o class added,
gdtoa to 20110304,
tzdata2011c.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229826 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228754:
eadler [Sun, 8 Jan 2012 21:00:37 +0000 (21:00 +0000)]
MFC r228754:
 - Add restrict keyword to glob(3)

PR: kern/161958
Approved by: jilles

git-svn-id: svn://svn.freebsd.org/base/stable/9@229823 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd relnotes items:
hrs [Sun, 8 Jan 2012 19:52:56 +0000 (19:52 +0000)]
Add relnotes items:
Capsicum Capability Mode,
ng_one2many(4) XMIT_FAILOVER support added,
kern.geom.confxml sysctl now support <ident> and <descr>, and
ZFS SPA version 28.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229820 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd relnotes items:
hrs [Sun, 8 Jan 2012 19:24:08 +0000 (19:24 +0000)]
Add relnotes items:
add descriptions about kern.features.*,
new NFS implementation (newnfs) is now compiled in by default,
add some descriptions about NFSv4 configuration, and
document a workaround for the kern.geom.part.check_integrity issue.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229819 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd relnotes items:
hrs [Sun, 8 Jan 2012 17:40:10 +0000 (17:40 +0000)]
Add relnotes items:
cxgbe(4) for Chelsio T4 added,
dc(4) PAE support on FreeBSD/i386,
re(4) RTL8401E support added,
IPsec HMAC-SHA-256/384/512 authenticator hash size fix,
cc(4) TCP_CONGESTION socket option,
Citrus iconv imported (but disabled by default),
utxrm(8) utility added,
GNU binutils to 2.17.50,
LLVM/Clang 3.0 imported,
xz to 5.0.1,
bsdinstall(8) added as the default installer.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229817 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd relnotes items:
hrs [Sun, 8 Jan 2012 13:54:08 +0000 (13:54 +0000)]
Add relnotes items:
igb(4) Intel I350 GbE support,
re(4) TX IP checksum disabled on RTL8168C-based cards,
cc(9) TCP congestion control algorithm framework added,
gpart(8) various aliases and bios-boot GUID added,
FFS SU+J added,
more kern.features.* for UFS-related features,
hastd(8) drops root privilege in worker processes,
newsyslog(8) xz compression support added,
ppp(8) iface name and iface description commands added,
sh(1) arithmetic expression handling updated,
ISC BIND to 9.8.1-P1, and
tzdata2011a.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229812 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229196:
dim [Sun, 8 Jan 2012 13:51:09 +0000 (13:51 +0000)]
MFC r229196:

Redo r228645, but instead of casting away const conversion warnings in
contrib/less, add a few const qualifiers in the right places.

Suggested by: das

git-svn-id: svn://svn.freebsd.org/base/stable/9@229811 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229185:
kib [Sun, 8 Jan 2012 07:51:40 +0000 (07:51 +0000)]
MFC r229185:
Avoid double-unlock or double unreference for ndp->ni_dvp when the vnode dp
lock upgrade right after the 'success' label fails.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229804 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r228260
rmacklem [Sun, 8 Jan 2012 00:42:07 +0000 (00:42 +0000)]
MFC: r228260
This patch adds a sysctl to the NFSv4 server which optionally disables the
check for a UTF-8 compliant file name. Enabling this sysctl results in
an NFSv4 server that is non-RFC3530 compliant, therefore it is not enabled
by default. However, enabling this sysctl results in NFSv3 compatible
behaviour and fixes the problem reported by "dan at sunsaturn.com"
to freebsd-current@ on Nov. 14, 2011 under the subject "NFSV4 readlink_stat".

git-svn-id: svn://svn.freebsd.org/base/stable/9@229799 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years ago- Add relnotes items:
hrs [Sun, 8 Jan 2012 00:14:45 +0000 (00:14 +0000)]
- Add relnotes items:
  nfe(4) reinit issue fixed,
re(4) RX int moderation changed from int taskq to one-shot timer,
re(4) TSO disabled by default,
re(4) RTL8105E support, and
rlphy(4) RTL8201E support.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229797 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years ago- Add relnotes items:
hrs [Sat, 7 Jan 2012 23:47:09 +0000 (23:47 +0000)]
- Add relnotes items:
alc(4) AR8152-based card lockup fixed,
ixgbe(4) to 2.3.8,
sis(4) reinit issue fixed,
netstat(1) embedded address scope id handling,
sh(1) signal handling fixed,
unifdef(1) to 2.5.6.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229796 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years ago- Fix spelling.
hrs [Sat, 7 Jan 2012 22:29:46 +0000 (22:29 +0000)]
- Fix spelling.
- Add relnotes items:
        nxstack on powerpc,
        ral(4) and run(4) ieee80211_ratectl_node_init() call fix,
        re(4) RTL8168E/8111E-VL support added,
        re(4) TX/RX checksum offloading configuarable independently,
        cpuset(1) -C and "all" keyword added,
        sh(1) exit status in trap action for !EXIT signals,
        sh(1) trap -- handling,
        ACPI CA to 20110527.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229793 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd relnotes items:
hrs [Sat, 7 Jan 2012 20:29:05 +0000 (20:29 +0000)]
Add relnotes items:
PT_GNU_STACK and kern.elf{32,64}.nxstack sysctls in ELF imgact,
FreeBSD/powerpc PS3 support added,
re(4) TSO support added,
  re(4) RTL8169[CDE] jumbo frame panic fixed,
source address selection in unbound sockets fixed,
ifconfig(8) fdx/flow/hdx/loop aliases added,
sed(1) -i race fixed,
sh(1) EXIT trap fixed,
sh(1) %builtin keyword removed,
dialog to 1.1-20110707 and description about key operation change.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229792 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoAdd revision attribute handling. Links are now generated at the end
hrs [Sat, 7 Jan 2012 18:53:14 +0000 (18:53 +0000)]
Add revision attribute handling.  Links are now generated at the end
of the paragraph from revision="NNN".

git-svn-id: svn://svn.freebsd.org/base/stable/9@229788 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years ago- Remove unnecessary and/or old parts.
hrs [Sat, 7 Jan 2012 18:52:16 +0000 (18:52 +0000)]
- Remove unnecessary and/or old parts.
- Add relnote entries:
msk(4) RX checksum bugfix,
rdcphy(4) for R6040 10/100 PHY added,
vte(4) for RDC R6040 added,
vlan(4) IPv6 LLA interface ID bugfix,
wpi(4) bugfix,
md(4) vm.md_malloc_wait sysctl added,
mmc(4) device detection fixed,
FFS TRIM support added,
poweroff(8) added,
rtld(1) now supports shared objects for filtering,
sh(1) kill built-in added, and
KDE 4.7.3.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229787 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229076:
dim [Sat, 7 Jan 2012 14:35:37 +0000 (14:35 +0000)]
MFC r229076:

In sys/dev/hwpmc/hwpmc_amd.c, fix a clang warning about invalid enum
conversions.

Reviewed by: jkoshy

git-svn-id: svn://svn.freebsd.org/base/stable/9@229776 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229765 - Fix the ar724x shift calculation when writing to the PCI config space.
adrian [Sat, 7 Jan 2012 12:32:50 +0000 (12:32 +0000)]
MFC r229765 - Fix the ar724x shift calculation when writing to the PCI config space.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229772 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMerge from head/ 228732,228811,228813-228816,228855:
glebius [Sat, 7 Jan 2012 11:01:35 +0000 (11:01 +0000)]
Merge from head/ 228732,228811,228813-228816,228855:

  r228732 | glebius | 2011-12-20 16:34:16 +0400 (вт, 20 дек 2011) | 3 lines

  - Cover pfsync callouts deletion with PF_LOCK().
  - Cover setting up interface between pf and pfsync with PF_LOCK().

  r228811 | glebius | 2011-12-22 22:31:47 +0400 (чт, 22 дек 2011) | 3 lines

  In FreeBSD we always have bpf(4) API, either real or stub. No need
  in detecting presense of 'device bpf'.

  r228813 | glebius | 2011-12-22 22:51:35 +0400 (чт, 22 дек 2011) | 2 lines

  We really mean MTU of the real interface here, not of our pseudo.

  r228814 | glebius | 2011-12-22 22:56:27 +0400 (чт, 22 дек 2011) | 16 lines

  Merge couple more fixes from OpenBSD to bulk processing:

    revision 1.118
    date: 2009/03/23 06:19:59;  author: dlg;  state: Exp;  lines: +8 -6
    wait an appropriate amount of time before giving up on a bulk update,
    rather than giving up after a hardcoded 5 seconds (which is generally much
    too short an interval for a bulk update).
    pointed out by david@, eyeballed by mcbride@

    revision 1.171
    date: 2011/10/31 22:02:52;  author: mikeb;  state: Exp;  lines: +2 -1
    Don't forget to cancel bulk update failure timeout when destroying an
    interface.  Problem report and fix from Erik Lax, thanks!

  Start a brief note of revisions merged from OpenBSD.

  r228815 | glebius | 2011-12-22 23:05:58 +0400 (чт, 22 дек 2011) | 12 lines

  Merge from OpenBSD:
    revision 1.120
    date: 2009/04/04 13:09:29;  author: dlg;  state: Exp;  lines: +5 -5
    use time_uptime instead of time_second internally. time_uptime isnt
    affected by adjusting the clock.

    revision 1.175
    date: 2011/11/25 12:52:10;  author: dlg;  state: Exp;  lines: +3 -3
    use time_uptime to set state creation values as time_second can be
    skewed at runtime by things like date(1) and ntpd. time_uptime is
    monotonic and therefore more useful to compare against.

  r228816 | glebius | 2011-12-22 23:09:55 +0400 (чт, 22 дек 2011) | 11 lines

  Merge from OpenBSD:
    revision 1.122
    date: 2009/05/13 01:01:34;  author: dlg;  state: Exp;  lines: +6 -4
    only keep track of the number of updates on tcp connections. state sync on
    all the other protocols is simply pushing the timeouts along which has a
    resolution of 1 second, so it isnt going to be hurt by pfsync taking up
    to a second to send it over.

    keep track of updates on tcp still though, their windows need constant
    attention.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229770 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229508:
kib [Sat, 7 Jan 2012 10:49:04 +0000 (10:49 +0000)]
MFC r229508:
Postpone the resolution of IRELATIVE relocations and IFUNC-targeted
relocations until tls is initialized and stacks permissions correctly
set. This allows the ifunc to call malloc(3) and some other heavy
services.

Add debug banner.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229769 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227491:
eadler [Sat, 7 Jan 2012 03:32:47 +0000 (03:32 +0000)]
MFC r227491:

-  new sentence should start on new line.

Approved by: gjb

git-svn-id: svn://svn.freebsd.org/base/stable/9@229764 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228355:
gjb [Sat, 7 Jan 2012 02:03:07 +0000 (02:03 +0000)]
MFC r228355:

- As of r226865, daily_scrub_zfs_default_threshold is 35 days.

PR: 162890

git-svn-id: svn://svn.freebsd.org/base/stable/9@229757 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r228217
rmacklem [Sat, 7 Jan 2012 00:36:17 +0000 (00:36 +0000)]
MFC: r228217
Post r223774, the NFSv4 client no longer has multiple instances
of the same lock_owner4 string. As such, the handling of cleanup
of lock_owners could be simplified. This simplification permitted
the client to do a ReleaseLockOwner operation when the process that
the lock_owner4 string represents, has exited. This permits the
server to release any storage related to the lock_owner4 string
before the associated open is closed. Without this change, it
is possible to exhaust a server's storage when a long running
process opens a file and then many child processes do locking
on the file, because the open doesn't get closed. A similar patch
was applied to the Linux NFSv4 client recently so that it wouldn't
exhaust a server's storage.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229752 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoWhen copying/pasting a line to create a line you want to add make sure
kensmith [Sat, 7 Jan 2012 00:33:13 +0000 (00:33 +0000)]
When copying/pasting a line to create a line you want to add make sure
to change all pieces of it, not just some of them.

Submitted by: A helpful soul on IRC
Pointy hat: me

git-svn-id: svn://svn.freebsd.org/base/stable/9@229751 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC the rest of r225757 that applies to the package set directories.
kensmith [Sat, 7 Jan 2012 00:07:23 +0000 (00:07 +0000)]
MFC the rest of r225757 that applies to the package set directories.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229748 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228370:
yongari [Fri, 6 Jan 2012 23:57:21 +0000 (23:57 +0000)]
MFC r228370:
  After r228293, et(4) supports altq(4).

git-svn-id: svn://svn.freebsd.org/base/stable/9@229745 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228817:
dim [Fri, 6 Jan 2012 22:18:13 +0000 (22:18 +0000)]
MFC r228817:

Use the correct types when calling the decompression mask function.

There's currently no public code which uses this feature and the
current reference driver doesn't enable this feature at all.
It's possible it was used by a previous version of the driver and
that indeed it should return HAL_STATUS; but at this point I'm
happy to require that they complain and submit a patch.

This was found by LLVM compile-time type checking.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229740 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229004:
dim [Fri, 6 Jan 2012 22:15:58 +0000 (22:15 +0000)]
MFC r229004:

In sys/compat/ndis/subr_ntoskrnl.c, change the RtlFillMemory function
definition from K&R to ANSI, to avoid a clang warning about the uint8_t
parameter being promoted to int, which is not compatible with the type
declared in the earlier prototype.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229739 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228333,228335-228336,228362,228368-228369,228381:
yongari [Fri, 6 Jan 2012 21:43:26 +0000 (21:43 +0000)]
MFC r228333,228335-228336,228362,228368-228369,228381:
r228333:
  Protect SIOCSIFMTU ioctl handler with driver lock.
  Don't blindly re-initialize controller whenever MTU is changed.
  Now, reinitializing is done only when driver is running.

  While here, remove unnecessary assignment of error value since it
  was already initialized to 0.

r228335:
  Consistently use a tab character instead of using either a space or
  tab after #define.
  While I'm here consistently use capital letters when it uses
  hexadecimal notation.

  No functional changes.

r228336:
  Disable all clocks and put PHY into COMA before entering into
  suspend state.  This will save more power.
  On resume, make sure to enable all clocks.  While I'm here, if
  controller is not fast ethernet, enable gigabit PHY.

r228362:
  Do not disable interrupt without knowing whether the raised
  interrupt is ours.  Note, interrupts are automatically ACKed when
  the status register is read.
  Add RX/TX DMA error to interrupt handler and do full controller
  reset if driver happen to encounter these errors.  There is no way
  to recover from these DMA errors without controller reset.
  Rename local variable name intrs with status to enhance
  readability.

  While I'm here, rename ET_INTR_TXEOF and ET_INTR_RXEOF to
  ET_INTR_TXDMA and ET_INTR_RXDMA respectively.  These interrupts
  indicate that a frame is successfully DMAed to controller's
  internal FIFO and they have nothing to do with EOF(end of frame).
  Driver does not need to wait actual end of TX/RX of a frame(e.g.
  no need to wait the end signal of TX which is generated when a
  frame in TX FIFO is emptied by MAC).  Previous names were somewhat
  confusing.

r228368:
  Remove unnecessary definition of ET_PCIR_BAR.  Controller support
  I/O memory only.
  While here, use pci_set_max_read_req(9) rather than directly
  manipulating PCIe device control register.

r228369:
  Announce flow control ability to PHY driver and enable RX flow
  control.  Controller does not automatically generate pause frames
  based on number of available RX buffers so it's very hard to
  know when driver should generate XON frame in time.  The only
  mechanism driver can detect low number of RX buffer condition is
  ET_INTR_RXRING0_LOW or ET_INTR_RXRING1_LOW interrupt.  This
  interrupt is generated whenever controller notices the number of
  available RX buffers are lower than pre-programmed value(
  ET_RX_RING0_MINCNT and ET_RX_RING1_MINCNT register).  This scheme
  does not provide a way to detect when controller sees enough number
  of RX buffers again such that efficient generation of XON/XOFF
  frame is not easy.

  While here, add more flow control related register definition.

r228381:
  FreeBSD driver does not require arpcom structure in softc.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229736 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228994:
dim [Fri, 6 Jan 2012 21:23:00 +0000 (21:23 +0000)]
MFC r228994:

Disable several instances instances of clang's -Wself-assign warning.
All of these are harmless, and are in fact used to shut up warnings from
lint.

While here, remove -Wno-missing-prototypes from the xfs module
Makefile, as I could not reproduce those warnings either with gcc or
clang.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229734 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228980:
dim [Fri, 6 Jan 2012 21:19:43 +0000 (21:19 +0000)]
MFC r228980:

Reapply r228785 now it has been tested by Adrian.  Also add comments
with the old AR_SCR_SLE_XXX values, with a short explanation why they
were changed.

Reviewed by: adrian

git-svn-id: svn://svn.freebsd.org/base/stable/9@229733 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228979:
dim [Fri, 6 Jan 2012 21:16:51 +0000 (21:16 +0000)]
MFC r228979:

In sys/dev/drm/radeon_state.c, use the correct printf length modifiers
for ints.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229732 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228978:
dim [Fri, 6 Jan 2012 21:14:54 +0000 (21:14 +0000)]
MFC r228978:

For several files in sys/dev/drm, disable -Wunused-value when building
with clang.  There are several macros in these files that return values,
and in some cases nothing is done with them, but it is completely
harmless.  For some other files, also disable -Wconstant-conversion,
since that triggers a false positive with the DMA_BIT_MASK() macro.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229731 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoRegen.
jhb [Fri, 6 Jan 2012 19:30:17 +0000 (19:30 +0000)]
Regen.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229724 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 227070,227341,227502:
jhb [Fri, 6 Jan 2012 19:29:16 +0000 (19:29 +0000)]
MFC 227070,227341,227502:
Add the posix_fadvise(2) system call.  It is somewhat similar to
madvise(2) except that it operates on a file descriptor instead of a
memory region.  It is currently only supported on regular files.

Note that this adds a new VOP, so all filesystem modules must be
recompiled.

Approved by: re (kib)

git-svn-id: svn://svn.freebsd.org/base/stable/9@229723 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228326-228327,228331-228332:
yongari [Fri, 6 Jan 2012 19:24:33 +0000 (19:24 +0000)]
MFC r228326-228327,228331-228332:
r228326:
  Controller does not require TX start command for every frame.  So
  send a single TX command after setting up all TX frames.  This
  removes unnecessary register accesses and bus_dmamap_sync(9) calls.
  et(4) uses TX interrupt moderation so it's possible to have TX
  buffers that were already transmitted but waiting for TX completion
  interrupt.  If the number of available TX descriptor is less then
  1/3 of total TX descriptor, try reclaiming first to get enough free
  TX descriptors before setting up TX descriptors.
  After r228325, et_txeof() no longer tries to send frames after
  reclaiming TX buffers.  That change was made to give more chance
  to transmit frames in main interrupt handler since we can still
  send frames in interrupt handler with RX interrupt.  So right
  before exiting interrupt hander, after enabling interrupt, try to
  send more frames.  This gives slightly better performance numbers.

  While I'm here reduce number of spare TX descriptors from 8 to 4.
  Controller does not require reserved TX descriptors, it was just to
  reduce TX overhead.  After r228325, driver has much lower TX
  overhead so it does not make sense to reserve 8 TX descriptors.

r228327:
  Remove et_enable_intrs(), et_disable_intrs() functions and
  manipulation of interrupt register access is done through
  CSR_WRITE_4 macro.  Also add disabling interrupt into et_reset()
  because we want interrupt disabled state after controller reset.
  While I'm here slightly change interrupt handler to be more
  readable one.

r228331:
  Rework link state tracking and TX/RX MAC configuration.
   o Do not report link status if driver is not running.
   o TX/RX MAC configuration should be done with resolved speed,
     duplex and flow control after establishing a link so it can't
     be done in driver initialization routine.
     Move the configuration to miibus_statchg callback which will be
     called whenever any link state change is detected.
     At this moment, flow-control is not enabled yet mainly because
     I was not able to set correct flow control parameters to
     generate TX pause frames.
   o Now TX/RX MAC is enabled only when a valid link is detected.
     Rearragnge hardware initialization routine a bit to leave
     enabling MAC to miibus_statchg callback.  In order to that,
     TX/RX DMA engine is enabled in et_init_locked().
   o Introduce ET_FLAG_LINK flag to track current link state.
   o Introduce ET_FLAG_FASTETHER flag to mark whether controller is
     fast ethernet.  This flag is checked in miibus_statchg callback
     to know whether PHY established a valid link.
   o In et_stop(), TX/RX MAC is explicitly disabled instead of
     relying on et_reset().  And move et_reset() from et_stop() to
     controller initialization.  Controler reset is not required here
     and it would also clear critial registers(i.e station address,
     RX filter configuration, WOL etc) that are required to make WOL
     work.
   o Switching to current media is done in et_init_locked() after
     setting IFF_DRV_RUNNING flag.  This should ensure reliable
     auto-negotiation/manual link establishment.
   o In et_start_locked(), check whether driver got a valid link
     before trying to send frames.
   o Remove checking a link in et_tick() as this is done by
     miibus_statchg callback.

r228332:
  Implement hardware MAC statistics counter.  Counters could be
  queried with dev.et.%d.stats sysctl node where %d is an instance of
  device.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229720 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228325:
yongari [Fri, 6 Jan 2012 19:09:47 +0000 (19:09 +0000)]
MFC r228325:
  Overhaul bus_dma(9) usage in et(4) and clean up TX/RX path.  This
  change should make et(4) work on any architectures.
   o Remove m_getl inline function and replace it with stanard mbuf
     interfaces.  Previous code tried to minimize code duplication
     but this came from incorrect use of common DMA tag.
     Driver may be still use a common RX allocation handler with
     additional structure changes but I don't see much point to do
     that it would make it hard to understand the code.
   o Remove DragonflyBSD specific constant EVL_ENCAPLEN, use
     ETHER_VLAN_ENCAP_LEN instead.
   o Add bunch of new RX status definition.  It seems controller
     supports RX checksum offloading but I was not able to make the
     feature work yet.  Currently driver checks whether recevied
     frame is good one or not.
   o Avoid a typedef ending in '_t' as style(9) says.
   o Controller has no restriction on DMA address space, so there
     is no reason to limit the DMA address to 32bit.  Descriptor
     rings,  status blocks and TX/RX buffers now use full 64bit DMA
     addressing.
   o Allocate DMA memory shared between host and controller as
     coherent.
   o Create 3 separate DMA tags to be used as TX, mini RX ring and
     stanard RX ring.  Previously it created a single DMA tag and it
     was used to all three rings.
   o et(4) does not support jumbo frame at this moment and I still
     don't quite understand how jumbo frame works on this controller
     so use two RX rings to handle small sized frame and normal sized
     frame respectively.  The mini RX ring will be used to receive
     frames that are less than or equal to 127 bytes.  The second RX
     ring is used to receive frames that are not handled by the first
     RX ring.
     If jumbo frame support is implemented, driver may have to choose
     better RX scheme by letting the second RX ring handle jumbo
     frames.  This scheme will mimic Broadcom's efficient jumbo frame
     handling feature.  However RAM buffer size(16KB) of the
     controller is too small to hold 2 jumbo frames, if 9KB
     jumbo frame is used, I'm not sure how good performance would it
     have.
   o In et_rxeof(), make sure to check whether controller received
     good frame or not.  Passing corrupted frame to upper layer is
     bad idea.
   o If driver receives a bad frame or driver fails to allocate RX
     buffer due to resource shortage condition, reuse previously
     loaded DMA map for RX buffer instead of unloading/loading RX
     buffer again.
   o et_init_tx_ring() never fails so change return type to void.
   o In watchdog handler, show TX DMA write back status of errored
     frame which could be used as a clue to debug watchdog timeout.
   o Add missing bus_dmamap_sync() in various places such that et(4)
     should work with bounce buffers(e.g. PAE).
   o TX side bus_dmamap_load_mbuf_sg(9) support.
   o RX side bus_dmamap_load_mbuf_sg(9) support.
   o Controller has no DMA alignment limit in RX buffer so use
     m_adj(9) in RX buffer allocation to make IP header align on 2
     bytes boundary.  Otherwise it would trigger unaligned access
     error in upper layer on strict alignment architectures.
     One of down side of controller is it provides limited set of RX
     buffer length like most Intel controllers.  This is not problem
     at this moment because driver does not support jumbo frame yet
     but it may require alignment fixup code to support jumbo frame
     on strict alignment architectures.
   o In et_txeof(), don't zero TX descriptors for transmitted frames.
     TX descriptors don't need write access after transmission.
     Driver sets IFF_DRV_OACTIVE when the number of available TX
     descriptors are less than or equal to ET_NSEG_SPARE.  Make sure
     to clear IFF_DRV_OACTIVE only when the number of available TX
     descriptor is greater than ET_NSEG_SPARE.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229717 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228291-228293,228297-228298:
yongari [Fri, 6 Jan 2012 18:15:27 +0000 (18:15 +0000)]
MFC r228291-228293,228297-228298:
r228291:
  Remove NetBSD license. r199548 removed all bit macros that were
  derived from NetBSD.

r228292:
  Implement suspend/resume methods.  Driver has no issue with
  suspend/resume.

r228293:
  Fix alt(4) support.  Also add check for number of available TX
  descriptors before trying to send frames.  If we're not able to
  send a frame, make sure to prepend it to if_snd queue such that
  alt(4) should work.

  While I'm here prefer ETHER_BPF_MTAP to BPF_MTAP.  ETHER_BPF_MTAP
  should be used for controllers that support VLAN hardware tag
  insertion.  The controller supports VLAN tag insertion but lacks
  VLAN tag stripping in RX path though.

r228297:
  et(4) supports VLAN oversized frame so correctly set header length.
  While I'm here remove initializing if_mtu, it is set by
  ether_ifattach(9).  Also move callout_init_mtx(9) to the right below
  driver lock initialization.

r228298:
  Make et_probe() return BUS_PROBE_DEFAULT such that allow other
  driver that has high precedence for the controller override et(4).
  Add missing callout_drain(9) in device detach and rework detach
  routine.  While I'm here use rman_get_rid(9) instead of using
  cached resource id because bus methods are free to change the
  id.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229711 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227317, r227355:
trociny [Fri, 6 Jan 2012 16:57:56 +0000 (16:57 +0000)]
MFC r227317, r227355:

When displaying process virtual memory mappings print superpage
mapping flag.

Submitted by: Mel Flynn <mel.flynn+fbsd.hackers@mailing.thruhere.net>
Reviewed by: alc, rwatson

git-svn-id: svn://svn.freebsd.org/base/stable/9@229710 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228967:
jhb [Fri, 6 Jan 2012 16:56:09 +0000 (16:56 +0000)]
MFC 228967:
Update if_obytes and if_omcast after successful transmit.
While I'm here update if_oerrors if parent interface of vlan is not
up and running.  Previously it updated collision counter and it was
confusing to interprete it.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229708 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227316:
trociny [Fri, 6 Jan 2012 16:54:16 +0000 (16:54 +0000)]
MFC r227316:

Add KVME_FLAG_SUPER and use it in sysctl_kern_proc_vmmap for marking
entries with superpages.

Submitted by: Mel Flynn <mel.flynn+fbsd.hackers@mailing.thruhere.net>
Reviewed by: alc, rwatson

git-svn-id: svn://svn.freebsd.org/base/stable/9@229707 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227954:
trociny [Fri, 6 Jan 2012 16:45:44 +0000 (16:45 +0000)]
MFC r227954:

Add const qualifier to rlimit_ident.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229705 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227697:
kib [Fri, 6 Jan 2012 15:07:28 +0000 (15:07 +0000)]
MFC r227697:
Change the interface for VOP_VPTOCNP(), now the dvp must be
referenced. Convert all in-tree implementations of VOP_VPTOCNP().
This fixes VOP_VPTOCNP bypass for nullfs.

Approved by: re (bz)

git-svn-id: svn://svn.freebsd.org/base/stable/9@229703 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228838:
kib [Fri, 6 Jan 2012 11:06:15 +0000 (11:06 +0000)]
MFC r228838:
Optimize the common case of msyncing the whole file mapping with
MS_SYNC flag.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229695 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMerge r226830 from head/:
glebius [Fri, 6 Jan 2012 08:46:26 +0000 (08:46 +0000)]
Merge r226830 from head/:
  Add macro IF_DEQUEUE_ALL(ifq, m), that takes the entire mbuf chain off
  the queue. It can be utilized in queue processing to avoid multiple
  locking/unlocking.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229690 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227871:
kevlo [Fri, 6 Jan 2012 05:51:00 +0000 (05:51 +0000)]
MFC r227871:
Remove unused variable mii.
This variable is initialized but not used.

Reviewed by: yongari

git-svn-id: svn://svn.freebsd.org/base/stable/9@229689 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228048:
kevlo [Fri, 6 Jan 2012 05:48:52 +0000 (05:48 +0000)]
MFC r228048:
Plug memory leaks and fix open(2) error check.

Reviewed by: nwhitehorn

git-svn-id: svn://svn.freebsd.org/base/stable/9@229688 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r229379:
kevlo [Fri, 6 Jan 2012 05:45:23 +0000 (05:45 +0000)]
MFC r229379:
Add support for Intel EG20T serial ports

git-svn-id: svn://svn.freebsd.org/base/stable/9@229687 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years ago- Update copyright year.
hrs [Fri, 6 Jan 2012 05:17:43 +0000 (05:17 +0000)]
- Update copyright year.
- Remove a paragraph which describes sysinstall(8).

git-svn-id: svn://svn.freebsd.org/base/stable/9@229686 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years ago- Update copyright year.
hrs [Fri, 6 Jan 2012 05:12:57 +0000 (05:12 +0000)]
- Update copyright year.
- Add SA-11:0[12456789] and -11:10.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229685 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoUpdate entities and variables for 9.0R.
hrs [Fri, 6 Jan 2012 05:08:51 +0000 (05:08 +0000)]
Update entities and variables for 9.0R.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229684 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years ago- Update copyright year.
hrs [Fri, 6 Jan 2012 05:03:22 +0000 (05:03 +0000)]
- Update copyright year.
- Add SA-11:0[12456789] and -11:10.
- Update the upgrade section.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229683 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227488:
eadler [Fri, 6 Jan 2012 02:24:29 +0000 (02:24 +0000)]
MFC r227488:

- add "check" option to MD5 and friends to compare files against known hash.

Approved by: cperciva

git-svn-id: svn://svn.freebsd.org/base/stable/9@229680 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r227796
rmacklem [Fri, 6 Jan 2012 01:57:41 +0000 (01:57 +0000)]
MFC: r227796
Clean up some cruft in the NFSv4 client left over from the
OpenBSD port, so that it is more readable. No logic change
is made by this commit.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229678 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r227760
rmacklem [Fri, 6 Jan 2012 00:42:32 +0000 (00:42 +0000)]
MFC: r227760
Add two arguments to the nfsrpc_rellockown() function in the NFSv4
client. This does not change the client's behaviour, but prepares
the code so that nfsrpc_rellockown() can be called elsewhere in a
future commit.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229674 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 227577: The sys/sysctl.h header is needed when MFI_DEBUG is defined.
jhb [Thu, 5 Jan 2012 22:14:18 +0000 (22:14 +0000)]
MFC 227577: The sys/sysctl.h header is needed when MFI_DEBUG is defined.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229661 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228286:
yongari [Thu, 5 Jan 2012 20:49:48 +0000 (20:49 +0000)]
MFC r228286:
  Fix off by one error in mbuf access.  Previously it caused panic.
  While I'm here use NULL to compare mbuf pointer and add additional
  check for zero length mbuf before accessing the mbuf.

  PR: kern/162932

git-svn-id: svn://svn.freebsd.org/base/stable/9@229648 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228205:
yongari [Thu, 5 Jan 2012 20:37:13 +0000 (20:37 +0000)]
MFC r228205:
  Add more controllers that support jumbo frame.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229644 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228086:
yongari [Thu, 5 Jan 2012 20:30:16 +0000 (20:30 +0000)]
MFC r228086:
  Announce flow control capability to PHY drivers and enable flow
  control for all vr(4) controllers that support it.  It's known that
  old vr(4) controllers(Rhine II) does not support TX pause but Rhine
  III supports both TX and RX pause.
  Make TX pause really work on Rhine III by letting controller know
  available RX buffers.
  While here, adjust XON/XOFF parameters to get better performance
  with flow control.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229641 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228866:
jhb [Thu, 5 Jan 2012 19:56:30 +0000 (19:56 +0000)]
MFC 228866:
Fix a bug where TAILQ_FIRST(&V_ifnet) was accessed without holding the
proper lock.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229637 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228593:
jhb [Thu, 5 Jan 2012 19:53:01 +0000 (19:53 +0000)]
MFC 228593:
Fire a kevent if necessary after seeking on a regular file.  This fixes a
case where a kevent would not fire on a regular file if an application read
to EOF and then seeked backwards into the file.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229635 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228089:
jhb [Thu, 5 Jan 2012 19:50:12 +0000 (19:50 +0000)]
MFC 228089:
Change the if_vlan driver to use if_transmit for forwarding packets to the
parent interface.  This avoids the overhead of queueing a packet to an IFQ
only to immediately dequeue it again.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229633 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228361:
jhb [Thu, 5 Jan 2012 19:36:23 +0000 (19:36 +0000)]
MFC 228361:
Explicitly use curthread while manipulating td_fpop during last close
of a devfs file descriptor in devfs_close_f().  The passed in td argument
may be NULL if the close was invoked by garbage collection of open
file descriptors in pending control messages in the socket buffer of a
UNIX domain socket after it was closed.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229627 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228496:
jhb [Thu, 5 Jan 2012 19:18:20 +0000 (19:18 +0000)]
MFC 228496:
Implement BUS_ADD_CHILD() for the isab(4) driver.  It already calls
bus_generic_probe() and bus_generic_attach() to handle drivers that add
new children via identify methods.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229625 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228278:
jhb [Thu, 5 Jan 2012 19:14:02 +0000 (19:14 +0000)]
MFC 228278:
Use the correct volume identifier field when parsing MR_EVT_ARG_LD_STRIP
arguments.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229623 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228207:
jhb [Thu, 5 Jan 2012 18:55:59 +0000 (18:55 +0000)]
MFC 228207:
When changing the user priority of a thread, change the real priority
in addition to the user priority for threads whose current real priority
is equal to the previous user priority or if the new priority is a
real-time priority.  This allows priority changes of other threads to
have an immediate effect.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229619 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228185:
jhb [Thu, 5 Jan 2012 18:50:12 +0000 (18:50 +0000)]
MFC 228185:
Enhance the sequential access heuristic used to perform readahead in the
NFS server and reuse it for writes as well to allow writes to the backing
store to be clustered.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229617 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 228181:
jhb [Thu, 5 Jan 2012 18:38:13 +0000 (18:38 +0000)]
MFC 228181:
If the -d flag is specified, ignore any new values specified and only
display the descriptions of specified nodes.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229615 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 227562:
jhb [Thu, 5 Jan 2012 18:30:48 +0000 (18:30 +0000)]
MFC 227562:
Add single-message MSI support to mfi(4).  It is disabled by default but
can be enabled via the hw.mfi.msi tunable.  Many mfi(4) controllers also
support MSI-X, but in testing it seems that many adapters do not work with
MSI-X but do work with MSI.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229611 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228084:
yongari [Thu, 5 Jan 2012 18:21:17 +0000 (18:21 +0000)]
MFC r228084:
  Reuse flag variable to represent driver internal states rather than
  using member variables in softc.
  While I'm here change media after setting IFF_DRV_RUNNING. This
  will remove unnecessary link state handling in vr_tick() if
  controller established a link immediately.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229607 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC 227507: Finish making 'wcommitsize' an NFS client mount option.
jhb [Thu, 5 Jan 2012 17:22:32 +0000 (17:22 +0000)]
MFC 227507: Finish making 'wcommitsize' an NFS client mount option.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229604 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228971:
dim [Thu, 5 Jan 2012 17:14:13 +0000 (17:14 +0000)]
MFC r228971:

For sys/dev/ce/tau32-ddk.c, disable the following warning when building
with clang:

sys/dev/ce/tau32-ddk.c:1228:37: warning: implicit truncation from 'int' to bitfield changes value from 65532 to 8188 [-Wconstant-conversion]

Since this file is obfuscated C, we can never determine (in a sane way,
at least :) if this points to a real problem or not.  The driver has
been in the tree for more than five years, so it most likely isn't.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229602 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228963:
dim [Thu, 5 Jan 2012 17:12:20 +0000 (17:12 +0000)]
MFC r228963:

Fix clang warnings in sys/dev/ce/if_ce.c and sys/dev/cp/if_cp.c,
using jkim's last patch (reviewed by bde) from here:

http://docs.freebsd.org/cgi/mid.cgi?201010141558.03154.jkim

git-svn-id: svn://svn.freebsd.org/base/stable/9@229601 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r227744
rmacklem [Thu, 5 Jan 2012 16:43:54 +0000 (16:43 +0000)]
MFC: r227744
Since the nfscl_cleanup() function isn't used by the FreeBSD NFSv4 client,
delete the code and fix up the related comments. This should not have
any functional effect on the client.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229599 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228970:
pluknet [Thu, 5 Jan 2012 14:51:43 +0000 (14:51 +0000)]
MFC r228970:

 Fix manual section for acl_get(3) and mac_get(3) family functions.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229597 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228797:
mm [Thu, 5 Jan 2012 12:52:05 +0000 (12:52 +0000)]
MFC r228797:
Use contrib sources for building libarchive, tar and cpio.
Make "make test" fully operational.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229595 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC contrib/libarchive:
mm [Thu, 5 Jan 2012 12:06:54 +0000 (12:06 +0000)]
MFC contrib/libarchive:
r228761-r228764, r228770-r228777, r228835, r228911:

MFC r228761:
Copy libarchive from vendor branch to contrib

MFC r228762:
Add FREEBSD-Xlist and FREEBSD-upgrade to contrib/libarchive

MFC r228763:
Set svn:keywords to FreeBSD=%H for contrib/libarchive

MFC r228764:
Strip unnecessary files and directories from contrib/libarchive
according to FREEBSD-Xlist

MFC r228770:
Remove libarchive/archive_entry_copy_bhfi.c and libarchive/mtree.5
Add these files to FREEBSD-Xlist

MFC r228771:
Partial merge of r224691 from lib/libarchive:

Add compatibility for ISO images created with unfixed makefs that
violated ECMA-119 (ISO9660): allow reserved4 to be 0x20 in PVD.
This allows tar to read FreeBSD distribution ISO images created
with makefs prior to NetBSD bin/45217 bugfix (up to 9.0-BETA1).

MFC r228772:
Add missing integer casts to comparsions in libarchive read.

MFC r228773:
Merge FreeBSD changes from lib/libarchive to contrib/libarchive:

r204111 (uqs):
Fix common misspelling of hierarchy

r208027 (uqs):
mdoc: move CAVEATS, BUGS and SECURITY CONSIDERATIONS sections to the
bottom of the manpages and order them consistently.

GNU groff doesn't care about the ordering, and doesn't even mention
CAVEATS and SECURITY CONSIDERATIONS as common sections and where to put
them.

r208291 (uqs):
mdoc: consistently spell our email addresses <foo@FreeBSD.org>

r209031 (uqs):
mdoc nitpicking: the title argument shall be uppercase

r214822 (kientzle):
Clarify the naming:  Methods that free an object should
be called "free".  Retain the old "finish" names to preserve
source compatibility for now.

r214905 (kientzle):
If the Zip reader doesn't see a PK signature block
because there's inter-entry garbage, just scan forward
to find the next one.  This allows us to handle a lot
of Zip archives that have been modified in-place.

Thanks to: Gleb Kurtsou for sending me a sample archive

r216258 (kientzle):
Don't write data into an empty "file."

In particular, this check avoids a warning when
extracting directory entries from certain GNU tar
archives that store directory contents.

r225525 (kientzle):
Fix cpio on ARM.

MFC r228774:
Add $FreeBSD$ to libarchive_fe headers where missing.

MFC r228775:
Merge FreeBSD changes from usr.bin/tar to contrib/libarchive/libarchive_fe:

r213469:
Recognize both ! and ^ as markers for negated character classes.

MFC r228776:
Merge FreeBSD changes from usr.bin/tar to contrib/libarchive/tar:

r204111 (uqs):
Fix common misspelling of hierarchy

r207786 (kientzle):
Various manpage updates, including many long-option synonyms that were
previously undocumented.

r208028 (uqs):
mdoc: move remaining sections into consistent order

This pertains mostly to FILES, HISTORY, EXIT STATUS and AUTHORS sections.

r209152 (kientzle):
If the compressed data is larger than the uncompressed,
report the compression ratio as 0% instead of displaying
nonsense triggered by numeric overflow.  This is common
when dealing with uncompressed files when the I/O blocking
causes there to be small transient differences in the
accounting.

r210720 (joel):
Fix typos.

r223541 (kientzle):
If there is a read error reading Y/N confirmation from the keyboard,
exit immediately with an error.

If there is an error opening or reading a file to put into the archive,
set the return value for a deferred error exit.

r223573 (kientzle):
The --newer-than test should descend into old
directories to look for new files.

r226636 (kientzle):
Typo from previous commit. Urgh.

r224153 (mm, partial):
Update bsdtar.1 manpage

MFC r228777:
Merge FreeBSD changes from usr.bin/cpio to contrib/libarchive/cpio:

r204111 (uqs):
Fix common misspelling of hierarchy

r211054 (kientzle);
Fix -R when used with -p.  Previously, the
uname and gname weren't overwritten, so the
disk restore would use those to lookup the
original uid/gid again.  Clearing the uname
and gname prevents this.

r212263 (gjb):
Fix typo in bsdcpio manual:
s/libarchive_formats/libarchive-formats

MFC r228835:
Fix typo s/xz/libarchive/

Reported by: Emil Mikulic (private e-mail)

MFC r228911:
Update to vendor revision 4016.

Vendor has integrated most of our local changes in revisions 3976-3979 so
future updates are going to be easier.
Thanks to Tim Kientzle <kientzle@FreeBSD.org>.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229592 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228744, r228745, r228748:
mm [Thu, 5 Jan 2012 11:44:55 +0000 (11:44 +0000)]
MFC r228744, r228745, r228748:

MFC r228744 [1]:
Merge vendor revision 3723:
Fixes extraction of Zip entries that use length-at-end without specifying
either the compressed or uncompressed length.  In particular, fixes bsdtar
extraction of such files.

Reported by: Patrick Lamaiziere <patfbsd@davenulle.org> (freebsd-stable@)

MFC r228745:
Update libarchive, tar and cpio to version 2.8.5

The following additional vendor revisions are applied:

Revision 3740:
Use archive_clear_error() to clear the error markers.

Obtained from: http://code.google.com/p/libarchive

MFC r228748:
Sync libarchive with vendor branch release/2.8:

3730:
Fix issue 174 (Windows path names, not relevant for FreeBSD)

3734:
Merge r1989: archive_clear_error should set errno to 0.

3735:
Merge r3247 from trunk: Clear errors before returning
from archive_read_support_format_all()

3799:
Check the position before dereferencing the pointer.
This avoids dereferencing one byte past the end of a string

3824:
Merge r3823 from trunk for issue 199 (hang in iso9660 reading)

Obtained from: http://code.google.com/p/libarchive

git-svn-id: svn://svn.freebsd.org/base/stable/9@229588 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMerge r228463, that explicily uses 255.0.0.0 mask for the temporary prefix.
glebius [Thu, 5 Jan 2012 11:14:28 +0000 (11:14 +0000)]
Merge r228463, that explicily uses 255.0.0.0 mask for the temporary prefix.
This change isn't actually needed in the stable/9, but let it be here, in
case if anyone tries to run stable/9 world on a head/ kernel.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229583 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228206, r228353:
mm [Thu, 5 Jan 2012 11:11:46 +0000 (11:11 +0000)]
MFC r228206, r228353:

MFC r228206:
Remove unnecesary "Ns" macros and add missing command example to zpool(8).

MFC r228353:
Some mdoc(7) style and typo fixes to zfs(8).

Submitted by: Nobuyuki Koganemaru <n-kogane@syd.odn.ne.jp>

git-svn-id: svn://svn.freebsd.org/base/stable/9@229581 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMerge r229003:
glebius [Thu, 5 Jan 2012 11:11:33 +0000 (11:11 +0000)]
Merge r229003:
  style(9), whitespace and spelling nits.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229580 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228103, r228104:
mm [Thu, 5 Jan 2012 11:06:05 +0000 (11:06 +0000)]
MFC r228103, r228104:

MFC r228103:
Merge new ZFS features from illumos:

1644 add ZFS "clones" property
https://www.illumos.org/issues/1644

1645 add ZFS "written" and "written@..." properties
https://www.illumos.org/issues/1645

1646 "zfs send" should estimate size of stream
https://www.illumos.org/issues/1646

1647 "zfs destroy" should determine space reclaimed by destroying multiple
snapshots
https://www.illumos.org/issues/1647

1693 persistent 'comment' field for a zpool
https://www.illumos.org/issues/1693

1708 adjust size of zpool history data
https://www.illumos.org/issues/1708

1748 desire support for reguid in zfs
https://www.illumos.org/issues/1748

MFC r228104:
Fix typo in copyright notice.

Obtained from: illumos (changesets 13514, 13524, 13525)

git-svn-id: svn://svn.freebsd.org/base/stable/9@229578 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC zfs manpage update
mm [Thu, 5 Jan 2012 10:55:17 +0000 (10:55 +0000)]
MFC zfs manpage update
(r227646, r227648, r227649, r227752, r228019, r228045, r228054, r228055)

MFC r227646 (partial):
Update and desolarization of zfs(8) and zpool(8) manual pages:
- synchronized to match new vendor code (Illumos rev. 13513) [1]
- removed references to sun commands (replaced with FreeBSD commands)
- removed ATTRIBUTES sections
- updated SEE ALSO sections
- properly updated copyright information (required by CDDL)

zfs(8) only:
- replaced "Zones" section with new "Jails" section
- removed misleading "ZFS Volumes as Swap or Dump Devices" section
- updated shareiscsi and sharesmb option information (not supported on FreeBSD)
- replace zoned property with jailed property

zpool(8) only:
- updated device names in examples

MFC r227648:
Fix reference to fsync(2).
Add more references to SEE ALSO section.

MFC r227649:
More zfs(8) manpage fixes:
- remove shareiscsi property
- mark casesensitivity property as unsupported
- remove reference to Solaris Administration Guide

MFC r227752 (partial):
Update and desolarization of zdb(8) and zstreamdump(1) manual pages:
- synchronized to match new vendor code [1]
- removed ATTRIBUTES sections
- updated SEE ALSO sections
- properly updated copyright information (required by CDDL)

MFC r228019:
Update ZFS manual pages to a mdoc(7) reimplementation.

The zfs(8) and zpool(8) manual pages now match the state of the ZFS module
and have been customized for FreeBSD.

The new texts of the "Deduplication" subsection in zfs(8), the zpool "split"
command, the zfs "dedup" property and several other missing parts have been
added from illumos or OpenSolaris snv_134 (CDDL-licensed).

The mdoc(7) reimplementation of whole manual pages, the descriptions of the
zpool "readonly" property, "zfs diff" command and descriptions of several
other missing command flags and/or options were authored by myself.

MFC r228045:
Add missing -n flag to "zpool import" description.

MFC r228054:
Add missing warning to zfs(8) for using "zfs destroy" with -r and -R flags.

MFC r228055:
Use singular form for zfs destroy snapshot in zfs(8).

Obtained from: Illumos (as of rev. 13513:f84d4672fdbd) [1]

git-svn-id: svn://svn.freebsd.org/base/stable/9@229576 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228947:
kib [Thu, 5 Jan 2012 10:42:19 +0000 (10:42 +0000)]
MFC r228947:
Add PCI Id for the Intel AMT serial interface as found on my DQ67OW.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229573 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r228363, r228392:
mm [Thu, 5 Jan 2012 10:03:14 +0000 (10:03 +0000)]
MFC r228363, r228392:

MFC r228363 (pjd):
The vfs.zfs.txg.timeout sysctl can be safely modified at run time.

MFC r228392 (pjd) [1]:
Move ru_inblock increment into arc_read_nolock() so we don't account for
cached reads.

Discussed with: gibbs
No objections from: avg
Tested by: Marcus Reid <marcus@blazingdot.com> [1]
Approved by: pjd

git-svn-id: svn://svn.freebsd.org/base/stable/9@229568 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r226676, r226678, r226700, r226705, r226706, r226707:
mm [Thu, 5 Jan 2012 09:37:31 +0000 (09:37 +0000)]
MFC r226676, r226678, r226700, r226705, r226706, r226707:

MFC r226676 (pjd):
Allow to rename file systems without remounting if it is possible.
It is possible for file systems with 'mountpoint' preperty set to 'legacy'
or 'none' - we don't have to change mount directory for them.
Currently such file systems are unmounted on rename and not even mounted back.

This introduces layering violation, as we need to update 'f_mntfromname'
field in statfs structure related to mountpoint (for the dataset we are
renaming and all its children).

In my opinion it is worth it, as it allow to update FreeBSD in even cleaner
way - in ZFS-only configuration root file system is ZFS file system with
'mountpoint' property set to 'legacy'. If root dataset is named system/rootfs,
we can snapshot it (system/rootfs@upgrade), clone it (system/oldrootfs),
update FreeBSD and if it doesn't boot we can boot back from system/oldrootfs
and rename it back to system/rootfs while it is mounted as /. Before it was
not possible, because unmounting / was not possible.

MFC r227768 (pjd):
Include <sys/zfs_vfsops.h> only when compiling kernel module.

MFC r226700 (pjd):
Don't forget to rename mounted snapshots of the file system being renamed.

MFC r226705 (pjd):
Extend r226676 to allow rename without unmount even for file systems with
non-legacy mountpoints. It is better to be able to rename such file systems and
let them be mounted in old places until next reboot than using live CD, etc. to
rename with remount.

This is implemented by adding -u option to 'zfs rename'. If file system's
mountpoint property is set to 'legacy' or 'none', there is no need to specify -u.

Update zfs(8) manual page to reflect this addition.

MFC r226706 (pjd):
Update copyright to include myself.

MFC r226707 (pjd):
- Use better naming now that we allow to rename any mounted file system (not
  only legacy).
- Update copyright to include myself.

Approved by: pjd

git-svn-id: svn://svn.freebsd.org/base/stable/9@229565 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227497, r228020:
mm [Thu, 5 Jan 2012 08:53:54 +0000 (08:53 +0000)]
MFC r227497, r228020:

MFC r227497 [1]:
Import upstream changesets for the output of the "zpool" command:

952 separate intent logs should be obvious in 'zpool iostat' output
1337 `zpool status -D' should tell if there are no DDT entries

References:
https://www.illumos.org/issues/952
https://www.illumos.org/issues/1337

MFC r228020:
Fix zfs(8) and zpool(8) context help to repport supported flags.

Obtained from: Illumos (issues 952, 1337; changesets 13384, 13432) [1]

git-svn-id: svn://svn.freebsd.org/base/stable/9@229563 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoReparent mergeinfo introduced in r229461 on lib/msun/man and lib/libc/gen to more...
eadler [Thu, 5 Jan 2012 04:36:57 +0000 (04:36 +0000)]
Reparent mergeinfo introduced in r229461 on lib/msun/man and lib/libc/gen to more appropriate directories.

This is an intentional direct commit to the stable/9 branch.

Approved by: lstewart

git-svn-id: svn://svn.freebsd.org/base/stable/9@229557 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r228756
pfg [Thu, 5 Jan 2012 02:36:37 +0000 (02:36 +0000)]
MFC: r228756

Clean an inconsistency with -ffinite-math-only.
Backported from the gcc-4_3-branch, revision (118001)
under the GPLv2.
This issue was also fixed in Apple's gcc.

PR: 157025
Reviewed by: mm
Approved by: jhb (mentor)

git-svn-id: svn://svn.freebsd.org/base/stable/9@229554 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r228780
pfg [Thu, 5 Jan 2012 01:48:25 +0000 (01:48 +0000)]
MFC: r228780

Update libstdc++ with small changes up to the latest rev. (135556)
from the gcc 4.2 branch.
The libraries in the gcc-4_2-branch remained under the LGPLv2.

Reviewed by: mm
Approved by: jhb (mentor)

git-svn-id: svn://svn.freebsd.org/base/stable/9@229551 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r228740
pfg [Thu, 5 Jan 2012 01:40:42 +0000 (01:40 +0000)]
MFC: r228740

Many style fixes.
Remove C99 initializers: they don't help in this case.
Set errno to 0 before strtoll() (from NetBSD).

PR: 151850
Suggested by: bde
Approved by: jhb (Mentor)

git-svn-id: svn://svn.freebsd.org/base/stable/9@229550 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r228507, r228539, r228583
pfg [Thu, 5 Jan 2012 01:35:01 +0000 (01:35 +0000)]
MFC: r228507, r228539, r228583

Merge ext2_readwrite.c into ext2_vnops.c as done in UFS.
Bring in reallocblk to ext2fs: new feature implemented by Zheng Liu as
GSoC 2010.
Many style fixes by jh@.

PR: 159232, 159233 and 162564
Approved by: jhb (mentor)

git-svn-id: svn://svn.freebsd.org/base/stable/9@229549 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC: r227743
rmacklem [Thu, 5 Jan 2012 01:25:47 +0000 (01:25 +0000)]
MFC: r227743
Post r223774 the NFSv4 client never uses the linked list with the
head nfsc_defunctlockowner. This patch simply removes the code that
loops through this always empty list, since the code no longer does
anything useful. It should not have any effect on the client's
behaviour.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229548 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227842:
yongari [Thu, 5 Jan 2012 00:08:16 +0000 (00:08 +0000)]
MFC r227842:
  For IP1001 PHY, do not set multi-port device(MASTER).  Ideally this
  bit should not affect link establishment process of auto-negotiation
  if manual configuration is not used, which is true in auto-negotiation.
  However it seems setting this bit interfere with IP1001 PHY's
  down-shifting feature such that establishing a 10/100Mbps link failed
  when 1000baseT link is not available during auto-negotiation process.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229543 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f

12 years agoMFC r227828,227835,227837:
yongari [Wed, 4 Jan 2012 23:58:54 +0000 (23:58 +0000)]
MFC r227828,227835,227837:
r227828:
  Always start MII auto polling before accessing any MII registers.

r227835:
  Rework link establishment and link state detection logic.
   - Remove MIIBUS statchg callback and program VGE_DIAGCTL before
     initiating link establishment.  Previously driver used to
     program VGE_DIAGCTL after getting a link in statchg callback.
     It seems the VGE_DIAGCTL register works like a kind of MII
     register such that it requires setting a 'to be' mode in advance
     rather than relying on resolved speed/duplex of established link.
     This means the statchg callback is not needed in driver.  In
     addition, if there was no link at the time of media change, this
     was not called at all.
   - Introduce vge_ifmedia_upd_locked() to change current media to
     configured one.  Actual media change is performed only after PHY
     reset and VGE_DIAGCTL setup.
   - In WOL configuration, make sure to clear forced mode such that
     controller can rely on auto-negotiation.
   - Unlike most other drivers that use miibus(4), vge(4) used
     controller's auto-polling feature for link state tracking via
     interrupt.  This came from controller's inefficient mechanism to
     access MII registers.  On link state change interrupt, vge(4)
     used to get current link state with series of MII register
     accesses.  Because vge(4) already enabled auto polling, read PHY
     status register to resolved speed/duplex/flow control parameters.

  vge(4) still does not drive MII_TICK to reduce number of MII
  register accesses which in turn means the driver does not know the
  status of auto-negotiation.  This was a one of long standing
  issue of vge(4).  Probably driver may be able to implement a timer
  that keeps track of auto-negotiation state and restart
  auto-negotiation when driver couldn't establish a link within a
  specified period.  However the controller does not provide a
  reliable way to detect auto-negotiation failure so I'm not sure
  whether it's worth to implement it in driver.

  Alternatively driver can completely disable MII auto-polling and
  let miibus(4) poll link state by driving MII_TICK.  This may reduce
  unnecessary overhead of stopping/restarting MII auto-polling of
  controller.  Unfortunately it was known that some variants of
  controller does not work correctly if MII auto-polling is disabled.

r227837:
  Announce flow control capability to underlying PHY driver.
  Pause timer value is initialized to 0xFFFF. Controller allows just
  4 different TX pause thresholds. The lowest possible threshold
  value looks too aggressive so use next available threshold value.

git-svn-id: svn://svn.freebsd.org/base/stable/9@229540 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f