svn commit: r303153 - head/share/man/man7

2016-07-21 Thread Konstantin Belousov
Author: kib Date: Thu Jul 21 16:58:53 2016 New Revision: 303153 URL: https://svnweb.freebsd.org/changeset/base/303153 Log: Remove spurious but harmless double-quote. Noted by: jhb Modified: head/share/man/man7/arch.7 Modified: head/share/man/man7/arch.7

svn commit: r303154 - head/sys/kern

2016-07-21 Thread Konstantin Belousov
Author: kib Date: Thu Jul 21 17:07:06 2016 New Revision: 303154 URL: https://svnweb.freebsd.org/changeset/base/303154 Log: Declare aio requests on files from local filesystems safe. Two notes: - I allow AIO on reclaimed vnodes, since it is deterministically terminated fast. - devfs

svn commit: r302893 - head/sys/kern

2016-07-15 Thread Konstantin Belousov
Author: kib Date: Fri Jul 15 09:23:18 2016 New Revision: 302893 URL: https://svnweb.freebsd.org/changeset/base/302893 Log: Do not allow creation of char or block special nodes with VNOVAL dev_t. As was reported on http://seclists.org/oss-sec/2016/q3/68, tmpfs code contains assertion that

svn commit: r302981 - head/sys/kern

2016-07-17 Thread Konstantin Belousov
Author: kib Date: Mon Jul 18 04:30:34 2016 New Revision: 302981 URL: https://svnweb.freebsd.org/changeset/base/302981 Log: Fix another bug after r302350. Reported and tested by: pho PR: 210884 Sponsored by: The FreeBSD Foundation MFC after:3 days Modified:

Re: svn commit: r303033 - head/share/man/man7

2016-07-19 Thread Konstantin Belousov
On Wed, Jul 20, 2016 at 05:01:03AM +0200, Jan Beich wrote: > Ed Maste writes: > > > +.It Sy Architecture Ta Sy Page Sizes > > +.It amd64 Ta 4K, 2M, 1G > > Does FreeBSD support 1G pages nowadays? Define what do you mean by 'support'. The direct map is mapped with 1G

svn commit: r303090 - head/sys/ufs/ufs

2016-07-20 Thread Konstantin Belousov
Author: kib Date: Wed Jul 20 14:40:56 2016 New Revision: 303090 URL: https://svnweb.freebsd.org/changeset/base/303090 Log: Ensure that the UFS directory vnode' vm_object is properly sized before UFS_BALLOC() is called. I do not believe that this caused any real issue on FreeBSD because the

svn commit: r302936 - head/sys/kern

2016-07-16 Thread Konstantin Belousov
Author: kib Date: Sat Jul 16 13:24:58 2016 New Revision: 302936 URL: https://svnweb.freebsd.org/changeset/base/302936 Log: Another issue reported on http://seclists.org/oss-sec/2016/q3/68 is that struct kevent member ident has uintptr_t type, which is silently truncated to int in the call

svn commit: r302770 - in head: sys/kern sys/sys usr.bin/kdump

2016-07-13 Thread Konstantin Belousov
Author: kib Date: Wed Jul 13 14:37:58 2016 New Revision: 302770 URL: https://svnweb.freebsd.org/changeset/base/302770 Log: Trace timeval parameters to the getitimer(2) and setitimer(2) syscalls. Reviewed by: jhb Tested by:pho Sponsored by: The FreeBSD Foundation MFC after:1

svn commit: r302613 - head/sys/kern

2016-07-11 Thread Konstantin Belousov
Author: kib Date: Tue Jul 12 03:52:05 2016 New Revision: 302613 URL: https://svnweb.freebsd.org/changeset/base/302613 Log: Add assert to complement r302328. AST must not execute with TDF_SBDRY or TDF_SEINTR/TDF_SERESTART thread flags set, which is asserted in userret(). As the

svn commit: r302614 - head/sys/kern

2016-07-11 Thread Konstantin Belousov
Author: kib Date: Tue Jul 12 03:53:15 2016 New Revision: 302614 URL: https://svnweb.freebsd.org/changeset/base/302614 Log: Revive the check, disabled in r197963. Despite the implication (process has pending signals -> the current thread marked for AST and has TDF_NEEDSIGCHK set) is not

svn commit: r302999 - head/sys/kern

2016-07-18 Thread Konstantin Belousov
Author: kib Date: Mon Jul 18 10:53:47 2016 New Revision: 302999 URL: https://svnweb.freebsd.org/changeset/base/302999 Log: The assertion re-added in r302614 was triggered when stopping signal is delivered to vforked child. Issue is that we avoid stopping such children in issignal() to not

svn commit: r302919 - head/sys/kern

2016-07-15 Thread Konstantin Belousov
Author: kib Date: Fri Jul 15 23:26:33 2016 New Revision: 302919 URL: https://svnweb.freebsd.org/changeset/base/302919 Log: In ptrace_vm_entry(), do not call vmspace_free() while owning a vm object lock. The vmspace_free() operations might need to lock map, object etc on last

svn commit: r302251 - head/sys/kern

2016-06-28 Thread Konstantin Belousov
Author: kib Date: Tue Jun 28 16:42:40 2016 New Revision: 302251 URL: https://svnweb.freebsd.org/changeset/base/302251 Log: Do not use Giant to prevent parallel calls to CLOCK_SETTIME(). Use private mtx in resettodr(), no implementation of CLOCK_SETTIME() is allowed to sleep. Reviewed

svn commit: r302252 - head/sys/kern

2016-06-28 Thread Konstantin Belousov
Author: kib Date: Tue Jun 28 16:43:23 2016 New Revision: 302252 URL: https://svnweb.freebsd.org/changeset/base/302252 Log: Currently the ntptime code and resettodr() are Giant-locked. In particular, the Giant is supposed to protect against parallel ntp_adjtime(2) invocations. But, for

svn commit: r302250 - head/sys/kern

2016-06-28 Thread Konstantin Belousov
Author: kib Date: Tue Jun 28 16:41:50 2016 New Revision: 302250 URL: https://svnweb.freebsd.org/changeset/base/302250 Log: Complete r302215. TDF_SBDRY | TDF_SERESTART and TDF_SBDRY | TDF_SEINTR flags values, unlike TDF_SBDRY, must be treated almost as if TDF_SBDRY is not set for STOP

svn commit: r302343 - head/sys/vm

2016-07-05 Thread Konstantin Belousov
Author: kib Date: Tue Jul 5 11:21:02 2016 New Revision: 302343 URL: https://svnweb.freebsd.org/changeset/base/302343 Log: Clarify the vnode_destroy_vobject() logic handling for already terminated objects. Assert that there is no new waiters for the already terminated objects. Old

Re: svn commit: r302517 - in head/sys: amd64/linux amd64/linux32 compat/linux i386/linux modules/linux modules/linux_common

2016-07-10 Thread Konstantin Belousov
On Sun, Jul 10, 2016 at 08:22:04AM +, Dmitry Chagin wrote: > Author: dchagin > Date: Sun Jul 10 08:22:04 2016 > New Revision: 302517 > URL: https://svnweb.freebsd.org/changeset/base/302517 > > Log: > Fix a copy/paste bug introduced during X86_64 Linuxulator work. > FreeBSD support NX bit

svn commit: r302567 - in head/sys: kern vm

2016-07-11 Thread Konstantin Belousov
Author: kib Date: Mon Jul 11 14:19:09 2016 New Revision: 302567 URL: https://svnweb.freebsd.org/changeset/base/302567 Log: In vgonel(), postpone setting BO_DEAD until VOP_RECLAIM() is called, if vnode is VMIO. For VMIO vnodes, set BO_DEAD in vm_object_terminate(). The

svn commit: r302573 - head/sys/i386/i386

2016-07-11 Thread Konstantin Belousov
Author: kib Date: Mon Jul 11 15:52:52 2016 New Revision: 302573 URL: https://svnweb.freebsd.org/changeset/base/302573 Log: Fill tf_trapno for trap frames created for syscall. If tf_trapno contains garbage which appears to be equal to T_NMI, e.g. due to thread previously entered kernel

svn commit: r302580 - head/sys/kern

2016-07-11 Thread Konstantin Belousov
Author: kib Date: Mon Jul 11 17:04:22 2016 New Revision: 302580 URL: https://svnweb.freebsd.org/changeset/base/302580 Log: Fix grammar. Submitted by: alc MFC after:2 weeks Modified: head/sys/kern/vfs_subr.c Modified: head/sys/kern/vfs_subr.c

svn commit: r303795 - in head/lib: libc/include libc/stdlib libc/tests/stdlib libthr/thread

2016-08-06 Thread Konstantin Belousov
Author: kib Date: Sat Aug 6 13:32:40 2016 New Revision: 303795 URL: https://svnweb.freebsd.org/changeset/base/303795 Log: Add __cxa_thread_atexit(3) API implementation. This is the backing feature to implement C++11 thread storage duration specified by the thread_local keyword. A

svn commit: r303794 - head/lib/libc

2016-08-06 Thread Konstantin Belousov
Author: kib Date: Sat Aug 6 13:28:58 2016 New Revision: 303794 URL: https://svnweb.freebsd.org/changeset/base/303794 Log: Create namespace for the symbols added during 12-CURRENT cycle. Sponsored by: The FreeBSD Foundation MFC after:2 weeks Modified: head/lib/libc/Versions.def

svn commit: r303712 - in head/sys: amd64/amd64 conf i386/i386 x86/x86

2016-08-03 Thread Konstantin Belousov
Author: kib Date: Wed Aug 3 13:51:53 2016 New Revision: 303712 URL: https://svnweb.freebsd.org/changeset/base/303712 Log: Merge i386 and amd64 variants of mp_watchdog.c into x86/, there is no difference between files. For pc98, put x86/mp_x86.c into the same place as used by i386 file

Re: svn commit: r303712 - in head/sys: amd64/amd64 conf i386/i386 x86/x86

2016-08-03 Thread Konstantin Belousov
On Wed, Aug 03, 2016 at 01:51:53PM +, Konstantin Belousov wrote: > Merge i386 and amd64 variants of mp_watchdog.c into x86/, there is no > difference between files. May be, the file should be deleted. ___ svn-src-head@freebsd.org mailin

Re: svn commit: r302252 - head/sys/kern

2016-06-30 Thread Konstantin Belousov
On Fri, Jul 01, 2016 at 03:30:41AM +1000, Bruce Evans wrote: > On Thu, 30 Jun 2016, Konstantin Belousov wrote: > > > On Thu, Jun 30, 2016 at 05:47:39AM +1000, Bruce Evans wrote: > >> On Wed, 29 Jun 2016, Konstantin Belousov wrote: > >> > >>> On Wed, Ju

Re: svn commit: r302252 - head/sys/kern

2016-06-30 Thread Konstantin Belousov
On Thu, Jun 30, 2016 at 09:01:06PM +0300, Konstantin Belousov wrote: > Yes, timehands for bootimebin should be the solution, but > not in the scope of this patch. I will work on this right after the > current changeset lands in svn. Well, there is the move of boottimebin into timehands

Re: svn commit: r302252 - head/sys/kern

2016-06-29 Thread Konstantin Belousov
This is a reply to two mails in one, both for r302251 and r302252 threads. On Wed, Jun 29, 2016 at 05:58:05PM +1000, Bruce Evans wrote: > On Tue, 28 Jun 2016, Konstantin Belousov wrote: > > > Log: > > Do not use Giant to prevent parallel calls to CLOCK_SETTIME(). Us

Re: svn commit: r302252 - head/sys/kern

2016-06-29 Thread Konstantin Belousov
On Wed, Jun 29, 2016 at 05:54:43PM +0300, Konstantin Belousov wrote: > This is a reply to two mails in one, both for r302251 and r302252 threads. > > On Wed, Jun 29, 2016 at 05:58:05PM +1000, Bruce Evans wrote: > > On Tue, 28 Jun 2016, Konstantin Belousov wrote: > > > &g

Re: svn commit: r302252 - head/sys/kern

2016-06-29 Thread Konstantin Belousov
On Thu, Jun 30, 2016 at 05:47:39AM +1000, Bruce Evans wrote: > On Wed, 29 Jun 2016, Konstantin Belousov wrote: > > > On Wed, Jun 29, 2016 at 05:54:43PM +0300, Konstantin Belousov wrote: > >> This is a reply to two mails in one, both for r302251 and r302252 threads. > &

svn commit: r302317 - head/sys/vm

2016-07-02 Thread Konstantin Belousov
Author: kib Date: Sun Jul 3 00:08:17 2016 New Revision: 302317 URL: https://svnweb.freebsd.org/changeset/base/302317 Log: Change type of the 'dead' variable to boolean. Requested by: alc MFC after:1 week Approved by: re (gjb) Modified: head/sys/vm/vm_fault.c Modified:

svn commit: r302322 - head/sys/kern

2016-07-02 Thread Konstantin Belousov
Author: kib Date: Sun Jul 3 01:56:48 2016 New Revision: 302322 URL: https://svnweb.freebsd.org/changeset/base/302322 Log: Remove racy assert. The thread which changes vnode usecount from 0 to 1 does it under the vnode interlock, but the interlock is not owned by the asserting thread. As

svn commit: r302328 - in head/sys: kern sys

2016-07-03 Thread Konstantin Belousov
Author: kib Date: Sun Jul 3 18:19:48 2016 New Revision: 302328 URL: https://svnweb.freebsd.org/changeset/base/302328 Log: Provide helper macros to detect 'non-silent SBDRY' state and to calculate appropriate return value for stops. Simplify the code by using them. Fix typo in

Re: svn commit: r302252 - head/sys/kern

2016-07-03 Thread Konstantin Belousov
On Sun, Jul 03, 2016 at 07:47:15PM -0500, Benjamin Kaduk wrote: > On Sat, Jul 2, 2016 at 3:04 AM, Bruce Evans wrote: > > > + .th_counter = _timecounter, > >> + .th_scale = (uint64_t)-1 / 100, > >> + .th_offset = {1, 0}, > >> > > > > Is there a syntax

svn commit: r302019 - head/sys/fs/nfsclient

2016-06-19 Thread Konstantin Belousov
Author: kib Date: Sun Jun 19 18:29:43 2016 New Revision: 302019 URL: https://svnweb.freebsd.org/changeset/base/302019 Log: Do not access NFS data for reclaimed vnode. Reported and tested by: pho Sponsored by: The FreeBSD Foundation MFC after:1 week Approved by: re

svn commit: r304232 - head/sys/ufs/ffs

2016-08-16 Thread Konstantin Belousov
Author: kib Date: Tue Aug 16 17:30:58 2016 New Revision: 304232 URL: https://svnweb.freebsd.org/changeset/base/304232 Log: In UFS_BALLOC(), invalidate pages of indirect buffers on failed block allocation unwinding. Dandling buffers are released on UFS_BALLOC() failure to ensure that

svn commit: r304209 - in head: lib/libc/include lib/libc/sys lib/libthr/thread share/man/man3

2016-08-16 Thread Konstantin Belousov
@@ +/* + * Copyright (c) 2016 The FreeBSD Foundation. + * All rights reserved. + * + * Portions of this software were developed by Konstantin Belousov + * under sponsorship from the FreeBSD Foundation. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted

svn commit: r304176 - in head: include lib/libc/sys sys/compat/freebsd32 sys/kern

2016-08-15 Thread Konstantin Belousov
Author: kib Date: Mon Aug 15 19:08:51 2016 New Revision: 304176 URL: https://svnweb.freebsd.org/changeset/base/304176 Log: Add an implementation of fdatasync(2). The syscall is a trivial wrapper around new VOP_FDATASYNC(), sharing code with fsync(2). For all filesystems, this commit

svn commit: r304177 - in head/sys: compat/freebsd32 kern sys

2016-08-15 Thread Konstantin Belousov
Author: kib Date: Mon Aug 15 19:15:46 2016 New Revision: 304177 URL: https://svnweb.freebsd.org/changeset/base/304177 Log: Regen after r304176, fdatasync(2) addition. Modified: head/sys/compat/freebsd32/freebsd32_proto.h head/sys/compat/freebsd32/freebsd32_syscall.h

svn commit: r304180 - head/sys/ufs/ffs

2016-08-15 Thread Konstantin Belousov
Author: kib Date: Mon Aug 15 19:22:23 2016 New Revision: 304180 URL: https://svnweb.freebsd.org/changeset/base/304180 Log: Implement VOP_FDATASYNC() for UFS. Reviewed by: mckusick Tested by:pho Sponsored by: The FreeBSD Foundation MFC after:2 weeks Differential revision:

svn commit: r304178 - in head/sys: fs/msdosfs kern sys

2016-08-15 Thread Konstantin Belousov
Author: kib Date: Mon Aug 15 19:17:00 2016 New Revision: 304178 URL: https://svnweb.freebsd.org/changeset/base/304178 Log: Implement VOP_FDATASYNC() for msdosfs. Standard VOP_FSYNC() implementation just syncs data buffers, and due to this, is the correct and efficient implementation for

svn commit: r304231 - head/sys/ufs/ffs

2016-08-16 Thread Konstantin Belousov
Author: kib Date: Tue Aug 16 17:18:38 2016 New Revision: 304231 URL: https://svnweb.freebsd.org/changeset/base/304231 Log: On unwind after failed block allocation in ffs_balloc_ufs{1,2}, assert that recorded allocated blocks numbers match the physical block numbers of dandling buffers which

Re: svn commit: r304182 - head/sys/compat/cloudabi

2016-08-15 Thread Konstantin Belousov
On Mon, Aug 15, 2016 at 07:42:21PM +, Ed Schouten wrote: > Author: ed > Date: Mon Aug 15 19:42:21 2016 > New Revision: 304182 > URL: https://svnweb.freebsd.org/changeset/base/304182 > > Log: > Let CloudABI use fdatasync() as well. > > Now that FreeBSD supports fdatasync() natively, we

Re: svn commit: r304185 - in head/sys: compat/cloudabi compat/linux kern sys

2016-08-15 Thread Konstantin Belousov
On Mon, Aug 15, 2016 at 08:11:52PM +, Ed Schouten wrote: > Author: ed > Date: Mon Aug 15 20:11:52 2016 > New Revision: 304185 > URL: https://svnweb.freebsd.org/changeset/base/304185 > > Log: > Eliminate use of sys_fsync() and sys_fdatasync(). > > Make the kern_fsync() function public,

svn commit: r304287 - head/lib/libc/sys

2016-08-17 Thread Konstantin Belousov
ved. +.\" +.\" Parts of this documentation were written by +.\" Konstantin Belousov <k...@freebsd.org> under sponsorship +.\" from the FreeBSD Foundation. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are perm

svn commit: r304285 - in head: lib/libc lib/libc/aarch64/sys lib/libc/amd64/sys lib/libc/arm/sys lib/libc/i386/sys lib/libc/sys lib/libc/x86 lib/libc/x86/sys sys/arm/arm sys/arm/include sys/arm64/a...

2016-08-17 Thread Konstantin Belousov
===== --- head/lib/libc/i386/sys/__vdso_gettc.c Wed Aug 17 09:21:55 2016 (r304281, copy source) +++ head/lib/libc/x86/sys/__vdso_gettc.c Wed Aug 17 09:52:09 2016 (r304285) @@ -1,5 +1,10 @@ /*- * Copyright (c) 2012 Konstantin Belousov <k...@free

Re: svn commit: r312975 - head/sys/i386/include

2017-02-02 Thread Konstantin Belousov
On Fri, Feb 03, 2017 at 05:14:15AM +1100, Bruce Evans wrote: > You won't want to ifdef this for SMP, so the i386 implementation has > further bugs like I expected (fcmpset is not implemented in the > CPU_DISABLE_CMPXCHG case). I think it is time to remove the option. It certainly outlived it

Re: svn commit: r313006 - in head: sys/conf sys/libkern sys/libkern/x86 sys/sys tests/sys/kern

2017-02-02 Thread Konstantin Belousov
On Tue, Jan 31, 2017 at 03:26:32AM +, Conrad E. Meyer wrote: > + compile-with"${CC} -c ${CFLAGS:N-nostdinc} ${WERROR} ${PROF} -msse4 > ${.IMPSRC}" \ BTW, new gcc has -mcrc32 option, but clang 3.9.1 apparently does not. ___

svn commit: r313109 - in head/sys/i386: i386 isa

2017-02-02 Thread Konstantin Belousov
Author: kib Date: Thu Feb 2 22:02:10 2017 New Revision: 313109 URL: https://svnweb.freebsd.org/changeset/base/313109 Log: Use ANSI definitions for some i386 functions. Sponsored by: The FreeBSD Foundation MFC after:1 week Modified: head/sys/i386/i386/machdep.c

Re: svn commit: r313177 - head/sys/cddl/contrib/opensolaris/uts/common/dtrace

2017-02-03 Thread Konstantin Belousov
On Fri, Feb 03, 2017 at 10:40:13PM +, George V. Neville-Neil wrote: > + > +#ifndef _DTRACE_XOROSHIRO128_PLUS_H > +#define _DTRACE_XOROSHIRO128_PLUS_H > +#endif This protective define is useless unless #endif is placed properly. > + > +#include > + > +extern void

Re: svn commit: r312988 - in head/sys: compat/cloudabi compat/linux kern sys

2017-01-31 Thread Konstantin Belousov
On Tue, Jan 31, 2017 at 03:07:27PM +, Edward Tomasz Napierala wrote: > On 0130T1502, Gleb Smirnoff wrote: > > On Mon, Jan 30, 2017 at 12:57:23PM +, Edward Tomasz Napierala wrote: > > E> Author: trasz > > E> Date: Mon Jan 30 12:57:22 2017 > > E> New Revision: 312988 > > E> URL:

Re: svn commit: r313040 - head/sys/mips/include

2017-02-01 Thread Konstantin Belousov
On Wed, Feb 01, 2017 at 05:00:34AM +, Alexander Kabaev wrote: > Author: kan > Date: Wed Feb 1 05:00:34 2017 > New Revision: 313040 > URL: https://svnweb.freebsd.org/changeset/base/313040 > > Log: > Add atomic_fcmpset_*() inlines for MIPS > > atomic_fcmpset_*() is analogous to

Re: svn commit: r313352 - in head/sys: compat/cloudabi compat/freebsd32 compat/linux vm

2017-02-07 Thread Konstantin Belousov
On Mon, Feb 06, 2017 at 03:03:11PM -0800, John Baldwin wrote: > On Monday, February 06, 2017 08:57:12 PM Edward Tomasz Napierala wrote: > > Author: trasz > > Date: Mon Feb 6 20:57:12 2017 > > New Revision: 313352 > > URL: https://svnweb.freebsd.org/changeset/base/313352 > > > > Log: > > Add

Re: svn commit: r313352 - in head/sys: compat/cloudabi compat/freebsd32 compat/linux vm

2017-02-07 Thread Konstantin Belousov
On Tue, Feb 07, 2017 at 02:50:15PM +0100, Mateusz Guzik wrote: > Can we start dropping the td argument? It always is curthread and > almost always has to be anyway as something down below accesses > data in a manner only safe for curthread (classic: credential checks). > > With this example the

Re: svn commit: r313040 - head/sys/mips/include

2017-02-01 Thread Konstantin Belousov
On Wed, Feb 01, 2017 at 10:38:42AM -0500, Alexander Kabaev wrote: > On Wed, 1 Feb 2017 16:17:21 +0200 > Konstantin Belousov <kostik...@gmail.com> wrote: > > > Please do not retry on sc failure, return the error to upper layer. > > See also r313007 and preceedi

svn commit: r313345 - in head/sys: arm/include arm64/include

2017-02-06 Thread Konstantin Belousov
Author: kib Date: Mon Feb 6 17:20:37 2017 New Revision: 313345 URL: https://svnweb.freebsd.org/changeset/base/313345 Log: Update arm and arm64 counters MD bits. On arm64 use atomics. Then, both arm and arm64 do not need a critical section around update. Replace all cpus loop by

Re: svn commit: r313352 - in head/sys: compat/cloudabi compat/freebsd32 compat/linux vm

2017-02-07 Thread Konstantin Belousov
On Tue, Feb 07, 2017 at 12:29:35PM -0600, Alan Cox wrote: > I tend to agree with John. Why not use the same types for the kern_* > parameters as are used in the corresponding args structure? Let the > conversion to the Mach VM types happen inside of the function's > implementation. I do not

svn commit: r313194 - in head/sys: arm/include arm64/include mips/include powerpc/include riscv/include sparc64/include sys x86/include

2017-02-04 Thread Konstantin Belousov
Author: kib Date: Sat Feb 4 12:26:38 2017 New Revision: 313194 URL: https://svnweb.freebsd.org/changeset/base/313194 Log: Define the vm_ooffset_t and vm_pindex_t types as machine-independend. The types are for the byte offset and page index in vm object. They are similar to off_t,

svn commit: r313249 - head/sys/vm

2017-02-04 Thread Konstantin Belousov
Author: kib Date: Sat Feb 4 19:16:19 2017 New Revision: 313249 URL: https://svnweb.freebsd.org/changeset/base/313249 Log: Style, use tab after #define. Reviewed by: alc Sponsored by: The FreeBSD Foundation MFC after:3 days Modified: head/sys/vm/vm_object.h Modified:

svn commit: r313154 - in head/sys: conf i386/conf i386/i386 i386/include i386/isa i386/linux x86/acpica x86/x86

2017-02-03 Thread Konstantin Belousov
Author: kib Date: Fri Feb 3 12:51:40 2017 New Revision: 313154 URL: https://svnweb.freebsd.org/changeset/base/313154 Log: For i386, remove config options CPU_DISABLE_CMPXCHG, CPU_DISABLE_SSE and device npx. This means that FPU is always initialized and handled when available, and SSE+

svn commit: r312645 - head/sys/kern

2017-01-22 Thread Konstantin Belousov
Author: kib Date: Sun Jan 22 19:36:02 2017 New Revision: 312645 URL: https://svnweb.freebsd.org/changeset/base/312645 Log: Provide fallback VOP methods for crossmp vnode. In particular, crossmp vnode might leak into rename code. PR: 216380 Reported by: fn...@protonmail.com

Re: svn commit: r312600 - head/sys/kern

2017-01-22 Thread Konstantin Belousov
On Mon, Jan 23, 2017 at 04:00:19AM +1100, Bruce Evans wrote: > On Sun, 22 Jan 2017, Konstantin Belousov wrote: > > > On Sun, Jan 22, 2017 at 11:41:09PM +1100, Bruce Evans wrote: > >> On Sun, 22 Jan 2017, Mateusz Guzik wrote: > >>> ... > >>> I have to

svn commit: r312646 - head/sys/kern

2017-01-22 Thread Konstantin Belousov
Author: kib Date: Sun Jan 22 19:38:45 2017 New Revision: 312646 URL: https://svnweb.freebsd.org/changeset/base/312646 Log: More style cleanup. Use ANSI C definition for vn_closefile(). Switch to VNASSERT in _vn_lock(), simplify messages. Sponsored by: The FreeBSD Foundation X-MFC

svn commit: r312649 - head/share/man/man5

2017-01-22 Thread Konstantin Belousov
Author: kib Date: Sun Jan 22 19:50:23 2017 New Revision: 312649 URL: https://svnweb.freebsd.org/changeset/base/312649 Log: Document mount option "nonc" for tmpfs. Sponsored by: The FreeBSD Foundation MFC after:2 weeks Differential revision:https://reviews.freebsd.org/D9258

svn commit: r312647 - head/sys/kern

2017-01-22 Thread Konstantin Belousov
Author: kib Date: Sun Jan 22 19:41:42 2017 New Revision: 312647 URL: https://svnweb.freebsd.org/changeset/base/312647 Log: Add comments explaining unobvious td_critnest adjustments in critical_exit(). Based on the discussion with: jhb Reviewed by: imp Sponsored by: The FreeBSD

svn commit: r312648 - head/share/man/man5

2017-01-22 Thread Konstantin Belousov
Author: kib Date: Sun Jan 22 19:46:14 2017 New Revision: 312648 URL: https://svnweb.freebsd.org/changeset/base/312648 Log: Editing and clarifications for tmpfs(5). Submitted by: wblock Sponsored by: The FreeBSD Foundation MFC after:1 week Differential revision:

Re: svn commit: r312588 - head/sys/mips/conf

2017-01-21 Thread Konstantin Belousov
On Sat, Jan 21, 2017 at 09:08:28AM +, Brooks Davis wrote: > +options TMPFS #Efficient memory filesystem Is the word 'efficient' copied from somewhere ? Yes, I see it in sys/conf/NOTES. I do not see what useful meaning the word has there, applied to the tmpfs. In my

Re: svn commit: r312600 - head/sys/kern

2017-01-21 Thread Konstantin Belousov
On Sat, Jan 21, 2017 at 06:38:17PM +, Mateusz Guzik wrote: > Author: mjg > Date: Sat Jan 21 18:38:16 2017 > New Revision: 312600 > URL: https://svnweb.freebsd.org/changeset/base/312600 > > Log: > vfs: refactor _vn_lock > > Stop testing for LK_RETRY and error multiple times. Also

Re: svn commit: r312588 - head/sys/mips/conf

2017-01-21 Thread Konstantin Belousov
On Sat, Jan 21, 2017 at 10:50:54AM -0700, Ian Lepore wrote: > On Sat, 2017-01-21 at 13:41 +0200, Konstantin Belousov wrote: > > On Sat, Jan 21, 2017 at 09:08:28AM +, Brooks Davis wrote: > > > > > > +optionsĀ  TMPFS #Efficient memory > > > f

Re: svn commit: r312770 - in head/sys: net netinet netinet6

2017-01-25 Thread Konstantin Belousov
On Wed, Jan 25, 2017 at 02:20:06PM -0800, Gleb Smirnoff wrote: > Thanks, Luiz! > > One stylistic nit that I missed in review: > > L> static int > L> -in_difaddr_ioctl(caddr_t data, struct ifnet *ifp, struct thread *td) > L> +in_difaddr_ioctl(u_long cmd, caddr_t data, struct ifnet *ifp,

Re: svn commit: r312973 - head/sys/powerpc/include

2017-01-30 Thread Konstantin Belousov
> +#ifdef __GNUCLIKE_ASM > + __asm __volatile ( > + "1:\tlwarx %0, 0, %3\n\t" /* load old value */ > + "cmplw %4, %0\n\t" /* compare */ > + "bne 2f\n\t"/* exit if not equal */ > + "stwcx. %5, 0, %3\n\t"

svn commit: r312954 - in head/sys: amd64/amd64 i386/i386

2017-01-29 Thread Konstantin Belousov
Author: kib Date: Sun Jan 29 19:14:48 2017 New Revision: 312954 URL: https://svnweb.freebsd.org/changeset/base/312954 Log: Do not leave stale 4K TLB entries on pde (superpage) removal or protection change. On superpage promotion, x86 pmaps do not invalidate existing 4K entries for the

Re: svn commit: r312600 - head/sys/kern

2017-01-22 Thread Konstantin Belousov
On Sun, Jan 22, 2017 at 11:41:09PM +1100, Bruce Evans wrote: > On Sun, 22 Jan 2017, Mateusz Guzik wrote: > > > On Sun, Jan 22, 2017 at 12:07:56PM +1100, Bruce Evans wrote: > > ... > >> Later commits further unimproved style by adding __predict_ugly() and > >> long lines from blind substitution of

svn commit: r313798 - head/bin/ls

2017-02-15 Thread Konstantin Belousov
Author: kib Date: Thu Feb 16 06:32:39 2017 New Revision: 313798 URL: https://svnweb.freebsd.org/changeset/base/313798 Log: Use uintmax_t to print st_nlink. Sponsored by: The FreeBSD Foundation MFC after:1 week Modified: head/bin/ls/print.c Modified: head/bin/ls/print.c

svn commit: r313797 - head/sys/fs/devfs

2017-02-15 Thread Konstantin Belousov
Author: kib Date: Thu Feb 16 06:31:36 2017 New Revision: 313797 URL: https://svnweb.freebsd.org/changeset/base/313797 Log: Minor style fixes. Sponsored by: The FreeBSD Foundation MFC after:3 days Modified: head/sys/fs/devfs/devfs_devs.c Modified: head/sys/fs/devfs/devfs_devs.c

Re: svn commit: r313798 - head/bin/ls

2017-02-15 Thread Konstantin Belousov
On Thu, Feb 16, 2017 at 06:32:39AM +, Konstantin Belousov wrote: > Author: kib > Date: Thu Feb 16 06:32:39 2017 > New Revision: 313798 > URL: https://svnweb.freebsd.org/changeset/base/313798 > > Log: > Use uintmax_t to print st_nlink. > > Sponsored by:

svn commit: r313799 - head/sys/fs/nfsclient

2017-02-15 Thread Konstantin Belousov
Author: kib Date: Thu Feb 16 06:34:20 2017 New Revision: 313799 URL: https://svnweb.freebsd.org/changeset/base/313799 Log: Do not allocate char[MNAMELEN] on stack in nfsclient. Right now this is not critical, but will be after planned increase of MNAMELEN from 88 to 1k. Reported and

svn commit: r313800 - head/sys/fs/nfsclient

2017-02-15 Thread Konstantin Belousov
Author: kib Date: Thu Feb 16 06:36:16 2017 New Revision: 313800 URL: https://svnweb.freebsd.org/changeset/base/313800 Log: Do not access memory past the buffer end. Do not accept and silently truncate too long hostname. Reported and tested by: pho Sponsored by: The FreeBSD

svn commit: r314087 - head/sys/x86/x86

2017-02-21 Thread Konstantin Belousov
Author: kib Date: Wed Feb 22 07:07:05 2017 New Revision: 314087 URL: https://svnweb.freebsd.org/changeset/base/314087 Log: More fixes for regression in r313898 on i386. Use long long constants where needed. Reported and tested by: kargl Sponsored by: The FreeBSD Foundation MFC

svn commit: r313933 - head/sys/amd64/amd64

2017-02-18 Thread Konstantin Belousov
Author: kib Date: Sun Feb 19 03:33:20 2017 New Revision: 313933 URL: https://svnweb.freebsd.org/changeset/base/313933 Log: Microoptimize amd64/pmap.c pmap_protect_pde(). For the loop that dirties vm_pages in case superpage was written to, check the complete condition before the loop.

svn commit: r313934 - head/sys/x86/x86

2017-02-18 Thread Konstantin Belousov
Author: kib Date: Sun Feb 19 03:57:41 2017 New Revision: 313934 URL: https://svnweb.freebsd.org/changeset/base/313934 Log: Fix regression in r313898 on i386. Use large enough type for calculation of mtrr physmask. Typical cpu_maxphyaddr is 36 or larger. Reported and tested by:

svn commit: r313939 - head/sys/i386/i386

2017-02-18 Thread Konstantin Belousov
Author: kib Date: Sun Feb 19 06:14:33 2017 New Revision: 313939 URL: https://svnweb.freebsd.org/changeset/base/313939 Log: MFamd64 r313933: microoptimize pmap_protect_pde(). Noted by: alc Sponsored by: The FreeBSD Foundation MFC after:1 week Modified:

svn commit: r313967 - in head/sys: fs/devfs kern

2017-02-19 Thread Konstantin Belousov
Author: kib Date: Sun Feb 19 20:51:04 2017 New Revision: 313967 URL: https://svnweb.freebsd.org/changeset/base/313967 Log: Apply noexec mount option for mmap(PROT_EXEC). Right now the noexec mount option disallows image activators to try execve the files on the mount point. Also, after

svn commit: r313966 - head/sys/arm/arm

2017-02-19 Thread Konstantin Belousov
Author: kib Date: Sun Feb 19 20:40:07 2017 New Revision: 313966 URL: https://svnweb.freebsd.org/changeset/base/313966 Log: MFamd64 r313933: microoptimize pmap_protect_pte1(). Noted by: alc Tested by:mmel Sponsored by: The FreeBSD Foundation MFC after:1 week Modified:

svn commit: r313898 - in head/sys: amd64/amd64 conf i386/i386 modules/mem x86/x86

2017-02-17 Thread Konstantin Belousov
3898) @@ -1,7 +1,11 @@ /*- * Copyright (c) 1999 Michael Smith <msm...@freebsd.org> + * Copyright (c) 2017 The FreeBSD Foundation * All rights reserved. * + * Portions of this software were developed by Konstantin Belousov + * under sponsorship from the FreeBSD Foundation. +

svn commit: r313903 - head/sys/x86/x86

2017-02-17 Thread Konstantin Belousov
Author: kib Date: Fri Feb 17 22:50:41 2017 New Revision: 313903 URL: https://svnweb.freebsd.org/changeset/base/313903 Log: Rely on CPUID feature only to enable attaching. MTRR are architectural and there is no reason to check cpu family or vendor. Noted by: royger Reviewed by: jhb

svn commit: r313902 - head/sys/x86/x86

2017-02-17 Thread Konstantin Belousov
Author: kib Date: Fri Feb 17 22:49:52 2017 New Revision: 313902 URL: https://svnweb.freebsd.org/changeset/base/313902 Log: smp_rendezvous() works for UP case as well, reduce duplicated code. Also fix cast and remove unneeded XXX in comment. Noted and reviewed by: jhb Sponsored by: The

svn commit: r314195 - head/sys/vm

2017-02-24 Thread Konstantin Belousov
Author: kib Date: Fri Feb 24 08:09:16 2017 New Revision: 314195 URL: https://svnweb.freebsd.org/changeset/base/314195 Log: Properly handle possible underflow in vm_fault_prefault(). In vm_fault_prefault(), if backward count causes underflow in calculation of starta = addra -

Re: svn commit: r314179 - in head: contrib/netbsd-tests/lib/librt include lib/libc/gen lib/libc/include share/man/man3 sys/kern

2017-02-24 Thread Konstantin Belousov
On Thu, Feb 23, 2017 at 07:36:39PM +, Eric van Gyzen wrote: > Modified: head/include/semaphore.h > == > --- head/include/semaphore.h Thu Feb 23 19:32:25 2017(r314178) > +++ head/include/semaphore.h Thu Feb 23

Re: svn commit: r314087 - head/sys/x86/x86

2017-02-24 Thread Konstantin Belousov
On Thu, Feb 23, 2017 at 06:33:43AM +1100, Bruce Evans wrote: > On Wed, 22 Feb 2017, Konstantin Belousov wrote: > > > Log: > > More fixes for regression in r313898 on i386. > > Use long long constants where needed. > > The long long abomination is never needed

Re: svn commit: r314087 - head/sys/x86/x86

2017-02-25 Thread Konstantin Belousov
On Sat, Feb 25, 2017 at 02:17:23PM +1100, Bruce Evans wrote: > On Fri, 24 Feb 2017, Konstantin Belousov wrote: > > > On Thu, Feb 23, 2017 at 06:33:43AM +1100, Bruce Evans wrote: > >> On Wed, 22 Feb 2017, Konstantin Belousov wrote: > >> > >>> Log: &

svn commit: r314252 - head/sys/x86/x86

2017-02-25 Thread Konstantin Belousov
Author: kib Date: Sat Feb 25 10:32:49 2017 New Revision: 314252 URL: https://svnweb.freebsd.org/changeset/base/314252 Log: Do not use ULL suffix. Cast to uint64_t where the suffix is needed, and just remove it in another place. Requested by: bde Sponsored by: The FreeBSD Foundation

Re: svn commit: r314216 - head/sys/x86/x86

2017-02-25 Thread Konstantin Belousov
On Sat, Feb 25, 2017 at 09:50:32AM +0200, Andriy Gapon wrote: > On 24/02/2017 20:56, Jonathan T. Looney wrote: > > Author: jtl > > Date: Fri Feb 24 18:56:00 2017 > > New Revision: 314216 > > URL: https://svnweb.freebsd.org/changeset/base/314216 > > > > Log: > > We have seen several cases

svn commit: r314253 - in head/sys: fs/nfsserver kern sys ufs/ffs

2017-02-25 Thread Konstantin Belousov
Author: kib Date: Sat Feb 25 10:38:18 2017 New Revision: 314253 URL: https://svnweb.freebsd.org/changeset/base/314253 Log: Do not leak mount references for dying threads. Thread might create a condition for delayed SU cleanup, which creates a reference to the mount point in td_su, but

svn commit: r314211 - in head/sys: dev/acpica kern sys x86/x86

2017-02-24 Thread Konstantin Belousov
Author: kib Date: Fri Feb 24 16:11:55 2017 New Revision: 314211 URL: https://svnweb.freebsd.org/changeset/base/314211 Log: Remove cpu_deepest_sleep variable. On Core2 and older Intel CPUs, where TSC stops in C2, system does not allow C2 entrance if timecounter hardware is TSC. This is

svn commit: r313655 - head/sys/vm

2017-02-11 Thread Konstantin Belousov
Author: kib Date: Sat Feb 11 20:27:39 2017 New Revision: 313655 URL: https://svnweb.freebsd.org/changeset/base/313655 Log: Change type of the prot parameter for kern_vm_mmap() from vm_prot_t to int. This makes the code to pass whole word of the mmap(2) syscall argument prot to the

svn commit: r313715 - head/sys/sys

2017-02-13 Thread Konstantin Belousov
Author: kib Date: Tue Feb 14 03:32:37 2017 New Revision: 313715 URL: https://svnweb.freebsd.org/changeset/base/313715 Log: Order alphabetically. Noted by: alc MFC after:3 days Modified: head/sys/sys/syscallsubr.h Modified: head/sys/sys/syscallsubr.h

svn commit: r313493 - head/sys/sys

2017-02-09 Thread Konstantin Belousov
Author: kib Date: Thu Feb 9 23:32:03 2017 New Revision: 313493 URL: https://svnweb.freebsd.org/changeset/base/313493 Log: Define ELF_ST_VISIBILITY(). Sponsored by: The FreeBSD Foundation MFC after:2 weeks Modified: head/sys/sys/elf_generic.h Modified: head/sys/sys/elf_generic.h

svn commit: r313496 - head/sys/kern

2017-02-09 Thread Konstantin Belousov
Author: kib Date: Thu Feb 9 23:36:50 2017 New Revision: 313496 URL: https://svnweb.freebsd.org/changeset/base/313496 Log: Increase a chance of devfs_close() calling d_close cdevsw method. If a file opened over a vnode has an advisory lock set at close, vn_closefile() acquires additional

svn commit: r313495 - head/sys/kern

2017-02-09 Thread Konstantin Belousov
Author: kib Date: Thu Feb 9 23:35:57 2017 New Revision: 313495 URL: https://svnweb.freebsd.org/changeset/base/313495 Log: Do not establish advisory locks when doing open(O_EXLOCK) or open(O_SHLOCK) for files which do not have DTYPE_VNODE type. Both flock(2) and fcntl(2) syscalls refuse

svn commit: r313494 - head/libexec/rtld-elf

2017-02-09 Thread Konstantin Belousov
Author: kib Date: Thu Feb 9 23:33:06 2017 New Revision: 313494 URL: https://svnweb.freebsd.org/changeset/base/313494 Log: Handle protected symbols in rtld. Protected symbol reference in GOT of the defining object must be resolved to itself, same as -Bsymbolic globally. Discussed

<    4   5   6   7   8   9   10   11   12   13   >