For posix_fallocate(2) and posix_fadvise(2), return ESPIPE when
underlying file does not have DFLAG_SEEKABLE set [1].

For posix_fallocate(2), simplify error handling logic.  Do return when
fp is not yet referenced.

Noted by:	bde [1]
Reviewed by:	jhb
Sponsored by:	The FreeBSD Foundation
MFC after:	1 week
Add the FDT table GUID. This is used to pass the device tree blob from UEFI
to the loader in a similar way to the ACPI tables.

This will be used on arm64 but is not specific to the architecture.

Sponsored by:	The FreeBSD Foundation
HBSD: added HardenedBSD_version

Signed-off-by: Oliver Pinter <oliver.pntr@gmail.com>
Finally merge hardened/current/chacha branch into hardened/current/master

github-issue: #38

Signed-off-by: David Carlier <david.carlier@gmail.com>
Signed-off-by: Shawn Webb <shawn.webb@gmail.com>
Signed-off-by: Oliver Pinter <oliver.pntr@gmail.com>
HBSD: bump __HardenedBSD version after arc4random update

Signed-off-by: Oliver Pinter <oliver.pntr@gmail.com>
﻿Pull in r221709 from upstream llvm trunk (by Frédéric Riss):

  Totally forget deallocated SDNodes in SDDbgInfo.

  What would happen before that commit is that the SDDbgValues associated with
  a deallocated SDNode would be marked Invalidated, but SDDbgInfo would keep
  a map entry keyed by the SDNode pointer pointing to this list of invalidated
  SDDbgNodes. As the memory gets reused, the list might get wrongly associated
  with another new SDNode. As the SDDbgValues are cloned when they are transfered,
  this can lead to an exponential number of SDDbgValues being produced during
  DAGCombine like in http://llvm.org/bugs/show_bug.cgi?id=20893

  Note that the previous behavior wasn't really buggy as the invalidation made
  sure that the SDDbgValues won't be used. This commit can be considered a
  memory optimization and as such is really hard to validate in a unit-test.

This should fix abnormally large memory usage and resulting OOM crashes
when compiling certain ports with debug information.

Reported by:	Dmitry Marakasov <amdmi3@amdmi3.ru>
Upstream PRs:	http://llvm.org/PR19031 http://llvm.org/PR20893
MFC after:	1 week
Fix previous change to this file (r273811).

This has been submitted upstream and should show up there soon.

Submitted by:	Hariprasad at Chelsio dot com
Make PL011 UART to wait on putc only when TX FIFO is full

Instead of waiting for empty TX FIFO it is more reasonable to
block on full FIFO. As soon as FIFO slot is free the character
can be transmitted.
In case of TX FIFO disabled, TXFF bit indicates that transmit
register is not empty.

Obtained from:   Semihalf
Reviewed by:     andrew, emaste
Sponsored by:    The FreeBSD Foundation
Make uart_bus_fdt a decendant of ofwbus

This will allow to attach UART drivers lying directly on the root node
instead of simple-bus compatible bus only.

Obtained from:   Semihalf
Sponsored by:    The FreeBSD Foundation
Fix wrong message when using pw -V with a non existent directory
Add a regression test about it

PR:		194971
Submitted by:	Freddy DISSAUX <bugzilla@dsx.bsdsx.fr>
ipsec6_process_packet is called before ip6_output fixes ip6_plen.
Update ip6_plen before bpf processing to be able see correct value.

MFC after:	1 week
Sponsored by:	Yandex LLC
We don't return sp pointer, thus NULL assignment isn't needed.
And reference to sp will be freed at the end.

MFC after:	1 week
Sponsored by:	Yandex LLC
Merge remote-tracking branch 'freebsd/master' into hardened/current/master
Merge remote-tracking branch 'origin/hardened/current/master' into hardened/current/ptrace