Commit Graph

216604 Commits

Author SHA1 Message Date
Ruslan Bukin
32797df534 Add different libc ldscript: the one without libssp --
we don't have it when MK_SSP==no.

This fixes compilation on MIPS.

Reviewed by:	imp
Sponsored by:	DARPA, AFRL
Sponsored by:	HEIF5
Differential Revision:	https://reviews.freebsd.org/D8212
2016-10-12 13:19:21 +00:00
Ed Maste
c874ff0f63 Use M_WAITOK in PIO_KEYMAP ioctl
The malloc return value is not checked.

Submitted by:	CTurt <ecturt@gmail.com>
MFC after:	1 week
2016-10-12 12:56:18 +00:00
Andriy Gapon
7c942547f2 remove a few stray spaces from sys/param.h 2016-10-12 11:17:10 +00:00
Andriy Gapon
32fdc4184a bump __FreeBSD_version for libzfs_core.h 2016-10-12 11:12:31 +00:00
Alexander Motin
25ee4c0429 Use copyout() instead of pointing sbuf to user-space buffer.
MFC after:	2 weeks
2016-10-12 08:25:13 +00:00
Andriy Gapon
dca5dd6894 install header files required development with libzfs_core
libzfs_core provides a rather limited but committed (stable) interface
for working with ZFS.  We install libzfs_core shared library but we do
not install header files required for developing programs that use
the library.  This change is to install the required header files
libzfs_core.h, libnvpair.h and sys/nvpair.h.

The headers are installed into the same locations as on illumos.

Reviewed by:	mav, markj
Differential Revision: https://reviews.freebsd.org/D8005
2016-10-12 07:08:32 +00:00
Andriy Gapon
94dce59911 smbus: allow child devices to be added via hints
This will allow to add slave drivers in the same fashion as for iicbus.

Also, allow other code to add a child device and set its 'addr' ivar.
The ivar can only be set if it's unset, it can not be changed.
That could be used, for example, by a platform driver that has
a precise description of the hardware and, thus, knows what drivers
can handle what slaves.

The slave auto-probing code is unsafe and broken because it uses
7-bit slave addresses.  It's going to be removed.

Note: internally the driver uses address of zero as an unset address
while smbus_get_addr() returns it as -1 for compatibility reasons.
The address is expected to be unset only for children that do not
work with slaves like, for example, smb(4).

Reviewed by:	jhb
Differential Revision: https://reviews.freebsd.org/D8173
2016-10-12 06:58:01 +00:00
Oleksandr Tymoshenko
0e3cfd98fc Fix typo in comment
Spotted by: loos
2016-10-12 05:35:57 +00:00
Oleksandr Tymoshenko
bf798f819a Make BCM28x USB driver compatible with upstream device tree
This should have been committed in r307093: resource allocation depends
on source of the device tree. upstream dts has extra interrupt that we can
ignore
2016-10-12 03:36:46 +00:00
Oleksandr Tymoshenko
79f6c27f4c Make VCHI driver compatible with upstream DT
- Add compatibility string
- Compensate difference in base address between our custom DTB and upstream one
2016-10-12 03:08:58 +00:00
Oleksandr Tymoshenko
43be86e31b Make BCM283x USB driver compatible with upstream DT
- Make resource allocation logic depend on compatibility string
    to check what format of DTS node should be used - FreeBSD's or upstream
2016-10-12 03:07:49 +00:00
Oleksandr Tymoshenko
aa2959bae5 Make BCM2835 GPIO driver compatible with upstream DT
- Add compatibility string
- Make reserverd and read-only properties optional
2016-10-12 03:06:05 +00:00
Oleksandr Tymoshenko
38e62ae597 Add compatibility string from upstream DT 2016-10-12 03:03:55 +00:00
Oleksandr Tymoshenko
5a715e8aa2 Make framebuffer driver compatible with upstream DT
- Add compatibility string
- Add simplebus as possible parent bus
2016-10-12 03:03:05 +00:00
Oleksandr Tymoshenko
9d6eb8bb3d Add compatible strings used in upstream dts files 2016-10-12 03:00:42 +00:00
Oleksandr Tymoshenko
511bc527ff Make sure intc is attached before interrupt consumers
If pass order is not specified devices are attached in the order they are
defined in dts. Some interrupt consumers may be defined before intc. Also
make sure intc interrupt-parent local_intc is attached before intc itself.
2016-10-12 02:58:27 +00:00
Jonathan T. Looney
4527476029 Currently, when tcp_input() receives a packet on a session that matches a
TCPCB, it checks (so->so_options & SO_ACCEPTCONN) to determine whether or
not the socket is a listening socket. However, this causes the code to
access a different cacheline. If we first check if the socket is in the
LISTEN state, we can avoid accessing so->so_options when processing packets
received for ESTABLISHED sessions.

If INVARIANTS is defined, the code still needs to access both variables to
check that so->so_options is consistent with the state.

Reviewed by:	gallatin
MFC after:	1 week
Sponsored by:	Netflix
2016-10-12 02:30:33 +00:00
Jonathan T. Looney
bd79708dbf In the TCP stack, the hhook(9) framework provides hooks for kernel modules
to add actions that run when a TCP frame is sent or received on a TCP
session in the ESTABLISHED state. In the base tree, this functionality is
only used for the h_ertt module, which is used by the cc_cdg, cc_chd, cc_hd,
and cc_vegas congestion control modules.

Presently, we incur overhead to check for hooks each time a TCP frame is
sent or received on an ESTABLISHED TCP session.

This change adds a new compile-time option (TCP_HHOOK) to determine whether
to include the hhook(9) framework for TCP. To retain backwards
compatibility, I added the TCP_HHOOK option to every configuration file that
already defined "options INET". (Therefore, this patch introduces no
functional change. In order to see a functional difference, you need to
compile a custom kernel without the TCP_HHOOK option.) This change will
allow users to easily exclude this functionality from their kernel, should
they wish to do so.

Note that any users who use a custom kernel configuration and use one of the
congestion control modules listed above will need to add the TCP_HHOOK
option to their kernel configuration.

Reviewed by:	rrs, lstewart, hiren (previous version), sjg (makefiles only)
Sponsored by:	Netflix
Differential Revision:	https://reviews.freebsd.org/D8185
2016-10-12 02:16:42 +00:00
Sepherosa Ziehau
368bf0c2c6 ifnet: Use if_link_state snapshot to invoke ifnet_link_event
So that everyone in this task have consistent view of link state.

Reviewed by:	ae
MFC after:	1 week
Sponsored by:	Microsoft
Differential Revision:	https://reviews.freebsd.org/D8214
2016-10-12 01:52:29 +00:00
Ed Maste
2a059700b6 Use correct size type in do_setopt_accept_filter
Submitted by:	ecturt@gmail.com
2016-10-12 00:56:49 +00:00
Jonathan Anderson
808b18e4d6 Extract suffix rules into bsd.suffixes[-posix].mk.
Refactor make suffix rules into separate files (one for POSIX and one not),
and rationalise the rules so that bsd.lib.mk can contain only those rules
that are library-specific (.c.po and .c.pico).

This can be accomplished by adding ${STATIC_CFLAGS} to the .c.o rule
unconditionally. STATIC_CFLAGS are only defined for use by sys.mk rules in
lib/libpam/Makefile.inc (see r227797), so it should be safe to include
them unconditionally in sys.mk's .c.o rule (tested by make universe and a
ports exp-run).

Reviewed by:	bdrewery, sjg
Approved by:	rwatson (mentor)
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D6805
2016-10-12 00:42:46 +00:00
Warner Losh
943ac2b07e Include stubs even on the platforms we don't support so libsysdecode
continues to build.
2016-10-11 22:54:29 +00:00
Warner Losh
852dd45ebc Properly include the 802.11n PHY support files when the BWM_GPL_PHY
option is included. Remove the comment suggesting that people
uncomment things because it is OBE.
2016-10-11 22:32:12 +00:00
Warner Losh
4b844f8d99 Add efivar(1) to manipulate EFI variables. It uses a similar command
line interface to the Linux program, as well as adding a number of
useful features to make using it in shell scripts easier (since we
don't have a filesystem to fall back on interacting with).

Differential Revision: https://reviews.freebsd.org/D8128
Reviewed by: kib@, wblock@, Ganael Laplanche
2016-10-11 22:31:45 +00:00
Warner Losh
d49a5ddd04 Create libefivar library. This library aims to provide
the same API as the GPL'd version of this library. It implements the common
Linux API for programatically manipulating UEFI environment varibales using
the UEFI Runtime Services the kernel provides. It replaces the old efi
library since it is programmed to a different interface, but retails the
CHAR16 to UTF-8 and vice versa conversion routines. The new name is to match
Linux program's expectations.

Differential Revision: https://reviews.freebsd.org/D8128
Reviewed by: kib@, wblock@, Ganael Laplanche
2016-10-11 22:30:41 +00:00
Warner Losh
f79d484dff Create /dev/efidev to provide an ioctl interface to
userland.  It supports userland interfaces to UEFI Runtime Services. This is
indended to the the MI portion of EFI RuntimeServices support.

Differential Revision: https://reviews.freebsd.org/D8128
Reviewed by: kib@, wblock@, Ganael Laplanche
2016-10-11 22:24:30 +00:00
Oleksandr Tymoshenko
58a3e50de6 Make Rapsberry Pi watchdog driver compatible with upstream DTS
- Fix compatibility strings
- Compensate the difference in base address for our custom DTS and
    upstream one (for backward compatibility)
2016-10-11 21:40:15 +00:00
Oleksandr Tymoshenko
98884a9ea9 Make intc driver compatible with upstream DTS
- Fix compatibility strings
- Properly decode upstream's two-cell interrupt specs. Our home-made dts
    does not have two-cell interrupts so no need to preserve backward
    compatibility
2016-10-11 21:37:34 +00:00
Ruslan Bukin
fae95359ee Don't use fmaxl/fminl on platforms with no long double support,
use fmax/fmin instead.

This fixes fmaxmin test failure on MIPS64.

Reviewed by:	emaste
Sponsored by:	DARPA, AFRL
Sponsored by:	HEIF5
Differential Revision:	https://reviews.freebsd.org/D8216
2016-10-11 20:31:59 +00:00
Konstantin Belousov
267ed8e2f7 When downgrading exclusively busied page to shared-busy state, wakeup
waiters.  Otherwise, owners of the shared-busy state are left blocked
and might get into a deadlock.

Note that the vm_page_busy_downgrade() function is not used in the
tree right now.

Reported and tested by:	pho (previous version)
Reviewed by:	alc, markj
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Differential revision:	https://reviews.freebsd.org/D8195
2016-10-11 18:09:37 +00:00
Andrey V. Elsukov
199511bcdd Make LLTABLE list lock private for if_llatbl.c
Rename lock and macros to reflect that it protects V_lltables list.
2016-10-11 17:41:13 +00:00
John Baldwin
9ba323071d Fix printf format warning. 2016-10-11 17:11:17 +00:00
Oleksandr Tymoshenko
609b0fe966 INTRNG - fix MSI/MSIX release path
Use isrc in attached MSI data structure instead of using map's
isrc directly. map's isrc is set to NULL on IRQ deactivation
which happens prior to pci_release_msi so MSI_RELEASE_MSI
receives array of NULLs

Reviewed by:	mmel
Differential Revision:	https://reviews.freebsd.org/D8206
2016-10-11 17:00:29 +00:00
George V. Neville-Neil
956c2a73cd Corrected non-portable reuse of va_list in dt_printf()
Submitted by:	Graeme Jenkinson
Reviewed by:	markj
MFC after:	2 weeks
Sponsored by:	DARPA, AFRL
Differential Revision:	https://reviews.freebsd.org/D8157
2016-10-11 16:12:12 +00:00
Konstantin Belousov
c3ad6e4f3e Remove mqtest{3,4} from the obsoleted list.
Reported by:	O. Hartmann <ohartman@zedat.fu-berlin.de>
Sponsored by:	The FreeBSD Foundation
MFC after:	3 days
2016-10-11 15:55:45 +00:00
Alexander Motin
7061250472 Fix copy/paste bug in r306747.
Submitted by:	emaste, pfg
MFC after:	3 days
2016-10-11 15:27:39 +00:00
Sean Bruno
1ee17b070d Fix bug where malloc(.., M_NOWAIT) return value is not checked, Change to
M_WAITOK and move outside the mutex

Submitted by:	shurd
Reviewed by:	mmacy@nextbsd.org
MFC after:	2 weeks
Differential Revision:	https://reviews.freebsd.org/D7649
2016-10-11 14:08:53 +00:00
Ed Maste
0140799acb Add Cavium sponsor entity 2016-10-11 13:30:39 +00:00
Andrew Rybchenko
b36a7ad2c9 sfxge(4): update external port mapping for Medford
Extend the mapping table for external port numbering to support port modes
which output to the second external port only. Where supported, map from
the current port mode rather than inferring from all the available modes.
Updated comments for clarity.

Submitted by:   Richard Houldsworth <rhouldsworth at solarflare.com>
Sponsored by:   Solarflare Communications, Inc.
MFC after:      2 days
Differential Revision:  https://reviews.freebsd.org/D8210
2016-10-11 13:08:48 +00:00
Konstantin Belousov
6886c70100 Correct indent.
Sponsored by:	The FreeBSD Foundation
MFC after:	3 days
2016-10-11 11:46:02 +00:00
Konstantin Belousov
c3b83049d6 Fill msg_len for the initial element of msgvec.
Submitted by:	Daniel Salzman <daniel.salzman@nic.cz>
MFC after:	3 days
2016-10-11 11:45:12 +00:00
Sepherosa Ziehau
4afe249835 hyperv/hn: Rework link status support.
This is the preamble for network device SR-IOV and
NDIS_STATUS_NETWORK_CHANGE handling.

MFC after:	1 week
Sponsored by:	Microsoft
Differential Revision:	https://reviews.freebsd.org/D8209
2016-10-11 02:54:56 +00:00
Sepherosa Ziehau
cca23e7c3c hyperv/vmbus: Allow driver to inject synchronous task into channel taskq.
MFC after:	1 week
Sponsored by:	Microsoft
Differential Revision:	https://reviews.freebsd.org/D8208
2016-10-11 02:43:23 +00:00
Navdeep Parhar
eb46c98711 Add the ability to override the size of the swap partition when building
VM images.  The default continues to be 1G.

Reviewed by:	gjb@
Sponsored by:	Chelsio Communications
2016-10-10 22:36:44 +00:00
Ed Maste
b422efa4c1 makewhatis: make output reproducible
The mandoc search database generation uses each page's inode number as
a hash key to index hard linked pages only once.  However, it also
processed the pages ordered by hash key resulting in effectively non-
deterministic output.

Instead:

1) provide fts_open() with a comparison function to process directories
   and files in a deterministic order
2) in addition to the existing hash, insert pages into a linked list
   which will be sorted (by virtue of 1)
3) iterate over pages by the list in 2, instead of hash order

I will work on upstreaming this change.

Reviewed by:	bapt
MFC after:	1 month
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D8213
2016-10-10 19:09:35 +00:00
Maxim Konovalov
adc6d59b9d FreeBSD 11.0 release date added. 2016-10-10 18:36:26 +00:00
Andriy Voskoboinyk
6e970b4d75 Add missing *.gz extension. 2016-10-10 17:18:23 +00:00
Andriy Voskoboinyk
1af4a58503 mbuf(9), mbuf_tags(9): fix function prototypes.
- Add m_getclr(9) symlink to ObsoleteFiles.inc (removed in r295481).
- Add const qualifiers in m_dup(), m_dup_pkthdr() and m_tag_copy_chain()
(r286450).
- Fix m_dup_pkthdr() definition (it's not the same as m_move_pkthdr()).

MFC after:	5 days
2016-10-10 17:16:02 +00:00
John Baldwin
f45a6fb935 Add a missing word.
MFC after:	1 month
2016-10-10 17:00:12 +00:00
Ed Maste
96f1cff18b src.conf.5: regen after r306965 2016-10-10 15:47:30 +00:00