]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
11 years agoRemove reference to vinum(4). The manual page was removed in r248370.
Joel Dahl [Sat, 16 Mar 2013 21:50:06 +0000 (21:50 +0000)]
Remove reference to vinum(4). The manual page was removed in r248370.

11 years agoHide version string under verbose.
Joel Dahl [Sat, 16 Mar 2013 17:57:00 +0000 (17:57 +0000)]
Hide version string under verbose.

Approved by: mav

11 years ago- Replace compat macros with function calls.
Gleb Smirnoff [Sat, 16 Mar 2013 08:58:28 +0000 (08:58 +0000)]
- Replace compat macros with function calls.

11 years ago- Replace compat macros with function calls.
Gleb Smirnoff [Sat, 16 Mar 2013 08:57:36 +0000 (08:57 +0000)]
- Replace compat macros with function calls.
- Remove superfluous cleaning of m_len after allocating.

Sponsored by: Nginx, Inc.

11 years agoContrary to what the deleted comment said, the m_move_pkthdr()
Gleb Smirnoff [Sat, 16 Mar 2013 08:55:21 +0000 (08:55 +0000)]
Contrary to what the deleted comment said, the m_move_pkthdr()
will not smash the M_EXT and data pointer, so it is safe to
pass an mbuf with external storage procuded by m_getcl() to
m_move_pkthdr().

Reviewed by: andre
Sponsored by: Nginx, Inc.

11 years agoBelatedly remove the vinum(4) manual page. The vinum
Gleb Smirnoff [Sat, 16 Mar 2013 08:51:47 +0000 (08:51 +0000)]
Belatedly remove the vinum(4) manual page. The vinum
manager is absent in FreeBSD since 6.0-RELEASE.

Reviewed by: joel

11 years agoChange the type of 'ndesc' from 'int' to 'uint16_t' so that descriptor index
Neel Natu [Sat, 16 Mar 2013 05:40:29 +0000 (05:40 +0000)]
Change the type of 'ndesc' from 'int' to 'uint16_t' so that descriptor index
wraparound is handled correctly.

The gory details are available here:
http://lists.freebsd.org/pipermail/freebsd-virtualization/2013-March/001119.html

This fixes a regression introduced in r247871.

Pointed out by: Bruce Evans, Chris Torek

11 years agoAdd END to ARM libkern assembly functions
Andrew Turner [Sat, 16 Mar 2013 04:08:01 +0000 (04:08 +0000)]
Add END to ARM libkern assembly functions

11 years agoMove the __aeabi_unwind_cpp_pr{0,1,2} functions to libkern so they can be
Andrew Turner [Sat, 16 Mar 2013 04:06:49 +0000 (04:06 +0000)]
Move the __aeabi_unwind_cpp_pr{0,1,2} functions to libkern so they can be
referenced in a non-debug kernel.

11 years agoThe compiler argument -mno-apcs-frame has no meaning when using EABI as we
Andrew Turner [Sat, 16 Mar 2013 03:57:46 +0000 (03:57 +0000)]
The compiler argument -mno-apcs-frame has no meaning when using EABI as we
will use aapcs frames, not apcs frames.

11 years agoImplement the required but unused __aeabi_unwind_cpp_* functions in the
Andrew Turner [Sat, 16 Mar 2013 03:50:27 +0000 (03:50 +0000)]
Implement the required but unused __aeabi_unwind_cpp_* functions in the
trampoline kernel.

11 years agoFix the indentation for a few commands that were missed or incorrectly
Andrew Turner [Sat, 16 Mar 2013 03:21:25 +0000 (03:21 +0000)]
Fix the indentation for a few commands that were missed or incorrectly
indented in r248362.

11 years agoAdjust the indentation of the trampoline compilation to make the commands
Andrew Turner [Sat, 16 Mar 2013 03:15:24 +0000 (03:15 +0000)]
Adjust the indentation of the trampoline compilation to make the commands
easier to follow.

11 years agoAdd an END macro to ARM. This is mostly used to tell gas where the bounds
Andrew Turner [Sat, 16 Mar 2013 02:48:49 +0000 (02:48 +0000)]
Add an END macro to ARM. This is mostly used to tell gas where the bounds
of the functions are when creating the EABI unwind tables.

11 years agoSort syscalls properly.
Pawel Jakub Dawidek [Fri, 15 Mar 2013 23:00:13 +0000 (23:00 +0000)]
Sort syscalls properly.

11 years agosh: Recognize "--" and explicitly reject options in wait builtin.
Jilles Tjoelker [Fri, 15 Mar 2013 20:29:31 +0000 (20:29 +0000)]
sh: Recognize "--" and explicitly reject options in wait builtin.

If syntactically invalid job identifiers are to be taken as jobs that exited
with status 127, this should not apply to options, so that we can add
options later if need be.

11 years agoWhy'd I keep this here? remove it entirely now.
Adrian Chadd [Fri, 15 Mar 2013 20:22:20 +0000 (20:22 +0000)]
Why'd I keep this here? remove it entirely now.

11 years agoAdd a few examples.
Joel Dahl [Fri, 15 Mar 2013 20:12:54 +0000 (20:12 +0000)]
Add a few examples.

Obtained from: OpenBSD

11 years agoFix two bugs:
Adrian Chadd [Fri, 15 Mar 2013 20:00:08 +0000 (20:00 +0000)]
Fix two bugs:

* when pulling frames off of the TID queue, the ATH_TID_REMOVE()
  macro decrements the axq_depth field.  So don't do it twice.

* in ath_tx_comp_cleanup_aggr(), bf wasn't being reset to bf_first
  before walking the buffer list to complete buffers; so those buffers
  will leak.

11 years agoAdd support for Exar XR17V358 8-port serial device to puc(4)
Ryan Stone [Fri, 15 Mar 2013 19:58:44 +0000 (19:58 +0000)]
Add support for Exar XR17V358 8-port serial device to puc(4)

Reviewed by: marius
Sponsored by: Sandvine Inc.
MFC after: 1 week

11 years agoSeparate the copyright lines and the informational block by a blank line.
Konstantin Belousov [Fri, 15 Mar 2013 14:01:37 +0000 (14:01 +0000)]
Separate the copyright lines and the informational block by a blank line.

Requested by: joel
MFC after: 2 weeks

11 years ago- Use m_getcl() instead of hand allocating.
Gleb Smirnoff [Fri, 15 Mar 2013 13:48:53 +0000 (13:48 +0000)]
- Use m_getcl() instead of hand allocating.
- Do not calculate constant length values at run time,
  CTASSERT() their sanity.
- Remove superfluous cleaning of mbuf fields after allocation.
- Replace compat macros with function calls.

Sponsored by: Nginx, Inc.

11 years agoWe can, and should use M_WAITOK here.
Gleb Smirnoff [Fri, 15 Mar 2013 13:10:06 +0000 (13:10 +0000)]
We can, and should use M_WAITOK here.

Sponsored by: Nginx, Inc.

11 years agoAdd my copyright for the 2012 year work, in particular vn_io_fault()
Konstantin Belousov [Fri, 15 Mar 2013 12:57:30 +0000 (12:57 +0000)]
Add my copyright for the 2012 year work, in particular vn_io_fault()
and f_offset locking.  Add required Foundation notice for r248319.

Sponsored by: The FreeBSD Foundation
MFC after: 2 weeks

11 years agoUse m_get/m_gethdr instead of compat macros.
Gleb Smirnoff [Fri, 15 Mar 2013 12:55:30 +0000 (12:55 +0000)]
Use m_get/m_gethdr instead of compat macros.

Sponsored by: Nginx, Inc.

11 years ago- Use m_getcl() instead of hand allocating.
Gleb Smirnoff [Fri, 15 Mar 2013 12:53:53 +0000 (12:53 +0000)]
- Use m_getcl() instead of hand allocating.

Sponsored by: Nginx, Inc.

11 years ago- Use m_getcl() instead of hand allocating.
Gleb Smirnoff [Fri, 15 Mar 2013 12:52:59 +0000 (12:52 +0000)]
- Use m_getcl() instead of hand allocating.
- Convert panic() to KASSERT.
- Remove superfluous cleaning of mbuf fields after allocation.
- Add comment on possible use of m_get2() here.

Sponsored by: Nginx, Inc.

11 years ago- Use m_getcl() instead of hand allocating.
Gleb Smirnoff [Fri, 15 Mar 2013 12:50:29 +0000 (12:50 +0000)]
- Use m_getcl() instead of hand allocating.
- Use m_get()/m_gethdr() instead of macros.
- Remove superfluous cleaning of mbuf fields after allocation.

Sponsored by: Nginx, Inc.

11 years agoUse m_getcl() instead of hand made allocation.
Gleb Smirnoff [Fri, 15 Mar 2013 12:33:23 +0000 (12:33 +0000)]
Use m_getcl() instead of hand made allocation.

Sponsored by: Nginx, Inc.

11 years agoImplement the helper function vn_io_fault_pgmove(), intended to use by
Konstantin Belousov [Fri, 15 Mar 2013 11:16:12 +0000 (11:16 +0000)]
Implement the helper function vn_io_fault_pgmove(), intended to use by
the filesystem VOP_READ() and VOP_WRITE() implementations in the same
way as vn_io_fault_uiomove() over the unmapped buffers.  Helper
provides the convenient wrapper over the pmap_copy_pages() for struct
uio consumers, taking care of the TDP_UIOHELD situations.

Sponsored by: The FreeBSD Foundation
Tested by: pho
MFC after: 2 weeks

11 years agoUse m_get() and m_getcl() instead of compat macros.
Gleb Smirnoff [Fri, 15 Mar 2013 10:21:18 +0000 (10:21 +0000)]
Use m_get() and m_getcl() instead of compat macros.

11 years agoUse m_get2() + m_align() instead of hand made key_alloc_mbuf(). Code
Gleb Smirnoff [Fri, 15 Mar 2013 10:20:15 +0000 (10:20 +0000)]
Use m_get2() + m_align() instead of hand made key_alloc_mbuf(). Code
examination shows, that although key_alloc_mbuf() could return chains,
the callers never use chains, so m_get2() should suffice.

Sponsored by: Nginx, Inc.

11 years ago- Use m_get2() instead of hand allocating.
Gleb Smirnoff [Fri, 15 Mar 2013 10:17:24 +0000 (10:17 +0000)]
- Use m_get2() instead of hand allocating.
- No need for u_int cast here.

Sponsored by: Nginx, Inc.

11 years agoMake m_get2() never use clusters that are bigger than PAGE_SIZE.
Gleb Smirnoff [Fri, 15 Mar 2013 10:15:07 +0000 (10:15 +0000)]
Make m_get2() never use clusters that are bigger than PAGE_SIZE.

Requested by: andre, jhb
Sponsored by: Nginx, Inc.

11 years agoMake this more compilable.
Gleb Smirnoff [Fri, 15 Mar 2013 09:19:19 +0000 (09:19 +0000)]
Make this more compilable.

11 years agoRemove a now incorrect comment.
Adrian Chadd [Fri, 15 Mar 2013 04:43:27 +0000 (04:43 +0000)]
Remove a now incorrect comment.

This comment dates back to my initial stab at TX aggregation completion,
where I didn't even bother trying to do software retries.

11 years agoAdd locking around the new holdingbf code.
Adrian Chadd [Fri, 15 Mar 2013 02:52:37 +0000 (02:52 +0000)]
Add locking around the new holdingbf code.

Since this is being done during buffer free, it's a crap shoot whether
the TX path lock is held or not.  I tried putting the ath_freebuf() code
inside the TX lock and I got all kinds of locking issues - it turns out
that the buffer free path sometimes is called with the lock held and
sometimes isn't. So I'll go and fix that soon.

Hence for now the holdingbf buffers are protected by the TXBUF lock.

11 years agoMFV of 248305, tzdata2013b
Edwin Groothuis [Fri, 15 Mar 2013 00:27:24 +0000 (00:27 +0000)]
MFV of 248305, tzdata2013b

Lots of historical data added.

Morocco: add DST rules for the coming years
Cuba: Doing DST in 2013.
Chili: Will do DST in 2013 as it seems.

11 years agoVendor import of tzdata2013b:
Edwin Groothuis [Fri, 15 Mar 2013 00:17:19 +0000 (00:17 +0000)]
Vendor import of tzdata2013b:

Lots of historical data added.

Morocco: add DST rules for the coming years
Cuba: Doing DST in 2013.
Chili: Will do DST in 2013 as it seems.

Obtained from: ftp://ftp.iana.org/tz/releases/

11 years agoMake file name generation to work with both new and old versions of OpenSSL.
Pawel Jakub Dawidek [Fri, 15 Mar 2013 00:10:38 +0000 (00:10 +0000)]
Make file name generation to work with both new and old versions of OpenSSL.

Sponsored by: The FreeBSD Foundation

11 years agoReplace our (un)vis(1) commands with implementations from NetBSD to
Brooks Davis [Fri, 15 Mar 2013 00:05:50 +0000 (00:05 +0000)]
Replace our (un)vis(1) commands with implementations from NetBSD to
match our import of the (un)vis(3) APIs.

This adds support for multibyte encoding and the -h and -m flags which
support HTTP and MIME encoding respectively.

PR: bin/175418
Obtained from: NetBSD

11 years agoUpdate to the latest (un)vis(3) sources from NetBSD. This adds
Brooks Davis [Thu, 14 Mar 2013 23:51:47 +0000 (23:51 +0000)]
Update to the latest (un)vis(3) sources from NetBSD.  This adds
multibyte support[0] and the new functions strenvisx and strsenvisx.

Add MLINKS for vis(3) functions add by this and the initial import from
NetBSD[1].

PR: bin/166364, bin/175418
Submitted by: "J.R. Oldroyd" <fbsd@opal.com>[0]
stefanf[1]
Obtained from: NetBSD
MFC after: 2 weeks

11 years agoWhen throttling a process to enforce RACCT limits, do not use neither
Edward Tomasz Napierala [Thu, 14 Mar 2013 23:25:42 +0000 (23:25 +0000)]
When throttling a process to enforce RACCT limits, do not use neither
PBDRY (which simply doesn't make any sense) nor PCATCH (which could
be used by a malicious process to work around the PCPU limit).

Submitted by: Rudo Tomori
Reviewed by: kib

11 years agoAccessing td_state requires thread lock to be held.
Edward Tomasz Napierala [Thu, 14 Mar 2013 23:20:18 +0000 (23:20 +0000)]
Accessing td_state requires thread lock to be held.

Submitted by: Rudo Tomori
Reviewed by: kib

11 years agoNow that ioctl(2) is allowed in capability mode and we can limit ioctls for the
Pawel Jakub Dawidek [Thu, 14 Mar 2013 23:14:47 +0000 (23:14 +0000)]
Now that ioctl(2) is allowed in capability mode and we can limit ioctls for the
given descriptors, use Capsicum sandboxing for hastd in primary and secondary
modes. Allow for DIOCGDELETE and DIOCGFLUSH ioctls on provider descriptor and
for G_GATE_CMD_MODIFY, G_GATE_CMD_START, G_GATE_CMD_DONE and G_GATE_CMD_DESTROY
on GEOM Gate descriptor.

Sponsored by: The FreeBSD Foundation

11 years agoMinor corrections.
Pawel Jakub Dawidek [Thu, 14 Mar 2013 23:11:52 +0000 (23:11 +0000)]
Minor corrections.

11 years agoWe don't need buffer to handle BIO_DELETE, so don't check buffer size for it.
Pawel Jakub Dawidek [Thu, 14 Mar 2013 23:07:01 +0000 (23:07 +0000)]
We don't need buffer to handle BIO_DELETE, so don't check buffer size for it.
This fixes handling BIO_DELETE larger than MAXPHYS.

11 years agoDelete requests can be larger than MAXPHYS.
Pawel Jakub Dawidek [Thu, 14 Mar 2013 23:03:48 +0000 (23:03 +0000)]
Delete requests can be larger than MAXPHYS.

11 years agoRename 'status' command to 'list' and introduce new 'status' which produces
Dmitry Morozovsky [Thu, 14 Mar 2013 22:29:37 +0000 (22:29 +0000)]
Rename 'status' command to 'list' and introduce new 'status' which produces
more terse output more observable for both scripts and humans.

Also, it shifts hastctl closer to GEOM utilities with their list/status command
pairs.

Approved by: pjd
MFC after: 4 weeks

11 years agoFDT_DTS_FILE is expanded in a Makefile so use :R to remove the suffix
Brooks Davis [Thu, 14 Mar 2013 22:16:13 +0000 (22:16 +0000)]
FDT_DTS_FILE is expanded in a Makefile so use :R to remove the suffix
rather than using echo|cut to remove everything after the first '.'.

11 years agoRemoved redundant includes.
Pawel Jakub Dawidek [Thu, 14 Mar 2013 21:21:14 +0000 (21:21 +0000)]
Removed redundant includes.

11 years agoAdd FreeBSD 9.1.
Joel Dahl [Thu, 14 Mar 2013 21:20:46 +0000 (21:20 +0000)]
Add FreeBSD 9.1.

11 years agoSome style fixes.
Konstantin Belousov [Thu, 14 Mar 2013 20:31:39 +0000 (20:31 +0000)]
Some style fixes.

Sponsored by: The FreeBSD Foundation

11 years agoAdd currently unused flag argument to the cluster_read(),
Konstantin Belousov [Thu, 14 Mar 2013 20:28:26 +0000 (20:28 +0000)]
Add currently unused flag argument to the cluster_read(),
cluster_write() and cluster_wbuild() functions.  The flags to be
allowed are a subset of the GB_* flags for getblk().

Sponsored by: The FreeBSD Foundation
Tested by: pho

11 years agoWhen pidptr was passed as NULL to pidfile_open(3), we were returning
Pawel Jakub Dawidek [Thu, 14 Mar 2013 20:22:52 +0000 (20:22 +0000)]
When pidptr was passed as NULL to pidfile_open(3), we were returning
EAGAIN/EWOULDBLOCK when another daemon was running and had the pidfile open.
We should return EEXIST in that case, fix it.

Reported by: Dirk Engling <erdgeist@erdgeist.org>
Reviewed by: jhb, Dirk Engling <erdgeist@erdgeist.org>
MFC after: 1 week

11 years agoAdd pmap function pmap_copy_pages(), which copies the content of the
Konstantin Belousov [Thu, 14 Mar 2013 20:18:12 +0000 (20:18 +0000)]
Add pmap function pmap_copy_pages(), which copies the content of the
pages around, taking array of vm_page_t both for source and
destination.  Starting offsets and total transfer size are specified.

The function implements optimal algorithm for copying using the
platform-specific optimizations.  For instance, on the architectures
were the direct map is available, no transient mappings are created,
for i386 the per-cpu ephemeral page frame is used.  The code was
typically borrowed from the pmap_copy_page() for the same
architecture.

Only i386/amd64, powerpc aim and arm/arm-v6 implementations were
tested at the time of commit. High-level code, not committed yet to
the tree, ensures that the use of the function is only allowed after
explicit enablement.

For sparc64, the existing code has known issues and a stab is added
instead, to allow the kernel linking.

Sponsored by: The FreeBSD Foundation
Tested by: pho (i386, amd64), scottl (amd64), ian (arm and arm-v6)
MFC after: 2 weeks

11 years agoCorrect type for DIOCGSTRIPESIZE. Without this there
Xin LI [Thu, 14 Mar 2013 20:05:49 +0000 (20:05 +0000)]
Correct type for DIOCGSTRIPESIZE.  Without this there
would be a stack overflow which will crash the program
later.

PR: bin/176953
Submitted by: r4721 tormail org
MFC after: 3 days

11 years agoSort sections.
Joel Dahl [Thu, 14 Mar 2013 19:56:21 +0000 (19:56 +0000)]
Sort sections.

11 years agoRemove excessive and inconsistent initializers for the various kernel
Konstantin Belousov [Thu, 14 Mar 2013 19:50:09 +0000 (19:50 +0000)]
Remove excessive and inconsistent initializers for the various kernel
maps and submaps.

MFC after: 2 weeks

11 years agoRewrite the vfs_bio_clrbuf(9) to not access the b_data for B_VMIO
Konstantin Belousov [Thu, 14 Mar 2013 19:48:25 +0000 (19:48 +0000)]
Rewrite the vfs_bio_clrbuf(9) to not access the b_data for B_VMIO
buffers directly, use pmap_zero_page_area(9) for each zeroing page
region instead.

Sponsored by: The FreeBSD Foundation
Tested by: pho
MFC after: 2 weeks

11 years agoFix minor spelling error in a comment.
Joel Dahl [Thu, 14 Mar 2013 19:36:20 +0000 (19:36 +0000)]
Fix minor spelling error in a comment.

11 years agoMinor mdoc fixes.
Joel Dahl [Thu, 14 Mar 2013 18:55:41 +0000 (18:55 +0000)]
Minor mdoc fixes.

11 years agoAdd GEOM_* kernel options to the SYNOPSIS.
Joel Dahl [Thu, 14 Mar 2013 18:46:11 +0000 (18:46 +0000)]
Add GEOM_* kernel options to the SYNOPSIS.

11 years agoMFV r248266:
Martin Matuska [Thu, 14 Mar 2013 10:02:59 +0000 (10:02 +0000)]
MFV r248266:
Import minor ZFS changes from vendor

Illumos ZFS issues:
  3604 zdb should print bpobjs more verbosely (fix zdb hang)
  3606 zpool status -x shouldn't warn about old on-disk format

MFC after: 3 days

11 years agoUpdate vendor/illumos/dist to illumos-gate 13983:fe80600e1f8e
Martin Matuska [Thu, 14 Mar 2013 08:25:10 +0000 (08:25 +0000)]
Update vendor/illumos/dist to illumos-gate 13983:fe80600e1f8e

Illumos ZFS issues:
  3604 zdb should print bpobjs more verbosely (fix zdb hang)
  3606 zpool status -x shouldn't warn about old on-disk format

11 years agoUpdate zfs.8 manpage date (missing in r247585)
Martin Matuska [Thu, 14 Mar 2013 08:18:40 +0000 (08:18 +0000)]
Update zfs.8 manpage date (missing in r247585)

MFC: together with r247585

11 years agoImplement "holding buffers" per TX queue rather than globally.
Adrian Chadd [Thu, 14 Mar 2013 06:20:02 +0000 (06:20 +0000)]
Implement "holding buffers" per TX queue rather than globally.

When working on TDMA, Sam Leffler found that the MAC DMA hardware
would re-read the last TX descriptor when getting ready to transmit
the next one.  Thus the whole ATH_BUF_BUSY came into existance -
the descriptor must be left alone (very specifically the link pointer
must be maintained) until the hardware has moved onto the next frame.

He saw this in TDMA because the MAC would be frequently stopping during
active transmit (ie, when it wasn't its turn to transmit.)

Fast-forward to today.  It turns out that this is a problem not with
a single MAC DMA instance, but with each QCU (from 0->9).  They each
maintain separate descriptor pointers and will re-read the last
descriptor when starting to transmit the next.

So when your AP is busy transmitting from multiple TX queues, you'll
(more) frequently see one QCU stopped, waiting for a higher-priority QCU
to finsh transmitting, before it'll go ahead and continue.  If you mess
up the descriptor (ie by freeing it) then you're short of luck.

Thanks to rpaulo for sticking with me whilst I diagnosed this issue
that he was quite reliably triggering in his environment.

This is a reimplementation; it doesn't have anything in common with
the ath9k or the Qualcomm Atheros reference driver.

Now - it in theory doesn't apply on the EDMA chips, as long as you
push one complete frame into the FIFO at a time.  But the MAC can DMA
from a list of frames pushed into the hardware queue (ie, you concat
'n' frames together with link pointers, and then push the head pointer
into the TXQ FIFO.)  Since that's likely how I'm going to implement
CABQ handling in hostap mode, it's likely that I will end up teaching
the EDMA TX completion code about busy buffers, just to be "sure"
this doesn't creep up.

Tested - iperf ap->sta and sta->ap (with both sides running this code):

* AR5416 STA
* AR9160/AR9220 hostap

To validate that it doesn't break the EDMA (FIFO) chips:

* AR9380, AR9485, AR9462 STA

Using iperf with the -S <tos byte decimal value> to set the TCP client
side DSCP bits, mapping to different TIDs and thus different TX queues.

TODO:

* Make this work on the EDMA chips, if we end up pushing lists of frames
  to the hardware (eg how we eventually will handle cabq in hostap/ibss
  mode.)

11 years agoDisable warning/errors for two files for now - they don't compile clean
Adrian Chadd [Thu, 14 Mar 2013 00:27:53 +0000 (00:27 +0000)]
Disable warning/errors for two files for now - they don't compile clean
with clang.

I'll work on this soon.

11 years agoNo need to call an external program.
David E. O'Brien [Wed, 13 Mar 2013 22:50:14 +0000 (22:50 +0000)]
No need to call an external program.

11 years agovinum isn't a new product.
Joel Dahl [Wed, 13 Mar 2013 22:27:01 +0000 (22:27 +0000)]
vinum isn't a new product.

11 years ago- Fix two possible overflows when testing if ELF program headers are on
Tijl Coosemans [Wed, 13 Mar 2013 22:01:31 +0000 (22:01 +0000)]
- Fix two possible overflows when testing if ELF program headers are on
  the first page:
  1. Cast uint16_t operands in a multiplication to unsigned int because
     otherwise the implicit promotion to int results in a signed
     multiplication that can overflow and the behaviour on integer
     overflow is undefined.
  2. Replace (offset + size > PAGE_SIZE) with (size > PAGE_SIZE - offset)
     because the sum may overflow.
- Use the same tests to see if the path to the interpreter is on the first
  page. There's no overflow here because size is already limited by
  MAXPATHLEN, but the compiler optimises the new tests better. Also fix an
  off-by-one error.
- Simplify tests to see if an ELF note program header is on the first page.
  This also fixes an off-by-one error.

Reviewed by: kib
MFC after: 1 week

11 years agoRevert 195703 and 195821 as this special stop handling in NFS is now
John Baldwin [Wed, 13 Mar 2013 21:06:03 +0000 (21:06 +0000)]
Revert 195703 and 195821 as this special stop handling in NFS is now
implemented via VFCF_SBDRY rather than passing PBDRY to individual
sleep calls.

11 years agoAdd quirk for Lenovo T530 headphone redirection.
Xin LI [Wed, 13 Mar 2013 20:35:51 +0000 (20:35 +0000)]
Add quirk for Lenovo T530 headphone redirection.

MFC after: 2 weeks

11 years agoAdd missed `_load' to the `if_foo_load="YES"' line.
Sergey Kandaurov [Wed, 13 Mar 2013 18:43:25 +0000 (18:43 +0000)]
Add missed `_load' to the `if_foo_load="YES"' line.

PR: docs/176915
MFC after: 1 week

11 years agolibc: Avoid SIGPIPE when nscd closes the connection unexpectedly.
Jilles Tjoelker [Wed, 13 Mar 2013 18:38:18 +0000 (18:38 +0000)]
libc: Avoid SIGPIPE when nscd closes the connection unexpectedly.

It is almost always a bug if nscd closes the connection unexpectedly but
programs should not be killed with SIGPIPE for it.

Reviewed by: bushman
Tested by: Jan Beich
MFC after: 1 week

11 years agoLink getcontextx(3) to getcontext(3).
Sergey Kandaurov [Wed, 13 Mar 2013 18:19:33 +0000 (18:19 +0000)]
Link getcontextx(3) to getcontext(3).

Reviewed by: kib
MFC after: 1 week

11 years agoAdd the getcontextx prototype to SYNOPSIS.
Sergey Kandaurov [Wed, 13 Mar 2013 18:18:16 +0000 (18:18 +0000)]
Add the getcontextx prototype to SYNOPSIS.

Reviewed by: kib
MFC after: 1 week

11 years agoFix typo.
Hans Petter Selasky [Wed, 13 Mar 2013 15:42:04 +0000 (15:42 +0000)]
Fix typo.

11 years ago- Make quirk for reading device descriptor from broken USB devices.
Hans Petter Selasky [Wed, 13 Mar 2013 15:38:01 +0000 (15:38 +0000)]
- Make quirk for reading device descriptor from broken USB devices.
Else they won't enumerate at all:
hw.usb.full_ddesc=1
- Reduce the USB descriptor read timeout from 1000ms to
500ms. Typical value for LOW speed devices is 50-100ms.
- Enumerate USB device a maximum of 3 times when a port
connection change event is detected, before giving up.

MFC after: 1 month

11 years ago- Make the FreeBSD's USB library compile under Linux.
Hans Petter Selasky [Wed, 13 Mar 2013 12:23:14 +0000 (12:23 +0000)]
- Make the FreeBSD's USB library compile under Linux.
- Fix a compile warning where the return value of a call
to a write() function was ignored.
- Remove redundant include files from userland USB header files.
- Add some now needed include files to various C-files.

11 years agoUnlike OpenBSD's, our setusercontext() will intentionally ignore the user's
Dag-Erling Smørgrav [Wed, 13 Mar 2013 09:41:55 +0000 (09:41 +0000)]
Unlike OpenBSD's, our setusercontext() will intentionally ignore the user's
own umask setting (from ~/.login.conf) unless running with the user's UID.
Therefore, we need to call it again with LOGIN_SETUMASK after changing UID.

PR: bin/176740
Submitted by: John Marshall <john.marshall@riverwillow.com.au>
MFC after: 1 week

11 years agoFix incorrect assertion that caused panic when periodic-only timers used.
Alexander Motin [Wed, 13 Mar 2013 06:42:01 +0000 (06:42 +0000)]
Fix incorrect assertion that caused panic when periodic-only timers used.

11 years agoDisable TX IP header checksum offloading on RL_HWREV_8168CP. The
Pyun YongHyeon [Wed, 13 Mar 2013 02:11:45 +0000 (02:11 +0000)]
Disable TX IP header checksum offloading on RL_HWREV_8168CP. The
controller generates wrong checksummed frame if the IP packet has
IP options.

Submitted by: Alexander Bluhm via brad@openbsd

11 years agor241438 broke IPMI access on Sun Fire X2200 M2(BCM5715).
Pyun YongHyeon [Wed, 13 Mar 2013 01:40:01 +0000 (01:40 +0000)]
r241438 broke IPMI access on Sun Fire X2200 M2(BCM5715).
Fix the IPMI regression by sending BGE_FW_DRV_STATE_UNLOAD to
ASF/IPMI firmware in driver attach phase.  Sending heartheat to
ASF/IPMI is enabled only after upping interface so
setting driver state to BGE_FW_DRV_STATE_START in attach phase
broke IPMI access.
While I'm here, add NVRAM arbitration lock before performing
controller reset. ASF/IPMI firmware may be able to access the NVRAM
while controller reset is in progress.  Without the arbitration
lock before resetting the controller, ASF/IPMI may not initialize
properly.

Special thanks to Miroslav Lachman who provided full remote
debugging environments.

11 years agoRemove pav from portmgr whom had also stepped down a few months ago.
Eitan Adler [Tue, 12 Mar 2013 23:14:18 +0000 (23:14 +0000)]
Remove pav from portmgr whom had also stepped down a few months ago.

Thank you for your years of service.

Reported by: rene

11 years agoWelcome Bryan to the team.
Eitan Adler [Tue, 12 Mar 2013 23:07:34 +0000 (23:07 +0000)]
Welcome Bryan to the team.

11 years agoUpdate vendor/illumos/dist and vendor-sys/illumos/dist
Martin Matuska [Tue, 12 Mar 2013 21:46:29 +0000 (21:46 +0000)]
Update vendor/illumos/dist and vendor-sys/illumos/dist
to illumos-gate 13980:d7059eb1884c

Illumos ZFS issues:
  3598 want to dtrace when errors are generated in zfs

11 years agoUpdate vendor-sys/illumos/dist to illumos-gate 13979:b01a4832cdf9
Martin Matuska [Tue, 12 Mar 2013 21:42:55 +0000 (21:42 +0000)]
Update vendor-sys/illumos/dist to illumos-gate 13979:b01a4832cdf9

Illumos ZFS issues:
  3517 importing pool with autoreplace=on and "hole" vdevs crashes syseventd

11 years agoRevert r246917, as it is causing incorrect behaviour as reported on
Mark Johnston [Tue, 12 Mar 2013 19:18:10 +0000 (19:18 +0000)]
Revert r246917, as it is causing incorrect behaviour as reported on
freebsd-current.

PR: bin/175213
Approved by: emaste (co-mentor)

11 years agoBump __FreeBSD_version after r248084, breaking VM KPI to introduce
Attilio Rao [Tue, 12 Mar 2013 14:30:36 +0000 (14:30 +0000)]
Bump __FreeBSD_version after r248084, breaking VM KPI to introduce
read/write lockers.

Sponsored by: EMC / Isilon storage division
Requested by: flo

11 years agoRemove netncp cscope entry missed in r248097
Bryan Venteicher [Tue, 12 Mar 2013 14:21:52 +0000 (14:21 +0000)]
Remove netncp cscope entry missed in r248097

Reviewed by: attilio

11 years agoFunctions m_getm2() and m_get2() have different order of arguments,
Gleb Smirnoff [Tue, 12 Mar 2013 13:42:47 +0000 (13:42 +0000)]
Functions m_getm2() and m_get2() have different order of arguments,
and that can drive someone crazy. While m_get2() is young and not
documented yet, change its order of arguments to match m_getm2().

Sorry for churn, but better now than later.

11 years agoUpdate Ruslan's last name per request.
Eitan Adler [Tue, 12 Mar 2013 13:03:31 +0000 (13:03 +0000)]
Update Ruslan's last name per request.

Submitted by: rm

11 years agoRemove fortunes-o from the base system. Debating what does or does not
John Baldwin [Tue, 12 Mar 2013 12:35:02 +0000 (12:35 +0000)]
Remove fortunes-o from the base system.  Debating what does or does not
belong in this file is not a useful exercise or conducive to producing a
high quality advanced operating system.

While here, simplify the make rules to autocompute BLDS and FILES from a
single DB variable.

Approved by: core
MFC after: 1 week

11 years ago- Use m_get2() instead of nfsm_reqhead().
Gleb Smirnoff [Tue, 12 Mar 2013 12:23:47 +0000 (12:23 +0000)]
- Use m_get2() instead of nfsm_reqhead().
- Use m_get(), m_getcl() instead of historic macros.

Sponsored by: Nginx, Inc.

11 years agoSimplify vm_page_is_valid().
Attilio Rao [Tue, 12 Mar 2013 12:20:49 +0000 (12:20 +0000)]
Simplify vm_page_is_valid().

Sponsored by: EMC / Isilon storage division
Reviewed by: alc

11 years agoUse m_get2() to get mbuf of appropriate size.
Gleb Smirnoff [Tue, 12 Mar 2013 12:19:23 +0000 (12:19 +0000)]
Use m_get2() to get mbuf of appropriate size.

Sponsored by: Nginx, Inc.

11 years agoUse m_get(), m_gethdr() and m_getcl() instead of historic macros.
Gleb Smirnoff [Tue, 12 Mar 2013 12:17:19 +0000 (12:17 +0000)]
Use m_get(), m_gethdr() and m_getcl() instead of historic macros.

Sponsored by: Nginx, Inc.

11 years agoIn kern_sendfile() use m_extadd() instead of MEXTADD() macro, supplying
Gleb Smirnoff [Tue, 12 Mar 2013 12:15:24 +0000 (12:15 +0000)]
In kern_sendfile() use m_extadd() instead of MEXTADD() macro, supplying
appropriate wait argument and checking return value. Before this change
m_extadd() could fail, and kern_sendfile() ignored that.

Sponsored by: Nginx, Inc.

11 years agoThe m_extadd() can fail due to memory allocation failure, thus:
Gleb Smirnoff [Tue, 12 Mar 2013 12:12:16 +0000 (12:12 +0000)]
The m_extadd() can fail due to memory allocation failure, thus:
- Make it return int, not void.
- Add wait parameter.
- Update MEXTADD() macro appropriately, defaults to M_NOWAIT, as
  before this change.

Sponsored by: Nginx, Inc.