Linux 4.4.168
Greg KH
maintainerI'm announcing the release of the 4.4.168 kernel.
All users of the 4.4 kernel series must upgrade.
The updated 4.4.y git tree can be found at:
git://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable.git linux-4.4.y
and can be browsed at the normal kernel.org git web browser:
http://git.kernel.org/?p=linux/kernel/git/stable/linux-stable.git;a=summary
thanks,
greg k-h
------------
Documentation/Makefile | 3 Documentation/networking/Makefile | 1 Documentation/networking/timestamping/.gitignore | 3 Documentation/networking/timestamping/Makefile | 14 Documentation/networking/timestamping/hwtstamp_config.c | 134 - Documentation/networking/timestamping/timestamping.c | 528 ------- Documentation/networking/timestamping/txtimestamp.c | 549 ------- Makefile | 2 arch/arm/mach-omap1/board-ams-delta.c | 3 arch/arm/mach-omap2/prm44xx.c | 2 arch/cris/arch-v32/drivers/cryptocop.c | 4 arch/ia64/kernel/err_inject.c | 2 arch/mips/mm/gup.c | 2 arch/s390/kernel/perf_cpum_cf.c | 2 arch/s390/mm/gup.c | 2 arch/sh/mm/gup.c | 3 arch/sparc/mm/gup.c | 3 arch/x86/include/asm/kvm_host.h | 2 arch/x86/include/asm/uaccess.h | 64 arch/x86/include/asm/uaccess_32.h | 26 arch/x86/include/asm/uaccess_64.h | 94 - arch/x86/kernel/cpu/common.c | 3 arch/x86/kvm/cpuid.c | 31 arch/x86/kvm/cpuid.h | 40 arch/x86/kvm/lapic.c | 2 arch/x86/kvm/svm.c | 143 + arch/x86/kvm/vmx.c | 741 +++++----- arch/x86/kvm/x86.c | 14 arch/x86/lib/usercopy_32.c | 20 arch/x86/mm/gup.c | 2 arch/x86/mm/mpx.c | 3 drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 6 drivers/gpu/drm/ast/ast_mode.c | 36 drivers/gpu/drm/exynos/exynos_drm_g2d.c | 3 drivers/gpu/drm/i915/i915_gem_userptr.c | 6 drivers/gpu/drm/radeon/radeon_ttm.c | 2 drivers/gpu/drm/via/via_dmablit.c | 4 drivers/hwmon/ina2xx.c | 2 drivers/hwmon/w83795.c | 2 drivers/infiniband/core/umem.c | 6 drivers/infiniband/core/umem_odp.c | 7 drivers/infiniband/hw/mthca/mthca_memfree.c | 4 drivers/infiniband/hw/qib/qib_user_pages.c | 3 drivers/infiniband/hw/usnic/usnic_uiom.c | 5 drivers/media/dvb-frontends/ascot2e.c | 4 drivers/media/dvb-frontends/cxd2841er.c | 4 drivers/media/dvb-frontends/horus3a.c | 4 drivers/media/dvb-frontends/itd1000.c | 5 drivers/media/dvb-frontends/mt312.c | 5 drivers/media/dvb-frontends/stb0899_drv.c | 3 drivers/media/dvb-frontends/stb6100.c | 6 drivers/media/dvb-frontends/stv0367.c | 4 drivers/media/dvb-frontends/stv090x.c | 4 drivers/media/dvb-frontends/stv6110x.c | 4 drivers/media/dvb-frontends/zl10039.c | 4 drivers/media/pci/ivtv/ivtv-udma.c | 3 drivers/media/pci/ivtv/ivtv-yuv.c | 8 drivers/media/platform/omap/omap_vout.c | 2 drivers/media/v4l2-core/videobuf-dma-sg.c | 7 drivers/media/v4l2-core/videobuf2-memops.c | 6 drivers/misc/mic/scif/scif_rma.c | 3 drivers/misc/sgi-gru/grufault.c | 2 drivers/net/ethernet/cavium/thunder/nic_main.c | 3 drivers/net/ethernet/hisilicon/hip04_eth.c | 4 drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c | 4 drivers/net/ethernet/realtek/8139cp.c | 5 drivers/net/ethernet/rocker/rocker.c | 24 drivers/net/phy/phy_device.c | 19 drivers/net/tun.c | 6 drivers/net/wireless/ath/wil6210/wmi.c | 8 drivers/scsi/sr_ioctl.c | 21 drivers/scsi/st.c | 5 drivers/staging/rdma/hfi1/user_pages.c | 2 drivers/staging/rdma/ipath/ipath_user_pages.c | 2 drivers/staging/speakup/kobjects.c | 4 drivers/usb/gadget/udc/omap_udc.c | 87 - drivers/video/fbdev/matrox/matroxfb_Ti3026.c | 2 drivers/video/fbdev/pvr2fb.c | 2 drivers/virt/fsl_hypervisor.c | 4 drivers/xen/xlate_mmu.c | 1 fs/btrfs/send.c | 11 fs/cachefiles/rdwr.c | 3 fs/exec.c | 9 fs/exportfs/expfs.c | 2 fs/fscache/object.c | 3 fs/hfs/btree.c | 3 fs/hfsplus/btree.c | 3 fs/hugetlbfs/inode.c | 30 fs/ocfs2/export.c | 2 fs/ocfs2/move_extents.c | 47 fs/proc/base.c | 19 fs/pstore/platform.c | 4 fs/sysv/inode.c | 2 include/linux/mm.h | 15 include/linux/posix-timers.h | 4 include/net/neighbour.h | 28 include/sound/pcm.h | 2 kernel/bpf/verifier.c | 98 + kernel/events/uprobes.c | 4 kernel/time/posix-cpu-timers.c | 2 kernel/time/posix-timers.c | 29 kernel/trace/bpf_trace.c | 8 lib/debugobjects.c | 3 lib/swiotlb.c | 20 mm/frame_vector.c | 9 mm/gup.c | 42 mm/hugetlb.c | 12 mm/memory.c | 18 mm/mempolicy.c | 2 mm/nommu.c | 42 mm/process_vm_access.c | 6 mm/util.c | 2 net/ceph/pagevec.c | 2 net/core/rtnetlink.c | 3 net/ipv4/tcp_output.c | 12 net/ipv6/ip6_output.c | 42 net/sched/sch_netem.c | 3 security/tomoyo/domain.c | 3 sound/core/pcm_lib.c | 2 sound/core/pcm_native.c | 6 sound/soc/omap/omap-dmic.c | 9 sound/soc/omap/omap-mcpdm.c | 43 sound/soc/soc-core.c | 1 tools/testing/selftests/networking/timestamping/.gitignore | 3 tools/testing/selftests/networking/timestamping/Makefile | 8 tools/testing/selftests/networking/timestamping/hwtstamp_config.c | 134 + tools/testing/selftests/networking/timestamping/timestamping.c | 528 +++++++ tools/testing/selftests/networking/timestamping/txtimestamp.c | 549 +++++++ virt/kvm/async_pf.c | 2 virt/kvm/kvm_main.c | 11 130 files changed, 2649 insertions(+), 2005 deletions(-)
Aaro Koskinen (4):
USB: omap_udc: use devm_request_irq()
USB: omap_udc: fix crashes on probe error and module removal
USB: omap_udc: fix omap_udc_start() on 15xx machines
USB: omap_udc: fix USB gadget functionality on Palm Tungsten E
Alexei Starovoitov (2):
bpf: support 8-byte metafield access
bpf: Prevent memory disambiguation attack
Arnd Bergmann (2):
media: dvb-frontends: fix i2c access helpers for KASAN
rocker: fix rocker_tlv_put_* functions for KASAN
Ashok Raj (1):
KVM/x86: Add IBPB support
Ben Hutchings (3):
bpf/verifier: Add spi variable to check_stack_write() bpf/verifier: Pass instruction index to check_mem_access() and check_xadd() mm/nommu.c: Switch __get_user_pages_unlocked() to use __get_user_pages()
Borislav Petkov (1):
x86/speculation: Use synthetic bits for IBRS/IBPB/STIBP
Christoph Paasch (1):
net: Prevent invalid access to skb->prev in __qdisc_drop_all
Colin Ian King (1):
fscache, cachefiles: remove redundant variable 'cache'
Dan Williams (3):
x86: Introduce __uaccess_begin_nospec() and uaccess_try_nospec x86/usercopy: Replace open coded stac/clac with __uaccess_{begin, end} x86/uaccess: Use __uaccess_begin_nospec() and uaccess_try_nospec
David Matlack (1):
KVM: nVMX: mark vmcs12 pages dirty on L2 exit
Eric Dumazet (1):
rtnetlink: ndo_dflt_fdb_dump() only work for ARPHRD_ETHER devices
Greg Kroah-Hartman (1):
Linux 4.4.168
Guenter Roeck (1):
staging: speakup: Replace strncpy with memcpy
Heiner Kallweit (1):
net: phy: don't allow __set_phy_supported to add unsupported modes
Huacai Chen (1):
hwmon: (w83795) temp4_type has writable permission
Janusz Krzysztofik (1):
ARM: OMAP1: ams-delta: Fix possible use of uninitialized field
Jens Axboe (1):
sr: pass down correctly sized SCSI sense buffer
Jim Mattson (1):
KVM: nVMX: Eliminate vmcs02 pool
Josh Elsasser (1):
ixgbe: recognize 1000BaseLX SFP modules as 1Gbps
KarimAllah Ahmed (3):
KVM/VMX: Emulate MSR_IA32_ARCH_CAPABILITIES KVM/VMX: Allow direct access to MSR_IA32_SPEC_CTRL KVM/SVM: Allow direct access to MSR_IA32_SPEC_CTRL
Kees Cook (1):
swiotlb: clean up reporting
Konrad Rzeszutek Wilk (2):
x86/bugs, KVM: Support the combination of guest and host IBRS x86/KVM/VMX: Expose SPEC_CTRL Bit(2) to the guest
Larry Chen (1):
ocfs2: fix deadlock caused by ocfs2_defrag_extent()
Linus Torvalds (3):
x86: reorganize SMAP handling in user space accesses
x86: fix SMAP in 32-bit environments
proc: don't use FOLL_FORCE for reading cmdline and environment
Lior David (1):
wil6210: missing length check in wmi_set_ie
Lorenzo Bianconi (1):
net: thunderx: fix NULL pointer dereference in nic_remove
Lorenzo Stoakes (8):
mm: remove write/force parameters from __get_user_pages_locked()
mm: remove write/force parameters from __get_user_pages_unlocked()
mm: replace get_user_pages_unlocked() write/force parameters with gup_flags
mm: replace get_user_pages_locked() write/force parameters with gup_flags
mm: replace get_vaddr_frames() write/force parameters with gup_flags
mm: replace get_user_pages() write/force parameters with gup_flags
mm: replace __access_remote_vm() write parameter with gup_flags
mm: replace access_remote_vm() write parameter with gup_flags
Martynas Pumputis (1):
bpf: fix check of allowed specifiers in bpf_trace_printk
Mike Kravetz (4):
mm/hugetlb.c: don't call region_abort if region_chg fails
hugetlbfs: fix offset overflow in hugetlbfs mmap
hugetlbfs: check for pgoff value overflow
hugetlbfs: fix bug in pgoff overflow checking
Namhyung Kim (1):
pstore: Convert console write to use ->write_buf
Nathan Chancellor (1):
ARM: OMAP2+: prm44xx: Fix section annotation on omap44xx_prm_enable_io_wakeup
NeilBrown (1):
fscache: fix race between enablement and dropping of object
Nicolas Dichtel (1):
tun: forbid iface creation with rtnl ops
Nicolin Chen (1):
hwmon: (ina2xx) Fix current value calculation
Pan Bian (5):
exportfs: do not read dentry after free
net: hisilicon: remove unexpected free_netdev
hfs: do not free node before using
hfsplus: do not free node before using
ocfs2: fix potential use after free
Paolo Bonzini (3):
KVM: VMX: introduce alloc_loaded_vmcs
KVM: VMX: make MSR bitmaps per-VCPU KVM/x86: Remove indirect MSR op calls from SPEC_CTRL
Peter Ujfalusi (2):
ASoC: omap-mcpdm: Add pm_qos handling to avoid under/overruns with CPU_IDLE
ASoC: omap-dmic: Add pm_qos handling to avoid overruns with CPU_IDLE
Qian Cai (1):
debugobjects: avoid recursive calls with kmemleak
Radim Krčmář (1):
KVM: nVMX: fix msr bitmaps to prevent L2 from accessing L0 x2APIC
Robbie Ko (1):
Btrfs: send, fix infinite loop due to directory rename dependencies
Shuah Khan (1):
selftests: Move networking/timestamping from Documentation
Srikanth Boddepalli (1):
xen: xlate_mmu: add missing header to fix 'W=1' warning
Stefano Brivio (2):
ipv6: Check available headroom in ip6_xmit() even without options
neighbour: Avoid writing before skb->head in neigh_hh_output()
Su Yanjun (1):
net: 8139cp: fix a BUG triggered by changing mtu with network traffic
Sudip Mukherjee (1):
matroxfb: fix size of memcpy
Takashi Sakamoto (1):
ALSA: pcm: remove SNDRV_PCM_IOCTL1_INFO internal command
Thomas Gleixner (3):
KVM: SVM: Move spec control call after restore of GS x86/bugs, KVM: Extend speculation control for VIRT_SPEC_CTRL
posix-timers: Sanitize overrun handling
Thomas Richter (1):
s390/cpum_cf: Reject request for sampling in event initialization
Tom Lendacky (1):
KVM: SVM: Implement VIRT_SPEC_CTRL support for SSBD
Tzung-Bi Shih (1):
ASoC: dapm: Recalculate audio map forcely when card instantiated
Willy Tarreau (1):
proc: do not access cmdline nor environ from file-backed areas
Y.C. Chen (1):
drm/ast: fixed reading monitor EDID not stable issue
Yi Wang (1):
KVM: x86: fix empty-body warnings
Yuchung Cheng (1):
tcp: fix NULL ref in tail loss probe
YueHaibing (1):
sysv: return 'err' instead of 0 in __sysv_write_inode
Greg KH
maintainerDocumentation/Makefile +1 -2
@@ -1,4 +1,3 @@ subdir-y := accounting auxdisplay blackfin connector \ filesystems filesystems ia64 laptops misc-devices \ - networking pcmcia prctl ptp spi timers vDSO video4linux \ - watchdog + pcmcia prctl ptp spi timers vDSO video4linux watchdog
Documentation/networking/Makefile deleted +0 -1
@@ -1 +0,0 @@ -subdir-y := timestamping
Documentation/networking/timestamping/.gitignore deleted +0 -3
@@ -1,3 +0,0 @@ -timestamping -txtimestamp -hwtstamp_config
Documentation/networking/timestamping/Makefile deleted +0 -14
@@ -1,14 +0,0 @@ -# To compile, from the source root -# -# make headers_install -# make M=documentation - -# List of programs to build -hostprogs-y := hwtstamp_config timestamping txtimestamp - -# Tell kbuild to always build the programs -always := $(hostprogs-y) - -HOSTCFLAGS_timestamping.o += -I$(objtree)/usr/include -HOSTCFLAGS_txtimestamp.o += -I$(objtree)/usr/include -HOSTCFLAGS_hwtstamp_config.o += -I$(objtree)/usr/include
Documentation/networking/timestamping/hwtstamp_config.c deleted +0 -134
134 lines not on this page · raw message
Documentation/networking/timestamping/timestamping.c deleted +0 -528
528 lines not on this page · raw message
Documentation/networking/timestamping/txtimestamp.c deleted +0 -549
549 lines not on this page · raw message
Makefile +1 -1
@@ -1,6 +1,6 @@ VERSION = 4 PATCHLEVEL = 4 -SUBLEVEL = 167 +SUBLEVEL = 168 EXTRAVERSION = NAME = Blurry Fish Butt
arch/arm/mach-omap1/board-ams-delta.c +3 -0
@@ -511,6 +511,9 @@ static void modem_pm(struct uart_port *port, unsigned int state, unsigned old) {struct modem_private_data *priv = port->private_data; +if (!priv) +return ; +if (IS_ERR (priv->regulator))return ;
arch/arm/mach-omap2/prm44xx.c +1 -1
@@ -344,7 +344,7 @@ static void omap44xx_prm_reconfigure_io_chain(void)* to occur, WAKEUPENABLE bits must be set in the pad mux registers, and * omap44xx_prm_reconfigure_io_chain() must be called. No return value. */ -static void __init omap44xx_prm_enable_io_wakeup (void ) +static void omap44xx_prm_enable_io_wakeup (void ) {s32 inst =omap4_prmst_get_prm_dev_inst ();
arch/cris/arch-v32/drivers/cryptocop.c +1 -3
@@ -2724,7 +2724,6 @@ static int cryptocop_ioctl_process(struct inode *inode, struct file *filp, unsig (unsigned long int )(oper.indata + prev_ix), noinpages,0 ,/* read access only for in data */ -0 ,/* no force */ inpages, NULL);
@@ -2740,8 +2739,7 @@ static int cryptocop_ioctl_process(struct inode *inode, struct file *filp, unsig current->mm, (unsigned long int )oper.cipher_outdata, nooutpages, -1 ,/* write access for out data */ -0 ,/* no force */ +FOLL_WRITE ,/* write access for out data */ outpages, NULL);up_read (¤t->mm->mmap_sem);
arch/ia64/kernel/err_inject.c +1 -1
@@ -143,7 +143,7 @@ store_virtual_to_phys(struct device *dev, struct device_attribute *attr,int ret; ret =get_user_pages (current, current->mm, virt_addr, -1 ,VM_READ ,0 ,NULL ,NULL ); +1 ,FOLL_WRITE ,NULL ,NULL );if (ret<=0 ) {#ifdef ERR_INJ_DEBUG printk ("Virtual address %lx is not existing.\n" ,virt_addr);
arch/mips/mm/gup.c +1 -1
@@ -303,7 +303,7 @@ slow_irqon: ret =get_user_pages_unlocked (current, mm, start, (end - start) >>PAGE_SHIFT , - write,0 , pages); + pages, write ?FOLL_WRITE :0 );/* Have to be a bit careful with return values */ if (nr >0 ) {
arch/s390/kernel/perf_cpum_cf.c +2 -0
@@ -344,6 +344,8 @@ static int __hw_perf_event_init(struct perf_event *event)break ;case PERF_TYPE_HARDWARE : +if (is_sampling_event (event))/* No sampling support */ +return -ENOENT ; ev = attr->config;/* Count user space (problem-state) only */ if (!attr->exclude_user && attr->exclude_kernel) {
arch/s390/mm/gup.c +1 -1
@@ -242,7 +242,7 @@ int get_user_pages_fast(unsigned long start, int nr_pages, int write, start += nr <<PAGE_SHIFT ; pages += nr; ret =get_user_pages_unlocked (current, mm, start, - nr_pages - nr, write,0 , pages); + nr_pages - nr, pages, write ?FOLL_WRITE :0 );/* Have to be a bit careful with return values */ if (nr >0 ) ret = (ret <0 ) ? nr : ret + nr;
arch/sh/mm/gup.c +2 -1
@@ -258,7 +258,8 @@ slow_irqon: pages += nr; ret =get_user_pages_unlocked (current, mm, start, - (end - start) >>PAGE_SHIFT , write,0 , pages); + (end - start) >>PAGE_SHIFT , pages, + write ?FOLL_WRITE :0 );/* Have to be a bit careful with return values */ if (nr >0 ) {
arch/sparc/mm/gup.c +2 -1
@@ -250,7 +250,8 @@ slow: pages += nr; ret =get_user_pages_unlocked (current, mm, start, - (end - start) >>PAGE_SHIFT , write,0 , pages); + (end - start) >>PAGE_SHIFT , pages, + write ?FOLL_WRITE :0 );/* Have to be a bit careful with return values */ if (nr >0 ) {
arch/x86/include/asm/kvm_host.h +1 -1
@@ -765,7 +765,7 @@ struct kvm_x86_ops {int (*hardware_setup)(void );/* __init */ void (*hardware_unsetup)(void );/* __exit */ bool (*cpu_has_accelerated_tpr)(void ); -bool (*cpu_has_high_real_mode_segbase)(void ); +bool (*has_emulated_msr)(int index);void (*cpuid_update)(struct kvm_vcpu *vcpu);/* Create, but do not attach this VCPU */
arch/x86/include/asm/uaccess.h +45 -19
178 lines not on this page · raw message
arch/x86/include/asm/uaccess_32.h +26 -0
@@ -48,20 +48,28 @@ __copy_to_user_inatomic(void __user *to, const void *from, unsigned long n)switch (n) {case 1 : +__uaccess_begin_nospec ();__put_user_size (*(u8 *)from, (u8 __user *)to,1 , ret,1 ); +__uaccess_end ();return ret;case 2 : +__uaccess_begin_nospec ();__put_user_size (*(u16 *)from, (u16 __user *)to,2 , ret,2 ); +__uaccess_end ();return ret;case 4 : +__uaccess_begin_nospec ();__put_user_size (*(u32 *)from, (u32 __user *)to,4 , ret,4 ); +__uaccess_end ();return ret;case 8 : +__uaccess_begin_nospec ();__put_user_size (*(u64 *)from, (u64 __user *)to,8 , ret,8 ); +__uaccess_end ();return ret; } }
@@ -103,13 +111,19 @@ __copy_from_user_inatomic(void *to, const void __user *from, unsigned long n)switch (n) {case 1 : +__uaccess_begin_nospec ();__get_user_size (*(u8 *)to, from,1 , ret,1 ); +__uaccess_end ();return ret;case 2 : +__uaccess_begin_nospec ();__get_user_size (*(u16 *)to, from,2 , ret,2 ); +__uaccess_end ();return ret;case 4 : +__uaccess_begin_nospec ();__get_user_size (*(u32 *)to, from,4 , ret,4 ); +__uaccess_end ();return ret; } }
@@ -148,13 +162,19 @@ __copy_from_user(void *to, const void __user *from, unsigned long n)switch (n) {case 1 : +__uaccess_begin_nospec ();__get_user_size (*(u8 *)to, from,1 , ret,1 ); +__uaccess_end ();return ret;case 2 : +__uaccess_begin_nospec ();__get_user_size (*(u16 *)to, from,2 , ret,2 ); +__uaccess_end ();return ret;case 4 : +__uaccess_begin_nospec ();__get_user_size (*(u32 *)to, from,4 , ret,4 ); +__uaccess_end ();return ret; } }
@@ -170,13 +190,19 @@ static __always_inline unsigned long __copy_from_user_nocache(void *to,switch (n) {case 1 : +__uaccess_begin_nospec ();__get_user_size (*(u8 *)to, from,1 , ret,1 ); +__uaccess_end ();return ret;case 2 : +__uaccess_begin_nospec ();__get_user_size (*(u16 *)to, from,2 , ret,2 ); +__uaccess_end ();return ret;case 4 : +__uaccess_begin_nospec ();__get_user_size (*(u32 *)to, from,4 , ret,4 ); +__uaccess_end ();return ret; } }
arch/x86/include/asm/uaccess_64.h +66 -28
175 lines not on this page · raw message
arch/x86/kernel/cpu/common.c +2 -1
@@ -693,7 +693,8 @@ static void init_speculation_control(struct cpuinfo_x86 *c)if (cpu_has (c,X86_FEATURE_INTEL_STIBP ))set_cpu_cap (c,X86_FEATURE_STIBP ); -if (cpu_has (c,X86_FEATURE_SPEC_CTRL_SSBD )) +if (cpu_has (c,X86_FEATURE_SPEC_CTRL_SSBD ) || +cpu_has (c,X86_FEATURE_VIRT_SSBD ))set_cpu_cap (c,X86_FEATURE_SSBD );if (cpu_has (c,X86_FEATURE_AMD_IBRS )) {
arch/x86/kvm/cpuid.c +28 -3
@@ -341,6 +341,10 @@ static inline int __do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function, F(3DNOWPREFETCH) | F(OSVW) | 0 /* IBS */ | F(XOP) |0 /* SKINIT, WDT, LWP */ |F (FMA4 ) |F (TBM ); +/* cpuid 0x80000008.ebx */ +const u32 kvm_cpuid_8000_0008_ebx_x86_features = +F (AMD_IBPB ) |F (AMD_IBRS ) |F (VIRT_SSBD ); +/* cpuid 0xC0000001.edx */ const u32 kvm_supported_word5_x86_features = F(XSTORE) | F(XSTORE_EN) | F(XCRYPT) | F(XCRYPT_EN) |
@@ -358,6 +362,10 @@ static inline int __do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function,const u32 kvm_supported_word10_x86_features =F (XSAVEOPT ) |F (XSAVEC ) |F (XGETBV1 ) | f_xsaves; +/* cpuid 7.0.edx*/ +const u32 kvm_cpuid_7_0_edx_x86_features = +F (SPEC_CTRL ) |F (SPEC_CTRL_SSBD ) |F (ARCH_CAPABILITIES ); +/* all calls to cpuid_count() should be made on the same cpu */ get_cpu ();
@@ -435,11 +443,14 @@ static inline int __do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function,cpuid_mask (&entry->ebx,9 );// TSC_ADJUST is emulated entry->ebx |=F (TSC_ADJUST ); - }else + entry->edx &= kvm_cpuid_7_0_edx_x86_features; +cpuid_mask (&entry->edx,CPUID_7_EDX ); + }else { entry->ebx =0 ; + entry->edx =0 ; + } entry->eax =0 ; entry->ecx =0 ; - entry->edx =0 ;break ; }case 9 :
@@ -583,7 +594,21 @@ static inline int __do_cpuid_ent(struct kvm_cpuid_entry2 *entry, u32 function,if (!g_phys_as) g_phys_as = phys_as; entry->eax = g_phys_as | (virt_as <<8 ); - entry->ebx = entry->edx =0 ; + entry->edx =0 ; +/* +* IBRS, IBPB and VIRT_SSBD aren't necessarily present in +* hardware cpuid +*/ +if (boot_cpu_has (X86_FEATURE_AMD_IBPB )) + entry->ebx |=F (AMD_IBPB ); +if (boot_cpu_has (X86_FEATURE_AMD_IBRS )) + entry->ebx |=F (AMD_IBRS ); +if (boot_cpu_has (X86_FEATURE_VIRT_SSBD )) + entry->ebx |=F (VIRT_SSBD ); + entry->ebx &= kvm_cpuid_8000_0008_ebx_x86_features; +cpuid_mask (&entry->ebx,CPUID_8000_0008_EBX ); +if (boot_cpu_has (X86_FEATURE_LS_CFG_SSBD )) + entry->ebx |=F (VIRT_SSBD );break ; }case 0x80000019 :
arch/x86/kvm/cpuid.h +40 -0
@@ -159,6 +159,46 @@ static inline bool guest_cpuid_has_rdtscp(struct kvm_vcpu *vcpu)return best && (best->edx &bit (X86_FEATURE_RDTSCP )); } +static inline bool guest_cpuid_has_ibpb (struct kvm_vcpu *vcpu) +{ +struct kvm_cpuid_entry2 *best; + + best =kvm_find_cpuid_entry (vcpu,0x80000008 ,0 ); +if (best && (best->ebx &bit (X86_FEATURE_AMD_IBPB ))) +return true; + best =kvm_find_cpuid_entry (vcpu,7 ,0 ); +return best && (best->edx &bit (X86_FEATURE_SPEC_CTRL )); +} + +static inline bool guest_cpuid_has_spec_ctrl (struct kvm_vcpu *vcpu) +{ +struct kvm_cpuid_entry2 *best; + + best =kvm_find_cpuid_entry (vcpu,0x80000008 ,0 ); +if (best && (best->ebx &bit (X86_FEATURE_AMD_IBRS ))) +return true; + best =kvm_find_cpuid_entry (vcpu,7 ,0 ); +return best && (best->edx & (bit (X86_FEATURE_SPEC_CTRL ) |bit (X86_FEATURE_SPEC_CTRL_SSBD ))); +} + +static inline bool guest_cpuid_has_arch_capabilities (struct kvm_vcpu *vcpu) +{ +struct kvm_cpuid_entry2 *best; + + best =kvm_find_cpuid_entry (vcpu,7 ,0 ); +return best && (best->edx &bit (X86_FEATURE_ARCH_CAPABILITIES )); +} + +static inline bool guest_cpuid_has_virt_ssbd (struct kvm_vcpu *vcpu) +{ +struct kvm_cpuid_entry2 *best; + + best =kvm_find_cpuid_entry (vcpu,0x80000008 ,0 ); +return best && (best->ebx &bit (X86_FEATURE_VIRT_SSBD )); +} + + +/* * NRIPS is provided through cpuidfn 0x8000000a.edx bit 3 */
arch/x86/kvm/lapic.c +1 -1
@@ -56,7 +56,7 @@#define APIC_BUS_CYCLE_NS 1/* #define apic_debug(fmt,arg...) printk(KERN_WARNING fmt,##arg) */ -#define apic_debug(fmt, arg...) +#define apic_debug(fmt, arg...) do {} while (0)#define APIC_LVT_NUM 6/* 14 is the version for Xeon and Pentium 8.4.8*/
arch/x86/kvm/svm.c +141 -2
232 lines not on this page · raw message
arch/x86/kvm/vmx.c +417 -324
877 lines not on this page · raw message
drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c +5 -1
Lines of this file are not shown. View the raw message.
drivers/gpu/drm/exynos/exynos_drm_g2d.c +2 -1
Lines of this file are not shown. View the raw message.
drivers/gpu/drm/i915/i915_gem_userptr.c +5 -1
Lines of this file are not shown. View the raw message.
drivers/infiniband/hw/mthca/mthca_memfree.c +2 -2
Lines of this file are not shown. View the raw message.
drivers/infiniband/hw/qib/qib_user_pages.c +2 -1
Lines of this file are not shown. View the raw message.
drivers/infiniband/hw/usnic/usnic_uiom.c +4 -1
Lines of this file are not shown. View the raw message.
drivers/media/dvb-frontends/cxd2841er.c +3 -1
Lines of this file are not shown. View the raw message.
drivers/media/dvb-frontends/stb0899_drv.c +2 -1
Lines of this file are not shown. View the raw message.
drivers/media/platform/omap/omap_vout.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/media/v4l2-core/videobuf-dma-sg.c +5 -2
Lines of this file are not shown. View the raw message.
drivers/media/v4l2-core/videobuf2-memops.c +5 -1
Lines of this file are not shown. View the raw message.
drivers/net/ethernet/cavium/thunder/nic_main.c +3 -0
Lines of this file are not shown. View the raw message.
drivers/net/ethernet/hisilicon/hip04_eth.c +1 -3
Lines of this file are not shown. View the raw message.
drivers/net/ethernet/intel/ixgbe/ixgbe_x550.c +3 -1
Lines of this file are not shown. View the raw message.
drivers/staging/rdma/ipath/ipath_user_pages.c +1 -1
Lines of this file are not shown. View the raw message.
drivers/usb/gadget/udc/omap_udc.c +30 -57
87 lines not on this page · raw message
drivers/video/fbdev/matrox/matroxfb_Ti3026.c +1 -1
Lines of this file are not shown. View the raw message.
fs/ocfs2/move_extents.c +26 -21
47 lines not on this page · raw message
kernel/bpf/verifier.c +77 -21
98 lines not on this page · raw message
mm/gup.c +22 -20
42 lines not on this page · raw message
mm/nommu.c +18 -24
42 lines not on this page · raw message
net/ipv6/ip6_output.c +21 -21
42 lines not on this page · raw message
sound/soc/omap/omap-mcpdm.c +42 -1
43 lines not on this page · raw message
tools/testing/selftests/networking/timestamping/.gitignore new file +3 -0
Lines of this file are not shown. View the raw message.
tools/testing/selftests/networking/timestamping/Makefile new file +8 -0
Lines of this file are not shown. View the raw message.
tools/testing/selftests/networking/timestamping/hwtstamp_config.c new file +134 -0
134 lines not on this page · raw message
tools/testing/selftests/networking/timestamping/timestamping.c new file +528 -0
528 lines not on this page · raw message
tools/testing/selftests/networking/timestamping/txtimestamp.c new file +549 -0
549 lines not on this page · raw message
The rest of this diff is not shown. View the raw message.
Part of the diff is not shown here. View the raw message.