Commit Graph

192636 Commits

Author SHA1 Message Date
Ian Lepore
9cbece6f0d Stop setting the iomux device status to disabled, now that we have a driver. 2014-09-04 19:52:17 +00:00
Gleb Smirnoff
770aa6cb25 Satisfy assertion in m_demote().
Sponsored by:	Nginx, Inc.
2014-09-04 19:28:02 +00:00
Gleb Smirnoff
7ee2d05890 Change a very strange code in m_demote() to simple assertion.
Sponsored by:	Nginx, Inc.
2014-09-04 19:27:30 +00:00
John Baldwin
a7c7f2a7e2 In tcp_input(), don't acquire the pcbinfo global write lock for SYN
packets targeting a listening socket.  Permit to reduce TCP input
processing starvation in context of high SYN load (e.g. short-lived TCP
connections or SYN flood).

Submitted by:	Julien Charbon <jcharbon@verisign.com>
Reviewed by:	adrian, hiren, jhb, Mike Bentkofsky
2014-09-04 19:09:08 +00:00
Pedro F. Giffuni
9908eab82e libc/locale: Remove a wrong comma.
This only had some effect when debugging.

Obtained from:	DragonflyBSD
MFC after:	3 days
2014-09-04 17:36:21 +00:00
Stefan Eßer
a5f38972dc Fix debug output that has erroneously been committed with the last update.
Obtained from:	Jan Beich
MFC after:	3 days
2014-09-04 17:19:16 +00:00
Gleb Smirnoff
07e845a3f4 Fixes for tcp_respond() comment. 2014-09-04 17:05:57 +00:00
Warner Losh
3da47f7cad Wrap some long lines. 2014-09-04 16:40:54 +00:00
Ian Lepore
f8afe33355 Implement the imx_iomux_get/set_gpr() interface for imx6. 2014-09-04 15:11:57 +00:00
Ian Lepore
5a782ebbd8 The iomux driver is no longer optional, all imx platforms have it as
standard now, so remove it from kernel configs.
2014-09-04 14:59:27 +00:00
Ian Lepore
1b8950cfab Implement the same public interface in imx51 and imx6 iomux; use the common
header file for both.  Remove some unused code from imx51_iomux.  The iomux
drivers are required, not optional, adjust the files.* entries accordingly.
2014-09-04 14:57:04 +00:00
Roger Pau Monné
77b6916d2e Revert r269814: blkfront: add support for unmapped IO
Current busdma code for unmapped bios will not properly align the segment
size, causing corruption on blkfront devices. Revert the commit until
busdma code is fixed.

Reported by:	mav
MFC after:	1 day
2014-09-04 14:56:24 +00:00
John Baldwin
33a50f1b0f Merge the amd64 and i386 identcpu.c into a single x86 implementation.
This brings the structured extended features mask and VT-x reporting to
i386 and Intel cache and TLB info (under bootverbose) to amd64.
2014-09-04 14:26:25 +00:00
Ian Lepore
f5a76413fe Add a basic iomux driver for imx6.
Submitted by:	bsam@
2014-09-04 14:25:32 +00:00
Ian Lepore
4734ecbfec Fix typo in variable name. 2014-09-04 13:13:42 +00:00
Ruslan Bukin
9493c332a3 Add initial support for Altera SOCFPGA (heterogeneous ARM/FPGA) SoC family.
Include board configuration for Terasic SoCKit (Altera Cyclone V).

Sponsored by:	DARPA, AFRL
2014-09-04 12:44:40 +00:00
Gleb Smirnoff
ba32fcfff9 Improve r265338. When inserting mbufs into TCP reassembly queue,
try to collapse adjacent pieces using m_catpkt(). In best case
scenario it copies data and frees mbufs, making mbuf exhaustion
attack harder.

Suggested by:		Jonathan Looney <jonlooney gmail.com>
Security:		Hardens against remote mbuf exhaustion attack.
Sponsored by:		Netflix
Sponsored by:		Nginx, Inc.
2014-09-04 09:15:44 +00:00
Gleb Smirnoff
1967edba02 Provide m_catpkt(), a wrapper around m_cat() that deals with M_PKTHDR mbufs.
Sponsored by:	Netflix
Sponsored by:	Nginx, Inc.
2014-09-04 09:07:14 +00:00
Benno Rice
39a8d9f3f0 Systems with lots of geom providers can end up with a kern.geom.confxml
value too large for the buffer allocated. Work around this by retrying
a few times with larger buffer sizes.

Submitted by:	Scott Ferris <scott.ferris@isilon.com>
Reviewed by:	mlaier, ngie
Sponsored by:	EMC Isilon Storage Division
2014-09-04 03:31:48 +00:00
Ian Lepore
f214250a17 The imx5x and imx6 chips have an onboard IOMUX device which also contains a
few "general purpose registers" whose values control chip behavior in ways
that have nothing to do with IO pin mux control.  Define a simple API that
other soc-specific code can use to read and write the registers, and provide
the imx51 implementation of them.
2014-09-04 03:04:37 +00:00
John Baldwin
2352bbe4cd Remove a stray blank line from the Intel cache and TLB info. 2014-09-04 02:28:17 +00:00
John Baldwin
fe760cfa1a - Move blacklists of broken TSCs out of the printcpuinfo() function
and into the TSC probe routine.
- Initialize cpu_exthigh once in finishidentcpu() which is called
  before printcpuinfo() (and matches the behavior on amd64).
2014-09-04 02:25:59 +00:00
Glen Barber
f4d5538f79 Fix typo: s/_maske/_mask/
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2014-09-04 02:06:33 +00:00
John Baldwin
2b793beefd Remove trailing whitespace. 2014-09-04 01:56:15 +00:00
John Baldwin
7fb40488d6 - Move prototypes for various functions into out of C files and into
<machine/md_var.h>.
- Move some CPU-related variables out of i386/i386/identcpu.c to
  initcpu.c to match amd64.
- Move the declaration of has_f00f_hack out of identcpu.c to machdep.c.
- Remove a misleading comment from i386/i386/initcpu.c (locore zeros
  the BSS before it calls identify_cpu()) and remove explicit zero
  assignments to reduce the diff with amd64.
2014-09-04 01:46:06 +00:00
Mateusz Guzik
2570cdd605 Plug a hypothetical use after free in sysctl kern.proc.groups.
MFC after:	1 week
2014-09-04 01:21:33 +00:00
Pyun YongHyeon
1dc616851a Do not blindly announce 1000baseT half-duplex capability in
autonegotiation.  Some controllers like cgem(4) do not support
half-duplex at gigabit speeds.
2014-09-04 01:04:37 +00:00
Benno Rice
c079e1c018 Add KASSERTs to catch the case where a developer may have forgotten to
set bo_bsize on a bufobj.

This is a slight modification of the patch provided.

PR:		193146
Submitted by:	Conrad Meyer <conrad.meyer@isilon.com>
Sponsored by:	EMC Isilon Storage Division
2014-09-04 00:10:06 +00:00
Warner Losh
7dbf7f266c Create a /boot/dtb directory to house DTB blobs. The flattened device
tree support includes a device tree source compiler dtc(8) which
converts .dts files into .dtb files. /boot/loader will load dtb files
from this directory by default, allowing for fewer differences between
images for different SoCs. Compiled dts files will wind up here
eventually as an alternative to embedding them into the kernel.
Document this in hier(7), as well as add missing entries for
/boot/firmware and /boot/zfs, though the latter two should only be
considered place holders if someone wants to make them better.
2014-09-03 21:59:07 +00:00
Ian Lepore
f14514a385 Add a function to get the frequency of the AHB bus. Another stopgap
function until we have full clock support for imx6.
2014-09-03 21:45:39 +00:00
Ian Lepore
7a969f2e05 When built with FDT support, add /boot/dtb to the list of search directories. 2014-09-03 21:25:36 +00:00
John Baldwin
6f00c0f90f Actually save and restore FPU state on APs during suspend and resume.
Committed from:	Atom-based HP netbook after resuming in X
2014-09-03 21:17:09 +00:00
Ian Lepore
64e9597058 Remove DIAGNOSTIC from the kernel config of low-end arm systems. Sanity
checks such as vmem_check() can make a low-end system go completely
unresponsive for as much as 3 seconds out of every 10.
2014-09-03 19:37:41 +00:00
David E. O'Brien
d630b56d1a Note that script(1) consumes filemon(4). 2014-09-03 19:06:08 +00:00
John Baldwin
c3d1e48a6b Always seek back to the beginning of a regular directory, even if the
previous seek location was 0.  Without this, readdir() would see
dd_loc of zero and call getdirentries() which would start reading
entries at the current seek location of the directory ignoring the
first batch of entries.  Also, rewinddir() should always seek so that
it reads the directory from the beginning to get updated entries.

PR:		192935
Reported by:	iron@mail.ua
MFC after:	3 days
2014-09-03 19:01:34 +00:00
Ed Maste
e527e84592 Avoid ./ in zoneinfo entries in METALOG
Use of "find ." resulted in METALOG entries with an extra ./ -- e.g.,
./usr/share/zoneinfo/./America/Toronto.  Avoid this by using globbing
via "find *" instead.

Reviewed by:	brooks
Sponsored by:	DARPA, AFRL
Differential Revision: https://reviews.freebsd.org/D719
2014-09-03 18:51:33 +00:00
Ian Lepore
df63a5d236 Fixes and enhancements for the if_cgem driver...
- miibus fixes as suggested by Yonghyeon Pyun.
- enable VLAN MTU support.
- fix a few WITNESS complaints in cgem_attach().
- have cgem_attach() properly init the ifnet struct before calling
  mii_attach() to fix panic when using e1000phy.
- fix ethernet address changing.
- fix transmit queue overflow handling.
- tweak receive queue handling to reduce receive overflows.
- bring out MAC statistic counters to sysctls.
- add e1000phy to config file.
- implement receive hang work-around described in reference guide.
- change device name from if_cgem to cgem to be consistent with other
  interfaces.

Submitted by:	Thomas Skibo <ThomasSkibo@sbcglobal.net>
Reviewed by:	wkoszek, Yonghyeon PYUN <pyunyh@gmail.com>
2014-09-03 17:51:03 +00:00
Ian Lepore
73d4905348 Use sh -c '...' to launch the dtb build scripts with env stuff prepended,
otherwise it tries to treat the env var stuff as a script file name.
2014-09-03 17:32:17 +00:00
John Baldwin
d1e9f1a83e Import a hackish tool I use to examine the skew of the TSC across
CPUs in a system.  The tool queries the kernel for its set of CPUs
and compares TSC values on each of the additional CPUs to the first
CPU in turn.  It then outputs a table of simple statistics.
2014-09-03 17:26:46 +00:00
Glen Barber
b8b210c185 Update the autofs(5) manual to reflect it first appeared in
FreeBSD 10.1-RELEASE.

Submitted by:	dhw
MFC after:	3 days
Sponsored by:	The FreeBSD Foundation
2014-09-03 17:15:12 +00:00
Sean Bruno
91f270fbe5 Apparently, the patch commited in svn r271029 doesn't actually do anyting,
so we still need to modify the code in place. Pointed out by emaste.

MFC after:	2 days
Relnotes:	yes
2014-09-03 15:48:07 +00:00
Sean Bruno
f2f01deb91 Do not direct commit to contrib/llvm. Make the change a patch file instead.
Reverts 271025 but still functionally patches it.  Original intent is still
the same.  Pointed out by rdivacky.

MFV:  Only emit movw on ARMv6T2

Building for the FreeBSD default target ARMv6 was emitting movw ASM on certain
test cases (found building qmake4/5 for ARM).  Don't do that, moreover, the AS
in base doesn't understand this instruction for this target.  One would need
to use --integrated-as to get this to build if desired.

http://llvm.org/viewvc/llvm-project?view=revision&revision=216989

Submitted by:	ian
Reviewed by:	dim
Obtained from:	llvm.org
MFC after:	2 days
Relnotes:	yes
2014-09-03 15:32:38 +00:00
Pawel Jakub Dawidek
51d915e0d1 Use better type for i. 2014-09-03 15:08:33 +00:00
Pawel Jakub Dawidek
04cbbf596c Declare i.
Reported by:	sbruno
2014-09-03 15:06:47 +00:00
Pawel Jakub Dawidek
c7bf0f5006 Fix descriptors leak in case of nvlist_xunpack() failure.
Submitted by:	Mariusz Zaborski <oshogbo@FreeBSD.org>
2014-09-03 14:44:23 +00:00
Sean Bruno
d1b809ff9f MFV: Only emit movw on ARMv6T2
Building for the FreeBSD default target ARMv6 was emitting movw ASM on certain
test cases (found building qmake4/5 for ARM).  Don't do that, moreover, the AS
in base doesn't understand this instruction for this target.  One would need
to use --integrated-as to get this to build if desired.

http://llvm.org/viewvc/llvm-project?view=revision&revision=216989

Submitted by:	ian
Reviewed by:	dim
Obtained from:	llvm.org
MFC after:	2 days
2014-09-03 14:16:50 +00:00
Hans Petter Selasky
6301574838 Fix spelling.
PR:		193279
MFC after:	1 week
2014-09-03 13:15:16 +00:00
Hans Petter Selasky
7b520cfbc5 Add new quirk.
PR:		193279
MFC after:	1 week
2014-09-03 11:46:43 +00:00
Alexander V. Chernikov
5c02a66b2b * Unconditionally turn on SIOCGI2C probing for all interfaces
on "ifconfig -v". I've seen no measurable timing difference
    for doing additional SIOCGI2C call for system with 4k vlans.
* Determine appropriate handler (SFP/QSFP) by reading identification
    byte (which is the same for both SFF-8472 and SFF-8436) instead
   of checking driver name.

MFC with:	r270064
Sponsored by:	Yandex LLC
2014-09-03 11:07:49 +00:00
Gleb Smirnoff
6b17688b56 Remove always false comparison.
Sponsored by:	Nginx, Inc.
2014-09-03 09:58:59 +00:00