[PATCH v2 1/6] kselftest: fix TAP output for skipped tests

2020-06-22 Thread Paolo Bonzini
According to the TAP specification, a skipped test must be marked as "ok" and annotated with the SKIP directive, for example ok 23 # skip Insufficient flogiston pressure. (https://testanything.org/tap-specification.html) Fix the kselftest infrastructure to match this. For ksft_exit_skip,

[PATCH v2 2/6] selftests: breakpoints: fix computation of test plan

2020-06-22 Thread Paolo Bonzini
The computation of the test plan uses the available_cpus bitset before calling sched_getaffinity to fill it in. The resulting plan is bogus, fix it. Signed-off-by: Paolo Bonzini --- .../selftests/breakpoints/step_after_suspend_test.c | 8 1 file changed, 4 insertions(+), 4

[PATCH v2 6/6] selftests: sync_test: do not use ksft_exit_skip after ksft_set_plan

2020-06-22 Thread Paolo Bonzini
Calling ksft_exit_skip after ksft_set_plan results in executing fewer tests than planned. Move it before. Signed-off-by: Paolo Bonzini --- tools/testing/selftests/sync/sync_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/testing/selftests/sync/sync_test.c

[PATCH v2 0/6] kselftest: fix TAP output for skipped test and ksft_set_plan misuse

2020-06-22 Thread Paolo Bonzini
This is v2 of the patch to fix TAP output for skipped tests. I noticed and fixed two other occurrences of "not ok ... # SKIP" which according to the TAP specification should be marked as "ok ... # SKIP" instead. Unfortunately, closer analysis showed ksft_exit_skip to be a badly misused API. It

[PATCH v2 4/6] selftests: pidfd: do not use ksft_exit_skip after ksft_set_plan

2020-06-22 Thread Paolo Bonzini
Calling ksft_exit_skip after ksft_set_plan results in executing fewer tests than planned. Use ksft_test_result_skip instead. The plan passed to ksft_set_plan was wrong, too, so fix it while at it. Signed-off-by: Paolo Bonzini --- tools/testing/selftests/pidfd/pidfd_test.c | 39

[PATCH v2 5/6] selftests: sigaltstack: do not use ksft_exit_skip after ksft_set_plan

2020-06-22 Thread Paolo Bonzini
Calling ksft_exit_skip after ksft_set_plan results in executing fewer tests than planned. Use ksft_test_result_skip when possible, or just bail out if memory corruption is detected. Signed-off-by: Paolo Bonzini --- tools/testing/selftests/sigaltstack/sas.c | 4 ++-- 1 file changed, 2

[PATCH v2 3/6] selftests: breakpoints: do not use ksft_exit_skip after ksft_set_plan

2020-06-22 Thread Paolo Bonzini
Calling ksft_exit_skip after ksft_set_plan results in executing fewer tests than planned. Use ksft_test_result_skip for the individual tests. The call in suspend() is fine, but ksft_set_plan should be after it. Signed-off-by: Paolo Bonzini --- .../breakpoints/step_after_suspend_test.c | 45

Re: [PATCH] PCI/IOV: Plug VF bus creation race

2020-06-22 Thread Bjorn Helgaas
On Sun, Jun 07, 2020 at 10:43:48AM +0100, Marc Zyngier wrote: > On a system that creates VFs for multiple PFs in parallel (in > this case, network bringup at boot time), and when these VFs > end-up on the same bus, bad things sometimes happen: > > [ 12.755534] sysfs: cannot create duplicate

[ANNOUNCE] 4.14.185-rt85

2020-06-22 Thread Clark Williams
Hello RT-list! I'm pleased to announce the 4.14.185-rt85 stable release. You can get this release via the git tree at: git://git.kernel.org/pub/scm/linux/kernel/git/rt/linux-stable-rt.git branch: v4.14-rt Head SHA1: 0997f0bdf9eb2aa24695fbd8a228cef4422cf1b6 Or to build 4.14.185-rt85

[ANNOUNCE] 4.9.227-rt146

2020-06-22 Thread Clark Williams
Hello RT-list! I'm pleased to announce the 4.9.227-rt146 stable release. Note that v4.9-rt is in maintenance mode so no RT backports are included, this is strictly a merge of the upstream stable changes for v4.9. You can get this release via the git tree at:

[PATCH tip/core/rcu 05/10] docs: RCU: Convert torture.txt to ReST

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab - Add a SPDX header; - Adjust document and section titles; - Some whitespace fixes and new line breaks; - Mark literal blocks as such; - Add it to RCU/index.rst. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Paul E. McKenney --- Documentation/RCU/index.rst

[PATCH tip/core/rcu 03/10] docs: RCU: Convert lockdep.txt to ReST

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab - Add a SPDX header; - Adjust document title; - Mark literal blocks as such; - Add it to RCU/index.rst. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Paul E. McKenney --- Documentation/RCU/index.rst| 1 + Documentation/RCU/{lockdep.txt

[PATCH tip/core/rcu 04/10] docs: RCU: Convert rculist_nulls.txt to ReST

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab - Add a SPDX header; - Adjust document title; - Some whitespace fixes and new line breaks; - Mark literal blocks as such; - Add it to RCU/index.rst. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Paul E. McKenney --- Documentation/RCU/index.rst | 1

[PATCH tip/core/rcu 07/10] docs: RCU: Convert stallwarn.txt to ReST

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab - Add a SPDX header; - Adjust document and section titles; - Fix list markups; - Some whitespace fixes and new line breaks; - Mark literal blocks as such; - Add it to RCU/index.rst. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Paul E. McKenney ---

[PATCH tip/core/rcu 10/10] doc: Tasks RCU must protect instructions before trampoline

2020-06-22 Thread paulmck
From: "Paul E. McKenney" Protecting the code in a trampoline can also require protecting a number of instructions prior to actually entering the trampoline. For example, these earlier instructions might be computing the address of the trampoline. This commit therefore updates RCU's requirements

[PATCH tip/core/rcu 08/10] docs: RCU: Don't duplicate chapter names in rculist_nulls.rst

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab Since changeset 58ad30cf91f0 ("docs: fix reference to core-api/namespaces.rst"), auto-references for chapters are generated. This is a nice feature, but has a drawback: no chapters can have the same sumber. So, we need to add two higher hierarchy chapters on this

[PATCH tip/core/rcu 09/10] doc: Timer problems can cause RCU CPU stall warnings

2020-06-22 Thread paulmck
From: "Paul E. McKenney" Over the past few years, there have been several cases where timekeeping bugs have caused RCU CPU stall warnings, particularly during hardware bringup. This commit therefore adds such bugs to the list of things that can result in RCU CPU stall warnings. Signed-off-by:

[PATCH tip/core/rcu 0/10] Documentation updates for v5.9

2020-06-22 Thread Paul E. McKenney
Hello! This series provides documentation updates. 1-7.Convert Documentation/RCU files to .rst, courtesy of Mauro Carvalho Chehab. 8. RCU: Don't duplicate chapter names in rculist_nulls.rst, courtesy of Mauro Carvalho Chehab. 9. Timer problems can cause RCU CPU

[PATCH tip/core/rcu 02/10] docs: RCU: Convert lockdep-splat.txt to ReST

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab - Add a SPDX header; - Add a document title; - Some whitespace fixes and new line breaks; - Mark literal blocks as such; - Add it to RCU/index.rst. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Paul E. McKenney --- Documentation/RCU/index.rst

[PATCH tip/core/rcu 01/10] docs: RCU: Convert checklist.txt to ReST

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab - Add a SPDX header; - Adjust document title; - Some whitespace fixes and new line breaks; - Use the right list markups; - Add it to RCU/index.rst. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Paul E. McKenney --- Documentation/RCU/{checklist.txt =>

[PATCH tip/core/rcu 06/10] docs: RCU: Convert rcuref.txt to ReST

2020-06-22 Thread paulmck
From: Mauro Carvalho Chehab - Add a SPDX header; - Adjust document title; - Some whitespace fixes and new line breaks; - Mark literal blocks as such; - Add it to RCU/index.rst. Signed-off-by: Mauro Carvalho Chehab Signed-off-by: Paul E. McKenney --- Documentation/RCU/index.rst

[PATCH] kselftest: ksft_test_num return type should be unsigned

2020-06-22 Thread Paolo Bonzini
Fixes a compiler warning: In file included from sync_test.c:37: ../kselftest.h: In function ‘ksft_print_cnts’: ../kselftest.h:78:16: warning: comparison of integer expressions of different signedness: ‘unsigned int’ and ‘int’ [-Wsign-compare] if (ksft_plan != ksft_test_num())

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Fri, Jun 19, 2020 at 04:10:11PM -0400, Jerome Glisse wrote: > Maybe we can audit how user ptr buffer are use today and see if > we can define a usage pattern that would allow to cut corner in > kernel. For instance we could use mmu notifier just to block CPU > pte update while we do GUP and

Re: [PATCH 13/16] mm: support THP migration to device private memory

2020-06-22 Thread Ralph Campbell
On 6/22/20 4:54 PM, Yang Shi wrote: On Mon, Jun 22, 2020 at 4:02 PM John Hubbard wrote: On 2020-06-22 15:33, Yang Shi wrote: On Mon, Jun 22, 2020 at 3:30 PM Yang Shi wrote: On Mon, Jun 22, 2020 at 2:53 PM Zi Yan wrote: On 22 Jun 2020, at 17:31, Ralph Campbell wrote: On 6/22/20 1:10

Re: [PATCH v4 3/5] stack: Optionally randomize kernel stack offset each syscall

2020-06-22 Thread Arvind Sankar
On Mon, Jun 22, 2020 at 04:07:11PM -0700, Kees Cook wrote: > On Mon, Jun 22, 2020 at 06:56:15PM -0400, Arvind Sankar wrote: > > On Mon, Jun 22, 2020 at 12:31:44PM -0700, Kees Cook wrote: > > > + > > > +#define add_random_kstack_offset() do { > > > \ > > > + if

Re: [Linaro-mm-sig] [PATCH 04/18] dma-fence: prime lockdep annotations

2020-06-22 Thread Jason Gunthorpe
On Mon, Jun 22, 2020 at 04:15:40PM -0400, Jerome Glisse wrote: > On Mon, Jun 22, 2020 at 08:46:17AM -0300, Jason Gunthorpe wrote: > > On Fri, Jun 19, 2020 at 04:31:47PM -0400, Jerome Glisse wrote: > > > Not doable as page refcount can change for things unrelated to GUP, with > > > John changes we

[PATCH][next] perf annotate: Use struct_size() helper

2020-06-22 Thread Gustavo A. R. Silva
Make use of the struct_size() helper instead of an open-coded version in order to avoid any potential type mistakes. Also, remove unnecessary function disasm_line_size(). This code was detected with the help of Coccinelle and, audited and fixed manually. Signed-off-by: Gustavo A. R. Silva ---

Re: New mode DM-Verity error handling

2020-06-22 Thread JeongHyeon Lee
Dear Milan Broz. Thank for your reply. I didn't understand well, could you explain it in more detail? For what reason isn't panic better? Is it because there is a place to use other device-mapper? Or other things? I just wonder. I would like to hear various explanations and information. I

Re: [PATCH] checkpatch: use $root/.git when seeding camel case

2020-06-22 Thread Jacob Keller
On 6/22/2020 3:11 PM, Joe Perches wrote: > On Mon, 2020-06-22 at 14:58 -0700, Jacob Keller wrote: >> When seeding the camel case file, checkpatch.pl uses the $root directory >> in order to find the acceptable list of allowed camel case words. >> >> However, if the current directory is a git

Re: [PATCH 13/16] mm: support THP migration to device private memory

2020-06-22 Thread Yang Shi
On Mon, Jun 22, 2020 at 4:02 PM John Hubbard wrote: > > On 2020-06-22 15:33, Yang Shi wrote: > > On Mon, Jun 22, 2020 at 3:30 PM Yang Shi wrote: > >> On Mon, Jun 22, 2020 at 2:53 PM Zi Yan wrote: > >>> On 22 Jun 2020, at 17:31, Ralph Campbell wrote: > On 6/22/20 1:10 PM, Zi Yan wrote: >

Re: [PATCH 06/11] phy: un-inline devm_mdiobus_register()

2020-06-22 Thread Florian Fainelli
On 6/22/20 3:00 AM, Bartosz Golaszewski wrote: > From: Bartosz Golaszewski > > Functions should only be static inline if they're very short. This > devres helper is already over 10 lines and it will grow soon as we'll > be improving upon its approach. Pull it into mdio_devres.c. > >

Re: [PATCH 1/2] net: ethernet: mvneta: Fix Serdes configuration for SoCs without comphy

2020-06-22 Thread Russell King - ARM Linux admin
On Tue, Jun 16, 2020 at 10:31:39AM +0200, Sascha Hauer wrote: > 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 > initialization,

[PATCH] RISC-V: Use a local variable instead of smp_processor_id()

2020-06-22 Thread Atish Patra
From: Greentime Hu Store the smp_processor_id() in a local variable to save some pointer chasing. Signed-off-by: Greentime Hu Signed-off-by: Atish Patra --- arch/riscv/kernel/smpboot.c | 7 --- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/arch/riscv/kernel/smpboot.c

[PATCH 01/17] fork: fold legacy_clone_args_valid() into _do_fork()

2020-06-22 Thread Christian Brauner
This separate helper only existed to guarantee the mutual exclusivity of CLONE_PIDFD and CLONE_PARENT_SETTID for legacy clone since CLONE_PIDFD abuses the parent_tid field to return the pidfd. But we can actually handle this uniformely thus removing the helper. For legacy clone we can detect that

[PATCH v2 0/3] Preventing job distribution to isolated CPUs

2020-06-22 Thread Nitesh Narayan Lal
Testing === * Patch 1:

Re: [PATCH v2 00/11] KVM: Support guest MAXPHYADDR < host MAXPHYADDR

2020-06-22 Thread Andy Lutomirski
On 6/19/20 4:07 PM, Paolo Bonzini wrote: > On 19/06/20 23:52, Tom Lendacky wrote: >>> A more subtle issue is when the host MAXPHYADDR is larger than that >>> of the guest. Page faults caused by reserved bits on the guest won't >>> cause an EPT violation/NPF and hence we also check guest MAXPHYADDR

Re: kprobe: __blkdev_put probe is missed

2020-06-22 Thread Masami Hiramatsu
On Mon, 22 Jun 2020 09:01:48 -0400 Steven Rostedt wrote: > On Mon, 22 Jun 2020 08:27:53 +0800 > Ming Lei wrote: > > > Can you kprobe guys improve the implementation for covering this case? > > For example, put probe on 3) in case the above situation is recognized. > > To do so would require

[PATCH 11/17] hexagon: switch to copy_thread_tls()

2020-06-22 Thread Christian Brauner
Use the copy_thread_tls() calling convention which passes tls through a register. This is required so we can remove the copy_thread{_tls}() split and remove the HAVE_COPY_THREAD_TLS macro. Cc: Brian Cain Cc: linux-hexa...@vger.kernel.org Signed-off-by: Christian Brauner ---

[PATCH 12/17] microblaze: switch to copy_thread_tls()

2020-06-22 Thread Christian Brauner
Use the copy_thread_tls() calling convention which passes tls through a register. This is required so we can remove the copy_thread{_tls}() split and remove the HAVE_COPY_THREAD_TLS macro. Cc: Michal Simek Signed-off-by: Christian Brauner --- arch/microblaze/Kconfig | 1 +

[PATCH 02/17] sparc64: enable HAVE_COPY_THREAD_TLS

2020-06-22 Thread Christian Brauner
This is part of a larger series that aims at getting rid of the copy_thread()/copy_thread_tls() split that makes the process creation codepaths in the kernel more convoluted and error-prone than they need to be. It also unblocks implementing clone3() on architectures not support copy_thread_tls().

[PATCH 15/17] unicore: switch to copy_thread_tls()

2020-06-22 Thread Christian Brauner
Use the copy_thread_tls() calling convention which passes tls through a register. This is required so we can remove the copy_thread{_tls}() split and remove the HAVE_COPY_THREAD_TLS macro. Cc: Guan Xuetao Signed-off-by: Christian Brauner --- arch/unicore32/Kconfig | 1 +

[Patch v2 3/3] net: Restrict receive packets queuing to housekeeping CPUs

2020-06-22 Thread Nitesh Narayan Lal
From: Alex Belits With the existing implementation of store_rps_map(), packets are queued in the receive path on the backlog queues of other CPUs irrespective of whether they are isolated or not. This could add a latency overhead to any RT workload that is running on the same CPU. Ensure that

[PATCH 14/17] sh: switch to copy_thread_tls()

2020-06-22 Thread Christian Brauner
Use the copy_thread_tls() calling convention which passes tls through a register. This is required so we can remove the copy_thread{_tls}() split and remove the HAVE_COPY_THREAD_TLS macro. Cc: Rich Felker Cc: Yoshinori Sato Cc: linux...@vger.kernel.org Signed-off-by: Christian Brauner ---

[PATCH 10/17] c6x: switch to copy_thread_tls()

2020-06-22 Thread Christian Brauner
Use the copy_thread_tls() calling convention which passes tls through a register. This is required so we can remove the copy_thread{_tls}() split and remove the HAVE_COPY_THREAD_TLS macro. CC: Mark Salter Cc: Aurelien Jacquiot Cc: linux-c6x-...@linux-c6x.org Signed-off-by: Christian Brauner

[PATCH 05/17] ia64: enable HAVE_COPY_THREAD_TLS, switch to kernel_clone_args

2020-06-22 Thread Christian Brauner
This is part of a larger series that aims at getting rid of the copy_thread()/copy_thread_tls() split that makes the process creation codepaths in the kernel more convoluted and error-prone than they need to be. I'm converting all the remaining arches that haven't yet switched and am collecting

[PATCH 03/17] sparc: share process creation helpers between sparc and sparc64

2020-06-22 Thread Christian Brauner
As promised in the previous patch, this moves the process creation helpers into a common process.c file that is shared between sparc and sparc64. It allows us to get rid of quite a bit custom assembler and the to remove the separe 32bit specific sparc_do_fork() call. One thing to note, is that

[PATCH 09/17] alpha: switch to copy_thread_tls()

2020-06-22 Thread Christian Brauner
Use the copy_thread_tls() calling convention which passes tls through a register. This is required so we can remove the copy_thread{_tls}() split and remove the HAVE_COPY_THREAD_TLS macro. Cc: linux-al...@vger.kernel.org Signed-off-by: Christian Brauner --- arch/alpha/Kconfig | 1 +

[PATCH 06/17] nios2: enable HAVE_COPY_THREAD_TLS, switch to kernel_clone_args

2020-06-22 Thread Christian Brauner
This is part of a larger series that aims at getting rid of the copy_thread()/copy_thread_tls() split that makes the process creation codepaths in the kernel more convoluted and error-prone than they need to be. I'm converting all the remaining arches that haven't yet switched and am collecting

[PATCH 08/17] fork: remove do_fork()

2020-06-22 Thread Christian Brauner
Now that all architectures have been switched to use _do_fork() and the new struct kernel_clone_args calling convention we can remove the legacy do_fork() helper completely. The calling convention used to be brittle and do_fork() didn't buy us anything. The only calling convention accepted should

[PATCH 07/17] h8300: select HAVE_COPY_THREAD_TLS, switch to kernel_clone_args

2020-06-22 Thread Christian Brauner
This is part of a larger series that aims at getting rid of the copy_thread()/copy_thread_tls() split that makes the process creation codepaths in the kernel more convoluted and error-prone than they need to be. I'm converting all the remaining arches that haven't yet switched and am collecting

[PATCH 13/17] nds32: switch to copy_thread_tls()

2020-06-22 Thread Christian Brauner
Use the copy_thread_tls() calling convention which passes tls through a register. This is required so we can remove the copy_thread{_tls}() split and remove the HAVE_COPY_THREAD_TLS macro. Cc: Greentime Hu Cc: Nick Hu Cc: Vincent Chen Signed-off-by: Christian Brauner --- arch/nds32/Kconfig

[PATCH 04/17] sparc: unconditionally enable HAVE_COPY_THREAD_TLS

2020-06-22 Thread Christian Brauner
Now that both sparc and sparc64 support copy_thread_tls() and don't rely on do_fork() anymore, turn on HAVE_COPY_THREAD_TLS unconditionally. Once all architectures are switched over this macro will be removed and the old do_fork() calling convention fully abandoned in favor of the cleaner struct

[Patch v2 1/3] lib: Restrict cpumask_local_spread to houskeeping CPUs

2020-06-22 Thread Nitesh Narayan Lal
From: Alex Belits The current implementation of cpumask_local_spread() does not respect the isolated CPUs, i.e., even if a CPU has been isolated for Real-Time task, it will return it to the caller for pinning of its IRQ threads. Having these unwanted IRQ threads on an isolated CPU adds up to a

[Patch v2 2/3] PCI: Restrict probe functions to housekeeping CPUs

2020-06-22 Thread Nitesh Narayan Lal
From: Alex Belits pci_call_probe() prevents the nesting of work_on_cpu() for a scenario where a VF device is probed from work_on_cpu() of the PF. Replace the cpumask used in pci_call_probe() from all online CPUs to only housekeeping CPUs. This is to ensure that there are no additional latency

[PATCH 00/17] arch: remove do_fork() and HAVE_COPY_THREAD_TLS

2020-06-22 Thread Christian Brauner
Hey, This is a series I had announced some time back (cf. [2]) when we reworked a chunk of the process creation paths in the kernel and switched to struct {kernel_}clone_args. I've been sitting on this for a while due to lack of time and because testing on all architectures that are non-trivially

[RESEND PATCH 2/3] nouveau: fix mixed normal and device private page migration

2020-06-22 Thread Ralph Campbell
The OpenCL function clEnqueueSVMMigrateMem(), without any flags, will migrate memory in the given address range to device private memory. The source pages might already have been migrated to device private memory. In that case, the source struct page is not checked to see if it is a device private

[RESEND PATCH 1/3] nouveau: fix migrate page regression

2020-06-22 Thread Ralph Campbell
The patch to add zero page migration to GPU memory inadvertantly included part of a future change which broke normal page migration to GPU memory by copying too much data and corrupting GPU memory. Fix this by only copying one page instead of a byte count. Fixes: 9d4296a7d4b3

[RESEND PATCH 3/3] nouveau: make nvkm_vmm_ctor() and nvkm_mmu_ptp_get() static

2020-06-22 Thread Ralph Campbell
The functions nvkm_vmm_ctor() and nvkm_mmu_ptp_get() are not called outside of the file defining them so make them static. Signed-off-by: Ralph Campbell --- drivers/gpu/drm/nouveau/nvkm/subdev/mmu/base.c | 2 +- drivers/gpu/drm/nouveau/nvkm/subdev/mmu/vmm.c | 2 +-

[RESEND PATCH 0/3] nouveau: fixes for SVM

2020-06-22 Thread Ralph Campbell
These are based on 5.8.0-rc2 and intended for Ben Skeggs' nouveau tree. I believe the changes can be queued for 5.8-rcX after being reviewed. These were part of a larger series but I'm resending them separately as suggested by Jason Gunthorpe.

Hello Dear

2020-06-22 Thread Lisa Tofan
Hello Dear, This is Miss Lisa Tofan, How are you today hope all is well with you, please I will need your urgent attention regarding this important discussion kindly contact me back here my Email: lisatofan...@gmail.com: for more details, Thanks, Miss Lisa Tofan

Re: [PATCH] usbnet: smsc95xx: Fix use-after-free after removal

2020-06-22 Thread David Miller
From: Tuomas Tynkkynen Date: Sun, 21 Jun 2020 13:43:26 +0300 > Syzbot reports an use-after-free in workqueue context: > > BUG: KASAN: use-after-free in mutex_unlock+0x19/0x40 > kernel/locking/mutex.c:737 > mutex_unlock+0x19/0x40 kernel/locking/mutex.c:737 > __smsc95xx_mdio_read

Re: [PATCH v2 net 0/3] net: ethtool: netdev_features_strings[] cleanup

2020-06-22 Thread David Miller
From: Alexander Lobakin Date: Sun, 21 Jun 2020 09:55:50 + > This little series adds the last forgotten feature string for > NETIF_F_GSO_TUNNEL_REMCSUM and attempts to prevent such losses > in future. > > Patches 2-3 seem more like net-next candidates rather than net-fixes, > but for me it

Re: [PATCH v2 1/3] vmlinux.lds.h: Add .gnu.version* to DISCARDS

2020-06-22 Thread Kees Cook
On Mon, Jun 22, 2020 at 04:04:40PM -0700, Fāng-ruì Sòng wrote: > On Mon, Jun 22, 2020 at 3:57 PM Kees Cook wrote: > > > > On Mon, Jun 22, 2020 at 03:52:37PM -0700, Fangrui Song wrote: > > > > And it's not in the output: > > > > > > > > $ readelf -Vs arch/x86/boot/compressed/vmlinux | grep version

[PATCH] crypto, x86: aesni: add compatibility with IAS

2020-06-22 Thread Jian Cai
Clang's integrated assembler complains "invalid reassignment of non-absolute variable 'var_ddq_add'" while assembling arch/x86/crypto/aes_ctrby8_avx-x86_64.S. It was because var_ddq_add was reassigned with non-absolute values several times, which IAS did not support. We can avoid the reassignment

[PATCH][next] libperf: Use struct_size() helper

2020-06-22 Thread Gustavo A. R. Silva
Make use of the struct_size() helper instead of an open-coded version in order to avoid any potential type mistakes. Also, remove unnecessary variable _size_. This code was detected with the help of Coccinelle and, audited and fixed manually. Signed-off-by: Gustavo A. R. Silva ---

Re: [PATCH 09/16] mm/hmm: add output flag for compound page mapping

2020-06-22 Thread Ralph Campbell
On 6/22/20 4:18 PM, Jason Gunthorpe wrote: On Mon, Jun 22, 2020 at 11:10:05AM -0700, Ralph Campbell wrote: On 6/22/20 10:25 AM, Jason Gunthorpe wrote: On Fri, Jun 19, 2020 at 02:56:42PM -0700, Ralph Campbell wrote: hmm_range_fault() returns an array of page frame numbers and flags for how

Re: [PATCH 0/2] prepare dwmac-meson8b for G12A specific initialization

2020-06-22 Thread David Miller
From: Martin Blumenstingl Date: Sat, 20 Jun 2020 21:26:39 +0200 > Some users are reporting that RGMII (and sometimes also RMII) Ethernet > is not working for them on G12A/G12B/SM1 boards. Upon closer inspection > of the vendor code for these SoCs new register bits are found. > > It's not clear

Re: [PATCH] rcu/tree: Remove CONFIG_PREMPT_RCU check in force_qs_rnp

2020-06-22 Thread Paul E. McKenney
On Mon, Jun 22, 2020 at 11:37:03PM +0530, Neeraj Upadhyay wrote: > Remove CONFIG_PREMPT_RCU check in force_qs_rnp(). Originally, > this check was required to skip executing fqs failsafe > for rcu-sched, which was added in commit a77da14ce9af ("rcu: > Yet another fix for preemption and CPU

Re: [PATCH 09/16] mm/hmm: add output flag for compound page mapping

2020-06-22 Thread Jason Gunthorpe
On Mon, Jun 22, 2020 at 11:10:05AM -0700, Ralph Campbell wrote: > > On 6/22/20 10:25 AM, Jason Gunthorpe wrote: > > On Fri, Jun 19, 2020 at 02:56:42PM -0700, Ralph Campbell wrote: > > > hmm_range_fault() returns an array of page frame numbers and flags for > > > how the pages are mapped in the

Re: [PATCH] vmlinux.lds: consider .text.{hot|unlikely}.* part of .text too

2020-06-22 Thread Fāng-ruì Sòng
On 2020-06-22, Nick Desaulniers wrote: On Wed, Jun 17, 2020 at 2:27 PM Fāng-ruì Sòng wrote: On 2020-06-17, Nick Desaulniers wrote: >ld.bfd's internal linker script considers .text.hot AND .text.hot.* to >be part of .text, as well as .text.unlikely and .text.unlikely.*. >ld.lld will produce

[PATCH] ima: extend boot_aggregate with kernel measurements

2020-06-22 Thread Maurizio Drocco
IMA is not considering TPM registers 8-9 when calculating the boot aggregate. When registers 8-9 are used to store measurements of the kernel and its command line (e.g., grub2 bootloader with tpm module enabled), IMA should include them in the boot aggregate. Registers 8-9 are only included in

Re: [PATCH net v3] net: phy: smsc: fix printing too many logs

2020-06-22 Thread David Miller
From: Dejin Zheng Date: Sat, 20 Jun 2020 22:55:34 +0800 > Commit 7ae7ad2f11ef47 ("net: phy: smsc: use phy_read_poll_timeout() > to simplify the code") will print a lot of logs as follows when Ethernet > cable is not connected: > > [4.473105] SMSC LAN8710/LAN8720 2188000.ethernet-1:00: >

Re: [Resend PATCH net] bridge: uapi: mrp: Fix MRP_PORT_ROLE

2020-06-22 Thread David Miller
From: Horatiu Vultur Date: Sat, 20 Jun 2020 15:14:03 +0200 > Currently the MRP_PORT_ROLE_NONE has the value 0x2 but this is in conflict > with the IEC 62439-2 standard. The standard defines the following port > roles: primary (0x0), secondary(0x1), interconnect(0x2). > Therefore remove the port

Re: [PATCH v4 3/5] stack: Optionally randomize kernel stack offset each syscall

2020-06-22 Thread Kees Cook
On Mon, Jun 22, 2020 at 06:56:15PM -0400, Arvind Sankar wrote: > On Mon, Jun 22, 2020 at 12:31:44PM -0700, Kees Cook wrote: > > + > > +#define add_random_kstack_offset() do { > > \ > > + if (static_branch_maybe(CONFIG_RANDOMIZE_KSTACK_OFFSET_DEFAULT, \ > > +

Re: [PATCH] vmlinux.lds: consider .text.{hot|unlikely}.* part of .text too

2020-06-22 Thread Nick Desaulniers
On Wed, Jun 17, 2020 at 2:27 PM Fāng-ruì Sòng wrote: > > > On 2020-06-17, Nick Desaulniers wrote: > >ld.bfd's internal linker script considers .text.hot AND .text.hot.* to > >be part of .text, as well as .text.unlikely and .text.unlikely.*. > > >ld.lld will produce .text.hot.*/.text.unlikely.*

Re: [PATCH v2 1/3] vmlinux.lds.h: Add .gnu.version* to DISCARDS

2020-06-22 Thread Fāng-ruì Sòng
On Mon, Jun 22, 2020 at 3:57 PM Kees Cook wrote: > > On Mon, Jun 22, 2020 at 03:52:37PM -0700, Fangrui Song wrote: > > > And it's not in the output: > > > > > > $ readelf -Vs arch/x86/boot/compressed/vmlinux | grep version > > > No version information found in this file. > > > > > > So... for the

[PATCH][next] net: ipv6: Use struct_size() helper and kcalloc()

2020-06-22 Thread Gustavo A. R. Silva
Make use of the struct_size() helper instead of an open-coded version in order to avoid any potential type mistakes. Also, remove unnecessary function ipv6_rpl_srh_alloc_size() and replace kzalloc() with kcalloc(), which has a 2-factor argument form for multiplication. This code was detected with

Re: [PATCH 13/16] mm: support THP migration to device private memory

2020-06-22 Thread John Hubbard
On 2020-06-22 15:33, Yang Shi wrote: On Mon, Jun 22, 2020 at 3:30 PM Yang Shi wrote: On Mon, Jun 22, 2020 at 2:53 PM Zi Yan wrote: On 22 Jun 2020, at 17:31, Ralph Campbell wrote: On 6/22/20 1:10 PM, Zi Yan wrote: On 22 Jun 2020, at 15:36, Ralph Campbell wrote: On 6/21/20 4:20 PM, Zi Yan

Re: [PATCH 3/4] pci: acs: Enable PCI_ACS_TB for untrusted/external-facing devices

2020-06-22 Thread Rajat Jain
Hi Ashok, On Fri, Jun 19, 2020 at 9:10 AM Raj, Ashok wrote: > > Hi Rajat > > > On Mon, Jun 15, 2020 at 06:17:41PM -0700, Rajat Jain wrote: > > When enabling ACS, currently the bit "translation blocking" was > > not getting changed at all. Set it to disable translation blocking > > Maybe you

Re: [PATCH v2 3/3] x86/boot: Warn on orphan section placement

2020-06-22 Thread Kees Cook
On Mon, Jun 22, 2020 at 03:49:28PM -0700, Fangrui Song wrote: > On 2020-06-22, Kees Cook wrote: > > On Mon, Jun 22, 2020 at 03:06:28PM -0700, Fangrui Song wrote: > > > LLD may report warnings for 3 synthetic sections if they are orphans: > > > > > > ld.lld: warning: :(.symtab) is being placed in

[PATCH 2/2] HID: wiimote: Don't use device IDs for Wii Balance Boards.

2020-06-22 Thread David Korth
Wii Balance Boards only have a single LED, so the player number can't be displayed on the board itself. Don't bother allocating a device ID in this case. Note that on the actual Wii system, only one board can usually be connected at a time, and it's listed as Player 4 on the HOME Menu.

[PATCH 1/2] HID: wiimote: Initialize the controller LEDs with a device ID value

2020-06-22 Thread David Korth
Based on a similar commit for Sony Sixaxis and DualShock 4 controllers: HID: sony: Initialize the controller LEDs with a device ID value Wii remotes have the same player LED layout as Sixaxis controllers, so the wiimote setup is based on the Sixaxis code. Signed-off-by: David Korth ---

Re: [PATCH v2 1/3] vmlinux.lds.h: Add .gnu.version* to DISCARDS

2020-06-22 Thread Kees Cook
On Mon, Jun 22, 2020 at 03:52:37PM -0700, Fangrui Song wrote: > > And it's not in the output: > > > > $ readelf -Vs arch/x86/boot/compressed/vmlinux | grep version > > No version information found in this file. > > > > So... for the kernel we need to silence it right now. > > Re-link with -M

Re: [PATCH v4 3/5] stack: Optionally randomize kernel stack offset each syscall

2020-06-22 Thread Arvind Sankar
On Mon, Jun 22, 2020 at 12:31:44PM -0700, Kees Cook wrote: > + > +#define add_random_kstack_offset() do { > \ > + if (static_branch_maybe(CONFIG_RANDOMIZE_KSTACK_OFFSET_DEFAULT, \ > + _kstack_offset)) {\ > +

Re: [PATCH net-next v5 0/3] net: dsa: qca8k: Improve SGMII interface handling

2020-06-22 Thread David Miller
From: Jonathan McDowell Date: Sat, 20 Jun 2020 11:30:03 +0100 > This 3 patch series migrates the qca8k switch driver over to PHYLINK, > and then adds the SGMII clean-ups (i.e. the missing initialisation) on > top of that as a second patch. The final patch is a simple spelling fix > in a comment.

Re: [PATCH] rcu/tree: Force quiescent state on callback overload

2020-06-22 Thread Paul E. McKenney
On Mon, Jun 22, 2020 at 09:16:24AM +0530, Neeraj Upadhyay wrote: > Hi Paul, > > On 6/22/2020 8:43 AM, Paul E. McKenney wrote: > > On Mon, Jun 22, 2020 at 01:30:31AM +0530, Neeraj Upadhyay wrote: > > > Hi Paul, > > > > > > On 6/22/2020 1:20 AM, Paul E. McKenney wrote: > > > > On Mon, Jun 22, 2020

Re: [PATCH v2 1/3] vmlinux.lds.h: Add .gnu.version* to DISCARDS

2020-06-22 Thread Fangrui Song
On 2020-06-22, Kees Cook wrote: On Mon, Jun 22, 2020 at 03:00:43PM -0700, Fangrui Song wrote: On 2020-06-22, Kees Cook wrote: > For vmlinux linking, no architecture uses the .gnu.version* section, > so remove it via the common DISCARDS macro in preparation for adding > --orphan-handling=warn

Re: [PATCH v2 3/3] x86/boot: Warn on orphan section placement

2020-06-22 Thread Fangrui Song
On 2020-06-22, Kees Cook wrote: On Mon, Jun 22, 2020 at 03:06:28PM -0700, Fangrui Song wrote: LLD may report warnings for 3 synthetic sections if they are orphans: ld.lld: warning: :(.symtab) is being placed in '.symtab' ld.lld: warning: :(.shstrtab) is being placed in '.shstrtab' ld.lld:

Re: LTP: crypto: af_alg02 regression on linux-next 20200621 tag

2020-06-22 Thread Luis Chamberlain
On Tue, Jun 23, 2020 at 12:04:06AM +0530, Naresh Kamboju wrote: > LTP crypto regressions noticed on linux next 20200621. > > The common case for all tests is timeout after 15 minutes which > means tests got hung and LTP timers killed those test runs after > timeout. > The root cause of the

Re: [PATCH 03/11] net: devres: relax devm_register_netdev()

2020-06-22 Thread Jakub Kicinski
On Mon, 22 Jun 2020 12:00:48 +0200 Bartosz Golaszewski wrote: > From: Bartosz Golaszewski > > This devres helper registers a release callback that only unregisters > the net_device. It works perfectly fine with netdev structs that are > not managed on their own. There's no reason to check this -

Re: [PATCH] [objtoo] fix memory leak in special_get_alts

2020-06-22 Thread Josh Poimboeuf
On Sun, Jun 21, 2020 at 10:04:34PM -0400, Gaurav Singh wrote: > Free alt before returning to avoid memory leak. > > Signed-off-by: Gaurav Singh Hi Gaurav, Since objtool is a short-lived (and performance sensitive) process, we don't care about memory leaks. In fact we intentionally don't fix

[PATCH 01/15] KVM: x86: Rename "shared_msrs" to "user_return_msrs"

2020-06-22 Thread Sean Christopherson
Rename the "shared_msrs" mechanism, which is used to defer restoring MSRs that are only consumed when running in userspace, to a more banal but less likely to be confusing "user_return_msrs". The "shared" nomenclature is confusing as it's not obvious who is sharing what, e.g. reasonable

[PATCH 10/15] KVM: VMX: Move uret MSR lookup into update_transition_efer()

2020-06-22 Thread Sean Christopherson
Move checking for the existence of MSR_EFER in the uret MSR array into update_transition_efer() so that the lookup and manipulation of the array in setup_msrs() occur back-to-back. This paves the way toward adding a helper to wrap the lookup and manipulation. To avoid unnecessary overhead, defer

[PATCH 02/15] KVM: VMX: Prepend "MAX_" to MSR array size defines

2020-06-22 Thread Sean Christopherson
Add "MAX" to the LOADSTORE and so called SHARED MSR defines to make it more clear that the define controls the array size, as opposed to the actual number of valid entries that are in the array. No functional change intended. Signed-off-by: Sean Christopherson --- arch/x86/kvm/vmx/nested.c |

[PATCH 08/15] KVM: VMX: Rename "__find_msr_index" to "__vmx_find_uret_msr"

2020-06-22 Thread Sean Christopherson
Rename "__find_msr_index" to scope it to VMX, associate it with guest_uret_msrs, and to avoid conflating "MSR's ECX index" with "MSR's array index". Similarly, don't use "slot" in the name so as to avoid colliding the common x86's half of "user_return_msrs" (the slot in kvm_user_return_msrs is

[PATCH 05/15] KVM: VMX: Rename vcpu_vmx's "nmsrs" to "nr_uret_msrs"

2020-06-22 Thread Sean Christopherson
Rename vcpu_vmx.nsmrs to vcpu_vmx.nr_uret_msrs to explicitly associate it with the guest_uret_msrs array. No functional change intended. Signed-off-by: Sean Christopherson --- arch/x86/kvm/vmx/vmx.c | 6 +++--- arch/x86/kvm/vmx/vmx.h | 2 +- 2 files changed, 4 insertions(+), 4 deletions(-)

Re: [PATCH] sparc: piggyback: handle invalid image

2020-06-22 Thread David Miller
From: Corentin Labbe Date: Wed, 10 Jun 2020 07:55:19 + > With an old elftoaout, the generation of tftpboot.img fail with "lseek: > invalid argument". > This is due to offset being negative. > > Instead of printing this error message, let's print a better one. > > Signed-off-by: Corentin

[PATCH 09/15] KVM: VMX: Check guest support for RDTSCP before processing MSR_TSC_AUX

2020-06-22 Thread Sean Christopherson
Check for RDTSCP support prior to checking if MSR_TSC_AUX is in the uret MSRs array so that the array lookup and manipulation are back-to-back. This paves the way toward adding a helper to wrap the lookup and manipulation. No functional change intended. Signed-off-by: Sean Christopherson ---

[PATCH 12/15] KVM: VMX: Rename "find_msr_entry" to "vmx_find_uret_msr"

2020-06-22 Thread Sean Christopherson
Rename "find_msr_entry" to scope it to VMX and to associate it with guest_uret_msrs. Drop the "entry" so that the function name pairs with the existing __vmx_find_uret_msr(), which intentionally uses a double underscore prefix instead of appending "index" or "slot" as those names are already

[PATCH v3 01/14] tools headers: Add kprobes.h header

2020-06-22 Thread Sasha Levin
This is now needed by liblockdep as a result of 2f43c6022d84 ("kprobes: Prohibit probing on lockdep functions"). Signed-off-by: Sasha Levin --- tools/include/linux/kprobes.h | 7 +++ 1 file changed, 7 insertions(+) create mode 100644 tools/include/linux/kprobes.h diff --git

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