DragonFlyBSD/src 27332c1sys/bus/u4b/input ukbd.c, sys/dev/misc/kbd atkbd.c

kernel - Get rid of old KDSETRAD keyboard ioctl, and some __i386__ kbd code.

* The KDSETREPEAT ioctl was implemented as a replacement more than 18 years
  ago in 1999 (FreeBSD svn r44628).

DragonFlyBSD/src fa729c8contrib/smbfs/mount_smbfs mount_smbfs.c, sbin/mount_std mount_std.c

mount_{smbfs,std,udf}: Use MOPT_NULL.

DragonFlyBSD/src 35a7b5elib/libc/sys reboot.2

reboot.2: Remove obsolete BUGS section.

DragonFlyBSD/src da37dfalib/libc/stdlib random.c

libc - Use O_CLOEXEC in srandomdev()

* Specify O_CLOEXEC in srandomdev() to avoid descriptor leakages
  if called during a concurrent threaded fork().

DragonFlyBSD/src a26d33c. UPDATING, sys/conf options

Remove various former kernel config options for good.
+8-62 files

DragonFlyBSD/src af61962sys/conf options, sys/config LINT64

kernel: Remove old SHOW_BUSYBUFS kernel configuration option.

It was removed in 5e13112632fcc46beba13acf879e178aba56391c.

DragonFlyBSD/src cebdaf4sys/kern imgact_resident.c

kernel: Remove <sys/inflate.h> inclusion from files that don't need it.

The <sys/inflate.h> is only needed for:
 * sys/kern/imgact_gzip.c
 * sys/kern/inflate.c

DragonFlyBSD/src 3d742b0sys/netinet6 ipcomp_output.c ipcomp_input.c

inet6: Remove few unneeded <net/zlib.h> headers.

No functional change.

DragonFlyBSD/src d7009a0lib/libc/sys kqueue.2

kqueue: Fix kqueue(2) EVFILT_FS section

Fix 05d3db1bc901548d6335d701c773c537d4ef42fd.

EVFILT_FS filter currently does not use ident. It can be any value
to catch mount/umount.

FreeBSD kqueue(2) man page doesn't have description on EVFILT_FS
by the way, while the code was taken from FreeBSD for mount/umount.

DragonFlyBSD/src a0cd65bshare/man/man9 kmalloc.9

kmalloc.9: Remove some obsolete information.

DragonFlyBSD/src 97b5e16share/man/man9 kprintf.9

Revert "kprintf.9: Remove unneeded header."

This reverts commit dbb5d235a84b2aa354a9d5745aa6a02ac9a26c50.

The header was actually useful because <sys/syslog.h> has the
priority definitions.

DragonFlyBSD/src dbb5d23share/man/man9 kprintf.9

kprintf.9: Remove unneeded header.

Reported-by: zrj

DragonFlyBSD/src acc9ff4. Makefile_upgrade.inc, sys/cpu/x86_64/include coredump.h

Remove unused <{cpu,machine}/coredump.h> header.

DragonFlyBSD/src beaef97sys/platform/vkernel64/platform pmap.c

vkernel - Sync to recent API changes (3)

* Fix va page offset in returned value.

DragonFlyBSD/src fd8b44bsys/platform/vkernel64/platform pmap.c

vkernel - Sync to recent API changes (2)

* Refactor uservtophys() to use vm_fault_page().  The pmap
  lookup isn't going to work coupled with the fuword style
  test because the vkernel's copyin/copyout/fuword/etc code
  doesn't fault the underlying page into the pmap.

DragonFlyBSD/src a94cabesys/platform/vkernel64/platform pmap.c copyio.c

vkernel - Sync to recent API changes

* Add uservtophys() to the vkernel code.  This is a bit of a quick hack
  but it should work.  It won't be efficient, though.

* vkernel compiles again and appears to run ok.

DragonFlyBSD/src db13471sys/kern vfs_subr.c

kernel - Fix vclean assertion due to short-cut taken by TMPFS

* Allow a vnode being destroyed to have a dirty VM object.  TMPFS
  doesn't bother to cleanup VM objects when destroying file nodes
  (e.g. when a file that is no longer referenced is removed), and
  can leave dirty pages present in the underlying object.

* Fixes occassional kernel assertions related to tmpfs (that only
  tend to occur with specific use cases).

Reported-by: zrj

DragonFlyBSD/src 692504blib/libc/citrus citrus_none.c

libc/citrus: Catch a NULL pointer earlier, check for empty string later.

This fixes a gcc8 warning.

Taken-from: NetBSD (Revisions 1.20-1.22)

DragonFlyBSD/src fef7d5cetc Makefile, gnu/lib Makefile

Remove the NO_CRYPT build option.

It has been broken for a long time without anyone complaining about and
we don't want to maintain it either.

In-discussion-with: zrj

DragonFlyBSD/src 2ab9cf2sys/sys indefinite2.h

<sys/indefinite2.h>: Fix header name.

This is never reached (<sys/globaldata.h> comes in via <sys/indefinite.h>
as it seems), but fix anyway.

DragonFlyBSD/src e8b301fsys/dev/misc/kbd kbdreg.h, sys/dev/raid/hptmv hptproc.c

kernel: Remove some semicolons at the end of macro definitions.

DragonFlyBSD/src 583abefsys/dev/netif/iwm if_iwmreg.h, sys/dev/raid/mlx mlx.c

kernel: Remove some unnecessary semicolons.

DragonFlyBSD/src 45568ffsys/cpu/x86_64/include atomic.h, sys/dev/raid/aac aacvar.h

kernel: Remove two final \ in macro definitions.

DragonFlyBSD/src ac61251sys/conf kern.pre.mk

LTO: Disable safety feature.

No longer can reproduce boot issue in the padlock/padlock_rng codes.
The -flto-partition=one can be supplied together with -flto as needed.

DragonFlyBSD/src bfd523fsys/conf kmod.mk

LTO: Pass CFLAGS to compiler for kernel module linking too.

Forgot to git add it in fa8104330967fab6248da216251a4382b39b1dab.
Linker still could link LTO'ed *.o objects, because ld is invoked by cc
with explicitly passed -plugin option that loads the liblto_plugin.so.
This only slightly changes how LTO is performed on kernel modules.

Note: this will need to be adjusted for clang -flto compatibility
when I will update the clangb version in git module.

Reported-by: dillon
+8-31 files

DragonFlyBSD/src 8172914contrib/gcc-4.7/gcc c-typeck.c

gcc47: Backport static initialization acceptance.

I only backporting these so that failing to accept drm/i915 _MMIO() stuff
would *not* be used as an argument to remove gcc47 alternative compiler
from base, just because "oh look it does not compile the i915.ko".
The gcc47 is likely the last C compiler compilable with C compiler able
to bootstrap the c++ compiler that is used on x86_64 anymore.
If anyone has/works on simple C compiler that could boostrap modern gcc,
you know where I hanging out and I gladly replace gcc47 with it in base.

It only takes few lines to accept updated drm/i915 "features".
It still warns with -pedantic:
/usr/src/sys/dev/drm/i915/intel_pm.c:3925:3: warning: initializer element is not constant 
/usr/src/sys/dev/drm/i915/intel_pm.c:3925:3: warning: (near initialization for 
'wm0_pipe_reg[0]') [-pedantic]
/usr/src/sys/dev/drm/i915/intel_pm.c:3926:3: warning: initializer element is not constant 
/usr/src/sys/dev/drm/i915/intel_pm.c:3926:3: warning: (near initialization for 
'wm0_pipe_reg[1]') [-pedantic]
/usr/src/sys/dev/drm/i915/intel_pm.c:3927:3: warning: initializer element is not constant 
/usr/src/sys/dev/drm/i915/intel_pm.c:3927:3: warning: (near initialization for 
'wm0_pipe_reg[2]') [-pedantic]

    [5 lines not shown]

DragonFlyBSD/src 69a0f59usr.bin/tftp tftp.c main.c

tftp(1): Avoid symbol conflict with ncurses.

The usr.bin/tftp/main.c: int trace;
while lib_trace.c: void trace(const unsigned int){};
This breaks -flto -static link against LTO'ed libncurses.a.

Fix it by just renaming: s/trace/tftp_trace/g.

DragonFlyBSD/src ada524fusr.bin/ftp Makefile

ftp(1): Avoid symbol conflict with ncurses.

The contrib/tnftp/src/ftp_var.h: GLOBAL int trace;
while lib_trace.c: void trace(const unsigned int){};
This breaks -flto -static link against LTO'ed libncurses.a.

Since it is in contrib code, just -Dtrace it.

DragonFlyBSD/src 06e4c4egames/backgammon/backgammon main.c text.c, games/backgammon/common_source board.c

backgammon(6): Avoid symbol issue with ncurses lib.

The backgammon(6) has: back.k: extern int raw;
while in ncurses tinfo/lib_raw.c: int raw(void){}.

This breaks -flto -static link against LTO'ed libncurses.a.
So just rename backgammon global raw to bgraw.

Just for the fun of it, note that init.c: struct termios bgraw;
NetBSD already have it fixed in games/backgammon/.
Also still not clear how to do with c5e1790f6b.

DragonFlyBSD/src 493c001sys/conf kmod.mk options, sys/config LINT64

Fix some trailing whitespace in sys/conf and sys/config.

Submitted-by: zrj

DragonFlyBSD/src 024d5a3usr.bin/banner banner.c

banner(1): Remove (void) casts.

Forgot about these. Sorry.

DragonFlyBSD/src d9f85b3games/arithmetic arithmetic.c, games/hunt/hunt display.c

games: Remove (void) casts.

No functional change.

DragonFlyBSD/src a8dc5a1games/fortune/datfiles dragonfly-tips fortunes-o

fortune(6): Add few fortunes.

DragonFlyBSD/src 03fc749games/tetris screen.c scores.c

Bring in OpenBSD's tetris(6).

Will be handy to test upcoming ncurses update.

Taken-from: OpenBSD

DragonFlyBSD/src 11da14fgames/boggle/boggle bog.c mach.c, games/boggle/mkdict mkdict.c

Bring in OpenBSD's boggle(6).

As per README, stuff is addictive!

Pointed-by: Thierry
Taken-from: OpenBSD

DragonFlyBSD/src effe646sbin/newfs_hammer2 newfs_hammer2.8

newfs_hammer.8: Fix up the HISTORY section.

Reported-by: kerma (Michael)

DragonFlyBSD/src d0a6ae3bin/cpdup cpdup.c BACKUPS

cpdup(1): Whitespace cleanup.

No functional change.

DragonFlyBSD/src 92c825dbin/cpdup Makefile

btools: Strip host lib deps for bin/cpdup.

Disable last libmd.a user in btools.
MD5 functionality (cpdup -m) for buildworld is redundant.
+5-01 files

DragonFlyBSD/src 6d7e22eusr.bin/sort sort.c coll.c

btools: Strip libmd dep for usr.bin/sort.

Implement SORT_RANDOM option and do not use if BOOTSTRAPPING.
This option is useless for a buildworld/buildkernel.

This allows to have sort(1) that only depends on libc.

DragonFlyBSD/src 8f006d6usr.bin/sort Makefile

btools: Strip libpthread dep for usr.bin/sort.

This is one in particular was annoying me for long. It has a potential of using
ptreads for sorting speed up. Running parallel sort(1) in various buildworld
places actually can result in less performance on maximum parallel builds due
to interference with other cpu cores and we can not be sure about the state of
host's static libpthread lib. Also, so far I did not noticed any performance
degradation when sort is used without threads support for buildworld purposes.
This utility (in btools case) is compiled statically so bringing whole pthreads
static lib into memory has a bigger penalty then in most cases sorting anyway.
This a single btools/ctools case that depends on -lpthread. Having a slim,
more stable buildings tools is prefered than dubious compilation speed
enhancements for critical buildworld infrastructure.

The libmd.a dependency will be revemoved in separate patch.

DragonFlyBSD/src 3f6af2c. Makefile.inc1

btools: Remove usr.bin/bzip2 from the list.

The bzip2 and its variants are not used during buildworld/buildkernel.
So avoid yet another dependency on host lib (libz2.a).
Only places i could find it referenced were:
  * etc/man.conf - for manpage compression (we only do and trac .gz ones).
  * etc/release  - for compressing the kernel sources (that is outside build
                   and already have a dependencies from DPorts).
+1-11 files

DragonFlyBSD/src 4620ab9. Makefile_upgrade.inc, lib/libncurses/libpanel Makefile

ncurses: Privatize the last public header.

Just move it with rest of privatized ncurses headers. Only user in base is
usr.sbin/installer/dfuife_curses/ and include path is already handled there.
As of this moment we are sure that none of private ncurses bits are used for
bootstrapping the world (non-interactive make/shell scripts redirected to
file should not care about colors anyway or try to format the layout).

No functional change.

DragonFlyBSD/src 30573b9. Makefile.inc1, bin/csh Makefile

btools: Remove /bin/csh from the list.

Our buildworld infrastructure does not use it (/bin/sh is used).
The csh is quite a complicated shell (ncurses, crypto deps).
One place less to trip while upgrading to newer releases.
This should simplify all the private libs handling.

DragonFlyBSD/src 5f5251ebin/sh Makefile

btools: Do not link with LIBEDIT for bin/sh.

The -DNO_HISTORY already disables all libprivate_edit functionality and
libncurses is only a dep for libedit. Simply remove extra dependencies.
Keeps btools slim and cleaner.
+1-191 files

DragonFlyBSD/src c2e4744. Makefile.inc1, share/terminfo Makefile

ncurses: Hook in fully bootstrapped tic_next.

This hopefully will allow for better future bootstraps better and w/o hacks.
Problem with tic(1) is his special knowledge through <progs.priv.h> header.
Because it is not a standard application (that uses only public headers) we
simply cannot expect to just compile three new main sources sources + link
with previously built libncurses.a from older release. Also, tic(1) during
buildworld builds terminfo binary database for the *new* ncurses lib version
and not for the *old* one. So full bootstrap is in order.

Note, share/terminfo database can still be built by a world installed tic(1).

DragonFlyBSD/src a0f7baalib/libncurses Makefile.sources Makefile, lib/libncurses/libtic Makefile

ncurses: Add hostprog variant of tic.

Tic(1) uses some of internal bits of ncurses implementation.
  * For now include a basic set of libncurses.
  * Link this tic with wide version of ncurses.
  * Adjust sources a bit for future reference.

DragonFlyBSD/src 9b45160lib/libncurses Makefile.sources Makefile.inc, lib/libncurses/libpanel Makefile

ncurses: Move in panel handling to Makefile.sources.

While there, install panel.h header only from a single place.
Previously it was installing it from both libpanel and libpanelw.
The libpanelw lib is currently unused in the world tree, while the
libpanel is only used by installer.

No functional change.

DragonFlyBSD/src aceb376lib/libncurses Makefile.sources Makefile.inc, lib/libncurses/libncurses Makefile

ncurses: Separate generators and sources list.

Keeps everything concentrated outside libncurses lib.
Add a bit of source sorting too.

No functional change, just moving stuff around.

DragonFlyBSD/src e011ff3lib/libncurses Makefile.inc, lib/libncurses/libncurses Makefile

ncurses: Do not use LIB_SUFFIX.

In preparations for update.

While there, remove two unused variables.

DragonFlyBSD/src d538e10contrib/ncurses/progs dump_entry.c

Revert "bootstrap: Expand BOOTSTRAPPING case to avoid warning."

This reverts commit 6b9ba3e86a05417c2af9786967ec92fc136cffde.