CVS commit: src

2019-04-27 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 27 15:45:21 UTC 2019 Modified Files: src/lib/libnvmm: nvmm.h src/sys/dev/nvmm: nvmm.h src/sys/dev/nvmm/x86: nvmm_x86.h nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Reorder the NVMM headers, to make a clear(er)

CVS commit: src/sys/arch/x86/x86

2019-04-27 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 27 10:40:17 UTC 2019 Modified Files: src/sys/arch/x86/x86: spectre.c Log Message: Add support for EnhancedIBRS, a more performant mitigation for SpectreV2, available on future CPUs (or maybe they already exist now...). To

CVS commit: src/sys/dev/nvmm/x86

2019-04-27 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 27 09:06:18 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: If guest events were being processed when a #VMEXIT occurred, reschedule the events rather than dismissing them. This can

CVS commit: src/sys/dev/nvmm/x86

2019-04-27 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 27 08:16:19 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_vmx.c nvmm_x86_vmxfunc.S Log Message: Optimize nvmm-intel, use inlined GCC assembly rather than function calls. To generate a diff of this commit: cvs rdi

CVS commit: src/sys/dev/nvmm/x86

2019-04-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 24 18:45:15 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svmfunc.S nvmm_x86_vmxfunc.S Log Message: Match the structure order, for better cache utilization. To generate a diff of this commit: cvs rdiff -u -r1.2 -

CVS commit: src/sys/dev/nvmm

2019-04-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 24 18:19:28 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm.h src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Provide the hardware error code for NVMM_EXIT_INVALID, useful when debugging. To genera

CVS commit: src/doc

2019-04-20 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 21 06:48:37 UTC 2019 Modified Files: src/doc: TODO.nvmm Log Message: update To generate a diff of this commit: cvs rdiff -u -r1.1 -r1.2 src/doc/TODO.nvmm Please note that diffs are not public domain; they are subject to t

CVS commit: src/doc

2019-04-20 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 21 06:46:03 UTC 2019 Modified Files: src/doc: CHANGES Log Message: Note removal of COMPAT_OSF1. To generate a diff of this commit: cvs rdiff -u -r1.2526 -r1.2527 src/doc/CHANGES Please note that diffs are not public domai

CVS commit: src/sys/arch/x86/x86

2019-04-20 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 21 06:37:21 UTC 2019 Modified Files: src/sys/arch/x86/x86: bus_dma.c db_memrw.c kgdb_machdep.c svs.c x86_tlb.c Log Message: Rename the PTE bits. To generate a diff of this commit: cvs rdiff -u -r1.77 -r1.78 src

CVS commit: src/sys/dev/nvmm/x86

2019-04-20 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 20 08:45:30 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Ah, take XSAVE into account in ECX too, not just in EBX. Otherwise if the guest relies only on ECX to initialize/copy the

CVS commit: src/sys/kern

2019-04-14 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 14 09:09:55 UTC 2019 Modified Files: src/sys/kern: uipc_socket.c Log Message: Add more checks, if the values are negative we hit a KASSERT later in the timeout. Reported-by: syzbot+662dbeb526303f458...@syzkaller.appspotmail

CVS commit: src/sys

2019-04-13 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 13 08:41:37 UTC 2019 Modified Files: src/sys/arch/amd64/conf: GENERIC src/sys/conf: files src/sys/kern: subr_pool.c src/sys/sys: pool.h Log Message: Introduce POOL_QUARANTINE, a feature that creates a

CVS commit: src/sys/dev/pci

2019-04-12 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 13 06:17:33 UTC 2019 Modified Files: src/sys/dev/pci: vioscsi.c Log Message: Fix use-after-free. If we're not polling, virtio_enqueue_commit() will send the transaction, and it means 'xs' can be immediately freed. So, save t

CVS commit: src/sys

2019-04-11 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Apr 11 17:43:45 UTC 2019 Modified Files: src/sys/kern: subr_asan.c src/sys/sys: systm.h Log Message: Add KASAN instrumentation for copyin/copyinstr/copyoutstr. No copyout for now, because mm.c needs whitelisting. To ge

CVS commit: src

2019-04-10 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 10 18:49:04 UTC 2019 Modified Files: src/lib/libnvmm: libnvmm.c nvmm.h src/sys/dev/nvmm: nvmm.c nvmm_internal.h nvmm_ioctl.h src/sys/secmodel/suser: secmodel_suser.c src/sys/sys: kauth.h Log Message:

CVS commit: src/sys/kern

2019-04-08 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Apr 8 18:38:45 UTC 2019 Modified Files: src/sys/kern: uipc_socket.c Log Message: Reset so_cred to NULL after freeing it, because close() may leave the PCB in pcblist, and we don't want a future lookup (via eg netstat) to read f

CVS commit: src/sys/dev/nvmm

2019-04-08 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Apr 8 18:30:55 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm.c Log Message: Switch to MODULE_CLASS_MISC, from pgoyette@. To generate a diff of this commit: cvs rdiff -u -r1.15 -r1.16 src/sys/dev/nvmm/nvmm.c Please note tha

CVS commit: src/sys/dev/nvmm

2019-04-08 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Apr 8 18:23:47 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm.c Log Message: Don't forget to call (*machine_destroy) when killing VMs. To generate a diff of this commit: cvs rdiff -u -r1.14 -r1.15 src/sys/dev/nvmm/nvmm.c Pl

CVS commit: src/sys/dev/nvmm

2019-04-08 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Apr 8 18:21:42 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm.c nvmm_internal.h Log Message: Use the fd_clone approach, to avoid losing references to the registered VMs during fork(). We attach an nvmm_owner struct to the fd,

CVS commit: src/sys/dev/nvmm/x86

2019-04-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 7 14:28:50 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Invert the filtering priority: now the kernel-managed cpuid leaves are overwritable by the virtualizer. This is useful to

CVS commit: src/lib/libnvmm

2019-04-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 7 14:13:03 UTC 2019 Modified Files: src/lib/libnvmm: libnvmm.3 Log Message: Sync, and fix grammar. To generate a diff of this commit: cvs rdiff -u -r1.13 -r1.14 src/lib/libnvmm/libnvmm.3 Please note that diffs are not pu

CVS commit: src/sys/dev/nvmm

2019-04-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 7 14:05:15 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm.c Log Message: Don't allow unloading when there are still VMs registered, and don't allow auto-unloading at all. Not a big problem actually, because since I changed

CVS commit: src/sys

2019-04-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 7 09:20:04 UTC 2019 Modified Files: src/sys/kern: kern_malloc.c subr_asan.c subr_kmem.c subr_pool.c src/sys/sys: asan.h src/sys/uvm: uvm_glue.c Log Message: Provide a code argument in kasan_mark(), and give

CVS commit: src/sys/kern

2019-04-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Apr 7 08:37:38 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Fix tiny race in pool+KASAN, that resulted in occasional false positives. We were uselessly marking already valid areas as valid. When doing that,

CVS commit: src/sys/dev/nvmm/x86

2019-04-06 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Apr 6 11:49:53 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86.c nvmm_x86.h nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Replace the misc[] state by a new compressed nvmm_x64_state_intr structure, which descri

CVS commit: src/lib/libnvmm

2019-04-04 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Apr 4 17:33:47 UTC 2019 Modified Files: src/lib/libnvmm: libnvmm.3 libnvmm.c libnvmm_x86.c nvmm.h Log Message: Check the GPA permissions too in the Assists, because it is possible that the guest traps on a page the virtualizer

CVS commit: src/sys/netinet6

2019-04-03 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 3 19:23:38 UTC 2019 Modified Files: src/sys/netinet6: ip6_output.c Log Message: Fix small read overflow; harmless, because since I removed RH0, the memory access on IPV6_RTHDR that would normally be illegal is not needed, a

CVS commit: src/sys/arch/amd64/stand/prekern

2019-04-03 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 3 19:14:25 UTC 2019 Modified Files: src/sys/arch/amd64/stand/prekern: console.c Log Message: When scrolling the screen don't forget to update the last line. Whatever, there is no case where the screen scrolls actually. To

CVS commit: src/sys/dev/nvmm/x86

2019-04-03 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 3 19:10:58 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86.c nvmm_x86.h nvmm_x86_vmx.c Log Message: VMX: if PAT is not valid, #GP on WRMSR, rather than crashing the guest. To generate a diff of this commit: cvs rd

CVS commit: src/sys/dev/nvmm/x86

2019-04-03 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 3 18:05:55 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_vmx.c Log Message: Add new VMCS bits. To generate a diff of this commit: cvs rdiff -u -r1.21 -r1.22 src/sys/dev/nvmm/x86/nvmm_x86_vmx.c Please note that

CVS commit: src/sys/dev/nvmm/x86

2019-04-03 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Apr 3 17:32:58 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86.c nvmm_x86.h nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Add MSR_TSC. To generate a diff of this commit: cvs rdiff -u -r1.3 -r1.4 src/sys/dev/n

CVS commit: src/sys/kern

2019-03-31 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 31 19:54:36 UTC 2019 Modified Files: src/sys/kern: uipc_socket.c Log Message: Also check for MT_CONTROL, and end the receive operation if we see one. It is possible to get an MT_CONTROL if we sleep in MSG_WAITALL. The other

CVS commit: src

2019-03-28 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 28 19:00:41 UTC 2019 Modified Files: src/share/man/man4: nvmm.4 src/sys/arch/amd64/conf: GENERIC src/sys/dev/nvmm: files.nvmm nvmm.c Log Message: Move NVMM in the "any" class, so that it can be enabled in GEN

CVS commit: src/sys/kern

2019-03-28 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 28 18:12:24 UTC 2019 Modified Files: src/sys/kern: subr_pool.c vfs_init.c Log Message: Move pnbuf_cache into vfs_init.c, where it belongs. To generate a diff of this commit: cvs rdiff -u -r1.245 -r1.246 src/sys/kern/subr_p

CVS commit: src/sys

2019-03-27 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Mar 27 18:27:47 UTC 2019 Modified Files: src/sys/kern: subr_pool.c src/sys/sys: pool.h Log Message: Kernel Heap Hardening: detect frees-in-wrong-pool on on-page pools. The detection is already implicitly done for off-pag

CVS commit: src/sys/kern

2019-03-26 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Tue Mar 26 20:05:18 UTC 2019 Modified Files: src/sys/kern: subr_kmem.c Log Message: Remove unneeded PR_NOALIGN, pool_allocator_kmem is already page-aligned. To generate a diff of this commit: cvs rdiff -u -r1.73 -r1.74 src/sys/ker

CVS commit: src/sys

2019-03-26 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Tue Mar 26 18:31:30 UTC 2019 Modified Files: src/sys/kern: subr_pool.c src/sys/sys: pool.h Log Message: Remove POOL_SUBPAGE, it is unused, undocumented, and adds confusion. To generate a diff of this commit: cvs rdiff -u -

CVS commit: src

2019-03-25 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Mar 25 19:24:31 UTC 2019 Modified Files: src/distrib/sets/lists/man: mi src/share/man/man4: options.4 src/share/man/man7: hier.7 symlink.7 src/share/man/man8: Makefile src/sys/arch/alpha/alpha: com

CVS commit: src/sys/compat/linux/arch/alpha

2019-03-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 24 16:39:47 UTC 2019 Modified Files: src/sys/compat/linux/arch/alpha: linux_syscall.h linux_syscallargs.h linux_syscalls.c linux_sysent.c Log Message: regen To generate a diff of this commit: cvs rdiff -u -r1.1

CVS commit: src/sys/compat

2019-03-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 24 16:24:20 UTC 2019 Modified Files: src/sys/compat/linux/arch/alpha: files.linux_alpha syscalls.master src/sys/compat/osf1: files.osf1 Added Files: src/sys/compat/linux/arch/alpha: linux_osf1.c linux_osf1.h

CVS commit: src/sys

2019-03-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 24 15:58:32 UTC 2019 Modified Files: src/sys/arch/amd64/amd64: machdep.c netbsd32_machdep.c src/sys/compat/linux32/arch/amd64: linux32_machdep.c Log Message: Disable preemption when setting PCB_COMPAT32, to prevent a

CVS commit: src/sys

2019-03-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 24 13:15:43 UTC 2019 Modified Files: src/sys/arch/amd64/amd64: machdep.c src/sys/compat/linux/arch/amd64: linux_machdep.c Log Message: Fix a tiny race in setregs and linux_setregs. Between the moment we set pcb_flags

CVS commit: src/sys/arch/hppa

2019-03-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Mar 23 13:05:24 UTC 2019 Modified Files: src/sys/arch/hppa/conf: GENERIC files.hppa src/sys/arch/hppa/hppa: trap.S Log Message: Remove references to COMPAT_OSF1 in HPPA, it has never been supported on this architecture.

CVS commit: src/sys/sys

2019-03-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Mar 23 12:01:18 UTC 2019 Modified Files: src/sys/sys: queue.h Log Message: Enable QUEUEDEBUG under DIAGNOSTIC. It has never been documented and used, but it's very useful and costs basically nothing. I even think we could enable

CVS commit: src/sys/arch/x86/x86

2019-03-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Mar 23 10:02:05 UTC 2019 Modified Files: src/sys/arch/x86/x86: spectre.c svs.c Log Message: In fact, xc_broadcast also applies to offline CPUs, so we don't need to make sure each CPU is online. Remove the checks, I suspect they

CVS commit: src

2019-03-21 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 21 20:21:41 UTC 2019 Modified Files: src/lib/libnvmm: libnvmm.3 libnvmm.c src/sys/dev/nvmm: nvmm.c nvmm.h nvmm_ioctl.h src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c src/tests/lib/libnvmm: h_io_as

CVS commit: src/tests/lib/libnvmm

2019-03-19 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Tue Mar 19 19:23:39 UTC 2019 Modified Files: src/tests/lib/libnvmm: h_io_assist.c h_io_assist_asm.S h_mem_assist.c h_mem_assist_asm.S Log Message: Add CVS ids, and rename the PTE bits. No functional change. To generate

CVS commit: src/sys/arch/amd64/stand/prekern

2019-03-19 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Tue Mar 19 19:15:57 UTC 2019 Modified Files: src/sys/arch/amd64/stand/prekern: locore.S prekern.c trap.S Log Message: Fix/remove some half-baked stuff I left in the prekern: - Page-align the idt store, to be extra sure. - Remove

CVS commit: src/sys/kern

2019-03-18 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Mar 18 20:34:48 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Kernel Heap Hardening: manage freed items with bitmaps rather than linked lists when we're on-page and the page header is naturally big enough to co

CVS commit: src/sys

2019-03-17 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 17 19:57:55 UTC 2019 Modified Files: src/sys/kern: subr_pool.c src/sys/sys: pool.h Log Message: Introduce a new flag, PR_USEBMAP, that indicates whether the pool uses a bitmap to manage freed items. It dissociates PR

CVS commit: src/sys/kern

2019-03-17 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 17 15:33:50 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Kernel Heap Hardening: put the pool header at the beginning of the backing page, not at the end of it. This makes it harder to exploit buffer overf

CVS commit: src/sys/kern

2019-03-17 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 17 14:52:25 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Move some code into a separate function, and explain a bit. Also define PHSIZE. No functional change. To generate a diff of this commit: cvs rdiff

CVS commit: src/sys/kern

2019-03-17 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 17 07:22:18 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: cosmetic To generate a diff of this commit: cvs rdiff -u -r1.238 -r1.239 src/sys/kern/subr_pool.c Please note that diffs are not public domain; t

CVS commit: src/sys/kern

2019-03-16 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 17 06:55:06 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Prepare the removal of the 'ioff' argument: add a KASSERT to ensure it is zero, and remove the internal logic. The pool code is simpler now. To ge

CVS commit: src/sys/arch/arm/xscale

2019-03-16 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 17 06:36:22 UTC 2019 Modified Files: src/sys/arch/arm/xscale: iopaau.c iopaaureg.h Log Message: Hard-align the fields of the structures with __aligned(32), and pass ioff=0 in the pool cache. To generate a diff of this comm

CVS commit: src/sys/kern

2019-03-16 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Mar 16 13:33:10 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Misc changes: - Turn two KASSERTs to real panics, they are useful and not expensive. - Rename a few variables for clarity. - Add a new panic, to

CVS commit: src/sys/arch/alpha/conf

2019-03-16 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Mar 16 08:03:04 UTC 2019 Modified Files: src/sys/arch/alpha/conf: GENERIC Log Message: Disable COMPAT_OSF1, will be removed. To generate a diff of this commit: cvs rdiff -u -r1.389 -r1.390 src/sys/arch/alpha/conf/GENERIC Plea

CVS commit: src/sys/dev/nvmm/x86

2019-03-14 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 14 20:29:53 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_vmx.c Log Message: Optimize NVMM-Intel: keep the VMCS active on the host CPU, and lazy-switch it on demand only when needed. This allows the CPU to use the

CVS commit: src/sys/dev/nvmm/x86

2019-03-14 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 14 19:26:44 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_vmx.c Log Message: Move a KASSERT, applies to all branches. To generate a diff of this commit: cvs rdiff -u -r1.17 -r1.18 src/sys/dev/nvmm/x86/nvmm_x86_vm

CVS commit: src/sys/dev/nvmm/x86

2019-03-14 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 14 19:15:26 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svm.c Log Message: Reduce the mask of the VTPR, only the first four bits matter. To generate a diff of this commit: cvs rdiff -u -r1.33 -r1.34 src/sys/dev

CVS commit: src/sys/dev/nvmm

2019-03-14 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 14 19:10:28 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm.c Log Message: Fail early if we're beyond the guest max ram. To generate a diff of this commit: cvs rdiff -u -r1.9 -r1.10 src/sys/dev/nvmm/nvmm.c Please note tha

CVS commit: src/sys/kern

2019-03-13 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Wed Mar 13 20:56:33 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: style To generate a diff of this commit: cvs rdiff -u -r1.235 -r1.236 src/sys/kern/subr_pool.c Please note that diffs are not public domain; they

CVS commit: src/sys/kern

2019-03-11 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Mar 11 20:38:28 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Add sanity check: make sure we retrieve a valid item header, by checking its page address against the one we computed. If there's a mismatch it mean

CVS commit: src/sys/kern

2019-03-11 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Mar 11 20:21:33 UTC 2019 Modified Files: src/sys/kern: subr_pool.c Log Message: Rename pr_item_notouch_* to pr_item_bitmap_*, and move some code into new pr_item_linkedlist_* functions. This makes it easier to see that we have t

CVS commit: src/sys/arch

2019-03-10 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 10 16:30:01 UTC 2019 Modified Files: src/sys/arch/x86/include: pmap.h src/sys/arch/x86/x86: pmap.c src/sys/arch/xen/x86: xen_pmap.c Log Message: Two changes: * Allow large pages to be passed in pmap_pdes_va

CVS commit: src/sys/arch

2019-03-09 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Mar 9 09:09:56 UTC 2019 Modified Files: src/sys/arch/amd64/include: pmap.h src/sys/arch/i386/include: pmap.h Log Message: New software PTE bits. To generate a diff of this commit: cvs rdiff -u -r1.59 -r1.60 src/sys/ar

CVS commit: src/sys/arch

2019-03-09 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Mar 9 08:42:26 UTC 2019 Modified Files: src/sys/arch/amd64/amd64: db_disasm.c gdt.c locore.S machdep.c src/sys/arch/amd64/include: asan.h pte.h src/sys/arch/amd64/stand/prekern: locore.S mm.c src/sys/arch

CVS commit: src/sys/kern

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 18:32:10 UTC 2019 Modified Files: src/sys/kern: kern_malloc.c Log Message: Mmh, fix len, mh_size includes the malloc header, but we don't redzone it. To generate a diff of this commit: cvs rdiff -u -r1.155 -r1.156 src/s

CVS commit: src/lib/libnvmm

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 15:47:34 UTC 2019 Modified Files: src/lib/libnvmm: libnvmm_x86.c Log Message: Micro optimizations: - Compress x86_rexpref, x86_regmodrm, x86_opcode and x86_instr. - Cache-align the register, opcode and group tables. -

CVS commit: src/sys/dev/nvmm

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 15:22:22 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm.c nvmm_internal.h Log Message: Rename the internal NVMM HVA table entries from "segment" to "hmapping", less confusing. Also fix the error handling in nvmm_hva_unma

CVS commit: src/sys/dev/nvmm/x86

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 15:06:37 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_vmx.c Log Message: Parse EXC_NMI on nvmm-intel, and don't return NVMM_EXIT_INVALID if we received a host NMI, otherwise the guest could get killed if an NMI

CVS commit: src/sys/arch

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 14:40:35 UTC 2019 Modified Files: src/sys/arch/amd64/include: pte.h src/sys/arch/i386/include: pte.h Log Message: Introduce a new set of PTE bits, with a different naming convention. PG_V -> PTE_P

CVS commit: src/sys/arch

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 13:26:25 UTC 2019 Modified Files: src/sys/arch/amd64/amd64: locore.S src/sys/arch/amd64/include: pte.h src/sys/arch/amd64/stand/prekern: locore.S mm.c src/sys/arch/i386/i386: genassym.cf locore.S ma

CVS commit: src/sys/arch/i386/include

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 13:02:13 UTC 2019 Modified Files: src/sys/arch/i386/include: pte.h Log Message: Style, and remove useless comments. To generate a diff of this commit: cvs rdiff -u -r1.27 -r1.28 src/sys/arch/i386/include/pte.h Please n

CVS commit: src/sys

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 12:29:14 UTC 2019 Modified Files: src/sys/kern: uipc_socket.c src/sys/sys: socketvar.h Log Message: Remove getsombuf(), unused. To generate a diff of this commit: cvs rdiff -u -r1.270 -r1.271 src/sys/kern/uipc_s

CVS commit: src/sys/kern

2019-03-07 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Mar 7 12:22:43 UTC 2019 Modified Files: src/sys/kern: uipc_socket.c Log Message: style To generate a diff of this commit: cvs rdiff -u -r1.269 -r1.270 src/sys/kern/uipc_socket.c Please note that diffs are not public domain;

CVS commit: src/sys/uvm

2019-03-03 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 3 17:37:36 UTC 2019 Modified Files: src/sys/uvm: uvm_map.c Log Message: Fix bug, the entry we're iterating on is 'current', not 'entry'. Here only the first entry gets wired in. To generate a diff of this commit: cvs rdif

CVS commit: src/sys/arch/x86/acpi

2019-03-03 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 3 17:33:33 UTC 2019 Modified Files: src/sys/arch/x86/acpi: acpi_machdep.c Log Message: Fix bug, PG_W is 'wired', not 'writable'. To generate a diff of this commit: cvs rdiff -u -r1.22 -r1.23 src/sys/arch/x86/acpi/acpi_mac

CVS commit: src/sys/arch/aarch64/conf

2019-03-02 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 3 07:04:40 UTC 2019 Modified Files: src/sys/arch/aarch64/conf: Makefile.aarch64 Log Message: Add KASAN use-after-scope detection in aarch64, tested by Ryo Shimizu, thanks. To generate a diff of this commit: cvs rdiff -u -

CVS commit: src/sys/dev/nvmm/x86

2019-03-02 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Mar 3 07:01:09 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86.c nvmm_x86.h nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Choose which CPUID bits to allow, rather than which bits to disallow. This is clearer, a

CVS commit: src

2019-02-26 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Tue Feb 26 12:23:12 UTC 2019 Modified Files: src/lib/libnvmm: libnvmm_x86.c src/sys/dev/nvmm/x86: nvmm_x86.c nvmm_x86.h nvmm_x86_svm.c nvmm_x86_vmx.c src/tests/lib/libnvmm: h_io_assist.c h_mem_assist.c Lo

CVS commit: src/lib/libnvmm

2019-02-26 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Tue Feb 26 10:18:39 UTC 2019 Modified Files: src/lib/libnvmm: libnvmm_x86.c Log Message: Set hardseg to -1 rather than 0, because 0 can be a valid segment. To generate a diff of this commit: cvs rdiff -u -r1.24 -r1.25 src/lib/libn

CVS commit: src/sys/netipsec

2019-02-25 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Tue Feb 26 06:52:34 UTC 2019 Modified Files: src/sys/netipsec: keysock.c Log Message: Fix locking: it is fine if the lock is already key_so_mtx, this can happen in socketpair. In that case don't take it. Ok ozaki-r@ Reported-by: s

CVS commit: src/sys/netinet

2019-02-25 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Feb 25 10:49:16 UTC 2019 Modified Files: src/sys/netinet: tcp_output.c Log Message: Improve panic messages. To generate a diff of this commit: cvs rdiff -u -r1.210 -r1.211 src/sys/netinet/tcp_output.c Please note that diffs a

CVS commit: src/sys/netinet6

2019-02-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Feb 25 07:31:32 UTC 2019 Modified Files: src/sys/netinet6: udp6_usrreq.c Log Message: Fix the order in udp6_attach: soreserve should be called before in6_pcballoc, otherwise if it fails there is still a PCB attached, and we hit

CVS commit: src/sys

2019-02-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Feb 25 06:49:44 UTC 2019 Modified Files: src/sys/netcan: can_pcb.c src/sys/netinet: sctp_usrreq.c src/sys/netinet6: raw_ip6.c sctp6_usrreq.c Log Message: RIP6, CAN, SCTP and SCTP6 lack a length check in their _se

CVS commit: src/sys/kern

2019-02-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Feb 24 10:44:41 UTC 2019 Modified Files: src/sys/kern: subr_asan.c Log Message: Improve the KASAN output, provide an error code, to help distinguish classes of bugs. To generate a diff of this commit: cvs rdiff -u -r1.4 -r1.5

CVS commit: src/sys

2019-02-24 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Feb 24 08:02:45 UTC 2019 Modified Files: src/sys/arch/amd64/conf: Makefile.amd64 src/sys/kern: subr_asan.c Log Message: Add support for use-after-scope detection in KASAN. It is available since GCC7, and we have GCC7 by

CVS commit: src/sys

2019-02-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sun Feb 24 07:20:33 UTC 2019 Modified Files: src/sys/netatalk: ddp_usrreq.c src/sys/netinet: raw_ip.c sctp_usrreq.c src/sys/netinet6: raw_ip6.c sctp6_usrreq.c Log Message: RIP, RIP6, DDP, SCTP and SCTP6 lack a length

CVS commit: src/sys

2019-02-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Feb 23 12:27:00 UTC 2019 Modified Files: src/sys/dev/nvmm: nvmm_internal.h src/sys/dev/nvmm/x86: nvmm_x86.h nvmm_x86_svm.c nvmm_x86_vmx.c src/sys/modules/nvmm: Makefile Added Files: src/sys/dev/nvmm/x86: n

CVS commit: src/sys/arch/x86

2019-02-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Feb 23 10:59:12 UTC 2019 Modified Files: src/sys/arch/x86/include: pmap.h src/sys/arch/x86/x86: pmap.c Log Message: Move PATENTRY into pmap.h, will be used outside. To generate a diff of this commit: cvs rdiff -u -r1.9

CVS commit: src/sys

2019-02-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Feb 23 10:43:37 UTC 2019 Modified Files: src/sys/arch/x86/x86: pmap.c src/sys/dev/nvmm/x86: nvmm_x86_vmx.c Log Message: Add support for CPUs that don't have the EPT_{A,D} bits. On such CPUs, these bits are ignored by th

CVS commit: src/sys/dev/nvmm/x86

2019-02-23 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Sat Feb 23 08:19:16 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Reorder the functions, and constify setstate. No functional change. To generate a diff of this commit: cvs rdiff -u -r1.

CVS commit: src/sys/dev/nvmm/x86

2019-02-22 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Fri Feb 22 12:24:34 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_vmx.c Log Message: Fix omission: if we receive a guest trap on CR0, and if the original instruction would have resulted in Long Mode being enabled, we need

CVS commit: src/doc

2019-02-21 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Feb 21 14:56:23 UTC 2019 Added Files: src/doc: TODO.nvmm Log Message: Add a TODO list for NVMM, just to list some known issues. To generate a diff of this commit: cvs rdiff -u -r0 -r1.1 src/doc/TODO.nvmm Please note that diff

CVS commit: src/sys/arch/x86/x86

2019-02-21 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Feb 21 14:31:55 UTC 2019 Modified Files: src/sys/arch/x86/x86: pmap.c Log Message: Remove wrong KASSERT in EPT, and reorder the code to reduce duplication. To generate a diff of this commit: cvs rdiff -u -r1.324 -r1.325 src/sy

CVS commit: src/sys/dev/nvmm/x86

2019-02-21 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Feb 21 13:25:44 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_vmx.c Log Message: Reorder the detection in vmx_ident(), to fix panic on old CPUs. We must read MSR_IA32_VMX_EPT_VPID_CAP _after_ ensuring EPT is there, bec

CVS commit: src/sys

2019-02-21 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Feb 21 12:17:52 UTC 2019 Modified Files: src/sys/arch/x86/x86: x86_tlb.c src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Another locking issue in NVMM: the {svm,vmx}_tlb_flush functions take VCPU mutexes

CVS commit: src/sys/dev/nvmm/x86

2019-02-21 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Thu Feb 21 11:58:04 UTC 2019 Modified Files: src/sys/dev/nvmm/x86: nvmm_x86_svm.c nvmm_x86_vmx.c Log Message: Clarify the gTLB code a little. To generate a diff of this commit: cvs rdiff -u -r1.27 -r1.28 src/sys/dev/nvmm/x86/nvmm_

CVS commit: src/sys/arch/x86/x86

2019-02-18 Thread Maxime Villard
Module Name:src Committed By: maxv Date: Mon Feb 18 19:03:12 UTC 2019 Modified Files: src/sys/arch/x86/x86: pmap.c Log Message: Fix stupid mistake, I didn't reflect correctly the behavior of pmap_sync_pv in the EPT callback, 'optep' can be NULL. To generate a diff of thi

<    1   2   3   4   5   6   7   8   9   10   >