Commit Graph

203191 Commits

Author SHA1 Message Date
Alan Somers
fac7bc2365 Serve /etc/eui64 via NIS.
The C library already knows how to lookup eui64 entries from NIS. For
example, fwcontrol(8) does it. But /var/yp/Makefile.dist doesn't build the
eui64 maps, and ypinit(8) doesn't push them to slaves. This change fixes
that.

Reviewed by:	brooks, wblock
MFC after:	2 weeks
Sponsored by:	SpectraLogic Corp
Differential Revision:	https://reviews.freebsd.org/D3404
2015-08-18 15:33:23 +00:00
Pedro F. Giffuni
b542033478 Calendar: add a few more dates to the Christian calendar
The many christian denominations have different dates for their
celebrations and controversies are likely to be always.

These are well established and happen to be holidays in many
Catholic countries.

MFC after:	1 month
2015-08-18 15:11:41 +00:00
Fabien Thomas
078246e50f Add ichwd TCO version 3 support (Bay Trail / Rangeley...)
Reviewed by: jhb
Obtained from: Cas-well
Sponsored by: Stormshield
2015-08-18 14:54:29 +00:00
Andriy Gapon
a4b6d5e128 5692 expose the number of hole blocks in a file
illumos/illumos-gate@2bcf0248e9

https://www.illumos.org/issues/5692
we would like to expose the number of hole (sparse) blocks in a file. this
can be useful to for example if you want to fill in the holes with some
data; knowing the number of holes in advances allows you to report progress
on hole filling. We could use SEEK_HOLE to do that but it would be O(n)
where n is the number of holes present in the file.

Author: Max Grossman <max.grossman@delphix.com>
Reviewed by: Adam Leventhal <ahl@delphix.com>
Reviewed by: Matthew Ahrens <mahrens@delphix.com>
Reviewed by: Boris Protopopov <bprotopopov@hotmail.com>
Approved by: Richard Lowe <richlowe@richlowe.net>
2015-08-18 14:10:04 +00:00
Tai-hwa Liang
0b81f3161f Using consistent coding style to deal with error inside the loop.
MFC after:	1 week
2015-08-18 13:16:23 +00:00
Tai-hwa Liang
076cf2dd66 Using the error return code documented in the comment.
Though there is no direct midi_uninit() caller amongst existing drivers
at this moment, a quick experiment indicates that EBUSY gives users more
precise error message once drivers start to honour this result.  For example,
emu_midi_detach() should check the result of mpu401_uninit() and block
module unloading if there is any MIDI I/O in progress.

MFC after:	2 weeks
2015-08-18 13:16:06 +00:00
Tai-hwa Liang
7cbd5add2f Fixing typo as well as improving readability of a few comments.
MFC after:	3 days
2015-08-18 12:50:46 +00:00
Christian Brueffer
520bb99704 RIP Stefan Farfeleder (stefanf), committer since 2004.
You will be missed!
2015-08-18 12:27:21 +00:00
Ed Maste
8d5bb77429 Correct comment typo noted by erik 2015-08-18 11:52:45 +00:00
Julien Charbon
a1e6f8ff27 callout_stop() should return 0 (fail) when the callout is currently
being serviced and indeed unstoppable.

A scenario to reproduce this case is:

- the callout is being serviced and at same time,
- callout_reset() is called on this callout that sets
  the CALLOUT_PENDING flag and at same time,
- callout_stop() is called on this callout and returns 1 (success)
  even if the callout is indeed currently running and unstoppable.

This issue was caught up while making r284245 (D2763) workaround, and
was discussed at BSDCan 2015.  Once applied the r284245 workaround
is not needed anymore and will be reverted.

Differential Revision:	https://reviews.freebsd.org/D3078
Reviewed by:		jhb
Sponsored by:		Verisign, Inc.
2015-08-18 10:15:09 +00:00
Ed Maste
5a060174cd Remove register dump from arm64 el0 unknown exception
An exception with an unknown reasion is the expected result of the
attempted execution of an instruction bit pattern that has no allocated
instruction.

Sponsored by:	The FreeBSD Foundation
2015-08-18 10:07:03 +00:00
Jason Evans
d8e39d2d4f Re-add LG_SIZEOF_PTR definition for __aarch64__.
This definition was erroneously removed during the 4.0.0 import.
2015-08-18 09:09:27 +00:00
Jason Evans
0ba74efb31 Bump __FreeBSD_version for the jemalloc 4.0.0 import. 2015-08-18 08:29:13 +00:00
Julien Charbon
31a7749d4b Make clear that TIME_WAIT timeout expiration is managed solely by
tcp_tw_2msl_scan().

Sponsored by:	Verisign, Inc.
2015-08-18 08:27:26 +00:00
Jason Evans
902d2afd2a Add missing sdallocx updates and remove *allocm manpage links.
Submitted by:	jbeich
2015-08-18 08:18:28 +00:00
Jason Evans
a4cee496bc Fix build failure due to missing CPU_SPINWAIT definition. 2015-08-18 08:10:46 +00:00
Jason Evans
8d13fecf5f Add jemalloc support for 8 KiB, 16 KiB, and 64 KiB pages. 2015-08-18 06:28:37 +00:00
Alexander V. Chernikov
0c4210f984 Fix panic when handling non-inet arp message introduced in r286825.
Submitted by:	delphij
2015-08-18 06:16:19 +00:00
Marcel Moolenaar
4a99d3f571 Add 24 more page table pages we allocate on boot-up. 16MB slop
is a little tight in and by itself, but severily insufficient
when one needs to map a large frame buffer as part of console
initialization. 64MB slop should be enough for a while. As an
example: a 15" MacBook Pro with retina display needs ~28MB of
KVA for the frame buffer.

PR:		193745
2015-08-18 01:53:41 +00:00
Marcel Moolenaar
ec6b1f6acc Support frame buffers that are larger than the default screen
size as defined by VT_FB_DEFAULT_WIDTH and VT_FB_DEFAULT_HEIGHT
(at this time 2048x1200). The default is really a max. We cap
the height and width to those defaults and position the screen
in the center of the frame buffer.

Ideally we use a bigger font to utility the entire real estate
that is the frame buffer, but that's seen as an improvement over
making it work first.

PR:		193745
2015-08-18 00:47:02 +00:00
Jason Evans
d0e79aa362 Update jemalloc to version 4.0.0. 2015-08-18 00:21:25 +00:00
Adrian Chadd
2cb71df183 Convert more ifp->if_softc -> ic->ic_softc.
These should be a big no-op.

Tested:

* make universe
2015-08-17 23:44:38 +00:00
Adrian Chadd
122d43f3fb Migrate ifp->if_softc -> ic->ic_softc.
Tested:

* Lenovo T400 (Intel 5300)
* make universe
2015-08-17 23:35:31 +00:00
Ed Maste
5e3cac3e57 On arm64 disable three tests that hang or panic
Each issue has a PR open to track. This workaround allows us to run the
tests to investigate the failures and avoid any new regressions.

PR:		202304, 202305, 202307
Reviewed by:	ngie
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D3378
2015-08-17 23:19:36 +00:00
Luiz Otavio O Souza
f2fc809dcd Fix the copy of addresses passed from userland in table replace command.
The size2 is the maximum userland buffer size (used when the addresses are
copied back to userland).

Obtained from:	pfSense
MFC after:	3 days
Sponsored by:	Rubicon Communications (Netgate)
2015-08-17 23:03:54 +00:00
John Baldwin
e462b12755 Use an xlat table and xlookup() instead of a home-rolled version for the
sigprocmask operation type.
2015-08-17 19:08:48 +00:00
John Baldwin
fb7eabb0bf Tidy the linux_socketcall decoding:
- Don't exit if get_struct() fails, instead print the raw pointer value to
  match all other argument decoding cases.
- Use an xlat table instead of a home-rolled switch for the operation name.
- Display the nested socketcall args structure as a structure instead of as
  two inline arguments.
2015-08-17 18:47:39 +00:00
Konstantin Belousov
7a39d38dbd XEN/amd64 may initiate i/o over the pages not mapped by the direct
map.  Handle busdma bouncing and ata PIO accesses by using global
frame used by the current CPU locally for the duration of
pmap_quick_enter/remove_page().  A spin mutex protects the concurent
frame use and prevents thread migration.

Noted by:	royger
Reviewed by:	alc, jah, royger (previous version)
Sponsored by:	The FreeBSD Foundation
2015-08-17 18:42:45 +00:00
Jason A. Harmening
9b0ffde9e8 Some cleanups to make the style of pmap_quick_enter_page() and pmap_quick_remove_page() in arm/pmap-v6-new.c more consistent with the rest of the file.
Submitted by:	Svatopluk Kraus <onwahe@gmail.com>
Approved by:	kib (mentor)
2015-08-17 18:28:40 +00:00
John Baldwin
c9c2e2dc06 Decode the optional SOCK_NONBLOCK and SOCK_CLOEXEC flags passed in a
socket type.
2015-08-17 17:57:01 +00:00
John Baldwin
b289a8d78a - Decode the arguments for several signal-related system calls: sigpending,
sigqueue, sigreturn, sigsuspend, sigtimedwait, sigwait, sigwaitinfo, and
  thr_kill.
- Print signal sets as a structure (with {}'s) and in particular use this to
  differentiate empty sets from a NULL pointer.
- Decode arguments for some other system calls: issetugid, pipe2, sysarch
  (operations are only decoded for amd64 and i386), and thr_self.
2015-08-17 17:52:28 +00:00
Luiz Otavio O Souza
e9aebbb018 gpioled(4) depends on gpiobus.
This fixes the loading of gpioled as a module.

Sponsored by:	Rubicon Communications (Netgate)
2015-08-17 17:09:57 +00:00
Luiz Otavio O Souza
1dd2aa86b9 Fix the build of gpiobus as a module.
Add the missing newbus interfaces and gpioc, which is part of basic gpiobus
framework.

Sponsored by:	Rubicon Communications (Netgate)
2015-08-17 17:01:26 +00:00
Luiz Otavio O Souza
978cdbedcd Fix a few bugs when gpiobus is detaching:
- Detach the gpiobus and the gpioc devices from the GPIO controller.

 - Fix the leak of gpiobus IRQ rman(9) region descriptor.

 - Fix the leak of child ivars and IRQ resource list.

While here return NULL (instead of 0) for a device_t that fails to allocate
the ivar memory.

Tested with gpiobus built as a module.

Sponsored by:	Rubicon Communications (Netgate)
2015-08-17 16:51:37 +00:00
Ed Schouten
edcf7fbf59 Don't forget to invoke pre_execve() and post_execve().
CloudABI's proc_exec() was implemented before r282708 introduced
pre_execve() and post_execve(). Sync up by adding these missing calls.
2015-08-17 13:07:12 +00:00
Ed Maste
084748985d Separate ELFTOOLCHAIN_BOOTSTRAP from BINUTILS_BOOTSTRAP
For most cases they are equivalent, but BINUTILS_BOOTSTRAP is a
BROKEN_OPTION on arm64 as the in-tree GNU binutils do not support it,
so we need a separate internal flag for ELF Tool Chain.

Reviewed by:	andrew, brooks
Sponsored by:	The FreeBSD Foundation
Differential Revision:	https://reviews.freebsd.org/D3381
2015-08-17 10:48:55 +00:00
Gleb Smirnoff
5041118435 Belatedly fix documentation on which interface to use as argument. 2015-08-17 09:18:54 +00:00
Mark Murray
646041a89a Add DEV_RANDOM pseudo-option and use it to "include out" random(4)
if desired.

Retire randomdev_none.c and introduce random_infra.c for resident
infrastructure. Completely stub out random(4) calls in the "without
DEV_RANDOM" case.

Add RANDOM_LOADABLE option to allow loadable Yarrow/Fortuna/LocallyWritten
algorithm.  Add a skeleton "other" algorithm framework for folks
to add their own processing code. NIST, anyone?

Retire the RANDOM_DUMMY option.

Build modules for Yarrow, Fortuna and "other".

Use atomics for the live entropy rate-tracking.

Convert ints to bools for the 'seeded' logic.

Move _write() function from the algorithm-specific areas to randomdev.c

Get rid of reseed() function - it is unused.

Tidy up the opt_*.h includes.

Update documentation for random(4) modules.

Fix test program (reviewers, please leave this).

Differential Revision:    https://reviews.freebsd.org/D3354
Reviewed by:              wblock,delphij,jmg,bjk
Approved by:              so (/dev/random blanket)
2015-08-17 07:36:12 +00:00
Peter Grehan
7a40703db9 Add simple (no-op) emulations for the CHECK_POWER_MODE,
READ_VERIFY and READ_VERIFY_EXT commands.

Reviewed by:	mav
2015-08-17 05:59:36 +00:00
Peter Grehan
949856d8d7 Add define for SATA Check-Power-Mode command, 0xe5. 2015-08-17 05:56:41 +00:00
Xin LI
e370f90a60 so_vnet is constant after creation and no locking is necessary,
document this fact.

(netmap have an assignment too but that socket object is on stack).

MFC after:	2 weeks
2015-08-17 05:53:37 +00:00
Adrian Chadd
3797bf0896 Remove most of the references of ifp->if_softc and replace with
references to ic->ic_softc.

This is in preparation for gleb's ifnet work.

Tested:

* ath(4), STA mode
* ath(4), hostap mode
* make universe
2015-08-17 02:04:11 +00:00
Xin LI
1ae1bd497f Use arc4random_buf(). While there, unifdef the code for HAVE_ARC4RANDOM.
MFC after:	2 weeks
2015-08-16 23:23:58 +00:00
Sean Bruno
7c669ab6cc Bump all copywrite dates to 2015
Differential Revision:	https://reviews.freebsd.org/D3160
Submitted by:	erj
MFC after:	2 weeks
Sponsored by:	Intel Corportation
2015-08-16 20:13:58 +00:00
Sean Bruno
d2635c677b e1000/if_lem.c bump to 1.1.0
- deprecate fbsd 8

Differential Revision:	https://reviews.freebsd.org/D3164
Submitted by:	erj
MFC after:	2 weeks
Sponsored by:	Intel Corporation
2015-08-16 20:10:43 +00:00
Sean Bruno
df40405fab Increase EM_MAX_SCATTER to 64 such that the size of em_xmit()::segs[EM_MAX_SCATTER]
doesn't get overrun by things like NFS that can and do shove more than 32 segs when
being used with em(4) and TSO4.

Update tso handling code in em_xmit() with update from jhb@ in email thread:
https://lists.freebsd.org/pipermail/freebsd-net/2014-July/039306.html

set ifp->if_hw_tsomax, ifp->if_hw_tsomaxsegcount & ifp->if_hw_tsomaxsegsize
to appropriate values.

Define a TSO workaround "magic" number  of 4 that is used to avoid an
alignment issue in hardware.

Change a couple of integer values that were used as booleans to actual
bool types.

Ensure that em_enable_intr() enables the appropriate mask of interrupts
and not just a hardcoded define of values.

PR:		200221 199174 195078
Differential Revision:	https://reviews.freebsd.org/D3192
Reviewed by:	erj jhb hiren
MFC after:	2 weeks
Sponsored by:	Limelight Networks
2015-08-16 19:43:44 +00:00
Jilles Tjoelker
842ad8ac0b wordexp(): Stop using the undocumented wordexp builtin.
The functionality of the wordexp builtin is easily replaced using normal
shell code, although performance is slightly worse.

This does not mean that wordexp() will remain shell-independent -- a fully
reliable implementation of WRDE_NOCMD is really only possible using
extensions to the shell, or by adding much of the shell's code to libc.
2015-08-16 19:42:15 +00:00
Sean Bruno
38be29d321 Add capability to disable CRC stripping. This breaks IPMI/BMC capabilities on certain adatpers.
Linux has been doing the exact same thing since 2008

eb7c3adb1c

PR:	161277
Differential Revision:	https://reviews.freebsd.org/D3282
Submitted by:	Fravadona@gmail.com
Reviewed by:	erj wblock
MFC after:	2 weeks
Relnotes:	yes
Sponsored by:	Limelight Networks
2015-08-16 19:06:23 +00:00
Alan Cox
f9b11500c2 As another piece of PG_CACHE page elimination, remove an LRU-defeating call
to vm_page_try_to_cache() from vm_pageout_flush().  Other changes, most
recently r286814, have made this call unnecessary.

Reviewed by:	kib
Discussed with:	jeff
Tested by:	pho
Sponsored by:	EMC / Isilon Storage Division
2015-08-16 17:07:53 +00:00
Ed Schouten
cd69db4b0e Pick UINT_MAX / 100 as an upperbound.
The fix that I applied in r286798 is already good, but it assumes that
sizeof(int) > sizeof(short). Express the upperbound in terms of
UINT_MAX. By dividing that by 100, we're sure that the resulting value
is never larger than approximately UINT_MAX / 10, which is safe.

PR:		202326
Discussed with:	kcwu csie org
MFC after:	1 month
2015-08-16 13:59:11 +00:00