]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/log
FreeBSD/FreeBSD.git
10 years agoInstead of modeling the kernel-tools build after the bootstrap tools, build
ian [Thu, 7 Nov 2013 22:50:42 +0000 (22:50 +0000)]
Instead of modeling the kernel-tools build after the bootstrap tools, build
kernel tools the way cross-tools get built.  This seems to result in the
tool getting installed in the right place.  It also seems more correct in
retrospect, because if a tool emitted code or binary data as part of
building the kernel, it should do so in target-specific ways (endianess,
architecture, whatever).  That issue is moot for aicasm, our only current
tool, but it still seems to be more correct in principle.

10 years agoFix a bug that prevented `-d' from working as-documented in sysrc(8).
dteske [Thu, 7 Nov 2013 22:47:52 +0000 (22:47 +0000)]
Fix a bug that prevented `-d' from working as-documented in sysrc(8).
Rather, prevent a bunch of debugging information from spewing onto the
screen when using the `describe' flag (misinterpreted as `debug' by
the automatatic initialization routines).

10 years agoYet, another attempt to fix the libm breakage due to the
kargl [Thu, 7 Nov 2013 22:46:13 +0000 (22:46 +0000)]
Yet, another attempt to fix the libm breakage due to the
changes in s_roundl.c to use bit twiddling.

Reported by: ian

10 years agoExtend loader_delay as-documented in beastie.4th(8) and delay.4th(8), making it avail...
dteske [Thu, 7 Nov 2013 21:52:04 +0000 (21:52 +0000)]
Extend loader_delay as-documented in beastie.4th(8) and delay.4th(8), making it available to architectures that do not use or load the beastie
menu. This is reported to save headaches on some PPC systems where unload
followed by load does not produce the desired results wherein if-given
the opportunicy to abort the initial loading sequence, you can customize
the first load.

Reviewed by:    nwhitehorn, kan
Discussed on:   -current

10 years agoAdd support for controlling mfi(4) controller properties:
sbruno [Thu, 7 Nov 2013 21:47:59 +0000 (21:47 +0000)]
Add support for controlling mfi(4) controller properties:

allow user control of rebuild rate
allow user control of silence/enable alarm

MFC after: 2 weeks
Sponsored by: Yahoo! Inc.

10 years agoUse `pkg -vv' to obtain ABI for validating a chosen media server (done
dteske [Thu, 7 Nov 2013 21:38:46 +0000 (21:38 +0000)]
Use `pkg -vv' to obtain ABI for validating a chosen media server (done
prior to diving head-long into a pkg-update(8), et. al). This should
also be more future-proof than what was being done just before this.

10 years agoFix bulding libm on platforms with LDBL_MANT_DIG == 53.
kargl [Thu, 7 Nov 2013 21:20:34 +0000 (21:20 +0000)]
Fix bulding libm on platforms with LDBL_MANT_DIG == 53.

Reported by: ian

10 years agoFix cosmetic typos (since the typo's in the variable names were copied
dteske [Thu, 7 Nov 2013 21:16:32 +0000 (21:16 +0000)]
Fix cosmetic typos (since the typo's in the variable names were copied
and pasted, it wasn't noticed).

10 years agoClamp the dump block size to the dump device max I/O size.
jhibbits [Thu, 7 Nov 2013 21:02:57 +0000 (21:02 +0000)]
Clamp the dump block size to the dump device max I/O size.

10 years agoInclude rtld itself when iterating over loaded ELF objects in
markj [Thu, 7 Nov 2013 20:45:50 +0000 (20:45 +0000)]
Include rtld itself when iterating over loaded ELF objects in
dl_iterate_phdr(3).

Reviewed by: kib

10 years agoBuild the iwn2000 firmware too.
adrian [Thu, 7 Nov 2013 19:40:52 +0000 (19:40 +0000)]
Build the iwn2000 firmware too.

10 years agoAdd new AMT serial port PCI ID on Intel Lynx Point chipset
sbruno [Thu, 7 Nov 2013 19:38:19 +0000 (19:38 +0000)]
Add new AMT serial port PCI ID on Intel Lynx Point chipset

Submitted by: Dmitry Luhtionov <dmitryluhtionov@gmail.com>
MFC after: 2 weeks

10 years agoUpdate release(7) to include 'mini-memstick' after r257805.
gjb [Thu, 7 Nov 2013 19:17:17 +0000 (19:17 +0000)]
Update release(7) to include 'mini-memstick' after r257805.

MFC after: 1 week
X-MFC-After: 10.0-RELEASE
X-MFC-With: r257805, r257806
Sponsored by: The FreeBSD Foundation

10 years agoRemove extra target from 'memstick' that I forgot to remove before
gjb [Thu, 7 Nov 2013 18:59:06 +0000 (18:59 +0000)]
Remove extra target from 'memstick' that I forgot to remove before
previous commit.

MFC after: 1 week
X-MFC-After: 10.0-RELEASE
X-MFC-With: r257805
Sponsored by: The FreeBSD Foundation

10 years agoAdd a 'mini-memstick.img' release target, which will use the
gjb [Thu, 7 Nov 2013 18:53:55 +0000 (18:53 +0000)]
Add a 'mini-memstick.img' release target, which will use the
'bootonly.iso' components to create a smaller memory stick image.

This is useful for system recovery, where a full memstick.img image
is not necessarily needed (or wanted).  In addition, it is possible to
do bootonly-style installation, where the base.txz, kernel.txz, etc.
are fetched from a remote source.

Provide backwards-compatible target (mini-memstick), to keep in sync
with the targets documented in release/Makefile.

Prompted by: wblock
MFC after: 1 week
X-MFC-after: 10.0-RELEASE
Sponsored by: The FreeBSD Foundation

10 years agoGet rid of the artification limitation enforced by
tuexen [Thu, 7 Nov 2013 18:50:11 +0000 (18:50 +0000)]
Get rid of the artification limitation enforced by
SCTP_AUTH_RANDOM_SIZE_MAX.
This was suggested by Andrew Galante.

MFC after: 3 days

10 years agoMake sure that we don't try to build an ASCONF-ACK chunk
tuexen [Thu, 7 Nov 2013 17:08:09 +0000 (17:08 +0000)]
Make sure that we don't try to build an ASCONF-ACK chunk
larger than what fits in the the mbuf cluster.
This issue was reported by Andrew Galante.

MFC after: 3 days

10 years agoSave some space by noting we don't have any alternative instruction formats.
imp [Thu, 7 Nov 2013 16:58:09 +0000 (16:58 +0000)]
Save some space by noting we don't have any alternative instruction formats.

10 years ago- Update release noted to DocBook 5.0 so that they work with the new tree
gabor [Thu, 7 Nov 2013 16:42:28 +0000 (16:42 +0000)]
- Update release noted to DocBook 5.0 so that they work with the new tree

10 years agoUse htons()/ntohs() appropriately.
tuexen [Thu, 7 Nov 2013 16:37:12 +0000 (16:37 +0000)]
Use htons()/ntohs() appropriately.
These issues were reported by Andrew Galante.

MFC after: 3 days

10 years agodevd: lower priority of action execution logging to info
avg [Thu, 7 Nov 2013 16:24:31 +0000 (16:24 +0000)]
devd: lower priority of action execution logging to info

Reviewed by: asomers

10 years agodevd: fix a typo in a comment
avg [Thu, 7 Nov 2013 16:22:04 +0000 (16:22 +0000)]
devd: fix a typo in a comment

Reviewed by: asomers

10 years agoFinish r257779.
glebius [Thu, 7 Nov 2013 14:05:49 +0000 (14:05 +0000)]
Finish r257779.

PR: usb/183728

10 years agoReplace pkg-tools with pkgng.
dteske [Thu, 7 Nov 2013 12:40:42 +0000 (12:40 +0000)]
Replace pkg-tools with pkgng.

10 years agoFix an off-by-one error that was causing menus to look funny.
dteske [Thu, 7 Nov 2013 11:20:50 +0000 (11:20 +0000)]
Fix an off-by-one error that was causing menus to look funny.

10 years agoComments.
dteske [Thu, 7 Nov 2013 10:48:00 +0000 (10:48 +0000)]
Comments.

10 years agoAdd f_sprintf() and f_vsprintf() to go along with previously added
dteske [Thu, 7 Nov 2013 10:47:12 +0000 (10:47 +0000)]
Add f_sprintf() and f_vsprintf() to go along with previously added
f_snprintf() and f_vsnprintf() (size-constraint) functions.

10 years agoFix a bug where a format with leading `-' could be mistaken for printf
dteske [Thu, 7 Nov 2013 10:45:25 +0000 (10:45 +0000)]
Fix a bug where a format with leading `-' could be mistaken for printf
getopts argument(s).

10 years agoComments.
dteske [Thu, 7 Nov 2013 10:44:24 +0000 (10:44 +0000)]
Comments.

10 years agoAdd some helpful debugging (showing the resolved host address).
dteske [Thu, 7 Nov 2013 10:40:19 +0000 (10:40 +0000)]
Add some helpful debugging (showing the resolved host address).

10 years agoFix a silly bug that would result in attempting to fetch (literally) the
dteske [Thu, 7 Nov 2013 10:36:24 +0000 (10:36 +0000)]
Fix a silly bug that would result in attempting to fetch (literally) the
URI "httpDirectory" (oops).

10 years agoUse dialog(1) to obtain maximum-size; stty fails when running in a pipe-
dteske [Thu, 7 Nov 2013 10:30:20 +0000 (10:30 +0000)]
Use dialog(1) to obtain maximum-size; stty fails when running in a pipe-
chain. This allows dialogs to reach full size even when executed as an
rvalue operand to a pipe (e.g., cat file | bsdconfig -f-).

10 years agoAdd an f_eval_catch() function for debugging individual commands in a
dteske [Thu, 7 Nov 2013 10:28:12 +0000 (10:28 +0000)]
Add an f_eval_catch() function for debugging individual commands in a
series of commands. Accepts the `-d' flag as a first argument to skip
displaying messages in a dialog box. The command is logged as it
appears to the shell prior to the first pass of parameter expansion to
allow copy/pasting into a real shell (opposed to simply echo'ing the
command which would produce debug output that has undergone at least one
pass of parameter expansion, thus no-longer copacetic for copy/paste).
Takes printf(1) style syntax and a utility identifier for error messages.

10 years agoAdd an f_show_err() function -- acts pretty much the same as f_show_msg()
dteske [Thu, 7 Nov 2013 10:23:37 +0000 (10:23 +0000)]
Add an f_show_err() function -- acts pretty much the same as f_show_msg()
except it stylizes the msgbox widget to indicate an Error has occurred by
setting an appropriate title and default message.

10 years agoAdd global DEBUG_INITIALIZE_FILE environment variable for controlling
dteske [Thu, 7 Nov 2013 10:20:19 +0000 (10:20 +0000)]
Add global DEBUG_INITIALIZE_FILE environment variable for controlling
whether the debugFile is truncated upon initialization (useful for when
children implicitly re-initialize debugging and you want children to
append to your existing debugFile).

10 years agoComments. Replace a funny syntax with f_isset() while here.
dteske [Thu, 7 Nov 2013 10:14:40 +0000 (10:14 +0000)]
Comments. Replace a funny syntax with f_isset() while here.

10 years agoWhitespace.
dteske [Thu, 7 Nov 2013 10:09:01 +0000 (10:09 +0000)]
Whitespace.

10 years ago- Use libusb20_strerror() function instead of custom usb_error() one.
hselasky [Thu, 7 Nov 2013 07:22:51 +0000 (07:22 +0000)]
- Use libusb20_strerror() function instead of custom usb_error() one.
- Rename "aux.[ch]" to "util.[ch]" which is a more common name for
utility functions and allows checkout on some non-FreeBSD systems
where the "aux.*" namespace is reserved.
- Fix some compile warnings while at it.

PR: usb/183728
MFC after: 2 weeks

10 years agoDo not build aicasm with the cross-tools/kernel-toolchain, instead add a
ian [Thu, 7 Nov 2013 04:31:21 +0000 (04:31 +0000)]
Do not build aicasm with the cross-tools/kernel-toolchain, instead add a
proper kernel-tools step/target modeled after the world build-tools stuff.

This is a re-do of r257730 which was backed out in r257734, but this time
it's one byte smaller... a leftover trailing backslash resulted in a .for
loop with no rules, so no compiler stuff got built and later steps built
with the wrong toolset.

10 years agoSwitch to the new common bus_space-v6.c, remove the local one.
ian [Thu, 7 Nov 2013 04:09:19 +0000 (04:09 +0000)]
Switch to the new common bus_space-v6.c, remove the local one.

10 years agoSwitch to the new common bus_space-v6.c, remove the local one.
ian [Thu, 7 Nov 2013 04:02:08 +0000 (04:02 +0000)]
Switch to the new common bus_space-v6.c, remove the local one.

10 years agoPropagate ancient fix from Junos.
sjg [Thu, 7 Nov 2013 00:36:39 +0000 (00:36 +0000)]
Propagate ancient fix from Junos.
Use of -h is not supposed to depend on AUTHENTICATION being defined.

Reviewed by: markm

10 years agocxgbe(4): Tidy up the display for payload memory statistics (pm_stats).
np [Thu, 7 Nov 2013 00:25:49 +0000 (00:25 +0000)]
cxgbe(4): Tidy up the display for payload memory statistics (pm_stats).

# sysctl -n dev.t4nex.0.misc.pm_stats
# sysctl -n dev.t5nex.0.misc.pm_stats

MFC after: 1 week

10 years ago* Use "math.h" instead of <math.h>.
kargl [Wed, 6 Nov 2013 23:44:52 +0000 (23:44 +0000)]
* Use "math.h" instead of <math.h>.
* Use bit twiddling.  This requires inclusion of math_private.h
  and inclusion of float.h in s_roundl.c.  Raise invalid exception.
* Use literal integer constants where possible.  Let the compiler
  do the appropriate conversion.
* In s_roundf.c, use an F suffix on float constants instead of
  promoting float to double and then converting the result back
  to float. In s_roundl.c, use an L suffix.
* In s_roundl.c, use the ENTERI and RETURNI macros.  This requires
  the inclusion of fpmath.h and on __i386__ class hardware ieeefp.h.

Reviewed by: bde

10 years agoFix powerd/states on AMD cpus. Resolves issues with system reporting:
sbruno [Wed, 6 Nov 2013 23:29:25 +0000 (23:29 +0000)]
Fix powerd/states on AMD cpus.  Resolves issues with system reporting:
hwpstate0: set freq failed, err 6

Tested on FX-8150 and others.

PR: 167018
Submitted by: avg
MFC after: 2 weeks

10 years agoFix an off-by-one error when iterating over the emulated PCI BARs.
neel [Wed, 6 Nov 2013 22:35:52 +0000 (22:35 +0000)]
Fix an off-by-one error when iterating over the emulated PCI BARs.

Submitted by: Tycho Nightingale (tycho.nightingale@pluribusnetworks.com)

10 years agothe number of slots used by a packet is NS_RFRAGS() not ns_cnt
luigi [Wed, 6 Nov 2013 21:42:58 +0000 (21:42 +0000)]
the number of slots used by a packet is NS_RFRAGS() not ns_cnt

10 years agoProvide compat layer for OSIOCAIFADDR.
glebius [Wed, 6 Nov 2013 19:46:20 +0000 (19:46 +0000)]
Provide compat layer for OSIOCAIFADDR.

10 years agoremove a debugging message
luigi [Wed, 6 Nov 2013 19:18:39 +0000 (19:18 +0000)]
remove a debugging message

10 years agomake it so that from/to can be missaligned as it can happen (the geli
jmg [Wed, 6 Nov 2013 19:14:49 +0000 (19:14 +0000)]
make it so that from/to can be missaligned as it can happen (the geli
regression manages to do it)...  We use a packed struct to coerce
gcc/clang into producing unaligned loads (there is not packed pointer
attribute, otherwise this would be easier)...

use _storeu_ and _loadu_ when using the structure is overkill...

be better at using types properly...  Since we allocate our own key
schedule and make sure it's aligned, use the __m128i type in various
arguments to functions...

clang ignores __aligned on prototypes and gcc errors on them, leave them
in comments to document that these function arguments are require to be
aligned...

about all that changes is movdqa -> movdqu from reading the diff of the
disassembly output...

Noticed by: symbolics at gmx.com
MFC after: 3 days

10 years agoFix a bug that resulted in spurious error message "f_media_shutdown_http:
dteske [Wed, 6 Nov 2013 18:43:16 +0000 (18:43 +0000)]
Fix a bug that resulted in spurious error message "f_media_shutdown_http:
not found" from /usr/libexec/bsdconfig/030.packages/packages.

10 years agoAdd support for dereferencing SRV records via f_host_lookup(). Takes the
dteske [Wed, 6 Nov 2013 18:26:38 +0000 (18:26 +0000)]
Add support for dereferencing SRV records via f_host_lookup(). Takes the
media choice into consideration for determining the appropriate SRV records
to query (e.g., _http._tcp, _ftp._tcp, _nfs.tcp, _nfs.udp, etc.).

10 years agoDon't return ENOBUFS if the transmit path handles the frame but queues it (eg in...
adrian [Wed, 6 Nov 2013 17:20:49 +0000 (17:20 +0000)]
Don't return ENOBUFS if the transmit path handles the frame but queues it (eg in power save.)

This is definitely an MFC candidate for 10.0-REL.

MFC after: 1 week

10 years agoAdd definition for the Atheros 8021 gigabit PHY.
nwhitehorn [Wed, 6 Nov 2013 16:28:26 +0000 (16:28 +0000)]
Add definition for the Atheros 8021 gigabit PHY.

MFC after: 1 week

10 years agoMake the powerpc dumpsys() more consistent with the other architectures.
jhibbits [Wed, 6 Nov 2013 15:56:03 +0000 (15:56 +0000)]
Make the powerpc dumpsys() more consistent with the other architectures.

MFC after: 10.0-RELEASE

10 years agoSwitch to using pkg(8) for the doc install in bsdinstall(8).
gjb [Wed, 6 Nov 2013 15:49:31 +0000 (15:49 +0000)]
Switch to using pkg(8) for the doc install in bsdinstall(8).
This also bootstraps the system with pkg(8) for future use.

PR: 183488
Submitted by: Joe Ennis
MFC after: 3 days
Sponsored by: The FreeBSD Foundation

10 years agoImplement a working write region function to speed up loading of the
hselasky [Wed, 6 Nov 2013 15:32:37 +0000 (15:32 +0000)]
Implement a working write region function to speed up loading of the
firmware. You can test this change by switching the "#if 1" statement
right above in the patched code to "#if 0" !

MFC after: 1 week

10 years agoAn addendum: it is possible, though of questionable utility, for a node
nwhitehorn [Wed, 6 Nov 2013 14:38:53 +0000 (14:38 +0000)]
An addendum: it is possible, though of questionable utility, for a node
to have no properties at all. Do the right thing in such cases.

10 years agoDo not panic if pmap_mincore() is called. This prevents crashing userland
nwhitehorn [Wed, 6 Nov 2013 14:36:38 +0000 (14:36 +0000)]
Do not panic if pmap_mincore() is called. This prevents crashing userland
binaries from bringing down the kernel.

MFC after: 3 days

10 years agoMake OF_nextprop() work correctly for FDT by using the libfdt
nwhitehorn [Wed, 6 Nov 2013 14:33:37 +0000 (14:33 +0000)]
Make OF_nextprop() work correctly for FDT by using the libfdt
fdt_next_property_offset() API. The old code would sometimes (e.g. on
the device tree supplied by the RB800 boot loader) get confused and stop
partway through listing properties.

MFC after: 1 week

10 years agoCheck for "ieee80211_vap_setup()" failure in all USB WLAN drivers.
hselasky [Wed, 6 Nov 2013 12:57:01 +0000 (12:57 +0000)]
Check for "ieee80211_vap_setup()" failure in all USB WLAN drivers.

MFC after: 1 week

10 years agoSwitch allwinner A10/A20 and rockchip ports to use common ARMv6/v7 bus_space tag.
ray [Wed, 6 Nov 2013 10:31:52 +0000 (10:31 +0000)]
Switch allwinner A10/A20 and rockchip ports to use common ARMv6/v7 bus_space tag.

Tested by: ganbold

10 years agoSwitch to use common ARMv6/v7 bus_space tag.
ray [Wed, 6 Nov 2013 09:44:32 +0000 (09:44 +0000)]
Switch to use common ARMv6/v7 bus_space tag.

Tested by: ian, ray

10 years agoAdd common bus_space tag definition shared for most supported ARMv6/v7 SoCs.
ray [Wed, 6 Nov 2013 09:41:19 +0000 (09:41 +0000)]
Add common bus_space tag definition shared for most supported ARMv6/v7 SoCs.

Tested by: ian, ray

10 years agoFix my braino in r257692. For SIOCG*ADDR we don't need exact match on
glebius [Wed, 6 Nov 2013 08:36:08 +0000 (08:36 +0000)]
Fix my braino in r257692. For SIOCG*ADDR we don't need exact match on
specified address, actually in most cases the address isn't specified.

Reported by: peter

10 years ago- Remove mac_get_fd/mac_set_fd - those are not syscalls. The __mac_get_fd() and
pjd [Wed, 6 Nov 2013 07:46:10 +0000 (07:46 +0000)]
- Remove mac_get_fd/mac_set_fd - those are not syscalls. The __mac_get_fd() and
  __mac_set_fd() syscalls are listed earlier.
- Correct typo in syscall name. It should be sched_rr_get_interval,
  not sched_rr_getinterval.

Submitted by: David Drysdale <drysdale@google.com>
MFC after: 3 days

10 years agoRemove the gross hack for the Octeon Simple Executive to the least
imp [Wed, 6 Nov 2013 05:26:15 +0000 (05:26 +0000)]
Remove the gross hack for the Octeon Simple Executive to the least
intrusive place for it to be: the octeon std file.
Fix a comment while I'm here.
Allow for future architectural specific flags.

Reviewed by: jmallet@

10 years agoRevert r257730:
gjb [Wed, 6 Nov 2013 04:38:49 +0000 (04:38 +0000)]
Revert r257730:
 Make head/ buildable again, instead of spewing garbage like:
 /src/gnu/lib/csu/../../../contrib/gcc/config/rs6000/crtsavres.asm:280:
  Error: no such instruction: `lwz 28,-16(11)'

10 years agoRevert r257691, r257645:
gjb [Wed, 6 Nov 2013 03:36:43 +0000 (03:36 +0000)]
Revert r257691, r257645:
 Let amd64/amd64 build again.

10 years agoReading the RT2860_ASIC_VER_ID register is not needed and returns
kevlo [Wed, 6 Nov 2013 02:49:16 +0000 (02:49 +0000)]
Reading the RT2860_ASIC_VER_ID register is not needed and returns
completely bogus value.

10 years agoFix build on GCC.
nwhitehorn [Wed, 6 Nov 2013 01:14:00 +0000 (01:14 +0000)]
Fix build on GCC.

10 years agoDo not build aicasm with the cross-tools/kernel-toolchain, instead add a
ian [Wed, 6 Nov 2013 00:32:40 +0000 (00:32 +0000)]
Do not build aicasm with the cross-tools/kernel-toolchain, instead add a
proper kernel-tools step/target modeled after the world build-tools stuff.

10 years agoAdd the VM name to the process name with setproctitle().
grehan [Wed, 6 Nov 2013 00:25:17 +0000 (00:25 +0000)]
Add the VM name to the process name with setproctitle().
Remove the VM name from some of the thread-naming calls
since it is now in the proc title.
Slightly modify the thread-naming for the net and block
threads.

This improves readability when using top/ps with the -a
and -H options on a system with a large number of bhyve VMs.

Requested by: Michael Dexter
Reviewed by: neel
MFC after: 4 weeks

10 years agoFix .Dd after r257646.
gjb [Tue, 5 Nov 2013 21:47:00 +0000 (21:47 +0000)]
Fix .Dd after r257646.
DST affects the day by one hour, but the number of days in the
week stay the same.

10 years agoDon't explicitly invoke ifn_start on new child interfaces (vaps and
jhb [Tue, 5 Nov 2013 19:49:53 +0000 (19:49 +0000)]
Don't explicitly invoke ifn_start on new child interfaces (vaps and
subinterfaces) after they are created.  Interfaces are already started
by devd invoking /etc/pccard_ether when they are created, so the explicit
calls in childif_create() resulted in interfaces being started twice.

Note that interfaces created via cloned_interfaces are not explicitly
started but depend on the devd mechanism already.

MFC after: 1 week

10 years agoFix build.
glebius [Tue, 5 Nov 2013 19:17:19 +0000 (19:17 +0000)]
Fix build.

Pointy hat to: glebius

10 years agoProtect the "ratectl_ch" callout in the "run" driver by the "run"
hselasky [Tue, 5 Nov 2013 18:27:25 +0000 (18:27 +0000)]
Protect the "ratectl_ch" callout in the "run" driver by the "run"
softc's "sc->sc_mtx" mutex. Currently the callout was marked
multi-processor safe, which is fine, but it is better to
start/stop/reset callouts while holding the "run" drivers own
mutex. While at it add a missing "ULL" at end of the 64-bit unsigned
integer constant.

MFC after: 1 week

10 years agoFix fallout from r257223. Since pf_test_state_icmp() can call
glebius [Tue, 5 Nov 2013 16:54:25 +0000 (16:54 +0000)]
Fix fallout from r257223. Since pf_test_state_icmp() can call
pf_icmp_state_lookup() twice, we need to unlock previously found state.

Reported & tested by: gavin

10 years agoClean up -Wtautological-compare -Wformat warnings.
pluknet [Tue, 5 Nov 2013 14:20:39 +0000 (14:20 +0000)]
Clean up -Wtautological-compare -Wformat warnings.

10 years agoAxe IFF_SMART.
glebius [Tue, 5 Nov 2013 14:11:31 +0000 (14:11 +0000)]
Axe IFF_SMART.

Submitted by: pluknet

10 years agoWhen writing DTS to a file, don't write some of it to stderr.
theraven [Tue, 5 Nov 2013 14:07:30 +0000 (14:07 +0000)]
When writing DTS to a file, don't write some of it to stderr.

Reported by: ray

10 years agoTeach nexus(4) about Open Firmware (e.g. FDT) on ARM and MIPS, retiring
nwhitehorn [Tue, 5 Nov 2013 13:48:34 +0000 (13:48 +0000)]
Teach nexus(4) about Open Firmware (e.g. FDT) on ARM and MIPS, retiring
fdtbus in most cases. This brings ARM and MIPS more in line with existing
Open Firmware platforms like sparc64 and powerpc, as well as preventing
double-enumeration of the OF tree on embedded PowerPC (first through nexus,
then through fdtbus).

This change is also designed to simplify resource management on FDT platforms
by letting there exist a platform-defined root bus resource_activate() call
instead of replying on fdtbus to do the right thing through fdt_bs_tag.
The OFW_BUS_MAP_INTR() and OFW_BUS_CONFIG_INTR() kobj methods are also
available to implement for similar purposes.

Discussed on: -arm, -mips
Tested by: zbb, brooks, imp, and others
MFC after: 6 weeks

10 years agoRemove condition which can never be true as the previous loop
bdrewery [Tue, 5 Nov 2013 13:36:05 +0000 (13:36 +0000)]
Remove condition which can never be true as the previous loop
is never exited while remote == NULL.

Reported by: Coverity
Approved by: bapt
MFC after: 2 days

10 years agoAxe IFF_SMART. Fortunately this layering violating flag was never used,
glebius [Tue, 5 Nov 2013 12:52:56 +0000 (12:52 +0000)]
Axe IFF_SMART. Fortunately this layering violating flag was never used,
it was just declared.

10 years agoDrop support for historic ioctls and also undefine them, so that code
glebius [Tue, 5 Nov 2013 10:29:47 +0000 (10:29 +0000)]
Drop support for historic ioctls and also undefine them, so that code
that checks their presence via ifdef, won't use them.

Bump __FreeBSD_version as safety measure.

10 years ago- Fix link loss on vlan reconfiguration.
oleg [Tue, 5 Nov 2013 09:46:01 +0000 (09:46 +0000)]
- Fix link loss on vlan reconfiguration.
- Fix issues with 'vlanhwfilter'.

MFC after: 1 week
Silence from: jfv 5 weeks

10 years agoRemove remnants of BIND from /etc, since there is no BIND in base now.
glebius [Tue, 5 Nov 2013 09:30:06 +0000 (09:30 +0000)]
Remove remnants of BIND from /etc, since there is no BIND in base now.

Sorry, that would break users running head and BIND from ports, since
ports rely on these scripts. The ports will be fixed soon.

Reviewed by: erwin

10 years agonetinet code no longer uses IFA_RTSELF.
glebius [Tue, 5 Nov 2013 07:45:20 +0000 (07:45 +0000)]
netinet code no longer uses IFA_RTSELF.

10 years agoRewrite in_control(), so that it is comprehendable without getting mad.
glebius [Tue, 5 Nov 2013 07:44:15 +0000 (07:44 +0000)]
Rewrite in_control(), so that it is comprehendable without getting mad.

o Provide separate functions for SIOCAIFADDR and for SIOCDIFADDR, with
  clear code flow from beginning to the end. After that the rest of
  in_control() gets very small and clear.
o Provide sx(9) lock to protect against parallel ioctl() invocations.
o Reimplement logic from r201282, that tried to keep localhost route in
  table when multiple P2P interfaces with same local address are created
  and deleted.

Discussed with: pluknet, melifaro
Sponsored by: Netflix
Sponsored by: Nginx, Inc.

10 years agoFix libgcc build with gcc after r257645, by using -Wno-static-in-inline
dim [Tue, 5 Nov 2013 07:37:35 +0000 (07:37 +0000)]
Fix libgcc build with gcc after r257645, by using -Wno-static-in-inline
for clang only.

10 years agoIn complemence to ifa_add_loopback_route() and ifa_del_loopback_route()
glebius [Tue, 5 Nov 2013 07:36:17 +0000 (07:36 +0000)]
In complemence to ifa_add_loopback_route() and ifa_del_loopback_route()
provide function ifa_switch_loopback_route() that will be used in case when
an interface address used for a loopback route goes away, but we have another
interface address with same address value and want to preserve loopback
route.

Sponsored by: Netflix
Sponsored by: Nginx, Inc.

10 years agoRemove net.link.ether.inet.useloopback sysctl tunable. It was always on by
glebius [Tue, 5 Nov 2013 07:32:09 +0000 (07:32 +0000)]
Remove net.link.ether.inet.useloopback sysctl tunable. It was always on by
default from the very beginning. It was placed in wrong namespace
net.link.ether, originally it had been at another wrong namespace. It was
incorrectly documented at incorrect manual page arp(8). Since new-ARP commit,
the tunable have been consulted only on route addition, and ignored on route
deletion. Behaviour of a system with tunable turned off is not fully correct,
and has no advantages comparing to normal behavior.

10 years agoAdd required kernel option.
glebius [Tue, 5 Nov 2013 06:44:33 +0000 (06:44 +0000)]
Add required kernel option.

10 years agoMFV of 255902, tzdata2013f
edwin [Tue, 5 Nov 2013 06:32:23 +0000 (06:32 +0000)]
MFV of 255902, tzdata2013f
MFV of 257651, tzdata2013h

tzdata2013f
- Jordan goes to winter time on the last Friday in October.
- Tocantins in Brazil will not go into summer time in October.
- Indonesian time zones renames.
- Lots of cleanups in with regarding to links and historical data.

tzdata2013h
- Libya didn't go back to DST.
- Fix Morocco 2038 issue.
- Brazil/Acre and Western Amazonas are chaning timezones.

10 years agoDo not coalesce if the swap object belongs to tmpfs vnode. The
kib [Tue, 5 Nov 2013 06:18:50 +0000 (06:18 +0000)]
Do not coalesce if the swap object belongs to tmpfs vnode.  The
coalesce would extend the object to keep pages for the anonymous
mapping created by the process.  The pages has no relations to the
tmpfs file content which could be written into the corresponding
range, causing anonymous mapping and file content aliasing and
subsequent corruption.

Another lesser problem created by coalescing is over-accounting on the
tmpfs node destruction, since the object size is substracted from the
total count of the pages owned by the tmpfs mount.

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

10 years agoUse suword32 and suword64 instead of copyout(9). This fixes a bug in the
markj [Tue, 5 Nov 2013 06:13:46 +0000 (06:13 +0000)]
Use suword32 and suword64 instead of copyout(9). This fixes a bug in the
emulation of the call instruction caused by reversing the uaddr and kaddr
arguments when copying data out to userland: the suword* functions take the
uaddr as the first argument whereas copyout(9) takes the kaddr as the first
argument. This also partially undoes the fixes from r257143.

Submitted by: Prashanth Kumar <pra_udupi@yahoo.co.in> (original version)
MFC after: 1 month

10 years agoRemove local devmap code and use the essentially identical common code
ian [Tue, 5 Nov 2013 05:18:18 +0000 (05:18 +0000)]
Remove local devmap code and use the essentially identical common code
that got moved from imx_machdep.c to arm/devmap.c.

10 years agoStyle and comment tweaks, no functional changes.
ian [Tue, 5 Nov 2013 05:01:46 +0000 (05:01 +0000)]
Style and comment tweaks, no functional changes.

10 years agoAdd new helper routines for arm static device mapping. The new code
ian [Tue, 5 Nov 2013 04:30:55 +0000 (04:30 +0000)]
Add new helper routines for arm static device mapping.  The new code
allocates kva space from the top down for the device mappings and builds
entries in an internal table which is automatically used later by
arm_devmap_bootstrap().  The platform code just calls the new
arm_devmap_add_entry() function as many times as it needs to (up to 32
entries allowed; most platforms use 2 or 3 at most).

There is also a new arm_devmap_lastaddr() function that returns the lowest
kva address allocated; this can be used to implement initarm_lastaddr()
which is used to initialize vm_max_kernel_address.

The new code is based on a similar concept developed for the imx family
SoCs recently.  They will soon be converted to use this new common code.

10 years agoMake PTE_DEVICE a synonym for PTE_NOCACHE on armv4, to make it easier to
ian [Tue, 5 Nov 2013 04:06:29 +0000 (04:06 +0000)]
Make PTE_DEVICE a synonym for PTE_NOCACHE on armv4, to make it easier to
share the same code on both architectures.