[PATCH 19/23] fs: remove ksys_getdents64

2020-07-14 Thread Christoph Hellwig
Just open code it in the only caller. Signed-off-by: Christoph Hellwig --- fs/readdir.c | 11 ++- include/linux/syscalls.h | 2 -- 2 files changed, 2 insertions(+), 11 deletions(-) diff --git a/fs/readdir.c b/fs/readdir.c index a49f07c11cfbd0..19434b3c982cd3 100644 ---

[PATCH 05/23] md: replace the RAID_AUTORUN ioctl with a direct function call

2020-07-14 Thread Christoph Hellwig
Instead of using a spcial RAID_AUTORUN ioctl that only exists for non-modular builds and is only called from the early init code, just call the actual function directly. Signed-off-by: Christoph Hellwig Acked-by: Song Liu --- drivers/md/md-autodetect.c | 10 ++ drivers/md/md.c

[PATCH 20/23] fs: remove ksys_open

2020-07-14 Thread Christoph Hellwig
Just open code it in the two callers. Signed-off-by: Christoph Hellwig --- fs/open.c| 11 --- include/linux/syscalls.h | 11 --- 2 files changed, 8 insertions(+), 14 deletions(-) diff --git a/fs/open.c b/fs/open.c index 75166f071d280a..ab3671af8a9705 100644 ---

Re: [RFC PATCH 04/15] x86/pks: Preserve the PKRS MSR on context switch

2020-07-14 Thread Ira Weiny
On Tue, Jul 14, 2020 at 09:05:39PM +0200, Peter Zijlstra wrote: > On Tue, Jul 14, 2020 at 11:53:22AM -0700, Ira Weiny wrote: > > On Tue, Jul 14, 2020 at 10:27:01AM +0200, Peter Zijlstra wrote: > > > On Tue, Jul 14, 2020 at 12:02:09AM -0700, ira.we...@intel.com wrote: > > > > From: Ira Weiny > > >

[PATCH 21/23] fs: remove ksys_dup

2020-07-14 Thread Christoph Hellwig
Fold it into the only remaining caller. Signed-off-by: Christoph Hellwig --- fs/file.c| 7 +-- include/linux/syscalls.h | 1 - 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/fs/file.c b/fs/file.c index abb8b7081d7a44..85b7993165dd2f 100644 --- a/fs/file.c +++

[PATCH 07/23] md: remove the kernel version of md_u.h

2020-07-14 Thread Christoph Hellwig
mdp_major can just move to drivers/md/md.h. Signed-off-by: Christoph Hellwig Acked-by: Song Liu --- drivers/md/md.h | 1 + include/linux/raid/md_u.h | 13 - 2 files changed, 1 insertion(+), 13 deletions(-) delete mode 100644 include/linux/raid/md_u.h diff --git

[PATCH 22/23] fs: remove ksys_fchmod

2020-07-14 Thread Christoph Hellwig
Fold it into the only remaining caller. Signed-off-by: Christoph Hellwig --- fs/open.c| 7 +-- include/linux/syscalls.h | 1 - 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/fs/open.c b/fs/open.c index ab3671af8a9705..b316dd6a86a8b9 100644 --- a/fs/open.c +++

[PATCH 23/23] fs: remove ksys_ioctl

2020-07-14 Thread Christoph Hellwig
Fold it into the only remaining caller. Signed-off-by: Christoph Hellwig --- fs/ioctl.c | 7 +-- include/linux/syscalls.h | 1 - 2 files changed, 1 insertion(+), 7 deletions(-) diff --git a/fs/ioctl.c b/fs/ioctl.c index d69786d1dd9115..4e6cc0a7d69c9f 100644 --- a/fs/ioctl.c

[PATCH 16/23] initramfs: simplify clean_rootfs

2020-07-14 Thread Christoph Hellwig
Just use d_genocide instead of iterating through the root directory with cumbersome userspace-like APIs. This also ensures we actually remove files that are not direct children of the root entry, which the old code failed to do. Fixes: df52092f3c97 ("fastboot: remove duplicate

[PATCH 13/23] initrd: mark init_linuxrc as __init

2020-07-14 Thread Christoph Hellwig
Signed-off-by: Christoph Hellwig --- init/do_mounts_initrd.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init/do_mounts_initrd.c b/init/do_mounts_initrd.c index e4f88e9e1c0839..57ad5b2da8f5f5 100644 --- a/init/do_mounts_initrd.c +++ b/init/do_mounts_initrd.c @@ -56,7

[PATCH 14/23] initrd: mark initrd support as deprecated

2020-07-14 Thread Christoph Hellwig
The classic initial ramdisk has been replaced by the much more flexible and efficient initramfs a long time. Warn about it being removed soon. Signed-off-by: Christoph Hellwig --- init/do_mounts_initrd.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/init/do_mounts_initrd.c

[PATCH 5.4 018/109] ixgbe: protect ring accesses with READ- and WRITE_ONCE

2020-07-14 Thread Greg Kroah-Hartman
From: Ciara Loftus [ Upstream commit f140ad9fe2ae16f385f8fe4dc9cf67bb4c51d794 ] READ_ONCE should be used when reading rings prior to accessing the statistics pointer. Introduce this as well as the corresponding WRITE_ONCE usage when allocating and freeing the rings, to ensure protected access.

[PATCH 5.4 037/109] gpio: pca953x: Fix GPIO resource leak on Intel Galileo Gen 2

2020-07-14 Thread Greg Kroah-Hartman
From: Andy Shevchenko [ Upstream commit 5d8913504ccfeea6120df5ae1c6f4479ff09b931 ] When adding a quirk for IRQ on Intel Galileo Gen 2 the commit ba8c90c61847 ("gpio: pca953x: Override IRQ for one of the expanders on Galileo Gen 2") missed GPIO resource release. We can safely do this in the same

[PATCH 5.4 043/109] net: mvneta: fix use of state->speed

2020-07-14 Thread Greg Kroah-Hartman
From: Russell King [ Upstream commit f2ca673d2cd5df9a76247b670e9ffd4d63682b3f ] When support for short preambles was added, it incorrectly keyed its decision off state->speed instead of state->interface. state->speed is not guaranteed to be correct for in-band modes, which can lead to short

[PATCH 03/23] init: remove the bstat helper

2020-07-14 Thread Christoph Hellwig
The only caller of the bstat function becomes cleaner and simpler when open coding the function. Signed-off-by: Christoph Hellwig Acked-by: Song Liu --- init/do_mounts.h| 10 -- init/do_mounts_md.c | 8 2 files changed, 4 insertions(+), 14 deletions(-) diff --git

[PATCH 5.4 031/109] block: release bip in a right way in error path

2020-07-14 Thread Greg Kroah-Hartman
From: Chengguang Xu [ Upstream commit 0b8eb629a700c0ef15a437758db8255f8444e76c ] Release bip using kfree() in error path when that was allocated by kmalloc(). Signed-off-by: Chengguang Xu Reviewed-by: Christoph Hellwig Acked-by: Martin K. Petersen Signed-off-by: Jens Axboe Signed-off-by:

[PATCH 02/23] fs: add a vfs_fchmod helper

2020-07-14 Thread Christoph Hellwig
Add a helper for struct file based chmode operations. To be used by the initramfs code soon. Signed-off-by: Christoph Hellwig --- fs/open.c | 9 +++-- include/linux/fs.h | 1 + 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/fs/open.c b/fs/open.c index

[PATCH 5.4 016/109] net: ethernet: mvneta: Fix Serdes configuration for SoCs without comphy

2020-07-14 Thread Greg Kroah-Hartman
From: Sascha Hauer [ Upstream commit b4748553f53f2971e07d2619f13d461daac0f3bb ] The MVNETA_SERDES_CFG register is only available on older SoCs like the Armada XP. On newer SoCs like the Armada 38x the fields are moved to comphy. This patch moves the writes to this register next to the comphy

[PATCH 5.4 009/109] drm/tegra: hub: Do not enable orphaned window group

2020-07-14 Thread Greg Kroah-Hartman
From: Nicolin Chen [ Upstream commit ef4e417eb3ec7fe657928f10ac1d2154d8a5fb38 ] Though the unconditional enable/disable code is not a final solution, we don't want to run into a NULL pointer situation when window group doesn't link to its DC parent if the DC is disabled in Device Tree. So this

[PATCH 5.4 073/109] ALSA: hda - let hs_mic be picked ahead of hp_mic

2020-07-14 Thread Greg Kroah-Hartman
From: Hui Wang commit 6a6ca7881b1ab1c13fe0d70bae29211a65dd90de upstream. We have a Dell AIO, there is neither internal speaker nor internal mic, only a multi-function audio jack on it. Users reported that after freshly installing the OS and plug a headset to the audio jack, the headset can't

[PATCH] platform/x86: apple-gmux: Replace HTTP links with HTTPS ones

2020-07-14 Thread Alexander A. Klimov
Rationale: Reduces attack surface on kernel devs opening the links for MITM as HTTPS traffic is much harder to manipulate. Deterministic algorithm: For each file: If not .svg: For each line: If doesn't contain `\bxmlns\b`: For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`:

[PATCH 5.4 059/109] cxgb4: fix all-mask IP address comparison

2020-07-14 Thread Greg Kroah-Hartman
From: Rahul Lakkireddy [ Upstream commit 76c4d85c9260c3d741cbd194c30c61983d0a4303 ] Convert all-mask IP address to Big Endian, instead, for comparison. Fixes: f286dd8eaad5 ("cxgb4: use correct type for all-mask IP address comparison") Signed-off-by: Rahul Lakkireddy Signed-off-by: David S.

[PATCH 5.4 072/109] ALSA: opl3: fix infoleak in opl3

2020-07-14 Thread Greg Kroah-Hartman
From: xidongwang commit ad155712bb1ea2151944cf06a0e08c315c70c1e3 upstream. The stack object “info” in snd_opl3_ioctl() has a leaking problem. It has 2 padding bytes which are not initialized and leaked via “copy_to_user”. Signed-off-by: xidongwang Cc: Link:

[PATCH 5.4 088/109] module: Refactor section attr into bin attribute

2020-07-14 Thread Greg Kroah-Hartman
From: Kees Cook commit ed66f991bb19d94cae5d38f77de81f96aac7813f upstream. In order to gain access to the open file's f_cred for kallsym visibility permission checks, refactor the module section attributes to use the bin_attribute instead of attribute interface. Additionally removes the

[PATCH 5.4 086/109] KVM: arm64: Fix kvm_reset_vcpu() return code being incorrect with SVE

2020-07-14 Thread Greg Kroah-Hartman
From: Steven Price If SVE is enabled then 'ret' can be assigned the return value of kvm_vcpu_enable_sve() which may be 0 causing future "goto out" sites to erroneously return 0 on failure rather than -EINVAL as expected. Remove the initialisation of 'ret' and make setting the return value

[PATCH 5.4 044/109] net: cxgb4: fix return error value in t4_prep_fw

2020-07-14 Thread Greg Kroah-Hartman
From: Li Heng [ Upstream commit 8a259e6b73ad8181b0b2ef338b35043433db1075 ] t4_prep_fw goto bye tag with positive return value when something bad happened and which can not free resource in adap_init0. so fix it to return negative value. Fixes: 16e47624e76b ("cxgb4: Add new scheme to update

[PATCH 5.4 093/109] btrfs: fix fatal extent_buffer readahead vs releasepage race

2020-07-14 Thread Greg Kroah-Hartman
From: Boris Burkov commit 6bf9cd2eed9aee6d742bb9296c994a91f5316949 upstream. Under somewhat convoluted conditions, it is possible to attempt to release an extent_buffer that is under io, which triggers a BUG_ON in btrfs_release_extent_buffer_pages. This relies on a few different factors.

[PATCH 5.4 066/109] net: macb: mark device wake capable when "magic-packet" property present

2020-07-14 Thread Greg Kroah-Hartman
From: Nicolas Ferre [ Upstream commit ced4799d06375929e013eea04ba6908207afabbe ] Change the way the "magic-packet" DT property is handled in the macb_probe() function, matching DT binding documentation. Now we mark the device as "wakeup capable" instead of calling the device_init_wakeup()

[PATCH 5.4 068/109] mlxsw: spectrum_router: Remove inappropriate usage of WARN_ON()

2020-07-14 Thread Greg Kroah-Hartman
From: Ido Schimmel [ Upstream commit d9d5420273997664a1c09151ca86ac993f2f89c1 ] We should not trigger a warning when a memory allocation fails. Remove the WARN_ON(). The warning is constantly triggered by syzkaller when it is injecting faults: [ 2230.758664] FAULT_INJECTION: forcing a

Re: [PATCH v4 09/10] net: eth: altera: add msgdma prefetcher

2020-07-14 Thread Westergreen, Dalon
On Tue, 2020-07-14 at 09:29 -0700, Jakub Kicinski wrote: > On Tue, 14 Jul 2020 15:58:53 + Westergreen, Dalon wrote: > > On Tue, 2020-07-14 at 08:55 -0700, Jakub Kicinski wrote: > > > On Tue, 14 Jul 2020 14:35:16 + Ooi, Joyce wrote: > > > > > I'm no device tree expert but these look

[PATCH 5.4 050/109] perf intel-pt: Fix PEBS sample for XMM registers

2020-07-14 Thread Greg Kroah-Hartman
From: Adrian Hunter [ Upstream commit 4c95ad261cfac120dd66238fcae222766754c219 ] The condition to add XMM registers was missing, the regs array needed to be in the outer scope, and the size of the regs array was too small. Fixes: 143d34a6b387b ("perf intel-pt: Add XMM registers to synthesized

[PATCH 5.4 098/109] mmc: meson-gx: limit segments to 1 when dram-access-quirk is needed

2020-07-14 Thread Greg Kroah-Hartman
From: Neil Armstrong commit 27a5e7d36d383970affae801d77141deafd536a8 upstream. The actual max_segs computation leads to failure while using the broadcom sdio brcmfmac/bcmsdh driver, since the driver tries to make usage of scatter gather. But with the dram-access-quirk we use a 1,5K SRAM bounce

[PATCH 5.4 079/109] ALSA: hda/realtek: Enable headset mic of Acer Veriton N4660G with ALC269VC

2020-07-14 Thread Greg Kroah-Hartman
From: Jian-Hong Pan commit 781c90c034d994c6a4e2badf189128a95ed864c2 upstream. The Acer Veriton N4660G desktop's audio (1025:1248) with ALC269VC cannot detect the headset microphone until ALC269VC_FIXUP_ACER_MIC_NO_PRESENCE quirk maps the NID 0x18 as the headset mic pin. Signed-off-by:

[PATCH] platform/x86: acerhdf: Replace HTTP links with HTTPS ones

2020-07-14 Thread Alexander A. Klimov
Rationale: Reduces attack surface on kernel devs opening the links for MITM as HTTPS traffic is much harder to manipulate. Deterministic algorithm: For each file: If not .svg: For each line: If doesn't contain `\bxmlns\b`: For each link, `\bhttp://[^# \t\r\n]*(?:\w|/)`:

[PATCH 5.4 106/109] perf scripts python: exported-sql-viewer.py: Fix zero id in call graph Find result

2020-07-14 Thread Greg Kroah-Hartman
From: Adrian Hunter commit 7ff520b0a71dd2db695b52ad117d81b7eaf6ff9d upstream. Using ctrl-F ('Find') would not find 'unknown' because it matches id zero. Fix by excluding id zero from selection. Example: $ perf record -e intel_pt//u uname Linux [ perf record: Woken up 1 times to write

[PATCH 5.4 095/109] drm/radeon: fix double free

2020-07-14 Thread Greg Kroah-Hartman
From: Tom Rix commit 41855a898650803e24b284173354cc3e44d07725 upstream. clang static analysis flags this error drivers/gpu/drm/radeon/ci_dpm.c:5652:9: warning: Use of memory after it is freed [unix.Malloc] kfree(rdev->pm.dpm.ps[i].ps_priv);

decruft the early init / initrd / initramfs code v2

2020-07-14 Thread Christoph Hellwig
Hi all, this series starts to move the early init code away from requiring KERNEL_DS to be implicitly set during early startup. It does so by first removing legacy unused cruft, and the switches away the code from struct file based APIs to our more usual in-kernel APIs. There is no really good

Re: [RFC PATCH 04/15] x86/pks: Preserve the PKRS MSR on context switch

2020-07-14 Thread Peter Zijlstra
On Tue, Jul 14, 2020 at 11:53:22AM -0700, Ira Weiny wrote: > On Tue, Jul 14, 2020 at 10:27:01AM +0200, Peter Zijlstra wrote: > > On Tue, Jul 14, 2020 at 12:02:09AM -0700, ira.we...@intel.com wrote: > > > From: Ira Weiny > > > > > > The PKRS MSR is defined as a per-core register. This isolates

Re: [RFC PATCH 12/15] kmap: Add stray write protection for device pages

2020-07-14 Thread Ira Weiny
On Tue, Jul 14, 2020 at 10:44:51AM +0200, Peter Zijlstra wrote: > On Tue, Jul 14, 2020 at 12:02:17AM -0700, ira.we...@intel.com wrote: > > From: Ira Weiny > > > > Device managed pages may have additional protections. These protections > > need to be removed prior to valid use by kernel users. >

[PATCH 5.7 017/166] ALSA: hda: Intel: add missing PCI IDs for ICL-H, TGL-H and EKL

2020-07-14 Thread Greg Kroah-Hartman
From: Pierre-Louis Bossart [ Upstream commit d50313a5a0d803bcf55121a2b82086633060d05e ] Mirror PCI ids used for SOF. Signed-off-by: Pierre-Louis Bossart Reviewed-by: Guennadi Liakhovetski Reviewed-by: Kai Vehmanen Link:

[PATCH 5.4 080/109] KVM: arm64: Fix definition of PAGE_HYP_DEVICE

2020-07-14 Thread Greg Kroah-Hartman
From: Will Deacon commit 68cf617309b5f6f3a651165f49f20af1494753ae upstream. PAGE_HYP_DEVICE is intended to encode attribute bits for an EL2 stage-1 pte mapping a device. Unfortunately, it includes PROT_DEVICE_nGnRE which encodes attributes for EL1 stage-1 mappings such as UXN and nG, which are

[PATCH 5.7 016/166] ASoC: hdac_hda: fix memleak with regmap not freed on remove

2020-07-14 Thread Greg Kroah-Hartman
From: Pierre-Louis Bossart [ Upstream commit a94eaccefea1186947c5c5451fcae2245dd7e714 ] kmemleak throws error reports on module load/unload tests, add snd_hdac_regmap_exit() in .remove(). While we are at it, also fix the error handling flow in .probe() to use snd_hdac_regmap_exit() if needed.

[PATCH 5.4 084/109] KVM: x86: Inject #GP if guest attempts to toggle CR4.LA57 in 64-bit mode

2020-07-14 Thread Greg Kroah-Hartman
From: Sean Christopherson commit d74fcfc1f0ff4b6c26ecef1f9e48d8089ab4eaac upstream. Inject a #GP on MOV CR4 if CR4.LA57 is toggled in 64-bit mode, which is illegal per Intel's SDM: CR4.LA57 57-bit linear addresses (bit 12 of CR4) ... blah blah blah ... This bit cannot be modified in

[PATCH 5.4 083/109] KVM: x86: bit 8 of non-leaf PDPEs is not reserved

2020-07-14 Thread Greg Kroah-Hartman
From: Paolo Bonzini commit 5ecad245de2ae23dc4e2dbece92f8ccfbaed2fa7 upstream. Bit 8 would be the "global" bit, which does not quite make sense for non-leaf page table entries. Intel ignores it; AMD ignores it in PDEs and PDPEs, but reserves it in PML4Es. Probably, earlier versions of the AMD

[PATCH 5.4 105/109] perf scripts python: export-to-postgresql.py: Fix struct.pack() int argument

2020-07-14 Thread Greg Kroah-Hartman
From: Adrian Hunter commit 640432e6bed08e9d5d2ba26856ba3f55008b07e3 upstream. Python 3.8 is requiring that arguments being packed as integers are also integers. Add int() accordingly. Before: $ perf record -e intel_pt//u uname $ perf script --itrace=bep -s

Re: [PATCH -v2.1] x86/msr: Filter MSR writes

2020-07-14 Thread Srinivas Pandruvada
On Tue, 2020-07-14 at 18:56 +0200, Borislav Petkov wrote: > On Tue, Jul 14, 2020 at 05:04:48PM +0100, Chris Down wrote: > > Since the issue involves DPTF which is only supported via binary > > blobs, I > > can't say for certain what the issue is. As I understand it, when > > the > > throttling

Re: [PATCH 6/6] staging: qlge: qlge_ethtool: Remove one byte memset.

2020-07-14 Thread Suraj Upadhyay
On Tue, Jul 14, 2020 at 11:57:23AM -0700, Joe Perches wrote: > On Mon, 2020-07-13 at 17:17 +0300, Dan Carpenter wrote: > > On Mon, Jul 13, 2020 at 05:52:22PM +0530, Suraj Upadhyay wrote: > > > Use direct assignment instead of using memset with just one byte as an > > > argument. > > > Issue found

[PATCH 5.7 001/166] KVM: s390: reduce number of IO pins to 1

2020-07-14 Thread Greg Kroah-Hartman
From: Christian Borntraeger [ Upstream commit 774911290c589e98e3638e73b24b0a4d4530e97c ] The current number of KVM_IRQCHIP_NUM_PINS results in an order 3 allocation (32kb) for each guest start/restart. This can result in OOM killer activity even with free swap when the memory is fragmented

[PATCH 5.4 108/109] perf scripts python: exported-sql-viewer.py: Fix unexpanded Find result

2020-07-14 Thread Greg Kroah-Hartman
From: Adrian Hunter commit 3a3cf7c570a486b07d9a6e68a77548aea6a8421f upstream. Using Python version 3.8.2 and PySide2 version 5.14.0, ctrl-F ('Find') would not expand the tree to the result. Fix by using setExpanded(). Example: $ perf record -e intel_pt//u uname Linux [ perf record:

[PATCH 5.7 043/166] nfs: Fix memory leak of export_path

2020-07-14 Thread Greg Kroah-Hartman
From: Tom Rix [ Upstream commit 4659ed7cc8514369043053463514408ca16ad6f3 ] The try_location function is called within a loop by nfs_follow_referral. try_location calls nfs4_pathname_string to created the export_path. nfs4_pathname_string allocates the memory. export_path is stored in the

[PATCH 5.7 042/166] arm64: Add KRYO{3,4}XX silver CPU cores to SSB safelist

2020-07-14 Thread Greg Kroah-Hartman
From: Sai Prakash Ranjan [ Upstream commit 108447fd0d1a34b0929cd26dc637c917a734ebab ] QCOM KRYO{3,4}XX silver/LITTLE CPU cores are based on Cortex-A55 and are SSB safe, hence add them to SSB safelist -> arm64_ssb_cpus[]. Reported-by: Stephen Boyd Signed-off-by: Sai Prakash Ranjan

[PATCH 5.7 047/166] gpio: pca953x: Synchronize interrupt handler properly

2020-07-14 Thread Greg Kroah-Hartman
From: Andy Shevchenko [ Upstream commit 064c73afe7385de99e5b2785b88c83dc5d84403b ] Since the commit aa58a21ae378 ("gpio: pca953x: disable regmap locking") the locking of regmap is disabled and that immediately introduces a synchronization issue. It's easy to see when we try to monitor more than

[PATCH 5.7 038/166] arm64: kpti: Add KRYO{3, 4}XX silver CPU cores to kpti safelist

2020-07-14 Thread Greg Kroah-Hartman
From: Sai Prakash Ranjan [ Upstream commit f4617be35b4b547e82d30993f56d631dfc2d5f88 ] QCOM KRYO{3,4}XX silver/LITTLE CPU cores are based on Cortex-A55 and are meltdown safe, hence add them to kpti_safe_list[]. Signed-off-by: Sai Prakash Ranjan Link:

[PATCH 5.7 024/166] ice: protect ring accesses with WRITE_ONCE

2020-07-14 Thread Greg Kroah-Hartman
From: Ciara Loftus [ Upstream commit b1d95cc2391ffac0c5b27256a4fb0d2cfb021a29 ] The READ_ONCE macro is used when reading rings prior to accessing the statistics pointer. The corresponding WRITE_ONCE usage when allocating and freeing the rings to ensure protected access was not in place.

[PATCH 5.7 033/166] cifs: update ctime and mtime during truncate

2020-07-14 Thread Greg Kroah-Hartman
From: Zhang Xiaoxu [ Upstream commit 5618303d8516f8ac5ecfe53ee8e8bc9a40eaf066 ] As the man description of the truncate, if the size changed, then the st_ctime and st_mtime fields should be updated. But in cifs, we doesn't do it. It lead the xfstests generic/313 failed. So, add the

[PATCH 5.7 015/166] ASoC: SOF: Intel: add PCI ID for CometLake-S

2020-07-14 Thread Greg Kroah-Hartman
From: Pierre-Louis Bossart [ Upstream commit 258fb4f4c34a0db9d3834aba6784d7b322176bb9 ] Mirror ID added for legacy HDaudio Signed-off-by: Pierre-Louis Bossart Reviewed-by: Guennadi Liakhovetski Reviewed-by: Kai Vehmanen Link:

[PATCH 5.7 019/166] spi: spidev: fix a potential use-after-free in spidev_release()

2020-07-14 Thread Greg Kroah-Hartman
From: Zhenzhong Duan [ Upstream commit 06096cc6c5a84ced929634b0d79376b94c65a4bd ] If an spi device is unbounded from the driver before the release process, there will be an NULL pointer reference when it's referenced in spi_slave_abort(). Fix it by checking it's already freed before reference.

[PATCH 5.7 007/166] ARM: dts: omap4-droid4: Fix spi configuration and increase rate

2020-07-14 Thread Greg Kroah-Hartman
From: Tony Lindgren [ Upstream commit 0df12a01f4857495816b05f048c4c31439446e35 ] We can currently sometimes get "RXS timed out" errors and "EOT timed out" errors with spi transfers. These errors can be made easy to reproduce by reading the cpcap iio values in a loop while keeping the CPUs busy

[PATCH 5.7 066/166] drm/meson: viu: fix setting the OSD burst length in VIU_OSD1_FIFO_CTRL_STAT

2020-07-14 Thread Greg Kroah-Hartman
From: Martin Blumenstingl [ Upstream commit 17f64701ea6f541db7eb5d7423a830cb929b3052 ] The burst length is configured in VIU_OSD1_FIFO_CTRL_STAT[31] and VIU_OSD1_FIFO_CTRL_STAT[11:10]. The public S905D3 datasheet describes this as: - 0x0 = up to 24 per burst - 0x1 = up to 32 per burst - 0x2 =

Re: [PATCH v4 1/5] docs: IOMMU user API

2020-07-14 Thread Alex Williamson
On Mon, 13 Jul 2020 22:00:23 -0700 Jacob Pan wrote: > Hi Alex, > > On Mon, 13 Jul 2020 16:48:42 -0600 > Alex Williamson wrote: > > > On Tue, 7 Jul 2020 16:43:45 -0700 > > Jacob Pan wrote: > > > > > IOMMU UAPI is newly introduced to support communications between > > > guest virtual IOMMU

[PATCH 5.7 028/166] iommu/vt-d: Dont apply gfx quirks to untrusted devices

2020-07-14 Thread Greg Kroah-Hartman
From: Rajat Jain [ Upstream commit 67e8a5b18d41af9298db5c17193f671f235cce01 ] Currently, an external malicious PCI device can masquerade the VID:PID of faulty gfx devices, and thus apply iommu quirks to effectively disable the IOMMU restrictions for itself. Thus we need to ensure that the

Re: [PATCH v5 1/4] arm64: dts: rockchip: Trivial cleanups for RockPI N10

2020-07-14 Thread Heiko Stuebner
Am Donnerstag, 9. Juli 2020, 12:07:53 CEST schrieb Jagan Teki: > Radxa dalang carrier boards are used to mount vmarc SoM's > of rk3399pro and rk3288 to make complete SBC. > > So, this patch adds trivial changes to properties. > - move common properties into radxa dalang carrier dtsi. > - maintain

[PATCH 5.7 053/166] KVM: arm64: vgic-v4: Plug race between non-residency and v4.1 doorbell

2020-07-14 Thread Greg Kroah-Hartman
From: Marc Zyngier [ Upstream commit a3f574cd65487cd993f79ab235d70229d9302c1e ] When making a vPE non-resident because it has hit a blocking WFI, the doorbell can fire at any time after the write to the RD. Crucially, it can fire right between the write to GICR_VPENDBASER and the write to the

[PATCH 5.7 082/166] net: ipa: fix QMI structure definition bugs

2020-07-14 Thread Greg Kroah-Hartman
From: Alex Elder [ Upstream commit 74478ea4ded519db35cb1f059948b1e713bb4abf ] Building with "W=1" did exactly what it was supposed to do, namely point out some suspicious-looking code to be verified not to contain bugs. Some QMI message structures defined in "ipa_qmi_msg.c" contained some bad

[PATCH 5.7 068/166] net: dsa: microchip: set the correct number of ports

2020-07-14 Thread Greg Kroah-Hartman
From: Codrin Ciubotariu [ Upstream commit af199a1a9cb02ec0194804bd46c174b6db262075 ] The number of ports is incorrectly set to the maximum available for a DSA switch. Even if the extra ports are not used, this causes some functions to be called later, like port_disable() and

Re: [PATCH 0/2] iowait and idle fixes in /proc/stat

2020-07-14 Thread Tom Hromatka
Ping. Thanks. Tom On 6/10/20 3:05 PM, Tom Hromatka wrote: A customer is using /proc/stat to track cpu usage in a VM and noted that the iowait and idle times behave strangely when a cpu goes offline and comes back online. This patchset addresses two issues that can cause iowait and idle to

[PATCH 5.7 067/166] IB/sa: Resolv use-after-free in ib_nl_make_request()

2020-07-14 Thread Greg Kroah-Hartman
From: Divya Indi [ Upstream commit f427f4d6214c183c474eeb46212d38e6c7223d6a ] There is a race condition where ib_nl_make_request() inserts the request data into the linked list but the timer in ib_nl_request_timeout() can see it and destroy it before ib_nl_send_msg() is done touching it. This

[PATCH 5.7 072/166] perf report TUI: Fix segmentation fault in perf_evsel__hists_browse()

2020-07-14 Thread Greg Kroah-Hartman
From: Wei Li [ Upstream commit d61cbb859b45fdb6b4997f2d51834fae41af0e94 ] The segmentation fault can be reproduced as following steps: 1) Executing perf report in tui. 2) Typing '/x' to filter the symbol to get nothing matched. 3) Pressing enter with no entry selected. Then it will

[PATCH 5.7 103/166] net: macb: fix macb_suspend() by removing call to netif_carrier_off()

2020-07-14 Thread Greg Kroah-Hartman
From: Nicolas Ferre [ Upstream commit 64febc5e56c9a748162f206dcc5be1a44436087a ] As we now use the phylink call to phylink_stop() in the non-WoL path, there is no need for this call to netif_carrier_off() anymore. It can disturb the underlying phylink FSM. Fixes: 7897b071ac3b ("net: macb:

[PATCH 5.7 063/166] net: ipa: no checksum offload for SDM845 LAN RX

2020-07-14 Thread Greg Kroah-Hartman
From: Alex Elder [ Upstream commit 41af5436e857ec64f302fcc9b6e4a8c526b6b402 ] The AP LAN RX endpoint should not have download checksum offload enabled. The receive handler does properly accommodate the trailer that's added by the hardware, but we ignore it. Fixes: 1ed7d0c0fdba ("soc: qcom:

[PATCH 5.7 090/166] cxgb4: fix all-mask IP address comparison

2020-07-14 Thread Greg Kroah-Hartman
From: Rahul Lakkireddy [ Upstream commit 76c4d85c9260c3d741cbd194c30c61983d0a4303 ] Convert all-mask IP address to Big Endian, instead, for comparison. Fixes: f286dd8eaad5 ("cxgb4: use correct type for all-mask IP address comparison") Signed-off-by: Rahul Lakkireddy Signed-off-by: David S.

[PATCH 5.7 101/166] net: macb: mark device wake capable when "magic-packet" property present

2020-07-14 Thread Greg Kroah-Hartman
From: Nicolas Ferre [ Upstream commit ced4799d06375929e013eea04ba6908207afabbe ] Change the way the "magic-packet" DT property is handled in the macb_probe() function, matching DT binding documentation. Now we mark the device as "wakeup capable" instead of calling the device_init_wakeup()

Re: [PATCH 6/6] staging: qlge: qlge_ethtool: Remove one byte memset.

2020-07-14 Thread Joe Perches
On Mon, 2020-07-13 at 17:17 +0300, Dan Carpenter wrote: > On Mon, Jul 13, 2020 at 05:52:22PM +0530, Suraj Upadhyay wrote: > > Use direct assignment instead of using memset with just one byte as an > > argument. > > Issue found by checkpatch.pl. > > > > Signed-off-by: Suraj Upadhyay > > --- > >

[PATCH 5.7 080/166] net: hns3: fix use-after-free when doing self test

2020-07-14 Thread Greg Kroah-Hartman
From: Yonglong Liu [ Upstream commit a06656211304fec653c1931c2ca6d644013b5bbb ] Enable promisc mode of PF, set VF link state to enable, and run iperf of the VF, then do self test of the PF. The self test will fail with a low frequency, and may cause a use-after-free problem. [ 87.142126]

[PATCH 5.7 084/166] ionic: centralize queue reset code

2020-07-14 Thread Greg Kroah-Hartman
From: Shannon Nelson [ Upstream commit 086c18f2452d0028f81e319f098bcb8e53133dbf ] The queue reset pattern is used in a couple different places, only slightly different from each other, and could cause issues if one gets changed and the other didn't. This puts them together so that only one

[PATCH 5.7 062/166] net: mvneta: fix use of state->speed

2020-07-14 Thread Greg Kroah-Hartman
From: Russell King [ Upstream commit f2ca673d2cd5df9a76247b670e9ffd4d63682b3f ] When support for short preambles was added, it incorrectly keyed its decision off state->speed instead of state->interface. state->speed is not guaranteed to be correct for in-band modes, which can lead to short

[PATCH 5.7 102/166] net: macb: fix macb_get/set_wol() when moving to phylink

2020-07-14 Thread Greg Kroah-Hartman
From: Nicolas Ferre [ Upstream commit 253fe09435045ab9346a8e364299d971185ae031 ] Keep previous function goals and integrate phylink actions to them. phylink_ethtool_get_wol() is not enough to figure out if Ethernet driver supports Wake-on-Lan. Initialization of "supported" and "wolopts"

[PATCH 5.7 088/166] arm64: kgdb: Fix single-step exception handling oops

2020-07-14 Thread Greg Kroah-Hartman
From: Wei Li [ Upstream commit 8523c006264df65aac7d77284cc69aac46a6f842 ] After entering kdb due to breakpoint, when we execute 'ss' or 'go' (will delay installing breakpoints, do single-step first), it won't work correctly, and it will enter kdb due to oops. It's because the reason gotten in

[PATCH 5.7 104/166] net: macb: fix call to pm_runtime in the suspend/resume functions

2020-07-14 Thread Greg Kroah-Hartman
From: Nicolas Ferre [ Upstream commit 6c8f85cac98a4c6b767c4c4f6af7283724c32b47 ] The calls to pm_runtime_force_suspend/resume() functions are only relevant if the device is not configured to act as a WoL wakeup source. Add the device_may_wakeup() test before calling them. Fixes: 3e2a5e153906

[PATCH 5.7 121/166] KVM: x86: Inject #GP if guest attempts to toggle CR4.LA57 in 64-bit mode

2020-07-14 Thread Greg Kroah-Hartman
From: Sean Christopherson commit d74fcfc1f0ff4b6c26ecef1f9e48d8089ab4eaac upstream. Inject a #GP on MOV CR4 if CR4.LA57 is toggled in 64-bit mode, which is illegal per Intel's SDM: CR4.LA57 57-bit linear addresses (bit 12 of CR4) ... blah blah blah ... This bit cannot be modified in

[PATCH 5.7 114/166] ALSA: hda/realtek - Enable audio jacks of Acer vCopperbox with ALC269VC

2020-07-14 Thread Greg Kroah-Hartman
From: Jian-Hong Pan commit 8eae7e9b3967f08efaa4d70403aec513cbe45ad0 upstream. The Acer desktop vCopperbox with ALC269VC cannot detect the MIC of headset, the line out and internal speaker until ALC269VC_FIXUP_ACER_VCOPPERBOX_PINS quirk applied. Signed-off-by: Jian-Hong Pan Signed-off-by:

[PATCH 5.7 118/166] KVM: arm64: Stop clobbering x0 for HVC_SOFT_RESTART

2020-07-14 Thread Greg Kroah-Hartman
From: Andrew Scull commit b9e10d4a6c9f5cbe6369ce2c17ebc67d2e5a4be5 upstream. HVC_SOFT_RESTART is given values for x0-2 that it should installed before exiting to the new address so should not set x0 to stub HVC success or failure code. Fixes: af42f20480bf1 ("arm64: hyp-stub: Zero x0 on

[PATCH 5.7 132/166] bpf: Check correct cred for CAP_SYSLOG in bpf_dump_raw_ok()

2020-07-14 Thread Greg Kroah-Hartman
From: Kees Cook commit 63960260457a02af2a6cb35d75e6bdb17299c882 upstream. When evaluating access control over kallsyms visibility, credentials at open() time need to be used, not the "current" creds (though in BPF's case, this has likely always been the same). Plumb access to associated

Re: [PATCH] KVM: x86: Don't attempt to load PDPTRs when 64-bit mode is enabled

2020-07-14 Thread Jim Mattson
On Tue, Jul 14, 2020 at 11:59 AM Sean Christopherson wrote: > > On Tue, Jul 14, 2020 at 11:55:45AM -0700, Jim Mattson wrote: > > On Mon, Jul 13, 2020 at 6:57 PM Sean Christopherson > > wrote: > > > > > > Don't attempt to load PDPTRs if EFER.LME=1, i.e. if 64-bit mode is > > > enabled. A recent

Re: [GIT PULL tip/core/rcu] RCU commits for v5.9

2020-07-14 Thread Sebastian Andrzej Siewior
On 2020-07-14 11:27:32 [-0700], Paul E. McKenney wrote: > I believe that Ulad and Joel are working on an update. I expressed multiple times that I am unhappy with the raw_spinlock_t which both want to keep. It is important to be future proof but at the same time I am not sure if they know how

[PATCH 5.7 109/166] ALSA: opl3: fix infoleak in opl3

2020-07-14 Thread Greg Kroah-Hartman
From: xidongwang commit ad155712bb1ea2151944cf06a0e08c315c70c1e3 upstream. The stack object “info” in snd_opl3_ioctl() has a leaking problem. It has 2 padding bytes which are not initialized and leaked via “copy_to_user”. Signed-off-by: xidongwang Cc: Link:

[PATCH 5.7 097/166] net/mlx5e: Fix 50G per lane indication

2020-07-14 Thread Greg Kroah-Hartman
From: Aya Levin [ Upstream commit 6a1cf4e443a3b0a4d690d3c93b84b1e9cbfcb1bd ] Some released FW versions mistakenly don't set the capability that 50G per lane link-modes are supported for VFs (ptys_extended_ethernet capability bit). When the capability is unset, read PTYS.ext_eth_proto_capability

[PATCH 5.7 089/166] nbd: Fix memory leak in nbd_add_socket

2020-07-14 Thread Greg Kroah-Hartman
From: Zheng Bin [ Upstream commit 579dd91ab3a5446b148e7f179b6596b270dace46 ] When adding first socket to nbd, if nsock's allocation failed, the data structure member "config->socks" was reallocated, but the data structure member "config->num_connections" was not updated. A memory leak will

[PATCH 5.7 092/166] qed: Populate nvm-file attributes while reading nvm config partition.

2020-07-14 Thread Greg Kroah-Hartman
From: Sudarsana Reddy Kalluru [ Upstream commit 13cf8aab7425a253070433b5a55b4209ceac8b19 ] NVM config file address will be modified when the MBI image is upgraded. Driver would return stale config values if user reads the nvm-config (via ethtool -d) in this state. The fix is to re-populate nvm

[PATCH 5.7 108/166] IB/hfi1: Do not destroy link_wq when the device is shut down

2020-07-14 Thread Greg Kroah-Hartman
From: Kaike Wan commit 2315ec12ee8e8257bb335654c62e0cae71dc278d upstream. The workqueue link_wq should only be destroyed when the hfi1 driver is unloaded, not when the device is shut down. Fixes: 71d47008ca1b ("IB/hfi1: Create workqueue for link events") Link:

[PATCH 5.7 144/166] drm/i915: Drop vm.ref for duplicate vma on construction

2020-07-14 Thread Greg Kroah-Hartman
From: Chris Wilson commit 42723673a193d5f8e30dba6ea9826d42262a502b upstream. As we allow for parallel threads to create the same vma instance concurrently, and we only filter out the duplicates upon reacquiring the spinlock for the rbtree, we have to free the loser of the constructors' race.

[PATCH 5.7 126/166] io_uring: fix memleak in io_sqe_files_register()

2020-07-14 Thread Greg Kroah-Hartman
From: Yang Yingliang commit 667e57da358f61b6966e12e925a69e42d912e8bb upstream. I got a memleak report when doing some fuzz test: BUG: memory leak unreferenced object 0x607eeac06e78 (size 8): comm "test", pid 295, jiffies 4294735835 (age 31.745s) hex dump (first 8 bytes): 00 00 00 00 00

[PATCH 5.7 148/166] smb3: fix unneeded error message on change notify

2020-07-14 Thread Greg Kroah-Hartman
From: Steve French commit 8668115cf2db40e22e7be02652a3673d8d30c9f0 upstream. We should not be logging a warning repeatedly on change notify. CC: Stable # v5.6+ Signed-off-by: Steve French Reviewed-by: Ronnie Sahlberg Signed-off-by: Greg Kroah-Hartman --- fs/cifs/smb2misc.c |8

[PATCH 5.7 125/166] io_uring: account user memory freed when exit has been queued

2020-07-14 Thread Greg Kroah-Hartman
From: Jens Axboe commit 309fc03a3284af62eb6082fb60327045a1dabf57 upstream. We currently account the memory after the exit work has been run, but that leaves a gap where a process has closed its ring and until the memory has been accounted as freed. If the memlocked ulimit is borderline, then

[PATCH 5.7 130/166] module: Do not expose section addresses to non-CAP_SYSLOG

2020-07-14 Thread Greg Kroah-Hartman
From: Kees Cook commit b25a7c5af9051850d4f3d93ca500056ab6ec724b upstream. The printing of section addresses in /sys/module/*/sections/* was not using the correct credentials to evaluate visibility. Before: # cat /sys/module/*/sections/.*text 0xc0458000 ... # capsh

[PATCH 5.7 127/166] io_uring: fix missing msg_name assignment

2020-07-14 Thread Greg Kroah-Hartman
From: Pavel Begunkov commit dd821e0c95a64b5923a0c57f07d3f7563553e756 upstream. Ensure to set msg.msg_name for the async portion of send/recvmsg, as the header copy will copy to/from it. Cc: sta...@vger.kernel.org # v5.5+ Signed-off-by: Pavel Begunkov Signed-off-by: Jens Axboe Signed-off-by:

[PATCH 5.7 153/166] ARC: entry: fix potential EFA clobber when TIF_SYSCALL_TRACE

2020-07-14 Thread Greg Kroah-Hartman
From: Vineet Gupta commit 00fdec98d9881bf5173af09aebd353ab3b9ac729 upstream. Trap handler for syscall tracing reads EFA (Exception Fault Address), in case strace wants PC of trap instruction (EFA is not part of pt_regs as of current code). However this EFA read is racy as it happens after

Re: [PATCH] KVM: x86: Don't attempt to load PDPTRs when 64-bit mode is enabled

2020-07-14 Thread Sean Christopherson
On Tue, Jul 14, 2020 at 11:55:45AM -0700, Jim Mattson wrote: > On Mon, Jul 13, 2020 at 6:57 PM Sean Christopherson > wrote: > > > > Don't attempt to load PDPTRs if EFER.LME=1, i.e. if 64-bit mode is > > enabled. A recent change to reload the PDTPRs when CR0.CD or CR0.NW is > > toggled botched

[PATCH 5.7 086/166] RDMA/siw: Fix reporting vendor_part_id

2020-07-14 Thread Greg Kroah-Hartman
From: Kamal Heib [ Upstream commit 04340645f69ab7abb6f9052688a60f0213b3f79c ] Move the initialization of the vendor_part_id to be before calling ib_register_device(), this is needed because the query_device() callback is called from the context of ib_register_device() before initializing the

[PATCH 5.7 137/166] btrfs: fix double put of block group with nocow

2020-07-14 Thread Greg Kroah-Hartman
From: Josef Bacik commit 230ed397435e85b54f055c524fcb267ae2ce3bc4 upstream. While debugging a patch that I wrote I was hitting use-after-free panics when accessing block groups on unmount. This turned out to be because in the nocow case if we bail out of doing the nocow for whatever reason we

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