Re: [PATCH] irqchip: plic: Fix priority base offset

2019-03-26 Thread Alistair Francis
On Fri, Mar 22, 2019 at 6:27 AM Christoph Hellwig wrote: > > On Wed, Mar 20, 2019 at 05:04:58PM -0700, Alistair Francis wrote: > > > Well, it starts at 0x00, but the first one is reserved. If you think > > > that is too confusing I'd rather throw in a comment explaining this > > > fact rather tha

Re: [RFC PATCH v4 0/8] This patch-set is to enable Guest CET support

2019-03-26 Thread Sean Christopherson
On Tue, Mar 26, 2019 at 04:45:34AM +0800, Yang Weijiang wrote: > Hi, Paolo and Sean, > Do you have any comments on v4 patches? My backlog is a bit full at the moment, I'll try to review the series later this week.

[PATCH 4/4] perf: arm_spe: Enable ACPI/Platform automatic module loading

2019-03-26 Thread Jeremy Linton
Lets add the MODULE_TABLE and platform id_table entries so that the SPE driver can attach to the ACPI platform device created by the core pmu code. Signed-off-by: Jeremy Linton Reviewed-by: Sudeep Holla --- drivers/perf/arm_spe_pmu.c | 11 +-- 1 file changed, 9 insertions(+), 2 deletion

[PATCH 3/4] arm_pmu: acpi: spe: Add initial MADT/SPE probing

2019-03-26 Thread Jeremy Linton
ACPI 6.3 adds additional fields to the MADT GICC structure to describe SPE PPI's. We pick these out of the cached reference to the madt_gicc structure similarly to the core PMU code. We then create a platform device referring to the IRQ and let the user/module loader decide whether to load the SPE

[PATCH 0/4] arm64: SPE ACPI enablement

2019-03-26 Thread Jeremy Linton
This patch series enables the Arm Statistical Profiling Extension (SPE) on ACPI platforms. This is possible because ACPI 6.3 uses a previously reserved field in the MADT to store the SPE interrupt number, similarly to how the normal PMU is described. If a consistent valid interrupt exists across a

[PATCH 1/4] ACPI/PPTT: Add function to return ACPI 6.3 Identical tokens

2019-03-26 Thread Jeremy Linton
ACPI 6.3 adds a flag to indicate that child nodes are all identical cores. This is useful to authoritatively determine if a set of (possibly offline) cores are identical or not. Since the flag doesn't give us a unique id we can generate one and use it to create bitmaps of sibling nodes, or simply

[PATCH 2/4] ACPI/PPTT: Modify node flag detection to find last IDENTICAL

2019-03-26 Thread Jeremy Linton
The ACPI specification implies that the IDENTICAL flag should be set on all non leaf nodes where the children are identical. This means that we need to be searching for the last node with the identical flag set rather than the first one. To achieve this with the existing code we need to pass a fun

RE: [PATCH v3] HID: core: move Usage Page concatenation to Main item

2019-03-26 Thread Junge, Terry
Hi Nicolas, This patch looks good except for one comment/question below. Thanks, Terry On Tuesday, March 26, 2019 1:04 PM Nicolas Saenz Julienne wrote: > >As seen on some USB wireless keyboards manufactured by Primax, the HID >parser was using some assumptions that are not always true. In this

Re: [PATCH 22/27] Lock down kprobes

2019-03-26 Thread Masami Hiramatsu
On Tue, 26 Mar 2019 10:41:23 -0700 Matthew Garrett wrote: > On Tue, Mar 26, 2019 at 5:30 AM Masami Hiramatsu wrote: > > > > On Mon, 25 Mar 2019 15:09:49 -0700 > > Matthew Garrett wrote: > > > > > From: David Howells > > > > > > Disallow the creation of kprobes when the kernel is locked down by

Re: [RFC PATCH v2 1/3] resource: Request IO port regions from children of ioport_resource

2019-03-26 Thread Bjorn Helgaas
[+cc Catalin, Will, linux-arm-kernel] On Tue, Mar 26, 2019 at 04:33:55PM +, John Garry wrote: > On 25/03/2019 23:32, Bjorn Helgaas wrote: > > On Thu, Mar 21, 2019 at 02:14:08AM +0800, John Garry wrote: > > > Currently when we request an IO port region, the request is made directly > > > to the

[PATCH 1/3] fs: stream_open - opener for stream-like files so that read and write can run simultaneously without deadlock

2019-03-26 Thread Kirill Smelkov
Commit 9c225f2655 (vfs: atomic f_pos accesses as per POSIX) added locking for file.f_pos access and in particular made concurrent read and write not possible - now both those functions take f_pos lock for the whole run, and so if e.g. a read is blocked waiting for data, write will deadlock waiting

Re: [PATCH v3] kmemleaak: survive in a low-memory situation

2019-03-26 Thread Qian Cai
On 3/26/19 12:06 PM, Catalin Marinas wrote: > I wonder whether we'd be better off to replace the metadata allocator > with gen_pool. This way we'd also get rid of early logging/replaying of > the memory allocations since we can populate the gen_pool early with a > static buffer. I suppose this is

Re: New feature/ABI review process [was Re: [RESEND PATCH v6 04/12] x86/fsgsbase/64:..]

2019-03-26 Thread Andi Kleen
> > If you want to advocate the more complex design of mixed SWAPGS/FSGSBASE > then provide numbers and not hand-waving. Numbers of real-world workloads, > not numbers of artificial test cases which exercise the rare worst case. Well you're proposing the much more complicated solution, not me. S

Re: [PATCH v2 2/4] mm/sparse: Optimize sparse_add_one_section()

2019-03-26 Thread Baoquan He
Hi Michal, On 03/26/19 at 03:31pm, Michal Hocko wrote: > > > > OK, I am fine to drop it. Or only put the section existence checking > > > > earlier to avoid unnecessary usemap/memmap allocation? > > > > > > DO you have any data on how often that happens? Should basically never > > > happening, ri

Re: [PATCH] EDAC/amd64: Use maximum channel count for the EDAC channel layer size

2019-03-26 Thread Borislav Petkov
On Tue, Mar 26, 2019 at 07:15:29PM +, Ghannam, Yazen wrote: > Just tested on a fully populated system. Everything seems to be okay. Thanks, queued. -- Regards/Gruss, Boris. Good mailing practices for 400: avoid top-posting and trim the reply.

Re: [PATCH] timekeeping: Force upper bound for setting CLOCK_REALTIME

2019-03-26 Thread Thomas Gleixner
On Tue, 26 Mar 2019, Arnd Bergmann wrote: > On Tue, Mar 26, 2019 at 1:31 PM Thomas Gleixner wrote: > > > > On Tue, 26 Mar 2019, Miroslav Lichvar wrote: > > > On Sat, Mar 23, 2019 at 11:36:19AM +0100, Thomas Gleixner wrote: > > > > It is reasonable to force an upper bound for the various methods of

[PATCH tip/core/rcu 0/2] straggling consolidation cleanups for v5.2

2019-03-26 Thread Paul E. McKenney
Hello! This series contains a few straggling RCU consolidation updates: 1. Update kprobes's documentation of obsolete RCU update functions. 2. Update netfilter comment from call_rcu_bh() to call_rcu() Thanx, Paul ---

[PATCH tip/core/rcu 2/2] net/ipv4/netfilter: Update comment from call_rcu_bh() to call_rcu()

2019-03-26 Thread Paul E. McKenney
The RCU flavors have been consolidated, so this commit replaces a comment's mention of call_rcu_bh() with call_rcu(). Signed-off-by: Paul E. McKenney Cc: Pablo Neira Ayuso Cc: Florian Westphal Cc: "David S. Miller" Cc: Alexey Kuznetsov Cc: Hideaki YOSHIFUJI Cc: Cc: Cc: --- net/ipv4/netfi

linux-next: build failure after merge of the sound-asoc tree

2019-03-26 Thread Stephen Rothwell
Hi all, After merging the sound-asoc tree, today's linux-next build (x86_64 allmodconfig) failed like this: In file included from include/linux/printk.h:330, from include/linux/kernel.h:15, from include/linux/clk.h:16, from sound/soc/fsl/fsl_audm

Re: INFO: rcu detected stall in __perf_sw_event

2019-03-26 Thread syzbot
syzbot has bisected this bug to: commit cf85d89562f39cc7ae73de54639f1915a9195b7a Author: Finn Thain Date: Fri May 25 07:34:36 2018 + m68k/mac: Enable PDMA for PowerBook 500 series bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=1226cb8b20 start commit: b0314565 Mer

[PATCH tip/core/rcu 0/4] Documentation updates for v5.2

2019-03-26 Thread Paul E. McKenney
Hello! This series contains documentation updates: 1. Remove obsolete RCU update functions from RCU documentation. 2. Repair some whitespace damage, courtesy of Tycho Andersen. 3. Describe choice of rcu_dereference() APIs and __rcu usage. 4. Fix typos and otherwise moderniz

[PATCH tip/core/rcu 3/4] doc: Describe choice of rcu_dereference() APIs and __rcu usage

2019-03-26 Thread Paul E. McKenney
Reported-by: Andrew Morton Signed-off-by: Paul E. McKenney --- Documentation/RCU/rcu_dereference.txt | 103 ++ 1 file changed, 103 insertions(+) diff --git a/Documentation/RCU/rcu_dereference.txt b/Documentation/RCU/rcu_dereference.txt index ab96227bad42..bf699e8cfc75 1

[PATCH tip/core/rcu 2/4] doc: Repair some whitespace damage

2019-03-26 Thread Paul E. McKenney
From: Tycho Andersen A diagram in whatisRCU.txt has space character before tabs. This commit therefore makes this diagram consistent with elsewhere in the document: Use one leading tab, followed by spaces for any additional whitespace required. Signed-off-by: Tycho Andersen Signed-off-by: Paul

[PATCH tip/core/rcu 1/4] doc: Remove obsolete RCU update functions from RCU documentation

2019-03-26 Thread Paul E. McKenney
Now that synchronize_rcu_bh, synchronize_rcu_bh_expedited, call_rcu_bh, rcu_barrier_bh, synchronize_sched, synchronize_sched_expedited, call_rcu_sched, rcu_barrier_sched, get_state_synchronize_sched, and cond_synchronize_sched are obsolete, let's remove them from the documentation aside from a smal

[PATCH tip/core/rcu 4/4] doc: Fix typos and otherwise modernize checklist.txt

2019-03-26 Thread Paul E. McKenney
This commit fixes some issues with Documentation/RCU/checklist.txt. Signed-off-by: Paul E. McKenney --- Documentation/RCU/checklist.txt | 43 +++-- 1 file changed, 25 insertions(+), 18 deletions(-) diff --git a/Documentation/RCU/checklist.txt b/Documentation/RCU/chec

[PATCH] Yama: mark local symbols as static

2019-03-26 Thread Jann Horn
sparse complains that Yama defines functions and a variable as non-static even though they don't exist in any header. Fix it by making them static. Signed-off-by: Jann Horn --- security/yama/yama_lsm.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/security/yama/yama_l

[PATCH tip/core/rcu 16/18] rcu: Eliminate redundant NULL-pointer check

2019-03-26 Thread Paul E. McKenney
Because rcu_wake_cond() checks for a null task_struct pointer, there is no need for its callers to do so. This commit eliminates the redundant check. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree_plugin.h | 7 ++- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/kernel/rc

[PATCH tip/core/rcu 0/18] Miscellaneous fixes for v5.2

2019-03-26 Thread Paul E. McKenney
Hello! This series contains miscellaneous fixes. 1. Unconditionally expedite during suspend/hibernate (unless the real-time guys have disabled expediting altogether, that is). 2. Avoid unnecessary softirq when system is idle, courtesy of Joel Fernandes. 3. rcu_qs

[PATCH tip/core/rcu 07/18] MAINTAINERS: Add -rcu branch name ("dev")

2019-03-26 Thread Paul E. McKenney
Signed-off-by: Paul E. McKenney --- MAINTAINERS | 10 +- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index 1924b52937a6..a9b5270d006e 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -8983,7 +8983,7 @@ R:Daniel Lustig L: linux-kernel@

Re: [PATCH 09/14] bus: ti-sysc: Move rstctrl reset to happen later

2019-03-26 Thread Tony Lindgren
* Tony Lindgren [190325 22:00]: > We should not do the reset until the clocks are enabled. Let's only init > restctrl in sysc_init_resets() and do the reset later on in sysc_reset(). ... > static int sysc_reset(struct sysc *ddata) > { > int offset = ddata->offsets[SYSC_SYSCONFIG]; > -

[PATCH tip/core/rcu 05/18] rcu: Set rcutree.kthread_prio sysfs access to read-only

2019-03-26 Thread Paul E. McKenney
From: Liu Song The rcutree.kthread_prio kernel-boot parameter is used to set the priority for boost (rcub), per-CPU (rcuc), and grace-period (rcu_preempt or rcu_sched) kthreads. It is also used by rcutorture to check whether it is possible to meaningfully test RCU priority boosting. However, al

[PATCH tip/core/rcu 18/18] rcu: Correct READ_ONCE()/WRITE_ONCE() for ->rcu_read_unlock_special

2019-03-26 Thread Paul E. McKenney
The task_struct structure's ->rcu_read_unlock_special field is only ever read or written by the owning task, but it is accessed both at process and interrupt levels. It may therefore be accessed using plain reads and writes while interrupts are disabled, but must be accessed using READ_ONCE() and

[PATCH tip/core/rcu 13/18] rcu: Do a single rhp->func read in rcu_head_after_call_rcu()

2019-03-26 Thread Paul E. McKenney
From: Neeraj Upadhyay The rcu_head_after_call_rcu() function reads the rhp->func pointer twice, which can result in a false-positive WARN_ON_ONCE() if the callback were passed to call_rcu() between the two reads. Although racing rcu_head_after_call_rcu() with call_rcu() is to be a dubious use ca

[PATCH tip/core/rcu 11/18] rcu: Fix self-wakeups for grace-period kthread

2019-03-26 Thread Paul E. McKenney
From: Neeraj Upadhyay The current rcu_gp_kthread_wake() function uses in_interrupt() and thus does a self-wakeup from all interrupt contexts, including the pointless case where the GP kthread happens to be running with bottom halves disabled, along with the impossible case where the GP kthread is

[PATCH tip/core/rcu 04/18] rcu: Make exit_rcu() handle non-preempted RCU readers

2019-03-26 Thread Paul E. McKenney
The purpose of exit_rcu() is to handle cases where buggy code causes a task to exit within an RCU read-side critical section. It currently does that in the case where said RCU read-side critical section was preempted at least once, but fails to handle cases where preemption did not occur. This ca

[PATCH tip/core/rcu 12/18] rcu: Default jiffies_to_sched_qs to jiffies_till_sched_qs

2019-03-26 Thread Paul E. McKenney
From: Neeraj Upadhyay The current code only calls adjust_jiffies_till_sched_qs() if jiffies_till_sched_qs is left at its default value, so when the jiffies_till_sched_qs kernel-boot parameter actually is specified, jiffies_to_sched_qs will be left with the value zero, which will result in useless

[PATCH tip/core/rcu 03/18] rcu: rcu_qs -- Use raise_softirq_irqoff to not save irqs twice

2019-03-26 Thread Paul E. McKenney
From: Cyrill Gorcunov The rcu_qs is disabling IRQs by self so no need to do the same in raise_softirq but instead we can save some cycles using raise_softirq_irqoff directly. CC: Paul E. McKenney Signed-off-by: Cyrill Gorcunov Signed-off-by: Paul E. McKenney --- kernel/rcu/tiny.c | 2 +- 1 f

[PATCH tip/core/rcu 10/18] rcu: Report error for bad rcu_nocbs= parameter values

2019-03-26 Thread Paul E. McKenney
This commit prints a console message when cpulist_parse() reports a bad list of CPUs, and sets all CPUs' bits in that case. The reason for setting all CPUs' bits is that this is the safe(r) choice for real-time workloads, which would normally be the ones using the rcu_nocbs= kernel boot parameter.

[PATCH tip/core/rcu 15/18] rcu: Fix force_qs_rnp() header comment

2019-03-26 Thread Paul E. McKenney
From: Zhouyi Zhou Previously, threads blocked on offlining CPUS were migrated to the root rcu_node structure, thus requiring RCU priority boosting on this structure. However, since commit d19fb8d1f3f6 ("rcu: Don't migrate blocked tasks even if all corresponding CPUs offline"), RCU does not migra

[PATCH tip/core/rcu 14/18] rcu: Update jiffies_to_sched_qs and adjust_jiffies_till_sched_qs() comments

2019-03-26 Thread Paul E. McKenney
This commit better documents the jiffies_to_sched_qs default-value strategy used by adjust_jiffies_till_sched_qs() Reported-by: Joel Fernandes Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kernel/rcu/tree.c b/kernel/r

[PATCH tip/core/rcu 02/18] rcu: Avoid unnecessary softirq when system is idle

2019-03-26 Thread Paul E. McKenney
From: "Joel Fernandes (Google)" When there are no callbacks pending on an idle system, I noticed that RCU softirq is continuously firing. During this the cpu_no_qs is set to false, and core_needs_qs is set to true indefinitely. This causes rcu_process_callbacks to be repeatedly called, even thoug

[PATCH tip/core/rcu 06/18] MAINTAINERS: RCU now has its own email list

2019-03-26 Thread Paul E. McKenney
This commit makes r...@vger.kernel.org be the official list for RCU-related topics. Signed-off-by: Paul E. McKenney --- MAINTAINERS | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/MAINTAINERS b/MAINTAINERS index e17ebf70b548..1924b52937a6 100644 --- a/MAINTAINERS +++ b/

[PATCH tip/core/rcu 01/18] rcu: Unconditionally expedite during suspend/hibernate

2019-03-26 Thread Paul E. McKenney
The rcu_pm_notify() function refuses to switch to/from expedited grace periods on systems with more than 256 CPUs due to the serialized initialization of expedited grace periods. However, expedited grace periods are now initialized in parallel, removing this concern. This commit therefore removes

[PATCH tip/core/rcu 08/18] rcu: Move common code out of if-else block

2019-03-26 Thread Paul E. McKenney
From: Akira Yokosawa As the result of recent addition of "rdp->core_needs_qs = false;" in the "if" block, now both branches of the if-else have the same assignment. Factor it out and reduce line count. Signed-off-by: Akira Yokosawa Cc: Joel Fernandes Signed-off-by: Paul E. McKenney Acked-by:

[PATCH tip/core/rcu 0/2] SRCU updates for v5.2

2019-03-26 Thread Paul E. McKenney
Hello! This series contains SRCU updates: 1. Check for in-flight callbacks in _cleanup_srcu_struct(). 2. Remove cleanup_srcu_struct_quiesced(). Thanx, Paul

[PATCH tip/core/rcu 17/18] rcu: Fix typo in tree_exp.h comment

2019-03-26 Thread Paul E. McKenney
This commit changes a rcu_exp_handler() comment from rcu_preempt_defer_qs() to rcu_preempt_deferred_qs() in order to better match reality. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree_exp.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/rcu/tree_exp.h b/kernel/

[PATCH tip/core/rcu 09/18] rcu: Allow rcu_nocbs= to specify all CPUs

2019-03-26 Thread Paul E. McKenney
Currently, the rcu_nocbs= kernel boot parameter requires that a specific list of CPUs be specified, and has no way to say "all of them". As noted by user RavFX in a comment to Phoronix topic 1002538, this is an inconvenient side effect of the removal of the RCU_NOCB_CPU_ALL Kconfig option. This co

Re: [RFC 4/4] net/ipv4/fib: Don't synchronise_rcu() every 512Kb

2019-03-26 Thread Dmitry Safonov
On 3/26/19 3:39 PM, David Ahern wrote: > On 3/26/19 9:30 AM, Dmitry Safonov wrote: >> Fib trie has a hard-coded sync_pages limit to call synchronise_rcu(). >> The limit is 128 pages or 512Kb (considering common case with 4Kb >> pages). >> >> Unfortunately, at Arista we have use-scenarios with full

[PATCH tip/core/rcu 2/2] srcu: Remove cleanup_srcu_struct_quiesced()

2019-03-26 Thread Paul E. McKenney
The cleanup_srcu_struct_quiesced() function was added because NVME used WQ_MEM_RECLAIM workqueues and SRCU did not, which meant that NVME workqueues waiting on SRCU workqueues could result in deadlocks during low-memory conditions. However, SRCU now also has WQ_MEM_RECLAIM workqueues, so there is

Re: [PATCH 4.14 00/41] 4.14.109-stable review

2019-03-26 Thread shuah
On 3/26/19 12:29 AM, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 4.14.109 release. There are 41 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know. Responses should be mad

[PATCH tip/core/rcu 1/2] srcu: Check for in-flight callbacks in _cleanup_srcu_struct()

2019-03-26 Thread Paul E. McKenney
If someone fails to drain the corresponding SRCU callbacks (for example, by failing to invoke srcu_barrier()) before invoking either cleanup_srcu_struct() or cleanup_srcu_struct_quiesced(), the resulting diagnostic is an ambiguous use-after-free diagnostic, and even then only if you are running som

Re: [PATCH 4.19 00/45] 4.19.32-stable review

2019-03-26 Thread shuah
On 3/26/19 12:29 AM, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 4.19.32 release. There are 45 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know. Responses should be made

Re: [PATCH 4.9 00/30] 4.9.166-stable review

2019-03-26 Thread shuah
On 3/26/19 12:29 AM, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 4.9.166 release. There are 30 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know. Responses should be made

Re: [PATCH 5.0 00/52] 5.0.5-stable review

2019-03-26 Thread shuah
On 3/26/19 12:29 AM, Greg Kroah-Hartman wrote: This is the start of the stable review cycle for the 5.0.5 release. There are 52 patches in this series, all will be posted as a response to this one. If anyone has any issues with these being applied, please let me know. Responses should be made b

RE: [PATCH v19,RESEND 08/27] x86/cpu/intel: Detect SGX support and update caps appropriately

2019-03-26 Thread Huang, Kai
> On Tue, Mar 26, 2019 at 02:25:52PM -0700, Huang, Kai wrote: > > > > > > That being said, this in no way impacts KVM's ability to virtualize SGX, > > > e.g. > > > KVM can directly do CPUID and {RD,WR}MSR to probe the capabilities > > > of the platform as needed. > > > > I am not following. KVM ca

[PATCH tip/core/rcu 0/11] RCU CPU stall-warning changes for v5.2

2019-03-26 Thread Paul E. McKenney
Hello! This series is primarily code movement for RCU CPU stall warnings. If I am having a hard time finding the various scattered pieces of this code, it is in need of consolidation! 1-3.Move RCU CPU stall-warning code into kernel/rcu/tree_stall.h. 4. Inline RCU task stall-warning help

[PATCH tip/core/rcu 01/11] rcu: Move RCU CPU stall-warning code out of update.c

2019-03-26 Thread Paul E. McKenney
The RCU CPU stall-warning code for normal grace periods is currently scattered across three files, due to earlier Tiny RCU support for RCU CPU stall warnings and for old Kconfig options that have long since been retired. Given that it is hard for the lead RCU maintainer to find relevant stall-warn

[PATCH tip/core/rcu 07/11] rcu: Move FAST_NO_HZ stall-warning code to tree_stall.h

2019-03-26 Thread Paul E. McKenney
This commit further consolidates the stall-warning code by moving print_cpu_stall_info() and its helper functions along with zero_cpu_stall_ticks() to kernel/rcu/tree_stall.h. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.h| 1 - kernel/rcu/tree_plugin.h | 80 -

[PATCH tip/core/rcu 03/11] rcu: Move RCU CPU stall-warning code out of tree.c

2019-03-26 Thread Paul E. McKenney
This commit completes the process of consolidating the code for RCU CPU stall warnings for normal grace periods by moving the remaining such code from kernel/rcu/tree.c to kernel/rcu/tree_stall.h. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree.c | 291 -

[PATCH tip/core/rcu 05/11] rcu: Move rcu_print_task_exp_stall() to tree_exp.h

2019-03-26 Thread Paul E. McKenney
Because expedited CPU stall warnings are contained within the kernel/rcu/tree_exp.h file, rcu_print_task_exp_stall() should live there too. This commit carries out the required code motion. Signed-off-by: Paul E. McKenney --- kernel/rcu/tree_exp.h| 32 kerne

Re: [PATCH 09/14] bus: ti-sysc: Move rstctrl reset to happen later

2019-03-26 Thread Suman Anna
Hi Tony, On 3/26/19 6:13 PM, Tony Lindgren wrote: > * Tony Lindgren [190325 22:00]: >> We should not do the reset until the clocks are enabled. Let's only init >> restctrl in sysc_init_resets() and do the reset later on in sysc_reset(). > ... > >> static int sysc_reset(struct sysc *ddata) >> {

[PATCH tip/core/rcu 02/11] rcu: Move RCU CPU stall-warning code out of tree_plugin.h

2019-03-26 Thread Paul E. McKenney
The RCU CPU stall-warning code for normal grace periods is currently scattered across two files, due to earlier Tiny RCU support for RCU CPU stall warnings and for old Kconfig options that have long since been retired. Given that it is hard for the lead RCU maintainer to find relevant stall-warnin

[PATCH tip/core/rcu 10/11] rcu: Move forward-progress checkers into tree_stall.h

2019-03-26 Thread Paul E. McKenney
This commit further consolidates stall-warning functionality by moving forward-progress checkers into kernel/rcu/tree_stall.h, updating a comment or two while in the area. More specifically, this commit moves show_rcu_gp_kthreads(), rcu_check_gp_start_stall(), rcu_fwd_progress_check(), sysrq_rcu,

[PATCH tip/core/rcu 11/11] rcu: Fix nohz status in stall warning

2019-03-26 Thread Paul E. McKenney
From: Neeraj Upadhyay The Documentation/RCU/stallwarn.txt file says that stall warnings print "D" if dyntick-idle processing is enabled, but the code in print_cpu_stall_fast_no_hz() prints "." instead. This commit therefore reverses the sense of the test to make the code match the documentation.

[PATCH tip/core/rcu 08/11] rcu: Organize functions in tree_stall.h

2019-03-26 Thread Paul E. McKenney
This commit does only code movement, removal of now-unneeded forward declarations, and addition of comments. It organizes the functions that implement RCU CPU stall warnings for normal grace periods into three categories: 1. Control of RCU CPU stall warnings, including computing timeouts. 2

[PATCH tip/core/rcu 06/11] rcu: Inline RCU stall-warning info helper functions

2019-03-26 Thread Paul E. McKenney
The print_cpu_stall_info_begin() and print_cpu_stall_info_end() print a single character each onto the console, and are a holdover from a time when RCU CPU stall warning messages could be abbreviated using a long-gone Kconfig option. This commit therefore adds these single characters to already-pr

[PATCH tip/core/rcu 09/11] rcu: Move irq-disabled stall-warning checking to tree_stall.h

2019-03-26 Thread Paul E. McKenney
The rcu_iw_handler() function's sole purpose in life is to indicate whether a stalled CPU had interrupts disabled, so it belongs in kernel/rcu/tree_stall.h. This commit therefore makes that move, clarifying its header comment while in the area. Signed-off-by: Paul E. McKenney --- kernel/rcu/tre

[PATCH tip/core/rcu 04/11] rcu: Inline RCU task stall-warning helper functions

2019-03-26 Thread Paul E. McKenney
The rcu_print_detail_task_stall(), rcu_print_task_stall_begin(), and rcu_print_task_stall_end() functions were defined to allow long-gone Kconfig options to provide an abbreviated RCU CPU stall warning printout. This commit saves a few lines of code by inlining them into their sole callers. While

Re: INFO: rcu detected stall in __perf_sw_event

2019-03-26 Thread Finn Thain
On Tue, 26 Mar 2019, syzbot wrote: > syzbot has bisected this bug to: > > commit cf85d89562f39cc7ae73de54639f1915a9195b7a > Author: Finn Thain > Date: Fri May 25 07:34:36 2018 + > >m68k/mac: Enable PDMA for PowerBook 500 series > Looks like a false positive. But if you really are ru

[PATCH tip/core/rcu 4/9] rcutorture: Remove ->ext_irq_conflict field

2019-03-26 Thread Paul E. McKenney
Back when there was a separate RCU-bh flavor, the ->ext_irq_conflict field was used to prevent executing local_bh_enable() while interrupts were disabled. However, there is no longer an RCU-bh flavor, so this commit removes the no-longer-needed ->ext_irq_conflict field. Signed-off-by: Paul E. McK

[PATCH tip/core/rcu 7/9] rcuperf: Fix cleanup path for invalid perf_type strings

2019-03-26 Thread Paul E. McKenney
If the specified rcuperf.perf_type is not in the rcu_perf_init() function's perf_ops[] array, rcuperf prints some console messages and then invokes rcu_perf_cleanup() to set state so that a future torture test can run. However, rcu_perf_cleanup() also attempts to end the test that didn't actually

RE: [RFC PATCH Xilinx Alveo 0/6] Xilinx PCIe accelerator driver

2019-03-26 Thread Sonal Santan
> -Original Message- > From: Daniel Vetter [mailto:daniel.vet...@ffwll.ch] On Behalf Of Daniel Vetter > Sent: Monday, March 25, 2019 1:28 PM > To: Sonal Santan > Cc: dri-de...@lists.freedesktop.org; gre...@linuxfoundation.org; Cyril > Chemparathy ; linux-kernel@vger.kernel.org; Lizhi Ho

[PATCH tip/core/rcu 2/9] tools/.../rcutorture: Convert to SPDX license identifier

2019-03-26 Thread Paul E. McKenney
Replace the license boiler plate with a SPDX license identifier. While in the area, update an email address and add copyright notices. Signed-off-by: Paul E. McKenney --- .../selftests/rcutorture/bin/configNR_CPUS.sh | 17 ++--- .../rcutorture/bin/config_override.sh | 17 ++

[PATCH tip/core/rcu 5/9] rcutorture: Fix expected forward progress duration in OOM notifier

2019-03-26 Thread Paul E. McKenney
From: Neeraj Upadhyay The rcutorture_oom_notify() function has a misplaced close parenthesis that results in increasingly long delays in rcu_fwd_progress_check()'s checking for various RCU forward-progress problems. This commit therefore puts the parenthesis in the right place. Signed-off-by: N

[PATCH tip/core/rcu 0/9] Torture-test updates for v5.2

2019-03-26 Thread Paul E. McKenney
Hello! This series contains torture-test updates: 1. Don't try to offline the last CPU. 2. Convert rcutorture scripting to SPDX license identifier. 3. Make rcutorture_extend_mask() comment match the code. 4. Remove ->ext_irq_conflict field. 5. Fix expected forward pro

[PATCH tip/core/rcu 8/9] locktorture: NULL cxt.lwsa and cxt.lrsa to allow bad-arg detection

2019-03-26 Thread Paul E. McKenney
Currently, lock_torture_cleanup() uses the values of cxt.lwsa and cxt.lrsa to detect bad parameters that prevented locktorture from initializing, let alone running. In this case, lock_torture_cleanup() does no cleanup aside from invoking torture_cleanup_begin() and torture_cleanup_end(), as requir

[PATCH tip/core/rcu 9/9] torture: Suppress false-positive CONFIG_INITRAMFS_SOURCE complaint

2019-03-26 Thread Paul E. McKenney
The scripting must supply the CONFIG_INITRAMFS_SOURCE Kconfig option so that kbuild can find the desired initrd, but the configcheck.sh script gets confused by this option because it takes a string instead of the expected y/n/m. This causes checkconfig.sh to complain about CONFIG_INITRAMFS_SOURCE

[PATCH tip/core/rcu 6/9] rcutorture: Fix cleanup path for invalid torture_type strings

2019-03-26 Thread Paul E. McKenney
If the specified rcutorture.torture_type is not in the rcu_torture_init() function's torture_ops[] array, rcutorture prints some console messages and then invokes rcu_torture_cleanup() to set state so that a future torture test can run. However, rcu_torture_cleanup() also attempts to end the test

[PATCH tip/core/rcu 1/9] torture: Don't try to offline the last CPU

2019-03-26 Thread Paul E. McKenney
If there is only one online CPU, it doesn't make sense to try to offline it, as any such attempt is guaranteed to fail. This commit therefore check for this condition and refuses to attempt the nonsensical. Reported-by: Su Yue Signed-off-by: Paul E. McKenney Tested-By: Su Yue --- kernel/tortu

[PATCH tip/core/rcu 3/9] rcutorture: Make rcutorture_extend_mask() comment match the code

2019-03-26 Thread Paul E. McKenney
The code actually rarely uses more than one type of RCU read-side protection, as is actually desired given that we need some reasonable probability of preempting RCU read-side critical sections, which cannot happen with multiple types of protection. This comment therefore adjusts the comment. Sig

[PATCH 3/3] fuse: Add FOPEN_STREAM and use stream_open() if filesystem returned that from open handler

2019-03-26 Thread Kirill Smelkov
Starting from 9c225f2655 (vfs: atomic f_pos accesses as per POSIX) files opened even via nonseekable_open gate read and write via lock and do not allow them to be run simultaneously. This can create read vs write deadlock if a filesystem is trying to implement a socket-like file which is intended t

Re: [PATCH 09/14] bus: ti-sysc: Move rstctrl reset to happen later

2019-03-26 Thread Tony Lindgren
Hi, * Suman Anna [190326 23:22]: > On 3/26/19 6:13 PM, Tony Lindgren wrote: > Hmm, are you envisioning the SYSC reset (OCP SoftReset) here or the PRCM > RSTCTRL hardresets here? The latter in general requires the clocks to be > running first (module won't be in ready status until you deassert the

[PATCH RFC memory-model 0/21] LKMM updates for review

2019-03-26 Thread Paul E. McKenney
Hello! This series contains LKMM updates: 1. Make scripts be executable. 2. Fix comment in MP+poonceonces.litmus, courtesy of Andrea Parri. 3. Do not use "herd" to refer to "herd7", courtesy of Andrea Parri. 4. Rewrite "KERNEL I/O BARRIER EFFECTS" section of memory-barriers

[PATCH tip/core/rcu 01/21] tools/memory-model: Make scripts be executable

2019-03-26 Thread Paul E. McKenney
This commit simplifies life a bit by making all of the scripts in tools/memory-model/scripts be executable. Signed-off-by: Paul E. McKenney --- tools/memory-model/scripts/checkghlitmus.sh | 0 tools/memory-model/scripts/checklitmushist.sh | 0 tools/memory-model/scripts/cmplitmushist.sh | 0

[PATCH tip/core/rcu 17/21] tools/memory-model: Make runlitmus.sh generate .litmus.out for --hw

2019-03-26 Thread Paul E. McKenney
In the absence of "Result:" comments, the runlitmus.sh script relies on litmus.out files from prior LKMM runs. This can be a bit user-hostile, so this commit makes runlitmus.sh generate any needed .litmus.out files that don't already exist. Signed-off-by: Paul E. McKenney --- tools/memory-model

[PATCH tip/core/rcu 03/21] tools/memory-model: Do not use "herd" to refer to "herd7"

2019-03-26 Thread Paul E. McKenney
From: Andrea Parri Use "herd7" in each such reference. Signed-off-by: Andrea Parri Cc: Alan Stern Cc: Will Deacon Cc: Peter Zijlstra Cc: Boqun Feng Cc: Nicholas Piggin Cc: David Howells Cc: Jade Alglave Cc: Luc Maranget Cc: "Paul E. McKenney" Cc: Akira Yokosawa Cc: Daniel Lustig Sign

[PATCH tip/core/rcu 10/21] tools/memory-model: Update parseargs.sh for hardware verification

2019-03-26 Thread Paul E. McKenney
This commit adds a --hw argument to parseargs.sh to specify the CPU family for a hardware verification. For example, "--hw AArch64" will specify that a C-language litmus test is to be translated to ARMv8 and the result verified. This will set the LKMM_HW_MAP_FILE environment variable accordingly.

[PATCH tip/core/rcu 14/21] tools/memory-model: Hardware checking for check{,all}litmus.sh

2019-03-26 Thread Paul E. McKenney
This commit makes checklitmus.sh and checkalllitmus.sh check to see if a hardware verification was specified (via the --hw command-line argument, which sets the LKMM_HW_MAP_FILE environment variable). If so, the C-language litmus test is converted to the specified type of assembly-language litmus t

[PATCH tip/core/rcu 06/21] tools/memory-model: Make cmplitmushist.sh note timeouts

2019-03-26 Thread Paul E. McKenney
Currently, cmplitmushist.sh treats timeouts (as in the "--timeout" argument) as "Missing Observation line". This can be misleading because it is quite possible that running the test longer would have produced a verification. This commit therefore changes cmplitmushist.sh to check for timeouts and

[PATCH tip/core/rcu 08/21] tools/memory-model: Add support for synchronize_srcu_expedited()

2019-03-26 Thread Paul E. McKenney
Given that synchronize_rcu_expedited() is supported, this commit adds support for synchronize_srcu_expedited(). Signed-off-by: Paul E. McKenney --- tools/memory-model/linux-kernel.def | 1 + 1 file changed, 1 insertion(+) diff --git a/tools/memory-model/linux-kernel.def b/tools/memory-model/li

[PATCH tip/core/rcu 15/21] tools/memory-model: Make judgelitmus.sh ransack .litmus.out files

2019-03-26 Thread Paul E. McKenney
The judgelitmus.sh script currently relies solely on the "Result:" comment in the .litmus file. This is problematic when using the --hw argument, because it is necessary to check the hardware model against LKMM even in the absence of "Result:" comments. This commit therefore modifies judgelitmus.

[PATCH tip/core/rcu 04/21] docs/memory-barriers.txt: Rewrite "KERNEL I/O BARRIER EFFECTS" section

2019-03-26 Thread Paul E. McKenney
From: Will Deacon The "KERNEL I/O BARRIER EFFECTS" section of memory-barriers.txt is vague, x86-centric, out-of-date, incomplete and demonstrably incorrect in places. This is largely because I/O ordering is a horrible can of worms, but also because the document has stagnated as our understanding

[PATCH tip/core/rcu 16/21] tools/memory-model: Split runlitmus.sh out of checklitmus.sh

2019-03-26 Thread Paul E. McKenney
This commit prepares for adding --hw capability to github litmus-test scripts by splitting runlitmus.sh (which simply runs the verification) out of checklitmus.sh (which also judges the results). Signed-off-by: Paul E. McKenney --- tools/memory-model/scripts/checklitmus.sh | 57 ++---

[PATCH tip/core/rcu 20/21] tools/memory-model: Allow herd to deduce CPU type

2019-03-26 Thread Paul E. McKenney
Currently, the scripts specify the CPU's .cat file to herd. But this is pointless because herd will select a good and sufficient .cat file from the assembly-language litmus test itself. This commit therefore removes the -model argument to herd, allowing herd to figure the CPU family out itself.

[PATCH tip/core/rcu 09/21] tools/memory-model: Make judgelitmus.sh detect hard deadlocks

2019-03-26 Thread Paul E. McKenney
If a litmus test specifies "Result: Never" and if it contains an unconditional ("hard") deadlock, then running checklitmus.sh on it will not flag any errors, despite the fact that there are no executions. This commit therefore updates judgelitmus.sh to complain about tests with no executions that a

[PATCH tip/core/rcu 18/21] tools/memory-model: Move from .AArch64.litmus.out to .litmus.AArch.out

2019-03-26 Thread Paul E. McKenney
When the github scripts see ".litmus.out", they assume that there must be a corresponding C-language ".litmus" file. Won't they be disappointed when they instead see nothing, or, worse yet, the corresponding assembly-language litmus test? This commit therefore swaps the hardware tag with the "lit

[PATCH tip/core/rcu 07/21] tools/memory-model: Make judgelitmus.sh identify bad macros

2019-03-26 Thread Paul E. McKenney
Currently, judgelitmus.sh treats use of unknown primitives (such as srcu_read_lock() prior to SRCU support) as "!!! Verification error". This can be misleading because it fails to call out typos and running a version LKMM on a litmus test requiring a feature not provided by that version. This comm

[PATCH tip/core/rcu 02/21] tools/memory-model: Fix comment in MP+poonceonces.litmus

2019-03-26 Thread Paul E. McKenney
From: Andrea Parri The comment should say "Sometimes" for the result. Signed-off-by: Andrea Parri Cc: Alan Stern Cc: Will Deacon Cc: Peter Zijlstra Cc: Boqun Feng Cc: Nicholas Piggin Cc: David Howells Cc: Jade Alglave Cc: Luc Maranget Cc: "Paul E. McKenney" Cc: Akira Yokosawa Cc: Dani

[PATCH tip/core/rcu 05/21] tools/memory-model: Make judgelitmus.sh note timeouts

2019-03-26 Thread Paul E. McKenney
Currently, judgelitmus.sh treats timeouts (as in the "--timeout" argument) as "!!! Verification error". This can be misleading because it is quite possible that running the test longer would have produced a verification. This commit therefore changes judgelitmus.sh to check for timeouts and to rep

[PATCH tip/core/rcu 12/21] tools/memory-model: Add simpletest.sh to check locking, RCU, and SRCU

2019-03-26 Thread Paul E. McKenney
This commit abstracts out common function to check a given litmus test for locking, RCU, and SRCU in order to avoid duplicating code. Signed-off-by: Paul E. McKenney --- tools/memory-model/scripts/simpletest.sh | 35 1 file changed, 35 insertions(+) create mode 100755 t

<    3   4   5   6   7   8   9   10   >