Commit Graph

197687 Commits

Author SHA1 Message Date
hselasky
9b3fc5a494 MFC r275624:
Add port routing support for Wildcat Point.

PR:		195793
2014-12-15 08:26:36 +00:00
andrew
7f8f9c5128 MFC 275379:
Set the correct architecture when targeting ARMv7

Sponsored by:	ABT Systems Ltd
2014-12-14 18:51:13 +00:00
jilles
df71c47219 MFC r268576: sh: Correctly handle positional parameters beyond INT_MAX on
64-bit systems.

Currently, there can be no more than INT_MAX positional parameters. Make
sure to treat all higher ones as unset to avoid incorrect results and
crashes.

On 64-bit systems, our atoi() takes the low 32 bits of the strtol() and
sign-extends them.

On 32-bit systems, the call to atoi() returned INT_MAX for too high values
and there is not enough address space for so many positional parameters, so
there was no issue.

PR:		195918
2014-12-14 18:30:30 +00:00
andrew
af32fb7fce MFC 275564:
Use the unified syntax when generating assembly for clang. The clang 3.5
integrated assembler only accepts it.

Sponsored by:	ABT Systems Ltd
2014-12-14 18:28:01 +00:00
andrew
56edfadd1e MFC 275378:
Pull in the NetBSD global offset table handling code. Clang 3.5 creates
relocations the linker complains about.

Obtained from:	NetBSD
2014-12-14 18:23:30 +00:00
andrew
8889da9263 MFC 275337:
There is no need to use FUNC_END with aeabi_ldiv0 or aeabi_idiv0 as they
are aliases.

Sponsored by:	ABT Systems Ltd

MFC 275380:

Use the floating-point instruction on ARMv7 as the clang 3.5 integrated
assembler doesn't allow these two instructions to use co-processor 11.

Sponsored by:	ABT Systems Ltd
2014-12-14 18:01:09 +00:00
andrew
ab2a78a144 MFC 275415:
Allow the UAL APSR_nzcv format for the mrc and mrc2 instructions. The clang
integrated assembler only allows these forms so binutils will need to
support them.

Sponsored by:	ABT Systems Ltd

MFC 275584:

Fix mrc and mrc2 with APSR_nzcv. Binutils encodes it internally as 0 where
we need it to be set to 15 for it to be equivalent to r15.

Sponsored by:	ABT Systems Ltd
2014-12-14 17:38:43 +00:00
andrew
23e47daf28 MFC 275336:
Use llabs when getting the absolute value of a long long.

Sponsored by:	ABT Ststems Ltd
2014-12-14 17:28:02 +00:00
andrew
90fc0dee7a Clean up our ARM assembly:
MFC 275256:

Switch to the ARM unified assembly language as the clang integrated as only
supports it. Binutils supports it when the ".syntax unified" directive
is set.

Sponsored by:   ABT Systems Ltd

MFC 275264:

Update _ENTRY to use _EENTRY to reduce the common code.

MFC 275321:

Remove extra labels, ENTRY_NP already provides them.

Sponsored by:   ABT Systems Ltd

MFC 275322:

Correctly a few incorrect uses of ENTRY/EENTRY and END/EEND

Sponsored by:   ABT Systems Ltd

MFC 275416:

Fix the name of the coprocessor to include the "p" prefix, the clang
integrated assembler expects this.

Sponsored by:   ABT Systems Ltd

MFC 275418:

Switch to unified syntax so these can be built with clang 3.5.

Sponsored by:   ABT Systems Ltd

MFC 275519:

Add missing END macros to some of the xscale functions.

Sponsored by:   ABT Systems Ltd

MFC 275520:

Use the unified syntax in a few more assembly files

Sponsored by:   ABT Systems Ltd

MFC 275521:

Set the alignment to 4-bytes after a string as clang 3.5 can switch to
thumb mode if this is incorrect.

Sponsored by:   ABT Systems Ltd

MFC 275522:

Place the literal pool after a RET otherwise clang 3.5 tries to put it too
far away from a ldr psuedo instruction. With this clang will place the
literal value here where it's close enough to be loaded.

Sponsored by:   ABT Systems Ltd

MFC 275523:

Switch to an armv6k cpu, without this clang 3.5 complains "bx lr" is
unsupported as it needs a newer cpu.

Sponsored by:   ABT Systems Ltd

MFC 275524:

Switch to a .cpu directive. These will work when clang 3.5 is imported
where the .arch directive is a nop.

Sponsored by:   ABT Systems Ltd
2014-12-14 16:28:53 +00:00
andrew
041226eb03 MFC 275207:
We don't use the hypervisor interrupt, make it optional in the device tree.

Submitted by:   Julien Grall <julien.grall AT linaro.org>

MFC 275208:

Some device tree configurations place the generic timer under the root
of the tree and not under simplebus. Update the driver to handle this.

Submitted by:   Julien Grall <julien.grall AT linaro.org>
2014-12-14 15:41:56 +00:00
andrew
35401942c2 MFC 273927:
Move the definitions of the fdt functions from a uboot header to a new fdt
header. There is nothing in the fdt spec that ties it to U-Boot.

While here sort and fix the signature of fdt_setup_fdtp.

MFC 273934:

Start to allow platforms other than U-Boot to use the FDT code in loader by
moving U-Boot specific code from libfdt.a to a new libuboot_fdt.a. This
needs to be a new library for linking to work correctly.

Differential Revision:  https://reviews.freebsd.org/D1054
Reviewed by:    ian, rpaulo (earlier version)
2014-12-14 15:33:45 +00:00
andrew
26961b2547 MFC r273913:
Clean up the types of a few strings to make them const when they are never
written to.

MFC r273914:

The command name is a constant, use the correct type.
2014-12-14 15:03:11 +00:00
trasz
8a9a84f3d8 MFC r274495:
Add missing commas to .Xr.

Sponsored by:	The FreeBSD Foundation
2014-12-14 11:03:22 +00:00
kib
88eaa27723 MFC r275347:
Provide mutual exclusion between zone allocation/destruction and
uma_reclaim().
2014-12-14 09:34:55 +00:00
dim
3156db9097 MFC r275633:
Pull in r223171 from upstream llvm trunk (by Michael Zolotukhin):

  PR21302. Vectorize only bottom-tested loops.

  rdar://problem/18886083

This fixes a bug in the llvm vectorizer, which could sometimes cause
vectorized loops to perform an additional iteration, leading to possible
buffer overruns.  Symptoms of this, which are usually segfaults, were
first noticed when building gcc ports, here:

https://lists.freebsd.org/pipermail/freebsd-ports/2014-September/095466.html
https://lists.freebsd.org/pipermail/freebsd-toolchain/2014-September/001211.html

Since this fix is very important for ports, bump __FreeBSD_version to
make it easier for port maintainers to test whether the fix has been
applied.

Upstream PR:	http://llvm.org/PR21302
2014-12-13 12:14:26 +00:00
kib
8b3b3c8447 MFC r275513:
When the last reference on the vnode' vm object is dropped, read the
vp->v_vflag without taking vnode lock and without bypass.
2014-12-12 09:22:52 +00:00
hselasky
722ac120b4 MFC r275636:
Move OFED init a bit earlier so that PXE boot works.

Sponsored by:	Mellanox Technologies
2014-12-12 07:59:05 +00:00
mav
dff991dbdf MFC r274411: Improve CAM's reaction on asymmetric access errors. 2014-12-12 07:41:08 +00:00
dim
76a5c6a0d7 MFC r275477:
Pull in r174303 from upstream gcc trunk (by Jason Merrill):

  PR c++/48211
  * name-lookup.h (cp_class_binding): Make base a pointer.
  * name-lookup.c (new_class_binding): Adjust.
  (poplevel_class): Adjust.

This fixes a potential segfault when compiling gold, a part of the
devel/binutils port, with gcc.  See also the upstream bug report:

https://gcc.gnu.org/bugzilla/show_bug.cgi?id=48211

Thanks to Jason Merrill, Tom Callaway and Red Hat legal for approving
the use of this patch under the GNU GPL, version 2 or later.
2014-12-11 08:05:59 +00:00
mav
cc4fa4df69 MFC r275478: Swap resource count scopes for used/available space.
Used count should be reported as per-LUN, while available should not.
2014-12-11 00:25:26 +00:00
cy
fef6395777 MFC r275199.
Correctly define constants.
2014-12-10 20:54:23 +00:00
mav
43c3b12592 MFC r275452: Do not corrupt the listen string when parsing it.
This fixes problem with ctld reload when it is configured to listen on two
portals with same IP, but different ports.
2014-12-10 08:53:41 +00:00
mav
4875c0a205 MFC r275446: Plug memory leaks on UNMAP and XCOPY with invalid parameters. 2014-12-10 08:52:47 +00:00
delphij
b24390d7fc MFC r275666:
Fix multiple vulnerabilities in file(1) and libmagic(3).

Security:	FreeBSD-SA-14:28.file
Security:	CVE-2014-3710, CVE-2014-8116, CVE-2014-8117
2014-12-10 08:26:53 +00:00
delphij
25ca306958 MFC r275665:
Fix buffer overflow in stdio.

Security:	FreeBSD-SA-14:27.stdio
Security:	CVE-2014-8611
2014-12-10 08:24:02 +00:00
rpaulo
88952b61c5 MFC r275376:
Allow multiple devices to mmap.  It's impossible to prevent this with
  checks on the open/close functions.
2014-12-09 17:03:14 +00:00
trasz
c131c42ed7 MFC r274310:
Add HISTORY section to ctld(8).

Sponsored by:	The FreeBSD Foundation
2014-12-09 11:52:36 +00:00
trasz
35a0788239 MFC r274308:
Add support for sending redirections to iSCSI target.

MFC r274309:

Fix several nits in redirection handling - don't use wrong CSG,
and avoid use-after-free.

Sponsored by:	The FreeBSD Foundation
2014-12-09 11:50:50 +00:00
dim
ace7dfdc9c MFC r275386:
Let GNU ld be less obscure about missing symbols and DSOs.  If the BFD
object looks like a typical shared library, suggest adding '-l<foo>',
where <foo> has the 'lib' prefix and '.so<bar>' or '.a' suffix removed.

Otherwise, suggest adding '-l:<foo>', where <foo> is the full DT_SONAME.

Submitted by:	Conrad Meyer <conrad.meyer@isilon.com>
Sponsored by:	EMC / Isilon storage division
Reviewed by:	emaste
PR:		194296
Differential Revision: https://reviews.freebsd.org/D1152
2014-12-09 07:15:53 +00:00
bryanv
5ce5864383 MFC r274322:
Attempt to report a better error if sanitize is not supported
2014-12-09 07:03:49 +00:00
delphij
04dbe28cc6 MFC r275071:
Reinstitate send() after syslogd restarts.

In r228193 the test of CONNPRIV have been moved to before the _usleep
and send in vsyslog().  When syslogd restarts, this would prevent the
message being logged after the disconnect/connect dance for
scenario #1.

PR:		194751
Submitted by:	Peter Creath <pjcreath+freebsd gmail com>
Reviewed By:	glebius
2014-12-09 00:47:02 +00:00
avg
0fb6d9ca37 MFC r275046: whitespace and cosmetic changes in callout_reset family of macros
Not applicable to earlier releases.
2014-12-08 13:19:29 +00:00
avg
36fdb56baa MFC r275045: callout(9): add sbt flavors of callout_schedule
Not applicable to earlier releases.
2014-12-08 13:13:17 +00:00
avg
c07a7147df MFC r274628: l2arc: restore correct rounding up of asize of compressed data 2014-12-08 13:06:44 +00:00
trasz
379a1af59c MFC r274277:
ctld(8) doesn't require -lcam or -lssl; remove those from DPADD and LDADD.

Sponsored by:	The FreeBSD Foundation
2014-12-08 11:28:08 +00:00
mav
16ad04df25 MFC r275368:
When passing LUN IDs through treat ASCII values as fixed-length, not
interpreating NULLs as EOLs, but converting them to spaces.

SPC-4 does not tell that T10-based IDs should be NULL-terminated/padded.
And while it tells that it should include only ASCII chars (0x20-0x7F),
there are some USB sticks (SanDisk Ultra Fit), that have NULLs inside
the value.  Treating NULLs as EOLs there made those LUN IDs non-unique.
2014-12-08 09:47:49 +00:00
jilles
26dad09e50 MFC r267265: truncate: Detect integer overflow, fix relative sizes, add tests.
The change to expand_number (r204654) broke detection of too large sizes and
relative sizes ('+'/'-').

Also add some tests.

The usr.bin/truncate/Makefile is slightly different in the MFC because
src.opts.mk does not exist in stable/10.

PR:		190735
Submitted by:	Kirk Russell
2014-12-07 22:30:54 +00:00
brooks
0ba04a3a67 MFC r263928:
Use the correct variable name in the example code.

PR:		195749
2014-12-06 17:50:37 +00:00
mav
72641b76c8 MFC r274843, r274845:
Move icl_pdu_get_data() and xpt_done() out of initiator's session lock.

During heavy reads data copying in icl_pdu_get_data() may consume large
percent of CPU time.  Moving it out of the lock significantly reduces
lock hold time and respectively lock congestion on read operations.
2014-12-06 07:30:08 +00:00
markj
dd6a87838b MFC r271695:
Fix some incorrect endianness checks.
2014-12-05 18:55:31 +00:00
ngie
bb7db53959 MFC r275170:
Convert sbin/mdconfig/tests from prove format tests to ATF format tests

  As a side effect...
  1. The tests now checks for the root user before continuing with kyua, which is
     more visible than the test being skipped with the TAP protocol
  2. The tests work with devices that aren't /dev/md0 by caching the device
     attached during the test to a file, and later use the cached information to
     detach the device in the cleanup routine
  3. The tests no longer require perl to run

  PR: 191191
  Sponsored by: EMC / Isilon Storage Division
2014-12-05 12:51:27 +00:00
ngie
dabf881564 MFC r274365:
Revert WiP to contrib/tzcode accidentally committed with r274364
2014-12-05 12:25:36 +00:00
ngie
32112cfc28 MFC r274364:
Add baud rate support to telnet(1)

  This implements part of RFC-2217

  It's based off a patch originally written by Sujal Patel at Isilon, and
  contributions from other Isilon employees.

  PR: 173728
  Phabric: D995
  Reviewed by: markj, markm
  Sponsored by: EMC / Isilon Storage Division
2014-12-05 12:23:29 +00:00
ngie
2ceba1b134 MFC r272057,r272083,r272084,r272087,r274016:
r272057:

  Import pjdfstest from ^/vendor/pjdfstest/abf03c3a47745d4521b0e4aa141317553ca48f91

  - Remove tools/regression/pjdfstest
  - Add upgrade directions for contrib/pjdfstest
  - Add a note to UPDATING for the move (the reachover Makefiles are coming
    soon)

  Functional differences:
  - ftruncate testcases are added from upstream (github)

  Non-functional differences:
  - The copyright for the project has been updated to 2012
  - pjd's contact information has been updated

  Discussed with: -testing, jmmv, pjd
  Sponsored by: EMC / Isilon Storage Division

r272083:

  Expect ELOOP on Darwin/Linux with "O_NOFOLLOW was specified and the target is a
  symbolic link" case. Assume EMLINK on the rest of the OSes (FreeBSD, Solaris,
  etc)

  Sponsored by: EMC / Isilon Storage Division

r272084:

  Fix the executed testplan count

  Sponsored by: EMC / Isilon Storage Division

r272087:

  Increase the memory disk size in the following testcases to avoid mount
  failures, which would cause cascade failures in the rest of the test
  run:

  link/15.t, open/19.t, mkdir/11.t, mkfifo/11.t, symlink/11.t

  Fail quickly in all of the testcases if mdconfig, mount, umount, etc
  fails to avoid issues similar to this in the future

  Submitted by: Casey Peel <cpeel@isilon.com>
  Sponsored by: EMC / Isilon Storage Division

r274016:

  Integrate pjdfstest test suite execution into kyua

  pjdfstest execution is opt-in and must be done as root due to some of the
  assumptions made by the test suite and lack of error checking in the non-root
  case

  A description of how to execute pjdfstest with kyua is provided in
  share/pjdfstest/README

  Phabric: D824 (an earlier prototype patch)
  Relnotes: yes
  Sponsored by: EMC / Isilon Storage Division
2014-12-05 11:44:18 +00:00
kib
f88754a36c MFC r275206:
Assert the state of the process lock and sigact mutex in
kern_sigprocmask() and reschedule_signals().
2014-12-05 09:30:07 +00:00
ngie
d21006ce12 MFC r271796 (by will):
Use 'cc' for the C compiler instead of 'gcc'.

  Sponsored by:	Spectra Logic
  MFSpectraBSD:	1079507 on 2014/07/24
2014-12-05 08:46:15 +00:00
rpaulo
2add70e7a9 MFC r275420:
gpioctl: don't print the command line arguments.

PR:	  	195330
Submitted by:	Scott Ellis jumpnowtek at gmail.com
2014-12-05 07:51:50 +00:00
mav
f55f3b5eab MFC r272937: Fix r272936 build with old GCC. 2014-12-05 07:48:22 +00:00
mav
2ba95e01e3 MFC r268395:
Pass correct command that should be aborted to ISPCTL_ABORT_CMD.

This makes XPT_ABORT to work for me on initiator side of isp(4).
Previous code was trying to abort the XPT_ABORT itself and failed.
2014-12-05 07:46:28 +00:00
mav
19732a0540 MFC r274248: Remove unused assignments, noticed by Clang analyzer. 2014-12-05 07:29:31 +00:00