]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
9 years agoAdd the AArch64 llvm backend to the build to allow for early testing and
dim [Wed, 7 Jan 2015 19:06:27 +0000 (19:06 +0000)]
Add the AArch64 llvm backend to the build to allow for early testing and
to ease any rework of how clang is built to take arm64 in to account.

Submitted by: andrew
Reviewed by: andrew, emaste
Differential Revision: https://reviews.freebsd.org/D1446

9 years agoBump __FreeBSD_version to 1100053 reflecting the addition of a return value
rwatson [Wed, 7 Jan 2015 18:24:42 +0000 (18:24 +0000)]
Bump __FreeBSD_version to 1100053 reflecting the addition of a return value
to MCLGET().

Suggested by: jmg
Sponsored by: EMC / Isilon Storage Division

9 years agoUse M_SIZE() instead of hand-crafted (and mostly correct) NFSMSIZ() macro
rwatson [Wed, 7 Jan 2015 17:22:56 +0000 (17:22 +0000)]
Use M_SIZE() instead of hand-crafted (and mostly correct) NFSMSIZ() macro
in the NFS server; garbage collect now-unused NFSMSIZ() and M_HASCL()
macros.  Also garbage collect now-unused versions in headers for the
removed previous NFS client and server.

Reviewed by: rmacklem
Sponsored by: EMC / Isilon Storage Division

9 years agoReduce the maximum number of pins for the Rockchip RK3188, this driver
loos [Wed, 7 Jan 2015 16:55:55 +0000 (16:55 +0000)]
Reduce the maximum number of pins for the Rockchip RK3188, this driver
isn't supposed to manage all the GPIO pins in the system from a single
instance, instead it will attach to each one of the four available GPIO
controllers and only deal with one bank at time (32 pins per bank).

Rework part of the driver to take advantage of that, this simplify the
code a lot.

Also fix a bug in rk30_gpio_get_function() which wouldn't return the
correct values.

While here fix a typo in register name.

9 years agoFix the counter_u64_alloc arguement
brd [Wed, 7 Jan 2015 16:15:00 +0000 (16:15 +0000)]
Fix the counter_u64_alloc arguement

Approved by: glebius
MFC after: 2 weeks

9 years agoMove MALTA_COMMON to std.MALTA (as we have for XLP and SWARM).
bz [Wed, 7 Jan 2015 12:12:36 +0000 (12:12 +0000)]
Move MALTA_COMMON to std.MALTA (as we have for XLP and SWARM).
This avoids universe trying to build MALTA_COMMON and fail due to
the problem addressed in r276773.
Include std.MALTA from the MALTA mipsel and MALTA64 mips64el config files,
where the machine lines exist.

9 years agocxgbe/tom: allocate page pod addresses instead of ppod#.
np [Wed, 7 Jan 2015 06:20:33 +0000 (06:20 +0000)]
cxgbe/tom: allocate page pod addresses instead of ppod#.

MFC after: 2 weeks

9 years agoar: Avoid null pointer deref while reading corrupt archives
emaste [Wed, 7 Jan 2015 01:51:02 +0000 (01:51 +0000)]
ar: Avoid null pointer deref while reading corrupt archives

ELF Tool Chain ticket #467

Reported by: Alexander Cherepanov <cherepan@mccme.ru>
MFC after: 1 week
Sponsored by: The FreeBSD Foundation

9 years agoRemove the machine directive from the common MALTA* configuration file
bz [Wed, 7 Jan 2015 01:41:45 +0000 (01:41 +0000)]
Remove the machine directive from the common MALTA* configuration file
to avoid conflicting machine lines for the MALTA64 kernel configuration
making config(8) go barf and builds to fail.

Pointed out by: adrian

9 years agoFactor out duplicated code from dumpsys() on each architecture into generic
markj [Wed, 7 Jan 2015 01:01:39 +0000 (01:01 +0000)]
Factor out duplicated code from dumpsys() on each architecture into generic
code in sys/kern/kern_dump.c. Most dumpsys() implementations are nearly
identical and simply redefine a number of constants and helper subroutines;
a generic implementation will make it easier to implement features around
kernel core dumps. This change does not alter any minidump code and should
have no functional impact.

PR: 193873
Differential Revision: https://reviews.freebsd.org/D904
Submitted by: Conrad Meyer <conrad.meyer@isilon.com>
Reviewed by: jhibbits (earlier version)
Sponsored by: EMC / Isilon Storage Division

9 years agoUse the new process reaper functionality
bapt [Tue, 6 Jan 2015 23:40:39 +0000 (23:40 +0000)]
Use the new process reaper functionality

When not using the --foreground option timeout(1) is supported to signal all
command children hierarchy, timeout(1) now acquire the reaper to ensure this
really happens and no children process can escaper from timeout(1) control

9 years agoFix typo from too many cut-n-paste operations. Use IMPSRC:T to just
imp [Tue, 6 Jan 2015 23:08:47 +0000 (23:08 +0000)]
Fix typo from too many cut-n-paste operations. Use IMPSRC:T to just
get the tail part of the path. We can now build kernels the
old-fashioned way on FreeBSD 9.x and 10.x on at least amd64 using
clang 3.3, 3.4 or gcc 4.2.1 (though with the latter you need
WITHOUT_MODULES="aesni vmm cxgbe" due to various issues with
gcc 4.2.1).

9 years agoFix a typographical error.
kargl [Tue, 6 Jan 2015 23:04:41 +0000 (23:04 +0000)]
Fix a typographical error.

Confirmed by: n1256.pdf
Obtained from: Dragonfly BSD

9 years agoMFV r276759: libpcap 1.6.2.
delphij [Tue, 6 Jan 2015 22:29:12 +0000 (22:29 +0000)]
MFV r276759: libpcap 1.6.2.

MFC after: 1 month

9 years agoPacify clang 3.3 by ending the file with a newline. This is common
imp [Tue, 6 Jan 2015 21:26:35 +0000 (21:26 +0000)]
Pacify clang 3.3 by ending the file with a newline. This is common
practice in the rest of the tree, but this file slipped through.

9 years agoProperly change directories before creating the
gjb [Tue, 6 Jan 2015 20:46:29 +0000 (20:46 +0000)]
Properly change directories before creating the
PKG_ALTABI -> PKG_ABI symlink.

MFC after: 3 days
X-MFC-With: r276765
Sponsored by: The FreeBSD Foundation

9 years agoUpdate pkg-stage.sh to be compatible with pkg-1.4.x.
gjb [Tue, 6 Jan 2015 20:42:50 +0000 (20:42 +0000)]
Update pkg-stage.sh to be compatible with pkg-1.4.x.

In 1.3.x and earlier, ABI format is, for example,
freebsd:11:x86:64.

In 1.4.x, ABI format is FreeBSD:11:amd64, and a new
configuration entry, ALTABI, is: freebsd:11:x86:64.

Export PKG_ABI and PKG_ALTABI accordingly, and if
PKG_ALTABI is set, create a symlink within the dvd
PKG_CACHEDIR so both new and old ABI directories
exist.

MFC after: 3 days
Sponsored by: The FreeBSD Foundation

9 years agoAdd support to crunchide for handling AArch64 (arm64) ELF files.
andrew [Tue, 6 Jan 2015 20:10:42 +0000 (20:10 +0000)]
Add support to crunchide for handling AArch64 (arm64) ELF files.

Sponsored by: The FreeBSD Foundation

9 years agoClear blocking due to STI or MOV SS in the hypervisor when an instruction is
neel [Tue, 6 Jan 2015 19:04:02 +0000 (19:04 +0000)]
Clear blocking due to STI or MOV SS in the hypervisor when an instruction is
emulated or when the vcpu incurs an exception. This matches the CPU behavior.

Remove special case code in HLT processing that was clearing the interrupt
shadow. This is now redundant because the interrupt shadow is always cleared
when the vcpu is resumed after an instruction is emulated.

Reported by: David Reed (david.reed@tidalscale.com)
MFC after: 2 weeks

9 years agoVendor import of libpcap 1.6.2.
delphij [Tue, 6 Jan 2015 18:58:31 +0000 (18:58 +0000)]
Vendor import of libpcap 1.6.2.

9 years agokdump: eliminate new clang warnings.
dchagin [Tue, 6 Jan 2015 18:53:09 +0000 (18:53 +0000)]
kdump: eliminate new clang warnings.

MFC after: 1 week

9 years agoGlobal-ify channel_type() - this fixes non-debug net80211 builds.
adrian [Tue, 6 Jan 2015 18:25:10 +0000 (18:25 +0000)]
Global-ify channel_type() - this fixes non-debug net80211 builds.

9 years agoReapply previous patch to fix build.
rodrigc [Tue, 6 Jan 2015 16:47:02 +0000 (16:47 +0000)]
Reapply previous patch to fix build.

PR: 194515

9 years agoRemove "New" label from NFSCL/NFSD now that they are the only NFS
jhb [Tue, 6 Jan 2015 16:15:57 +0000 (16:15 +0000)]
Remove "New" label from NFSCL/NFSD now that they are the only NFS
client/server.  While here, remove duplicate NFSCL from sys/conf/NOTES.

Approved by: rmacklem

9 years agoRemove compat shims for FreeBSD versions older than 6 (really early 5).
jhb [Tue, 6 Jan 2015 15:48:20 +0000 (15:48 +0000)]
Remove compat shims for FreeBSD versions older than 6 (really early 5).
The only diffs in the disassembly were different line numbers passed to
lock functions.

9 years agoUse struct thread directly instead of d_thread_t. This driver is not
jhb [Tue, 6 Jan 2015 15:41:23 +0000 (15:41 +0000)]
Use struct thread directly instead of d_thread_t.  This driver is not
likely to be backported to 4.x.

Reviewed by: kadesai

9 years agoUse M_WRITABLE() and M_LEADINGSPACE() rather than checking M_EXT and
rwatson [Tue, 6 Jan 2015 14:32:28 +0000 (14:32 +0000)]
Use M_WRITABLE() and M_LEADINGSPACE() rather than checking M_EXT and
doing hand-crafted length calculations in the IP options code.

Reviewed by: bz
Sponsored by: EMC / Isilon Storage Division

9 years agoRemove the check that prevent carp(4) advskew to be set to '0'.
loos [Tue, 6 Jan 2015 13:07:13 +0000 (13:07 +0000)]
Remove the check that prevent carp(4) advskew to be set to '0'.

CARP devices are created with advskew set to '0' and once you set it to
any other value in the valid range (0..254) you can't set it back to zero.

The code in question is also used to prevent that zeroed values overwrite
the CARP defaults when a new CARP device is created.  Since advskew already
defaults to '0' for newly created devices and the new value is guaranteed
to be within the valid range, it is safe to overwrite it here.

PR: 194672
Reported by: cmb@pfsense.org
In collaboration with: garga
Tested by: garga
MFC after: 2 weeks

9 years agoIn order to reduce use of M_EXT outside of the mbuf allocator and
rwatson [Tue, 6 Jan 2015 12:59:37 +0000 (12:59 +0000)]
In order to reduce use of M_EXT outside of the mbuf allocator and
socket-buffer implementations, introduce a return value for MCLGET()
(and m_cljget() that underlies it) to allow the caller to avoid testing
M_EXT itself.  Update all callers to use the return value.

With this change, very few network device drivers remain aware of
M_EXT; the primary exceptions lie in mbuf-chain pretty printers for
debugging, and in a few cases, custom mbuf and cluster allocation
implementations.

NB: This is a difficult-to-test change as it touches many drivers for
which I don't have physical devices.  Instead we've gone for intensive
review, but further post-commit review would definitely be appreciated
to spot errors where changes could not easily be made mechanically,
but were largely mechanical in nature.

Differential Revision: https://reviews.freebsd.org/D1440
Reviewed by: adrian, bz, gnn
Sponsored by: EMC / Isilon Storage Division

9 years agoFixes and updates for the Linux compatibility layer:
hselasky [Tue, 6 Jan 2015 10:02:14 +0000 (10:02 +0000)]
Fixes and updates for the Linux compatibility layer:
- Remove unsupported "bus" field from "struct pci_dev".
- Fix logic inside "pci_enable_msix()" when the number of allocated
  interrupts are less than the number of available interrupts.
- Update header files included from "list.h".
- Ensure that "idr_destroy()" removes all entries before destroying
  the IDR root node(s).
- Set the "device->release" function so that we don't leak memory at
  device destruction.
- Use FreeBSD's "log()" function for certain debug printouts.
- Put parenthesis around arguments inside the min, max, min_t and max_t macros.
- Make sure we don't leak file descriptors by dropping the extra file
  reference counts done by the FreeBSD kernel when calling falloc()
  and fget_unlocked().

MFC after: 1 week
Sponsored by: Mellanox Technologies

9 years agoFix kernel build after r276730.
hselasky [Tue, 6 Jan 2015 09:39:42 +0000 (09:39 +0000)]
Fix kernel build after r276730.

9 years agoInstead of creating a purge thread for every vnet, create
rodrigc [Tue, 6 Jan 2015 09:03:03 +0000 (09:03 +0000)]
Instead of creating a purge thread for every vnet, create
a single purge thread and clean up all vnets from this thread.

PR:                     194515
Differential Revision:  D1315
Submitted by:           Nikos Vassiliadis <nvass@gmx.com>

9 years agoMerge: r258322 from projects/pf branch
rodrigc [Tue, 6 Jan 2015 08:39:06 +0000 (08:39 +0000)]
Merge: r258322 from projects/pf branch

    Split functions that initialize various pf parts into their
    vimage parts and global parts.
    Since global parts appeared to be only mutex initializations, just
    abandon them and use MTX_SYSINIT() instead.
    Kill my incorrect VNET_FOREACH() iterator and instead use correct
    approach with VNET_SYSINIT().

PR: 194515
Differential Revision: D1309
Submitted by:  glebius, Nikos Vassiliadis <nvass@gmx.com>
Reviewed by:  trociny, zec, gnn

9 years agoGlue to suck in the QCA9550 HAL support if AH_SUPPORT_QCA9550 is defined.
adrian [Tue, 6 Jan 2015 07:52:19 +0000 (07:52 +0000)]
Glue to suck in the QCA9550 HAL support if AH_SUPPORT_QCA9550 is defined.

9 years agoAdd option to support the QCA955x SoC wifi.
adrian [Tue, 6 Jan 2015 07:51:46 +0000 (07:51 +0000)]
Add option to support the QCA955x SoC wifi.

9 years agoMake the apb.c code optional behind ar71xx_apb rather than standard.
adrian [Tue, 6 Jan 2015 07:43:07 +0000 (07:43 +0000)]
Make the apb.c code optional behind ar71xx_apb rather than standard.

The QCA955x has more mux interrupts going on - and the AR934x actually does,
but I cheated and assigned wlan and pcie to the same interrupt line.
They are, there's just a status register mux that I should've been using.

Luckily this isn't too bad a change in itself - almost all of the
Atheros MIPS configurations use a _BASE file to inherit from.
Except PB92, which I should really fix up at some point.

The AR934x will use the legacy apb for now until I write its replacement.

The QCA955x SoC I'm doing bring-up on will have a separate qca955x_apb.c
implementation that includes hooking into IP2/IP3 and doing further
interrupt demuxing as appropriate.

9 years agoAdd an APB base/size for the QCA955X for an upcoming QCA955x specific
adrian [Tue, 6 Jan 2015 07:37:33 +0000 (07:37 +0000)]
Add an APB base/size for the QCA955X for an upcoming QCA955x specific
APB mux.

It's larger than the AR71xx because it needs to replace the nexus
for some devices (notably wifi) and the wifi driver (if_ath_ahb.c)
reads the SPI data directly at early boot whilst it's memory mapped
in.

I'm eventually going to rip it out and replace it with a firmware
interface similar to what exists for the if_ath_pci.c path -
something early on (likely something new that I'll write) will
suck in the calibration data into a firmware API blob and that'll
be accessed from if_ath_ahb.c.

But, one thing at a time.

Tested:

* QCA955x SoC, AP135 development board

9 years agoThe QCA955x USB init path doesn't require any of this, so delete it.
adrian [Tue, 6 Jan 2015 07:35:05 +0000 (07:35 +0000)]
The QCA955x USB init path doesn't require any of this, so delete it.

Obtained from: Linux/OpenWRT

9 years agoRemove old ioctl use and support, once and for all.
imp [Tue, 6 Jan 2015 05:28:37 +0000 (05:28 +0000)]
Remove old ioctl use and support, once and for all.

9 years agoAdd some GEOM options.
rodrigc [Tue, 6 Jan 2015 05:28:22 +0000 (05:28 +0000)]
Add some GEOM options.

9 years agoRefactor common options from MALTA and MALTA64 kernel
rodrigc [Tue, 6 Jan 2015 05:26:13 +0000 (05:26 +0000)]
Refactor common options from MALTA and MALTA64 kernel
configs into MALTA_COMMON file.

9 years agoAvoid use of register variables. Clang 3.5 treats this as undefined behavior,
jhibbits [Tue, 6 Jan 2015 03:50:43 +0000 (03:50 +0000)]
Avoid use of register variables.  Clang 3.5 treats this as undefined behavior,
and bad things happen.

MFC after: 1 week

9 years agoApply r246556 to powerpc:
jhibbits [Tue, 6 Jan 2015 03:49:22 +0000 (03:49 +0000)]
Apply r246556 to powerpc:

Avoid use of register variables, which some compilers (e.g. clang)
don't like. It makes the code a little clearer as well.

This allows a clang 3.5 built powerpc world to run (tested in a jail).

MFC after: 1 week

9 years agoRefactor and split out the net80211 software scan engine from the rest
adrian [Tue, 6 Jan 2015 02:08:45 +0000 (02:08 +0000)]
Refactor and split out the net80211 software scan engine from the rest
of the scan API.

The eventual aim is to have 'ieee80211_scan.c' have the net80211 and
driver facing scan API to start, finish and continue doing scanning
while 'ieee80211_swscan.c' implements the software scanner that
runs the scan task, handles probe request/reply bits, configures
the VAP off-channel, changes channel and does the scanning bits.

For NICs that do no scanning at all, the existing code is needed.
ath(4) and most of the other NICs (dumb USB ones in particular)
do little to no scan offload - it's all done in software.

Some NICs may do single channel at a time scanning; I haven't really
checked them out in detail.

iwn(4), the upcoming 7260 driver stuff, the new Qualcomm Atheros
11ac chipsets and the Atheros mobile/USB full-offload chips all
have complete scan engines in firmware.  We don't have to drive
any of it at all - the firmware just needs to be told what to scan,
when to scan, how long to scan.  It'll take care of going off
channel, pausing TX/RX appropriately, sending sleep notification
to the AP, sending probe requests and handling probe responses.
It'll do passive/active scan itself.  It's almost completely
transparent to the network stack - all we see are scan notifications
when it finishes scanning each channel and beacons/probe responses
when it does its thing.  Once it's done we get a final notification
that the scan is complete, with some scan results in the message.
The iwn(4) NICs handle doing active scanning too as an option
and will handle waiting appropriately on 5GHz passive channels
before active scanning.

There's some more refactoring, tidying up and lock assertions to
sprinkle around to tidy this whole thing up before I turn swscan.c
into another set of ic methods to override by the driver or
alternate scan module.  So in theory this is all one big no-op
commit.  In theory.

Tested:

* iwn(4) 5200, STA mode
* ath(4) 6205, STA mode
* ath(4) - various NICs, AP mode

9 years agocxgbe/tom: use vmem(9) as the DDP page pod allocator.
np [Tue, 6 Jan 2015 01:30:32 +0000 (01:30 +0000)]
cxgbe/tom: use vmem(9) as the DDP page pod allocator.

MFC after: 1 month

9 years agocxgbe(4): fix the description of a strange bunch of counters.
np [Mon, 5 Jan 2015 23:43:24 +0000 (23:43 +0000)]
cxgbe(4): fix the description of a strange bunch of counters.

MFC after: 1 week

9 years agoUse crcopysafe(9) to make a copy of a process' credential struct. crcopy(9)
markj [Mon, 5 Jan 2015 23:07:22 +0000 (23:07 +0000)]
Use crcopysafe(9) to make a copy of a process' credential struct. crcopy(9)
may perform a blocking memory allocation, which is unsafe when holding a
mutex.

Differential Revision: https://reviews.freebsd.org/D1443
Reviewed by: rwatson
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division

9 years agoRestore use of ofw_bus_intr_to_rl() in the pseries vdevice driver after fixing
nwhitehorn [Mon, 5 Jan 2015 21:39:35 +0000 (21:39 +0000)]
Restore use of ofw_bus_intr_to_rl() in the pseries vdevice driver after fixing
ofw_bus_intr_to_rl() to match the spec for unspecified interrupt-parent
properties.

9 years agoTrim trailing whitespace.
jhb [Mon, 5 Jan 2015 20:50:44 +0000 (20:50 +0000)]
Trim trailing whitespace.

9 years agoOn some Intel CPUs with a P-state but not C-state invariant TSC the TSC
jhb [Mon, 5 Jan 2015 20:44:44 +0000 (20:44 +0000)]
On some Intel CPUs with a P-state but not C-state invariant TSC the TSC
may also halt in C2 and not just C3 (it seems that in some cases the BIOS
advertises its C3 state as a C2 state in _CST).  Just play it safe and
disable both C2 and C3 states if a user forces the use of the TSC as the
timecounter on such CPUs.

PR: 192316
Differential Revision: https://reviews.freebsd.org/D1441
No objection from: jkim
MFC after: 1 week

9 years agoInstall d_align.{in,out} for the :align test
ngie [Mon, 5 Jan 2015 20:38:47 +0000 (20:38 +0000)]
Install d_align.{in,out} for the :align test

X-MFC with: r276669
Pointyhat to: me

9 years agoAdd 64-bit DMA support in the XHCI controller driver.
hselasky [Mon, 5 Jan 2015 20:22:18 +0000 (20:22 +0000)]
Add 64-bit DMA support in the XHCI controller driver.
- Fix some comments and whitespace while at it.

MFC after: 1 month
Submitted by: marius@

9 years agoUse struct thread * directly instead of d_thread_t. This driver is not
jhb [Mon, 5 Jan 2015 19:49:20 +0000 (19:49 +0000)]
Use struct thread * directly instead of d_thread_t.  This driver is not
likely to be merged back to stable/4.

Reviewed by: delphij

9 years agoExclude drivers which build but don't actually work with PAE enabled,
marius [Mon, 5 Jan 2015 19:15:35 +0000 (19:15 +0000)]
Exclude drivers which build but don't actually work with PAE enabled,
missed in r276377

9 years agoRevert r272109 locally, which is not quite equivalent in how it deals with
nwhitehorn [Mon, 5 Jan 2015 18:15:16 +0000 (18:15 +0000)]
Revert r272109 locally, which is not quite equivalent in how it deals with
missing interrupt-parent properties. A better solution will come later,
but this restores pseries in QEMU for the time being.

9 years agoMissed change in r276688. Apologies for build breakage.
nwhitehorn [Mon, 5 Jan 2015 16:52:25 +0000 (16:52 +0000)]
Missed change in r276688. Apologies for build breakage.

9 years agoo Switch to use non-mergeable RX buffers to avoid mbuf adjustment needs
br [Mon, 5 Jan 2015 16:43:22 +0000 (16:43 +0000)]
o Switch to use non-mergeable RX buffers to avoid mbuf adjustment needs
o Operate with copy of iov as we expect later it was not modified

9 years agoreadelf: Handle note types from different operating systems
emaste [Mon, 5 Jan 2015 16:05:15 +0000 (16:05 +0000)]
readelf: Handle note types from different operating systems

Previously elftoolchain readelf(1) produced correct description text
only for Linux note types.

Upstream elftoolchain ticket #473

Differential Revision: https://reviews.freebsd.org/D1428
Reviewed by: kib
Sponsored by: The FreeBSD Foundation

9 years agoFix memory leaks.
trasz [Mon, 5 Jan 2015 15:34:23 +0000 (15:34 +0000)]
Fix memory leaks.

CID: 12585821258583.
MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoRemove leftovers.
trasz [Mon, 5 Jan 2015 15:29:28 +0000 (15:29 +0000)]
Remove leftovers.

MFC after: 1 month
Sponsored by: The FreeBSD Foundation

9 years agoEnable remote control using a local socket in the default configuration.
des [Mon, 5 Jan 2015 15:09:00 +0000 (15:09 +0000)]
Enable remote control using a local socket in the default configuration.

9 years agoMake a bunch of USB debug SYSCTLs tunable, so that their value(s) can
hselasky [Mon, 5 Jan 2015 15:04:17 +0000 (15:04 +0000)]
Make a bunch of USB debug SYSCTLs tunable, so that their value(s) can
be set before the USB device(s) are probed.

9 years agomfv (r276698): support for remote control over local sockets.
des [Mon, 5 Jan 2015 14:59:18 +0000 (14:59 +0000)]
mfv (r276698): support for remote control over local sockets.

9 years agoFix a few grammar issues.
brueffer [Mon, 5 Jan 2015 13:46:37 +0000 (13:46 +0000)]
Fix a few grammar issues.

9 years agoClang's 3.5 integrated assembler now handles these files correctly (it
imp [Mon, 5 Jan 2015 12:28:22 +0000 (12:28 +0000)]
Clang's 3.5 integrated assembler now handles these files correctly (it
has support for the .codeXX directives). However, it is desirable, for
a time, to allow kernels to be built with clang 3.4. Historically, it
has been advantageous to allow stable X-1 to build kernels the old
way (so long as the impact of doing so is small), and this restores
that ability.

Also, centralize the addition of ${ASM_CFLAGS.${.IMPSRC}}, place it in
kern.mk rather than kern.pre.mk so that all modules can benefit, and
give the same treatment to CFLAGS in kern.mk as well.

9 years agoAdd a very basic manpage for the Etherswitch framework.
brueffer [Mon, 5 Jan 2015 11:40:05 +0000 (11:40 +0000)]
Add a very basic manpage for the Etherswitch framework.

MFC after: 1 week

9 years agoWith r276692 m_align() moved and became an inline function.
bz [Mon, 5 Jan 2015 11:22:58 +0000 (11:22 +0000)]
With r276692 m_align() moved and became an inline function.
Remove the (now) redundant function declaration.

9 years agoMention axge(4).
kevlo [Mon, 5 Jan 2015 10:10:35 +0000 (10:10 +0000)]
Mention axge(4).

9 years agoTo ease changes to underlying mbuf structure and the mbuf allocator, reduce
rwatson [Mon, 5 Jan 2015 09:58:32 +0000 (09:58 +0000)]
To ease changes to underlying mbuf structure and the mbuf allocator, reduce
the knowledge of mbuf layout, and in particular constants such as M_EXT,
MLEN, MHLEN, and so on, in mbuf consumers by unifying various alignment
utility functions (M_ALIGN(), MH_ALIGN(), MEXT_ALIGN() in a single
M_ALIGN() macro, implemented by a now-inlined m_align() function:

- Move m_align() from uipc_mbuf.c to mbuf.h; mark as __inline.
- Reimplement M_ALIGN(), MH_ALIGN(), and MEXT_ALIGN() using m_align().
- Update consumers around the tree to simply use M_ALIGN().

This change eliminates a number of cases where mbuf consumers must be aware
of whether or not mbufs returned by the allocator use external storage, but
also assumptions about the size of the returned mbuf. This will make it
easier to introduce changes in how we use external storage, as well as
features such as variable-size mbufs.

Differential Revision: https://reviews.freebsd.org/D1436
Reviewed by: glebius, trasz, gnn, bz
Sponsored by: EMC / Isilon Storage Division

9 years agoRemove the remnants of the OpenWRT/Linux bits that this was based off
adrian [Mon, 5 Jan 2015 05:30:07 +0000 (05:30 +0000)]
Remove the remnants of the OpenWRT/Linux bits that this was based off
of.

Obtained from: Linux/OpenWRT

9 years agoOops - missed refclk.
adrian [Mon, 5 Jan 2015 05:26:57 +0000 (05:26 +0000)]
Oops - missed refclk.

Tested:

* AP135, QCA955x SoC

9 years agoaddr2line: fflush output after each address lookup
emaste [Mon, 5 Jan 2015 04:56:38 +0000 (04:56 +0000)]
addr2line: fflush output after each address lookup

Certain tools spawn addr2line and pass addresses one at a time for
resolution.

PR: 195561
Reported by: antoine
Sponsored by: The FreeBSD Foundation

9 years agoAdd kexec-based Linux shim loader for use with the firmware petitboot
nwhitehorn [Mon, 5 Jan 2015 04:33:39 +0000 (04:33 +0000)]
Add kexec-based Linux shim loader for use with the firmware petitboot
loader on PS3 and POWER8 systems. This is reasonably portable to other
architectures, especially FDT-based ones, if similar features are useful
elsewhere.

Netboot support is missing for now and will be added in a future commit,
at which time loader.ps3 will be garbage collected.

Done at: Hackathon

9 years agoAdd initial Qualcomm Atheros QCA955x SoC support.
adrian [Mon, 5 Jan 2015 02:06:26 +0000 (02:06 +0000)]
Add initial Qualcomm Atheros QCA955x SoC support.

This adds the initial frequency poking and configures up enough
for it to boot and spit out data over the console.

There's still a whole bunch of work to do in the reset path
and devices to support this thing, but hey, it's alive!

ath> go 0x80050100
## Starting application at 0x80050100 ...
CPU platform: Atheros AR9558 rev 0
CPU Frequency=720 MHz
CPU DDR Frequency=600 MHz
CPU AHB Frequency=200 MHz
platform frequency: 720 MHz
CPU reference clock: 0 MHz
CPU MDIO clock: 40 MHz

Done at: hackathon
Obtained from: Linux OpenWRT, Qualcomm Atheros

9 years agoACK interrupts on the new SoCs.
adrian [Mon, 5 Jan 2015 02:00:41 +0000 (02:00 +0000)]
ACK interrupts on the new SoCs.

9 years agoadd QCA955x SoC types.
adrian [Mon, 5 Jan 2015 01:59:44 +0000 (01:59 +0000)]
add QCA955x SoC types.

9 years agoAdd QCA955x series register definitions.
adrian [Mon, 5 Jan 2015 01:44:23 +0000 (01:44 +0000)]
Add QCA955x series register definitions.

There's likely a bunch of register offsets that I have to add the
register window base to before I use them.

Done at: Hackathon
Obtained from: Linux OpenWRT

9 years agoAvoid calling internal libc function through PLT or accessing data
kib [Mon, 5 Jan 2015 01:06:54 +0000 (01:06 +0000)]
Avoid calling internal libc function through PLT or accessing data
though GOT, by staticizing and hiding.  Add setter for
__error_selector to hide it as well.

Suggested and reviewed by: jilles
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

9 years agoUse FDT properties to identify a PS3 if present.
nwhitehorn [Mon, 5 Jan 2015 01:05:35 +0000 (01:05 +0000)]
Use FDT properties to identify a PS3 if present.

9 years agoMake PS3 work with the userspace kboot loader. loader.ps3 will disappear
nwhitehorn [Mon, 5 Jan 2015 00:50:16 +0000 (00:50 +0000)]
Make PS3 work with the userspace kboot loader. loader.ps3 will disappear
from the tree in the near future.

Done at: Hackathon

9 years agoBump .Dd again for the change done in r276483
ngie [Mon, 5 Jan 2015 00:03:42 +0000 (00:03 +0000)]
Bump .Dd again for the change done in r276483

Pointyhat to: me

9 years agoExpect :arithmetic_ops_body to fail with syntax errors on FreeBSD
ngie [Sun, 4 Jan 2015 23:41:17 +0000 (23:41 +0000)]
Expect :arithmetic_ops_body to fail with syntax errors on FreeBSD

MFC after: 2 weeks
Sponsored by: EMC / Isilon Storage Division

9 years agoDo not configure Altera PIO device on ARM startup.
br [Sun, 4 Jan 2015 23:14:04 +0000 (23:14 +0000)]
Do not configure Altera PIO device on ARM startup.
PIO is a device implemented in soft-core and becomes
available after flashing FPGA only.

9 years agoIntegrate bin/cat/tests from NetBSD into atf/kyua
ngie [Sun, 4 Jan 2015 22:37:44 +0000 (22:37 +0000)]
Integrate bin/cat/tests from NetBSD into atf/kyua

Sponsored by: EMC / Isilon Storage Division

9 years agoIntegrate sbin/ifconfig/tests from NetBSD into atf/kyua
ngie [Sun, 4 Jan 2015 22:25:16 +0000 (22:25 +0000)]
Integrate sbin/ifconfig/tests from NetBSD into atf/kyua

Sponsored by: EMC / Isilon Storage Division

9 years agoEliminate uninitialized variable warnings in kernel and module builds when
ian [Sun, 4 Jan 2015 20:08:24 +0000 (20:08 +0000)]
Eliminate uninitialized variable warnings in kernel and module builds when
building with gcc 4.2

This has been requested several times over the past few months by several
people (including me), because gcc 4.2 just gets it wrong too often.  It's
causing us to litter the code with lots of bogus initializers just to
squelch the warnings.  We still have clang and coverity telling us about
uninitialized variables, and they do so more accurately.

9 years agoPrevent live-lock and access of destroyed data in taskqueue_drain_all().
gibbs [Sun, 4 Jan 2015 19:55:44 +0000 (19:55 +0000)]
Prevent live-lock and access of destroyed data in taskqueue_drain_all().

Phabric: https://reviews.freebsd.org/D1247
Reviewed by: jhb, avg
Sponsored by: Spectra Logic Corporation

sys/kern_subr_taskqueue.c:
Modify taskqueue_drain_all() processing to use a temporary
"barrier task", rather than rely on a user task that may
be destroyed during taskqueue_drain_all()'s execution.  The
barrier task is queued behind all previously queued tasks
and then has its priority elevated so that future tasks
cannot pass it in the queue.

Use a similar barrier scheme to drain threads processing
current tasks.  This requires taskqueue_run_locked() to
insert and remove the taskqueue_busy object for the running
thread for every task processed.

share/man/man9/taskqueue.9:
Remove warning about live-lock issues with taskqueue_drain_all()
and indicate that it does not wait for tasks queued after
it begins processing.

9 years agoChange the type of blksize_t from uint32_t to a POSIX compliant int32_t
kevlo [Sun, 4 Jan 2015 15:26:02 +0000 (15:26 +0000)]
Change the type of blksize_t from uint32_t to a POSIX compliant int32_t
http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/sys_types.h.html

9 years agomdoc: paragraph improvements.
joel [Sun, 4 Jan 2015 12:49:24 +0000 (12:49 +0000)]
mdoc: paragraph improvements.

9 years agomdoc: use An macro.
joel [Sun, 4 Jan 2015 12:42:08 +0000 (12:42 +0000)]
mdoc: use An macro.

9 years agomdoc: sort SEE ALSO.
joel [Sun, 4 Jan 2015 12:38:00 +0000 (12:38 +0000)]
mdoc: sort SEE ALSO.

9 years agoRegen for r276654 (__getcwd()).
dchagin [Sun, 4 Jan 2015 10:40:23 +0000 (10:40 +0000)]
Regen for r276654 (__getcwd()).

9 years agoIndeed, instead of hiding the kern___getcwd() bug by bogus cast
dchagin [Sun, 4 Jan 2015 10:34:02 +0000 (10:34 +0000)]
Indeed, instead of hiding the kern___getcwd() bug by bogus cast
in r276564, change path type to char * (pathnames are always char *).
And remove bogus casts of malloc().
kern___getcwd() internally doesn't actually use or support u_char *
paths, except to copy them to a normal char * path.

These changes are not visible to libc as libc/gen/getcwd.c misdeclares
__getcwd() as taking a plain char * path.

While here remove _SYS_SYSPROTO_H_ for __getcwd() syscall as
we always have sysproto.h.

Pointed out by: bde

MFC after: 1 week

9 years agoTruncate DB_SMALL_VALUE_MAX to a much lower value.
jhibbits [Sun, 4 Jan 2015 01:45:26 +0000 (01:45 +0000)]
Truncate DB_SMALL_VALUE_MAX to a much lower value.

Unlike the other architectures, the PowerPC kernel is loaded under the 2GB
boundary.

MFC after: 2 weeks

9 years agoAdd pregenerated documentation for as(1) and ld(1)
bapt [Sun, 4 Jan 2015 00:58:30 +0000 (00:58 +0000)]
Add pregenerated documentation for as(1) and ld(1)

9 years agoFix generating documentation with modern texinfo
bapt [Sun, 4 Jan 2015 00:54:29 +0000 (00:54 +0000)]
Fix generating documentation with modern texinfo

9 years agoFix generating documents with modern texinfo
bapt [Sun, 4 Jan 2015 00:44:24 +0000 (00:44 +0000)]
Fix generating documents with modern texinfo

9 years agoDo not erronously export 'openat' symbol from rtld.
kib [Sun, 4 Jan 2015 00:33:41 +0000 (00:33 +0000)]
Do not erronously export 'openat' symbol from rtld.

The symbol leaked after r276630 since lib/libc/sys/openat.c defines
versions for openat using .symver (version script cannot assign two
versions to one symbol), and rtld uses openat.  Instead, directly use
__sys_openat().

Reported and tested by: antoine
Sponsored by: The FreeBSD Foundation
MFC after: 1 week

9 years agoDon't allow clang to use fpu instructions or registers in kernel modules.
ian [Sun, 4 Jan 2015 00:12:30 +0000 (00:12 +0000)]
Don't allow clang to use fpu instructions or registers in kernel modules.

Submitted by: Keith White <kwhite@site.uottawa.ca>

9 years agoSwitch all arm kernels with option SMP to use SCHED_ULE instead of 4BSD.
ian [Sat, 3 Jan 2015 23:57:03 +0000 (23:57 +0000)]
Switch all arm kernels with option SMP to use SCHED_ULE instead of 4BSD.