]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
11 years agoUse proper malloc type for ioctls white-list.
pjd [Thu, 23 May 2013 21:07:26 +0000 (21:07 +0000)]
Use proper malloc type for ioctls white-list.

Reported by: pho
Tested by: pho

11 years agoFix target selection logic, which did not comply with the man page.
se [Thu, 23 May 2013 20:57:20 +0000 (20:57 +0000)]
Fix target selection logic, which did not comply with the man page.

Instead of using the file with the least order of path name components,
shortest filename and finally the shortest basename (with the search
stopping as soon as one of these conditions is true), the first filename
checked was used as the reference, and another filename was only selected
if all of the above comparisons are in favour of the latter file.

This was wrong, because filenames with path less components were only
considered, if both of the other conditions were true as well. In fact,
the first filename to be checked had good chances to be selected in the
end, since it only needed to be better with regard to any one of the
three criteria ...

Reviewed by: delphij@freebsd.org

11 years agoAdd support for netgroup, based on patch in the PR but made consistent
ghelmer [Thu, 23 May 2013 20:52:30 +0000 (20:52 +0000)]
Add support for netgroup, based on patch in the PR but made consistent
with existing style.

PR: bin/132692

11 years agoInclude descriptions of the flags and fields printed when dumping the
markj [Thu, 23 May 2013 19:50:36 +0000 (19:50 +0000)]
Include descriptions of the flags and fields printed when dumping the
IPv6 prefix list.

Reviewed by: hrs
MFC after: 1 week

11 years agoChange the copyright notice to a standard BSD 2-clause license and assign
marcel [Thu, 23 May 2013 19:47:37 +0000 (19:47 +0000)]
Change the copyright notice to a standard BSD 2-clause license and assign
ownership to the FreeBSD foundation for the years this file has been in
the FreeBSD repository.

This file was originally created by Juniper as part of upgrading to FreeBSD
4.10 (which had no MIPS support) and held functions found on other machines
It grew actual functionality over time. The functionaliy was copied from
other architectures and ported to MIPS on a as-needed basis.

Approved by: Mark Baushke (Juniper IP)
Approved by: Megan Sugiyama (Juniper legal)
Pointed out by: jmallett@
Requested by: core (jhb@)

11 years agoCorrect the description of the -a option: rtsol(d) -a will in fact send out
markj [Thu, 23 May 2013 19:47:35 +0000 (19:47 +0000)]
Correct the description of the -a option: rtsol(d) -a will in fact send out
router solicitations on multiple interfaces.

Reviewed by: hrs
MFC after: 1 week

11 years agoLet iconv build on -HEAD properly.
ed [Thu, 23 May 2013 18:07:01 +0000 (18:07 +0000)]
Let iconv build on -HEAD properly.

- Add NO_WMISSING_VARIABLE_DECLARATIONS where we use Yacc/Lex.
- Add variable declarations where possible.
- Add missing static keyword.

11 years agoFix typo in the definition of the TWS_DATA_CCB.
kib [Thu, 23 May 2013 16:37:43 +0000 (16:37 +0000)]
Fix typo in the definition of the TWS_DATA_CCB.

Submitted by: Andreas Turriff <maillist@turriff.net>

11 years agoRework and organize pmap_enter_locked() function.
gber [Thu, 23 May 2013 12:24:46 +0000 (12:24 +0000)]
Rework and organize pmap_enter_locked() function.

pmap_enter_locked() implementation was very ambiguous and confusing.
Rearrange it so that each part of the mapping creation is separated.
Avoid walking through the redundant conditions.
Extract vector_page specific PTE setup from normal PTE setting.

Submitted by:   Zbigniew Bodek <zbb@semihalf.com>
Sponsored by:   The FreeBSD Foundation, Semihalf

11 years agoStop using PVF_MOD, PVF_REF & PVF_EXEC flags in pv_entry, use PTE.
gber [Thu, 23 May 2013 12:23:18 +0000 (12:23 +0000)]
Stop using PVF_MOD, PVF_REF & PVF_EXEC flags in pv_entry, use PTE.

Using PVF_MOD, PVF_REF and PVF_EXEC is redundant as we can get the proper
info from PTE bits.
When the mapping is marked as executable and has been referenced we assume
that it has been executed. Similarly, when the mapping is set to be writable
and is referenced, it must have been due to write access to it.
PVF_MOD and PVF_REF flags are kept just for pmap_clearbit() usage,
to pass the information on which bit should be cleared.

Submitted by:   Zbigniew Bodek <zbb@semihalf.com>
Sponsored by:   The FreeBSD Foundation, Semihalf

11 years agoImprove, optimize and clean-up ARMv6/v7 memory management related code.
gber [Thu, 23 May 2013 12:15:23 +0000 (12:15 +0000)]
Improve, optimize and clean-up ARMv6/v7 memory management related code.

Use pmap_find_pv if needed instead of multiplying its code throughout
pmap-v6.

Avoid possible NULL pointer dereference in pmap_enter_locked()
When trying to get m->md.pv_memattr, make sure that m != NULL,
in particular that vector_page is set to be NULL.

Do not set PGA_REFERENCED flag in pmap_enter_pv().
On ARM any new page reference will result in either entering the new
mapping by calling pmap_enter, etc. or fixing-up the existing mapping in
pmap_fault_fixup().
Therefore we set PGA_REFERENCED flag in the earlier mentioned cases and
setting it later in pmap_enter_pv() is just waste of cycles.

Delete unused pm_pdir pointer from the pmap structure.

Rearrange brackets in the fault cause detection in trap.c
Place the brackets correctly in order to see course of the conditions
instantaneously.

Unify naming in pmap-v6.c and improve style
Use naming common for whole pmap and compatible with other pmaps,
improve style where possible:
pm   -> pmap
pg   -> m
opg  -> om
*pt  -> *ptep
*pte -> *ptep
*pde -> *pdep

Submitted by:   Zbigniew Bodek <zbb@semihalf.com>
Sponsored by:   The FreeBSD Foundation, Semihalf

11 years agoSwitch to AP[2:1] access permissions model. Store "referenced"
gber [Thu, 23 May 2013 12:07:41 +0000 (12:07 +0000)]
Switch to AP[2:1] access permissions model. Store "referenced"
bit in PTE.

Enable Access Flag in CPU control. With AF enabled each valid mapping
needs to have referenced bit in PTE set in order to be able to cache
it in the TLB.

AP[0] bit is to be used as reference flag.
All access permissions are encoded by AP[2:1] wherein AP[1] is in fact
"user enable" and AP[2](APX) is "write disable".

All mappings are always set to be valid. Reference emulation is performed
by setting/clearing reference flag in PTE.

md.pvh_attrs are no longer necessary however pv_flags are still being used
for now.

Marking vm_page as "dirty" or "referenced" is being performed on:
- page or flag fault servicing in pmap_fault_fixup(), basing on the fault
  type
- vm_fault servicing in pmap_enter() according to the desired protections
  and faulty access type
Redundant page marking has been removed as on ARM we know exactly when the
particular page is referenced or is going to be written.

Submitted by: Zbigniew Bodek <zbb@semihalf.com>
Sponsored by: The FreeBSD Foundation, Semihalf

11 years agoWork around build breakages with GCC 4.2.
jkim [Thu, 23 May 2013 05:42:35 +0000 (05:42 +0000)]
Work around build breakages with GCC 4.2.

Reported by: tinderbox

11 years agoDon't depend on the touch binary being present.
ed [Wed, 22 May 2013 22:34:48 +0000 (22:34 +0000)]
Don't depend on the touch binary being present.

We can simply create an empty file by doing a no-op and redirecting stdout.

11 years agoFix loss of the emulated keyboard on Xen PV HVM domains.
gibbs [Wed, 22 May 2013 19:22:44 +0000 (19:22 +0000)]
Fix loss of the emulated keyboard on Xen PV HVM domains.

xen/xenbus/xenbusb.c:
    In xenbusb_probe_children(), do not modify the XenBus state of
    devices for which we have no PV driver support. An emulated device
    we do support may share this backend.  Hide the node from XenBus
    instead.

    This prevents closing the vkbd device, which Qemu's emulated keyboard
    device is using as the source for keyboard events.

    Tested with qemu-xen-traditional, qemu-xen and qemu stubdomains, all
    working as expected.

Submitted by: Roger Pau Monne <roger.pau@citrix.com>
Reviewed by: gibbs
MFC after: 1 week

11 years agoDon't mess with /etc/localtime if it is a symlink.
peter [Wed, 22 May 2013 19:00:05 +0000 (19:00 +0000)]
Don't mess with /etc/localtime if it is a symlink.

11 years agoImprove compatibility with old flex and fix build with GCC.
jkim [Wed, 22 May 2013 17:47:45 +0000 (17:47 +0000)]
Improve compatibility with old flex and fix build with GCC.

11 years agoCorrect panic on detach of Xen PV network interfaces.
gibbs [Wed, 22 May 2013 17:13:03 +0000 (17:13 +0000)]
Correct panic on detach of Xen PV network interfaces.

dev/xen/netfront:
    In netif_free(), properly stop the interface and drain any pending
    timers prior to disconnecting from the backend device.

    Remove all media and detach our interface object from the system
    prior to deleting it.

PR: kern/176471
Submitted by: Roger Pau Monne <roger.pau@citrix.com>
Reviewed by: gibbs
MFC after: 1 week

11 years agoRemove reference to removed !MPSAFE filesystem support
emaste [Wed, 22 May 2013 16:33:28 +0000 (16:33 +0000)]
Remove reference to removed !MPSAFE filesystem support

11 years agoIncrease the (arbitrary) limit for the number of packets per tick
luigi [Wed, 22 May 2013 16:32:18 +0000 (16:32 +0000)]
Increase the (arbitrary) limit for the number of packets per tick
from 1k to 20k The previous value was good 10 years ago, but not
anymore now.

More importantly, lots of good surprises:
polling is incredibly effective under virtualization, and not only
prevents livelock but also saves most of the VM exit overhead in
receive mode.

Using polling, a FreeBSD instance under qemu-kvm remains perfectly
responsive even when bombed with 10 Mpps over an emulated e1000,
and happily processes 1.7 Mpps through ipfw.

Note that some incompatibilities still remain: e.g. polling is not
(yet) compatible with netmap, and seems to freeze the guest when
kern.polling.idle_poll=1

MFC after: 3 days

11 years agoAcquire read lock on the src object for vm_fault_copy_entry().
attilio [Wed, 22 May 2013 15:11:00 +0000 (15:11 +0000)]
Acquire read lock on the src object for vm_fault_copy_entry().

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

11 years agoFix a copy-and-paste typo.
delphij [Wed, 22 May 2013 05:21:19 +0000 (05:21 +0000)]
Fix a copy-and-paste typo.

11 years agoRegenerate with manual fixup for WITH_LDNS_UTILS inheriting WITHOUT_BIND_UTILS.
delphij [Wed, 22 May 2013 05:16:07 +0000 (05:16 +0000)]
Regenerate with manual fixup for WITH_LDNS_UTILS inheriting WITHOUT_BIND_UTILS.

11 years agoProperly spell sentinel (missed in 250891)
mckusick [Wed, 22 May 2013 05:07:55 +0000 (05:07 +0000)]
Properly spell sentinel (missed in 250891)
No functional changes.

Spotted by:  Navdeep Parhar and Alexey Dokuchaev
MFC after:   2 weeks

11 years agoFix NULL-dereference kernel panic in case of mps_attach() failure.
mav [Wed, 22 May 2013 02:15:07 +0000 (02:15 +0000)]
Fix NULL-dereference kernel panic in case of mps_attach() failure.

MFC after: 1 week

11 years agoImplement beacon event debugging in athalq.
adrian [Wed, 22 May 2013 01:03:41 +0000 (01:03 +0000)]
Implement beacon event debugging in athalq.

11 years agoAdd missing buffer releases (brelse) after bread calls that return
mckusick [Wed, 22 May 2013 00:57:22 +0000 (00:57 +0000)]
Add missing buffer releases (brelse) after bread calls that return
an error. One could argue that returning a buffer even when it is
not valid is incorrect, but bread has always returned a buffer
valid or not.

Reviewed by: kib
MFC after:   2 weeks

11 years agoAdd missing 28th element to softdep types name array.
mckusick [Wed, 22 May 2013 00:48:24 +0000 (00:48 +0000)]
Add missing 28th element to softdep types name array.

Found by:    Coverity Scan, CID 1007621
Reviewed by: kib
MFC after:   2 weeks

11 years agoNull a pointer after it is freed so that when it is returned
mckusick [Wed, 22 May 2013 00:40:26 +0000 (00:40 +0000)]
Null a pointer after it is freed so that when it is returned
the return value is NULL. Based on the returned flags, the
return value should never be inspected in the case where NULL
is returned, but it is good coding practice not to return a
pointer to freed memory.

Found by:    Coverity Scan, CID 1006096
Reviewed by: kib
MFC after:   2 weeks

11 years agoRemove a bogus check for a NULL buffer pointer.
mckusick [Wed, 22 May 2013 00:30:34 +0000 (00:30 +0000)]
Remove a bogus check for a NULL buffer pointer.
Add a KASSERT that it is not NULL.

Found by:    Coverity Scan, CID 1009114
Reviewed by: kib
MFC after:   2 weeks

11 years agoProperly spell sentinel (not sintenel or sentinal).
mckusick [Wed, 22 May 2013 00:17:50 +0000 (00:17 +0000)]
Properly spell sentinel (not sintenel or sentinal).
No functional changes.

Spotted by:  kib
MFC after:   2 weeks

11 years agopassing fd over unix socket: fix a corner case where caller
mjg [Tue, 21 May 2013 21:58:00 +0000 (21:58 +0000)]
passing fd over unix socket: fix a corner case where caller
wants to pass no descriptors.

Previously the kernel would leak memory and try to free a potentially
arbitrary pointer.

Reviewed by: pjd

11 years agoAdd proper prerequisites for even two more headers.
ed [Tue, 21 May 2013 21:50:11 +0000 (21:50 +0000)]
Add proper prerequisites for even two more headers.

Spotted by:   http://hacks.owlfolio.org/header-survey/

11 years agoUpdate manpages for r250887.
ed [Tue, 21 May 2013 21:39:18 +0000 (21:39 +0000)]
Update manpages for r250887.

Remove the lists of unneeded header files.

Requested by: eadler

11 years agoAllow certain headers to be included more easily.
ed [Tue, 21 May 2013 21:20:10 +0000 (21:20 +0000)]
Allow certain headers to be included more easily.

Spotted by: http://hacks.owlfolio.org/header-survey/

11 years agovm_object locking is not needed there as pages are already wired.
attilio [Tue, 21 May 2013 20:54:03 +0000 (20:54 +0000)]
vm_object locking is not needed there as pages are already wired.

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

11 years agoo Relax locking assertions for vm_page_find_least()
attilio [Tue, 21 May 2013 20:38:19 +0000 (20:38 +0000)]
o Relax locking assertions for vm_page_find_least()
o Relax locking assertions for pmap_enter_object() and add them also
  to architectures that currently don't have any
o Introduce VM_OBJECT_LOCK_DOWNGRADE() which is basically a downgrade
  operation on the per-object rwlock
o Use all the mechanisms above to make vm_map_pmap_enter() to work
  mostl of the times only with readlocks.

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

11 years agoAdd <uchar.h>.
ed [Tue, 21 May 2013 19:59:37 +0000 (19:59 +0000)]
Add <uchar.h>.

The <uchar.h> header, part of C11, adds a small number of utility
functions for 16/32-bit "universal" characters, which may or may not be
UTF-16/32. As our wchar_t is already ISO 10646, simply add light-weight
wrappers around wcrtomb() and mbrtowc().

While there, also add (non-yet-standard) _l functions, similar to the
ones we already have for the other locale-dependent functions.

Reviewed by: theraven

11 years agoAvoid signed overflow in error handling code.
eadler [Tue, 21 May 2013 19:56:03 +0000 (19:56 +0000)]
Avoid signed overflow in error handling code.

Reviewed by: cperciva, bjk

11 years agoConnect flex 2.5.37 to the build and bump __FreeBSD_version.
jkim [Tue, 21 May 2013 19:32:35 +0000 (19:32 +0000)]
Connect flex 2.5.37 to the build and bump __FreeBSD_version.

11 years agoEnable GNU m4 compatibility mode.
jkim [Tue, 21 May 2013 19:23:49 +0000 (19:23 +0000)]
Enable GNU m4 compatibility mode.

11 years agoAllow YY_NO_UNPUT to disable unput() for backward compatibility.
jkim [Tue, 21 May 2013 19:22:42 +0000 (19:22 +0000)]
Allow YY_NO_UNPUT to disable unput() for backward compatibility.

11 years agoDefine yy_current_buffer for backward compatibility.
jkim [Tue, 21 May 2013 19:21:26 +0000 (19:21 +0000)]
Define yy_current_buffer for backward compatibility.

11 years agoDo not use log10(3) to get rid of libm dependency. It is really not useful.
jkim [Tue, 21 May 2013 19:20:03 +0000 (19:20 +0000)]
Do not use log10(3) to get rid of libm dependency.  It is really not useful.

11 years agoReduce compiler warnings.
jkim [Tue, 21 May 2013 19:17:02 +0000 (19:17 +0000)]
Reduce compiler warnings.

11 years agoApply still relevant local changes.
jkim [Tue, 21 May 2013 19:11:11 +0000 (19:11 +0000)]
Apply still relevant local changes.

r124183: Work around a `label defined but not used' warning.
r179549: De-register declarations.
r179657: De-register declarations in non-dot-c files.
r181269: Mark yy_fatal_error() as __dead2.
r228992: Spelling fixes.
r240518: Correct double "the the".

11 years agoAdd flex 2.5.37 from flex.sourceforge.net to contrib.
jkim [Tue, 21 May 2013 19:09:30 +0000 (19:09 +0000)]
Add flex 2.5.37 from flex.sourceforge.net to contrib.

11 years agoDisable keyword expansion.
jkim [Tue, 21 May 2013 18:52:37 +0000 (18:52 +0000)]
Disable keyword expansion.

11 years agoRemove an extra semicolon from the DOT language output.
jh [Tue, 21 May 2013 18:40:54 +0000 (18:40 +0000)]
Remove an extra semicolon from the DOT language output.

PR: kern/178540
Submitted by: Trond Endrestol
MFC after: 1 week

11 years agoMention the switch to bmake by default.
sjg [Tue, 21 May 2013 18:38:09 +0000 (18:38 +0000)]
Mention the switch to bmake by default.

Reviewed by: obrien

11 years agoImplement a separate hardware queue threshold for aggregate and non-aggr
adrian [Tue, 21 May 2013 18:13:57 +0000 (18:13 +0000)]
Implement a separate hardware queue threshold for aggregate and non-aggr
traffic.

When transmitting non-aggregate traffic, we need to keep the hardware
busy whilst transmitting or small bursts in txdone/tx latency will
kill us.

This restores non-aggregate iperf performance, especially when doing
TDMA.

Tested:

* AR5416<->AR5416, TDMA
* AR5416 STA <-> AR9280 AP

11 years agoEnable the use of TDMA on an 802.11n channel (with aggregation disabled,
adrian [Tue, 21 May 2013 18:02:54 +0000 (18:02 +0000)]
Enable the use of TDMA on an 802.11n channel (with aggregation disabled,
of course.)

There's a few things that needed to happen:

* In case someone decides to set the beacon transmission rate to be
  at an MCS rate, use the MCS-aware version of the duration calculation
  to figure out how long the received beacon frame was.

* If TxOP enforcing is available on the hardware and we're doing TDMA,
  enable it after a reset and set the TDMA guard interval to zero.
  This seems to behave fine.

TODO:

* Although I haven't yet seen packet loss, the PHY errors that would be
  triggered (specifically Transmit-Override-Receive) aren't enabled
  by the 11n HAL.  I'll have to do some work to enable these PHY errors
  for debugging.

What broke:

* My recent changes to the TX queue handling has resulted in the driver
  not keeping the hardware queue properly filled when doing non-aggregate
  traffic.  I have a patch to commit soon which fixes this situation
  (albeit by reminding me about how my ath driver locking isn't working
  out, sigh.)

  So if you want to test this without updating to the next set of patches
  that I commit, just bump the sysctl dev.ath.X.hwq_limit from 2 to 32.

Tested:

* AR5416 <-> AR5416, with ampdu disabled, HT40, 5GHz, MCS12+Short-GI.
  I saw 30mbit/sec in both directions using a bidirectional UDP test.

11 years agoFix the PowerPC Book-E register definitions used by the remote GDB
marcel [Tue, 21 May 2013 18:00:47 +0000 (18:00 +0000)]
Fix the PowerPC Book-E register definitions used by the remote GDB
protocol.

Obtained from: Juniper Networks, Inc.

11 years agoAdd a makefle that recurses into the right architecture-specific
marcel [Tue, 21 May 2013 17:47:53 +0000 (17:47 +0000)]
Add a makefle that recurses into the right architecture-specific
sub-directory. This to allow simpler logic outside of the csu
directory.

Obtained from: Juniper Networks, Inc.

11 years agoDon't look for headers outside of the source or object directories. In
marcel [Tue, 21 May 2013 17:30:27 +0000 (17:30 +0000)]
Don't look for headers outside of the source or object directories. In
particular, don't use DESTDIR. Such creates an unnecessary dependency
on the build machine.

Obtained from:  Juniper Networks, Inc.

11 years agoDon't look for headers outside of the source or object directories. In
marcel [Tue, 21 May 2013 17:28:19 +0000 (17:28 +0000)]
Don't look for headers outside of the source or object directories. In
particular, don't use DESTDIR. Such creates an unnecessary dependency
on the build machine.

Obtained from: Juniper Networks, Inc.

11 years agoRestore the ability to build on systems with 32-bit compat when
brooks [Tue, 21 May 2013 16:58:23 +0000 (16:58 +0000)]
Restore the ability to build on systems with 32-bit compat when
the system compiler is not clang.  clang and gcc appear to differ
signficantly in their interpretation of -isystem and --sysroot.  Further
work is likely required to support an external gcc.

Reported by: andreast, fidaj@ukr.net, sergey.dyatko@gmail.com

11 years agoFix build break - the SetCapability calls return HAL_BOOL,
adrian [Tue, 21 May 2013 14:28:05 +0000 (14:28 +0000)]
Fix build break - the SetCapability calls return HAL_BOOL,
not HAL_STATUS.

11 years agoRegenerate.
kib [Tue, 21 May 2013 11:41:08 +0000 (11:41 +0000)]
Regenerate.

11 years agoFix the wait6(2) on 32bit architectures and for the compat32, by using
kib [Tue, 21 May 2013 11:40:16 +0000 (11:40 +0000)]
Fix the wait6(2) on 32bit architectures and for the compat32, by using
the right type for the argument in syscalls.master.  Also fix the
posix_fallocate(2) and posix_fadvise(2) compat32 syscalls on the
architectures which require padding of the 64bit argument.

Noted and reviewed by: jhb
Pointy hat to: kib
MFC after: 1 week

11 years agoDo not leak the NULLV_NOUNLOCK flag from the nullfs_unlink_lowervp(),
kib [Tue, 21 May 2013 11:31:56 +0000 (11:31 +0000)]
Do not leak the NULLV_NOUNLOCK flag from the nullfs_unlink_lowervp(),
for the case when the nullfs vnode is not reclaimed.  Otherwise, later
reclamation would not unlock the lower vnode.

Reported by: antoine
Tested by: pho
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

11 years agoFix the hardware watchpoints on SMP amd64. Load the updated %dr
kib [Tue, 21 May 2013 11:24:32 +0000 (11:24 +0000)]
Fix the hardware watchpoints on SMP amd64.  Load the updated %dr
registers also on other CPUs, besides the CPU which happens to execute
the ddb.  The debugging registers are stored in the pcpu area,
together with the command which is executed by the IPI stop handler
upon resume.

Reviewed by: jhb
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

11 years agoAdd amd64-specific ddb command 'show phys2dmap', which calculates the
kib [Tue, 21 May 2013 11:07:12 +0000 (11:07 +0000)]
Add amd64-specific ddb command 'show phys2dmap', which calculates the
address in the direct map corresponding to the given physical address.

Reviewed by: jhb
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

11 years agoAdd ddb command 'show pginfo' which provides useful information about
kib [Tue, 21 May 2013 11:04:00 +0000 (11:04 +0000)]
Add ddb command 'show pginfo' which provides useful information about
a vm page, denoted either by an address of the struct vm_page, or, if
the '/p' modifier is specified, by a physical address of the
corresponding frame.

Reviewed by: jhb
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

11 years agoAdd new USB quirk.
hselasky [Tue, 21 May 2013 06:13:38 +0000 (06:13 +0000)]
Add new USB quirk.

MFC after: 1 week
PR: usb/178771

11 years agoExtend the TXOP enforce capability to support checking whether it's
adrian [Tue, 21 May 2013 05:51:49 +0000 (05:51 +0000)]
Extend the TXOP enforce capability to support checking whether it's
supported.

11 years agoAdd basic support for FDT to i386 & amd64. This change includes:
marcel [Tue, 21 May 2013 03:05:49 +0000 (03:05 +0000)]
Add basic support for FDT to i386 & amd64. This change includes:
1.  Common headers for fdt.h and ofw_machdep.h under x86/include
    with indirections under i386/include and amd64/include.
2.  New modinfo for loader provided FDT blob.
3.  Common x86_init_fdt() called from hammer_time() on amd64 and
    init386() on i386.
4.  Split-off FDT specific low-level console functions from FDT
    bus methods for the uart(4) driver. The low-level console
    logic has been moved to uart_cpu_fdt.c and is used for arm,
    mips & powerpc only. The FDT bus methods are shared across
    all architectures.
5.  Add dev/fdt/fdt_x86.c to hold the fdt_fixup_table[] and the
    fdt_pic_table[] arrays. Both are empty right now.

FDT addresses are I/O ports on x86. Since the core FDT code does
not handle different address spaces, adding support for both I/O
ports and memory addresses requires some thought and discussion.
It may be better to use a compile-time option that controls this.

Obtained from: Juniper Networks, Inc.

11 years agoBMAKE is now being built by default.
delphij [Tue, 21 May 2013 00:41:49 +0000 (00:41 +0000)]
BMAKE is now being built by default.

11 years agoMerge ACPICA 20130517.
jkim [Mon, 20 May 2013 23:52:49 +0000 (23:52 +0000)]
Merge ACPICA 20130517.

11 years agoSync with upstream version (20130520) that includes same fixes made last week.
sjg [Mon, 20 May 2013 22:51:11 +0000 (22:51 +0000)]
Sync with upstream version (20130520) that includes same fixes made last week.

11 years agoTag bmake-20130520
sjg [Mon, 20 May 2013 22:37:10 +0000 (22:37 +0000)]
Tag bmake-20130520

11 years agoImport bmake-20130520 to keep us in sync.
sjg [Mon, 20 May 2013 22:35:32 +0000 (22:35 +0000)]
Import bmake-20130520 to keep us in sync.

11 years ago- Prefer ACPI_COMPARE_NAME(a, b) macro over strncmp(a, b, ACPI_NAME_SIZE).
jkim [Mon, 20 May 2013 22:18:18 +0000 (22:18 +0000)]
- Prefer ACPI_COMPARE_NAME(a, b) macro over strncmp(a, b, ACPI_NAME_SIZE).
- Make sure the predefined name is a string type.
- Return slightly more useful errors.

11 years agoFix white spaces.
jkim [Mon, 20 May 2013 22:10:01 +0000 (22:10 +0000)]
Fix white spaces.

11 years agoFix distributekernel in the non NO_ROOT case.
brooks [Mon, 20 May 2013 21:16:38 +0000 (21:16 +0000)]
Fix distributekernel in the non NO_ROOT case.

PR: conf/178775
Submitted by: Garrett Cooper <yaneurabeya@gmail.com>

11 years agoUpdate the setfib man page to reflect recent changes.
julian [Mon, 20 May 2013 20:47:40 +0000 (20:47 +0000)]
Update the setfib man page to reflect recent changes.

11 years agoCleanups and markup improvements suggested by trociny and joel.
brooks [Mon, 20 May 2013 20:32:58 +0000 (20:32 +0000)]
Cleanups and markup improvements suggested by trociny and joel.

11 years agoRemove accidentally included line..
julian [Mon, 20 May 2013 20:14:12 +0000 (20:14 +0000)]
Remove accidentally included line..
No effect as it wasn't used but was a) wrong   b) clutter

11 years agoSpell extensions correctly.
brooks [Mon, 20 May 2013 19:41:34 +0000 (19:41 +0000)]
Spell extensions correctly.

Submitted by: dim

11 years agopopen(): Add 'e' mode character to set close-on-exec on the new fd.
jilles [Mon, 20 May 2013 17:31:18 +0000 (17:31 +0000)]
popen(): Add 'e' mode character to set close-on-exec on the new fd.

If 'e' is used, the kernel must support the recently added pipe2() system
call.

The use of pipe2() with O_CLOEXEC also fixes race conditions between
concurrent popen() calls from different threads, even if the close-on-exec
flag on the fd of the returned FILE is later cleared (because popen() closes
all file descriptors from earlier popen() calls in the child process).
Therefore, this approach should be used in all cases when pipe2() can be
assumed present.

The old version of popen() rejects "re" and "we" but treats "r+e" like "r+".

11 years agoNetBSD 6.1 added.
maxim [Mon, 20 May 2013 15:11:30 +0000 (15:11 +0000)]
NetBSD 6.1 added.

11 years agoAdd a test program for popen().
jilles [Mon, 20 May 2013 13:05:51 +0000 (13:05 +0000)]
Add a test program for popen().

11 years agoMake the HT rate duration calculation work for MCS rates > 15.
adrian [Mon, 20 May 2013 07:10:43 +0000 (07:10 +0000)]
Make the HT rate duration calculation work for MCS rates > 15.

11 years agogrep: change some int types.
pfg [Mon, 20 May 2013 03:15:25 +0000 (03:15 +0000)]
grep: change some int types.

Change several int variables to size_t, ssize_t, or ptrdiff_t.
This should fix the bug described in CVE-2012-5667 when an input
line is so long that its length cannot be stored in an int
variable.

This is based on NetBSD's revision which says:

This change to NetBSD's version of GNU grep 2.5.1 (licenced under
GPLv2) was made without direct reference to any code licenced
under GPLv3.

Obtained from: NetBSD
MFC after: 3 days

11 years agoRemove a block of code that was not intended to be part of the previous
markj [Mon, 20 May 2013 02:10:18 +0000 (02:10 +0000)]
Remove a block of code that was not intended to be part of the previous
revision.

X-MFC with: r250812

11 years agoFix vdc->Secondary_Element_Count metadata field access from 16 to 8 bit.
mav [Mon, 20 May 2013 00:33:54 +0000 (00:33 +0000)]
Fix vdc->Secondary_Element_Count metadata field access from 16 to 8 bit.
In some cases it could cause kernel panic during failed drive replacement.

Reported by: trasz
MFC after: 1 week

11 years agoStyle nits.
pjd [Sun, 19 May 2013 23:30:24 +0000 (23:30 +0000)]
Style nits.

11 years agoUse SDT_PROBE1() instead of SDT_PROBE().
pjd [Sun, 19 May 2013 23:29:22 +0000 (23:29 +0000)]
Use SDT_PROBE1() instead of SDT_PROBE().

11 years agoProtect SDT_PROBE() with do { } while (0) loop.
pjd [Sun, 19 May 2013 23:28:28 +0000 (23:28 +0000)]
Protect SDT_PROBE() with do { } while (0) loop.

11 years agoReally fix netmask address family this time.
melifaro [Sun, 19 May 2013 19:42:46 +0000 (19:42 +0000)]
Really fix netmask address family this time.

MFC with: r250813

11 years agoFinish r85740 : Make IPv6 netmask has address family set.
melifaro [Sun, 19 May 2013 19:19:01 +0000 (19:19 +0000)]
Finish r85740 : Make IPv6 netmask has address family set.
This pleases routing daemons like bird.

MFC after: 2 weeks

11 years agoRe-introduce another part of r249367. This commit fixes a register leak in
markj [Sun, 19 May 2013 17:14:36 +0000 (17:14 +0000)]
Re-introduce another part of r249367. This commit fixes a register leak in
dt_cg_ptrsize() and generally cleans up some of the error handling around
register allocation.

This change corresponds to part of illumos-gate commit e5803b76927480:
  3025 register leak in D code generation

Reviewed by: pfg
Obtained from: illumos
MFC after: 1 month

11 years agoAutomate import dance
sjg [Sun, 19 May 2013 16:45:17 +0000 (16:45 +0000)]
Automate import dance

11 years agoAdd a comment explaining why stack_capture is empty for EABI and clang.
andrew [Sun, 19 May 2013 16:25:09 +0000 (16:25 +0000)]
Add a comment explaining why stack_capture is empty for EABI and clang.

While here add a comment pointing out that, while r11 is not the frame
pointer on EABI as there is no frame pointer, it's value is unused so is
safe.

11 years agoInitialize the fibnum for outgoing packets to 0. This avoids
tuexen [Sun, 19 May 2013 16:06:43 +0000 (16:06 +0000)]
Initialize the fibnum for outgoing packets to 0. This avoids
crashing due to the usage of uninitialized fibnum.
This bugs became visiable after
http://svnweb.freebsd.org/changeset/base/250700

MFC after: 2 weeks

11 years agoRemove lint case for _Thread_local.
ed [Sun, 19 May 2013 07:44:01 +0000 (07:44 +0000)]
Remove lint case for _Thread_local.

I added this block, knowing that lint does not support _Thread_local.
When linting, we could argue that we don't care about TLS (yet). It
seems, however, that external pieces of software also sometimes do a
-Dlint, regex the output and compile it again.

Reported by: swills

11 years agoFix build after doc/projects/xml-tools integration.
hrs [Sun, 19 May 2013 05:49:21 +0000 (05:49 +0000)]
Fix build after doc/projects/xml-tools integration.

11 years agoRefine the "nojail" rc keyword, adding "nojailvnet" for files that don't
jamie [Sun, 19 May 2013 04:10:34 +0000 (04:10 +0000)]
Refine the "nojail" rc keyword, adding "nojailvnet" for files that don't
apply to most jails but do apply to vnet jails.  This includes adding
a new sysctl "security.jail.vnet" to identify vnet jails.

PR: conf/149050
Submitted by: mdodd
MFC after: 3 days

11 years agoUpdate snd quirks for T520, T420, X220.
sbruno [Sun, 19 May 2013 01:45:29 +0000 (01:45 +0000)]
Update snd quirks for T520, T420, X220.

Group onboard mic and headphone mic jack together.  Creates association that
will switch between microphone inputs depending on the state of the headphone
jack being connected to a live mic.

Fixes onboard mic not working at all on T520.

Tested on T520, T420.
Suspect X220 needs this too, untested on.

MFC after: 1 month

11 years agoMore non-ATH_DEBUG build fixes.
adrian [Sun, 19 May 2013 01:33:17 +0000 (01:33 +0000)]
More non-ATH_DEBUG build fixes.