Commit Graph

199281 Commits

Author SHA1 Message Date
Baptiste Daroussin
b7ba1c08fe Remove docs that are not shipped with nvi anymore
Reported by:	emaste
2015-04-10 19:07:43 +00:00
Will Andrews
677c3c0c66 tmpfs_getattr(): Return more correct allocated byte counts.
For VREG vnodes, return the resident page count (multiplied by PAGE_SIZE)
for the tmpfs node's anonymous VM object that stores actual file contents.

For all other vnodes, return the tmpfs_node's tn_size, which should not
be rounded to a page.

This change allows using stat(2) to identify a sparse file on tmpfs.

Reviewed by:	kib
MFC after:	1 week
2015-04-10 19:04:39 +00:00
Ed Maste
5ec8fa0ee4 Add build support for i386 loader.efi
Kernel changes are required for this to be useful but this will allow
others to experiment.

Differential Revision:	https://reviews.freebsd.org/D2276
2015-04-10 18:49:43 +00:00
Ed Maste
dea6bf66ea Limit EFI framebuffer metadata to amd64 for now
The i386 loader.efi does not yet exist. Avoid dealing with vt and
framebuffer issues there until the initial bootstrapping is done.
2015-04-10 18:08:09 +00:00
Jung-uk Kim
2a91972d59 Import ACPICA 20150410. 2015-04-10 17:54:53 +00:00
Baptiste Daroussin
c271fa9295 Update nvi to 2.1.3 which fixes the data corruption when locale conversion
failed
2015-04-10 17:50:28 +00:00
Xin LI
36d99b08a5 For reasons that I am not understand yet, using the libmd version of
SHA256 would make libarchive based application to give:

	archive_read_extract(): Lzma library error: Corrupted input data

(Internally this is LZMA_DATA_ERR)

However, the libmd version of SHA256 is supposed to give same result
as the bundled version do, and xz(1) is not affected.

As a precaution, revert the SHA256 portion of r281316 for now until
we figure out why it breaks libarchive interoperability as we can't
yet rule out this change have introduced an ABI breakage.
2015-04-10 17:21:47 +00:00
Ian Lepore
c441925e31 Use OF_getencpropalloc() to handle endianess of the properties.
Submitted by:	Michal Meloun
2015-04-10 13:50:57 +00:00
Ian Lepore
7669914f32 Add a pmap_kremove_device() to undo mappings made with pmap_kenter_device().
Previously we used pmap_kremove(), but with ARM_NEW_PMAP it does the remove
in a way that isn't SMP-coherent (which is appropriate in some circumstances
such as mapping/unmapping sf buffers).  With matching enter/remove routines
for device mappings, each low-level implementation can do the right thing.

Reviewed by:	Svatopluk Kraus <onwahe@gmail.com>
2015-04-10 13:26:35 +00:00
Baptiste Daroussin
5a709d61a3 Import nvi 2.1.3
Approved by:	peter
2015-04-10 13:26:05 +00:00
Ian Lepore
78261920b0 The "get latency" and "get bitmode" device commands are read operations,
not writes.
2015-04-10 13:20:31 +00:00
Gleb Smirnoff
4651df570c Redo r274966. Instead of global all-interface all-vnet undocumented sysctl,
use per-interface flag, and document it.

Sponsored by:	Nginx, Inc.
2015-04-10 09:50:13 +00:00
Enji Cooper
e04e98929f Use _exit, not exit in forked process
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 09:37:53 +00:00
Enji Cooper
62b65008d0 Remove argc/argv (-Wunused)
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 09:27:23 +00:00
Enji Cooper
7d075cff6e Fix warnings
- Remove argc/argv (-Wunused)
- Mark some parameters to socket_listen_update __unused (-Wunused)

MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 09:26:21 +00:00
Enji Cooper
cc469a3b3a Remove argc/argv (-Wunused)
MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 09:23:00 +00:00
Enji Cooper
41119c8725 - Parameterize out the number of accept/connect attempts
- Randomize the bind port to allow 2+ consecutive calls in < 10 minutes, and
  to also not fail if (for instance) there's a server already listening on port
  8080
- Don't leak the listening socket / fds into the child process
- Fix warnings:
-- Remove argc/argv (-Wunused)
-- Mark sig __unused (-Wunused)
-- Mark quit static (-Wmissing-variable-declarations)

MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 09:21:07 +00:00
Andrew Turner
b6e1ffd447 Port the EFI reloc codeto work on arm64. This used the rela relocation
table so wiill need the addend included in the relocation calculation.

Sponsored by:	The FreeBSD Foundation
2015-04-10 09:15:35 +00:00
Enji Cooper
957885bf58 Fix -Wunused warnings, bump WARNS to 6
The output is still broken if prove -rv is run and the testcase aborts
prematurely with fail_assertion (the testcase doesn't really conform to TAP
protocol properly, except when it completes fully)

MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 08:01:49 +00:00
Enji Cooper
1aa40dada2 Fix -Wunused warnings, bump WARNS to 6
The testcase fails today on subtest # 9

The output is still broken if prove -rv is run and the testcase aborts
prematurely (the testcase doesn't really conform to TAP protocol properly,
except when it completes fully)

MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 07:59:46 +00:00
Enji Cooper
2084db1777 Fix warnings, fix a typo in a testcase description, bump WARNS to 3
- Remove argc/argv (-Wunused)
- Cast len in comparison to size_t (-Wsign-compare)

MFC after: 1 week
Sponsored by: EMC / Isilon Storage Division
2015-04-10 07:35:53 +00:00
Gleb Smirnoff
16be9f54e7 UMA zone limit can be lowered, so remove protection against from
the sysctl_handle_uma_zone_max().

Sponsored by:	Nginx, Inc.
2015-04-10 06:56:49 +00:00
Gleb Smirnoff
c047fd1b99 o Use Jenkins hash. With previous hash, for a single source IP address and
sequential IP ID case (e.g. ping -f), distribution fell into 8-10 buckets
  out of 64. With Jenkins hash, distribution is even.
o Add random seed to the hash.

Sponsored by:	Nginx, Inc.
2015-04-10 06:55:43 +00:00
Gleb Smirnoff
1dbefcc00d Move all code related to IP fragment reassembly to ip_reass.c. Some
function names have changed and comments are reformatted or added, but
there is no functional change.

Claim copyright for me and Adrian.

Sponsored by:	Nginx, Inc.
2015-04-10 06:02:37 +00:00
Jung-uk Kim
d29c30140b Import ACPICA 20150408. 2015-04-09 23:08:47 +00:00
Bryan Drewery
daa301d1d0 - Fix support with new elftoolchain readelf(1)
- Fix not finding global symbols by checking for D and R.
- Follow symlinks
- Show which matching symbol was used to consider the library needed.

Discussed with:	bapt
2015-04-09 22:16:35 +00:00
Gleb Smirnoff
f25a3d10b3 Now that IP reassembly is no longer under single lock, book-keeping amount
of allocations in V_nipq is racy.  To fix that, we would simply stop doing
book-keeping ourselves, and rely on UMA doing that.  There could be a
slight overcommit due to caches, but that isn't a big deal.

o V_nipq and V_maxnipq go away.
o net.inet.ip.fragpackets is now just SYSCTL_UMA_CUR()
o net.inet.ip.maxfragpackets could have been just SYSCTL_UMA_MAX(), but
  historically it has special semantics about values of 0 and -1, so
  provide sysctl_maxfragpackets() to handle these special cases.
o If zone limit lowers either due to net.inet.ip.maxfragpackets or due to
  kern.ipc.nmbclusters, then new function ipq_drain_tomax() goes over
  buckets and frees the oldest packets until we are in the limit.
  The code that (incorrectly) did that in ip_slowtimo() is removed.
o ip_reass() doesn't check any limits and calls uma_zalloc(M_NOWAIT).
  If it fails, a new function ipq_reuse() is called. This function will
  find the oldest packet in the currently locked bucket, and if there is
  none, it will search in other buckets until success.

Sponsored by:	Nginx, Inc.
2015-04-09 22:13:27 +00:00
Baptiste Daroussin
933095dedc rtsold does not need to link to libkvm 2015-04-09 21:52:14 +00:00
Baptiste Daroussin
1e486a7e52 rpc.locked does not need to link to libutil 2015-04-09 21:48:17 +00:00
Baptiste Daroussin
5d0b9042a1 bhyvectl does not need to link to libutil 2015-04-09 21:39:58 +00:00
Baptiste Daroussin
ea4a4d8a2e Fix overlinking in bhyve:
libvmmapi is actually needed to be linked to libutil, not bhyve nor bhyveload
2015-04-09 21:38:40 +00:00
Marius Strobl
0f55f9d67b Don't enable RX and TX before their initial configuration is done, i. e.
after setting up interrupt moderation but before turning interrupts on.
This matches what Realtek's r8168 Linux driver does as of version 8.039.00
and fixes problems with certain incarnations of certain MAC revisions
like the interface requiring an extra up/down-cycle after boot to start
working or DMA configuration not being adhered to.

PR:		193743, 197535
MFC after:	1 week
2015-04-09 21:35:44 +00:00
Baptiste Daroussin
e4474f161b authpf does not need to link to libmd 2015-04-09 21:33:57 +00:00
Jung-uk Kim
7d369c6e2f Print 64-bit addresses cleary with leading zeros to avoid confusions.
MFC after:	1 week
2015-04-09 21:32:40 +00:00
Gleb Smirnoff
f5746f593c In the ip_reass() do packet examination and adjusting before acquiring
locks and doing lookups.

Sponsored by:	Nginx, Inc.
2015-04-09 21:32:32 +00:00
Baptiste Daroussin
64026fd83c Remove uneeded link to libkiconv 2015-04-09 21:30:11 +00:00
Baptiste Daroussin
32e5044deb Convert mt(1) and libmt to LIBADD
While here fix missing link to libbsdxml for libmt
Fix overlinking in mt(1)
Make add an indirect libmt dependency on bsdxml to allow static linking if
needed
2015-04-09 21:26:38 +00:00
Jung-uk Kim
fe1d0c2dae Do not crash when RSDT/XSDT contains an empty entry.
Reported by:	Slawa Olhovchenkov <slw@zxy.spb.ru>
MFC after:	3 days
2015-04-09 21:26:23 +00:00
Baptiste Daroussin
b6f4a0a1c7 Remove uneeded sbuf header 2015-04-09 21:23:27 +00:00
Gleb Smirnoff
e3c2c63476 Make ip reassembly queue mutexes per-vnet, putting them into the structure
that they protect.

Sponsored by:	Nginx, Inc.
2015-04-09 21:17:07 +00:00
Baptiste Daroussin
d56eff2c31 iscsictl(8) does not actually needs to be linked to libcam nor libutil 2015-04-09 21:14:40 +00:00
Baptiste Daroussin
4620173a5f Convert cftmerge to LIBADD and remove link on libdwarf which is not needed 2015-04-09 21:08:21 +00:00
Baptiste Daroussin
f2800dd40f bsnmptools does not depends on libcrypto 2015-04-09 21:05:48 +00:00
Jason Helfman
7d49cdeb2b - ggatel.8 currently doesn't mention the 'rescue' command and
documents a non-existing 'attach' command instead.
- while here address a spelling error

PR:		199111
Differential Revision:	https://reviews.freebsd.org/D2259
Submitted by:	fk@fabiankeil.de
Obtained from: ElectroBSD
Approved by:	wblock (mentor)
MFC after:	1 week
2015-04-09 20:58:38 +00:00
Ed Maste
b291974d25 Remove EOL whitespace from i386 EFI loader source 2015-04-09 19:48:42 +00:00
Pedro F. Giffuni
67128bdc88 Update documented OEM string in newfs_msdos(8).
This was updated in r203868 to better match the naming scheme
in other OSs that use FAT.

MFC after:	3 days
2015-04-09 19:07:01 +00:00
Xin LI
342bcb1232 MFV r281278:
- Update xz to 5.2.1, where the most visible change is that it
   fixed a compression-ratio regression in fast mode LZMA1 and
   LZMA2 and used cpuset_getaffinity() for CPU cores detection.
 - Make liblzma use the base system SHA256 implementation instead of
   the bundled one.
 - Additional annotation in config.h for FreeBSD specific tweaks.
 - Refresh symbols in XZprivate_1.0 to reflect reality.

Relnotes:	yes
MFC after:	1 month (TBD)
2015-04-09 18:03:27 +00:00
Ed Maste
0f9b4b57c1 Avoid escaping EOL for line continuation
Reported by:	kib
2015-04-09 15:08:39 +00:00
George V. Neville-Neil
51d4054eeb Revert 281276 as unnecessary. Proper change to be committed
to the base polling code in a subsequent commit.

Pointed out by: glebius

Sponsored by:	Rubicon Communications (NetGate)
2015-04-09 14:44:30 +00:00
Ed Maste
56ad941995 ar: Disallow directory traversal
Set ARCHIVE_EXTRACT_SECURE_SYMLINKS and ARCHIVE_EXTRACT_SECURE_NODOTDOT
as in bsdtar to prevent extraction of archive entries whose pathnames
contain .. or whose target directory would be altered by a symlink.
Also disallow absolute pathnames.

We don't currently provide an option to disable this behaviour (as
bsdtar's -P does). It is unlikely to be a problem in practice for ar(1),
but the -P option is not currently used and available if we want to
consider it for this purpose.

Differential Revision:	https://reviews.freebsd.org/D1524
Reported by:	Alexander Cherepanov <cherepan@mccme.ru>
Approved by:	delphij
Obtained from:	ELF tool chain ar, Ticket #474
MFC after:	1 week
Relnotes:	Yes
Sponsored by:	The FreeBSD Foundation
2015-04-09 13:45:17 +00:00