-off-by: Joel Fernandes (Google)
---
drivers/gpu/drm/i915/i915_request.c | 4 ++--
include/linux/irq_work.h| 33 ++---
include/linux/irqflags.h| 4 ++--
kernel/bpf/stackmap.c | 2 +-
kernel/irq_work.c | 18
From: Peter Zijlstra
Introduce the basic infrastructure to have a core wide rq->lock.
Tested-by: Julien Desfossez
Signed-off-by: Peter Zijlstra (Intel)
Signed-off-by: Julien Desfossez
Signed-off-by: Vineeth Remanan Pillai
Signed-off-by: Joel Fernandes (Google)
---
kernel/Kconfig.pree
APIs and support.
Reviewed-by: Josh Don
Tested-by: Julien Desfossez
Signed-off-by: Joel Fernandes (Google)
---
include/linux/sched.h | 2 +
kernel/sched/core.c | 241 --
kernel/sched/debug.c | 4 +
3 files changed, 236 insertions(+), 11 deletions
From: Vineeth Pillai
Similar to how user to kernel mode transitions are protected in earlier
patches, protect the entry into kernel from guest mode as well.
Tested-by: Julien Desfossez
Reviewed-by: Joel Fernandes (Google)
Reviewed-by: Alexandre Chartre
Signed-off-by: Vineeth Pillai
Signed
of existing core cookies so that multiple
tasks may share the same core_cookie.
This will be especially useful in the next patch, where the concept of
cookie color is introduced.
Reviewed-by: Joel Fernandes (Google)
Signed-off-by: Josh Don
Signed-off-by: Joel Fernandes (Google)
---
kernel
Add a per-thread core scheduling interface which allows a thread to share a
core with another thread, or have a core exclusively for itself.
ChromeOS uses core-scheduling to securely enable hyperthreading. This cuts
down the keypress latency in Google docs from 150ms to 50ms while improving
-by: Tim Chen
Signed-off-by: Vineeth Remanan Pillai
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/fair.c | 64
kernel/sched/sched.h | 29
2 files changed, 88 insertions(+), 5 deletions(-)
diff --git a/kernel/sched/fair.c b
From: Peter Zijlstra
Tested-by: Julien Desfossez
Signed-off-by: Peter Zijlstra (Intel)
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/fair.c | 11 +--
1 file changed, 9 insertions(+), 2 deletions(-)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 51483a00a755
This will be used by kselftest to verify the CGroup cookie value that is
set by the CGroup interface.
Reviewed-by: Josh Don
Tested-by: Julien Desfossez
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 31 +++
1 file changed, 31 insertions(+)
diff
From: Peter Zijlstra
Instead of only selecting a local task, select a task for all SMT
siblings for every reschedule on the core (irrespective which logical
CPU does the reschedule).
Tested-by: Julien Desfossez
Reviewed-by: Joel Fernandes (Google)
Signed-off-by: Peter Zijlstra (Intel)
Signed
-by: Vineeth Pillai
Signed-off-by: Vineeth Pillai
Signed-off-by: Joel Fernandes (Google)
---
.../admin-guide/kernel-parameters.txt | 11 +
include/linux/entry-common.h | 12 +-
include/linux/sched.h | 12 +
kernel/entry/common.c
Fernandes (Google)
---
include/linux/sched.h | 3 +++
kernel/fork.c | 1 +
kernel/sched/core.c | 8
3 files changed, 12 insertions(+)
diff --git a/include/linux/sched.h b/include/linux/sched.h
index 79d76c78cc8e..6fbdb1a204bf 100644
--- a/include/linux/sched.h
+++ b/include/linux
in case anyone reports an issue with it. Testing
shows it to be working for me.
Reviewed-by: Vineeth Pillai
Suggested-by: Peter Zijlstra (Intel)
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 73 -
1 file changed, 26 insertions
From: Josh Don
Google has a usecase where the first level tag to tag a CGroup is not
sufficient. So, a patch is carried for years where a second tag is added which
is writeable by unprivileged users.
Google uses DAC controls to make the 'tag' possible to set only by root while
the second-level
Add a kselftest test to ensure that the core-sched interface is working
correctly.
Tested-by: Julien Desfossez
Reviewed-by: Josh Don
Signed-off-by: Joel Fernandes (Google)
---
tools/testing/selftests/sched/.gitignore | 1 +
tools/testing/selftests/sched/Makefile| 14 +
tools
ime.
Suggested-by: Vineeth Remanan Pillai
Signed-off-by: Peter Zijlstra
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/fair.c | 11 +++
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/kernel/sched/fair.c b/kernel/sched/fair.c
index 12cf068eeec8..51483a00a755 100
Desfossez
Signed-off-by: Peter Zijlstra (Intel)
Signed-off-by: Joel Fernandes (Google)
---
include/linux/sched.h | 1 +
kernel/sched/core.c | 130 +-
kernel/sched/idle.c | 1 +
kernel/sched/sched.h | 6 ++
4 files changed, 137 insertions(+), 1
-by: Julien Desfossez
Reviewed-by: Chris Hyser
Signed-off-by: Chris Hyser
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/Makefile | 1 +
kernel/sched/core.c| 809 +---
kernel/sched/coretag.c | 819 +
kernel
Document the usecases, design and interfaces for core scheduling.
Co-developed-by: Vineeth Pillai
Signed-off-by: Vineeth Pillai
Tested-by: Julien Desfossez
Reviewed-by: Randy Dunlap
Signed-off-by: Joel Fernandes (Google)
---
.../admin-guide/hw-vuln/core-scheduling.rst | 330
Tested-by: Julien Desfossez
Not-Signed-off-by: Peter Zijlstra (Intel)
---
kernel/sched/core.c | 35 ++-
kernel/sched/fair.c | 9 +
2 files changed, 43 insertions(+), 1 deletion(-)
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index
Fernandes (Google)
---
.../admin-guide/kernel-parameters.txt | 14 ++
arch/x86/kernel/cpu/bugs.c| 19
include/linux/cpu.h | 1 +
include/linux/sched/smt.h | 4 ++
kernel/cpu.c
Pillai
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 183 +--
kernel/sched/sched.h | 4 +
2 files changed, 181 insertions(+), 6 deletions(-)
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 7f807a84cc30..b99a7493d590
.
Reviewed-by: Vineeth Pillai
Suggested-by: Peter Zijlstra (Intel)
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 61 +
kernel/sched/fair.c | 80
kernel/sched/sched.h | 7 +++-
3 files changed, 97
to schedule.
Tested-by: Julien Desfossez
Reviewed-by: Joel Fernandes (Google)
Signed-off-by: Vineeth Pillai
Signed-off-by: Julien Desfossez
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 15 ---
kernel/sched/fair.c | 40
Add a generic_idle_{enter,exit} helper function to enter and exit kernel
protection when entering and exiting idle, respectively.
While at it, remove a stale RCU comment.
Reviewed-by: Alexandre Chartre
Tested-by: Julien Desfossez
Signed-off-by: Joel Fernandes (Google)
---
include/linux/entry
-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 33 -
kernel/sched/fair.c | 40
kernel/sched/sched.h | 5 +
3 files changed, 65 insertions(+), 13 deletions(-)
diff --git a/kernel/sched/core.c b/kernel/sched
After rcu_do_batch(), add a check for whether the seglen counts went to
zero if the list was indeed empty.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/rcu_segcblist.c | 12
kernel/rcu/rcu_segcblist.h | 3 +++
kernel/rcu/tree.c | 1 +
3 files changed, 16
After rcu_do_batch(), add a check for whether the seglen counts went to
zero if the list was indeed empty.
Signed-off-by: Joel Fernandes (Google)
---
v1->v2: Added more debug checks.
kernel/rcu/rcu_segcblist.c | 12
kernel/rcu/rcu_segcblist.h | 3 +++
kernel/rcu/tre
by mm_struct.
o Keep overhead low by checking if tracing is enabled.
o Add some noise reduction and lower overhead by emitting only on
threshold changes.
Co-developed-by: Tim Murray
Signed-off-by: Tim Murray
Signed-off-by: Joel Fernandes (Google)
---
Cc: carmenjack...@google.com
Cc: mayankgu
Fernandes (Google)
---
v1->v2: Added more commit message.
Cc: carmenjack...@google.com
Cc: mayankgu...@google.com
Cc: dan...@google.com
Cc: rost...@goodmis.org
Cc: minc...@kernel.org
Cc: a...@linux-foundation.org
Cc: kernel-t...@android.com
include/linux/mm.h |
do cheaper
comparisons with zero instead for the code that keeps the tick on in
rcu_nmi_enter_common().
In the next patch, both of the concerns of (2) will be addressed and
then we can get rid of dynticks_nmi_nesting, however one step at a time.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/r
ail.com
Cc: byungchul.p...@lge.com
Cc: kernel-t...@android.com
Cc: kernel-t...@lge.com
Co-developed-by: Byungchul Park
Signed-off-by: Byungchul Park
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 198 --
1 file changed, 193 insert
Fernandes (Google)
---
kernel/rcu/rcuperf.c | 169 ++-
1 file changed, 168 insertions(+), 1 deletion(-)
diff --git a/kernel/rcu/rcuperf.c b/kernel/rcu/rcuperf.c
index 7a6890b23c5f..34658760da5e 100644
--- a/kernel/rcu/rcuperf.c
+++ b/kernel/rcu/rcuperf.c
bpf file to /sys/kernel/debug/tracing/events/X/Y/bpf
The following commands can be written into it:
attach: Attaches BPF prog fd to tracepoint
detach: Detaches BPF prog fd to tracepoint
Reading the bpf file will show all the attached programs to the tracepoint.
Joel Fernandes (Google) (4
Add a new bpf file to each trace event. The following commands can be
written into it:
attach: Attaches BPF prog fd to tracepoint
detach: Detaches BPF prog fd to tracepoint
Reading the bpf file will show all the attached programs to the
tracepoint.
Signed-off-by: Joel Fernandes (Google
Here we add support for testing the attach and detach of a BPF program
to a tracepoint through tracefs.
Signed-off-by: Joel Fernandes (Google)
---
.../raw_tp_writable_test_ftrace_run.c | 89 +++
1 file changed, 89 insertions(+)
create mode 100644
tools/testing
In preparation to use raw tracepoints for BPF directly from ftrace, move
the bpf_raw_tracepoint functionality into bpf_trace.c
Signed-off-by: Joel Fernandes (Google)
---
include/linux/bpf_trace.h | 10 ++
kernel/bpf/syscall.c| 69 ++---
kernel/trace
Add the needed library support in this commit.
Signed-off-by: Joel Fernandes (Google)
---
tools/lib/bpf/bpf.c | 53
tools/lib/bpf/bpf.h | 4 +++
tools/lib/bpf/libbpf.map | 2 ++
3 files changed, 59 insertions(+)
diff --git a/tools/lib/bpf
This commit fixes the issue.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 29 +
1 file changed, 17 insertions(+), 12 deletions(-)
diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
index 0512de9ead20..322b1b57967c 100644
--- a/kernel/rcu/tree.c
Sometimes I see rcu_urgent_qs is not set. This could be when the last
IPI was a long time ago, however, the grace period just started. Set
rcu_urgent_qs so the tick can indeed be stopped.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 1 +
1 file changed, 1 insertion(+)
diff
I really cannot explain this patch, but without it, the "else if" block
just doesn't execute thus causing the tick's dep mask to not be set and
causes the tick to be turned off.
I tried various _ONCE() macros but the only thing that works is this
patch.
Signed-off-by: Joel Fernand
Sometimes I see rcu_urgent_qs is not set. This could be when the last
IPI was a long time ago, however, the grace period just started. Set
rcu_urgent_qs so the tick can indeed not be stopped.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 1 +
1 file changed, 1 insertion
xchg() on a bool is causing issues on riscv and arm32. Please squash
this into the -rcu dev branch to resolve the issue.
Please squash this fix.
Fixes: -rcu dev commit 3cbd3aa7d9c7bdf ("rcu/tree: Add basic support for
kfree_rcu() batching")
Signed-off-by: Joel Fernandes (Google)
-
the "else" block
will run to do the irq_work stuff.
This commit is based on a partial revert of d143b3d1cd89 ("rcu: Simplify
rcu_read_unlock_special() deferred wakeups") with an additional in_irq()
check added.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree_plug
lse), then the "else" block
will run to do the irq_work stuff.
This commit is based on a partial revert of d143b3d1cd89 ("rcu: Simplify
rcu_read_unlock_special() deferred wakeups") with an additional in_irq()
check added.
Signed-off-by: Joel Fernandes (Google)
---
v1-&
Fernandes (Google)
---
arch/x86/pci/mmconfig-shared.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/arch/x86/pci/mmconfig-shared.c b/arch/x86/pci/mmconfig-shared.c
index 7389db538c30..6fa42e9c4e6f 100644
--- a/arch/x86/pci/mmconfig-shared.c
+++ b/arch/x86/pci/mmconfig
need to pass the
optional fourth argument (cond) unless they are under some non-RCU
protection and needs to make lockdep check pass.
Signed-off-by: Joel Fernandes (Google)
---
include/linux/rculist.h | 40
include/linux/rcupdate.h | 7 +++
kernel/rcu
list_for_each_entry_rcu has built-in RCU and lock checking. Make use of
it for acpi_ioremaps list traversal.
Signed-off-by: Joel Fernandes (Google)
---
drivers/acpi/osl.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/acpi/osl.c b/drivers/acpi/osl.c
index
list_for_each_entry_rcu now has support to check for RCU reader sections
as well as lock. Just use the support in it, instead of explictly
checking in the caller.
Signed-off-by: Joel Fernandes (Google)
---
kernel/workqueue.c | 5 ++---
1 file changed, 2 insertions(+), 3 deletions(-)
diff --git
Signed-off-by: Joel Fernandes (Google)
---
net/ipv4/fib_frontend.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/net/ipv4/fib_frontend.c b/net/ipv4/fib_frontend.c
index b298255f6fdb..ef7c9f8e8682 100644
--- a/net/ipv4/fib_frontend.c
+++ b/net/ipv4/fib_frontend.c
@@ -127,7
list_for_each_entry_rcu has built-in RCU and lock checking. Make use of
it in driver core.
Signed-off-by: Joel Fernandes (Google)
---
drivers/base/base.h | 1 +
drivers/base/core.c | 10 ++
drivers/base/power/runtime.c | 15 ++-
3 files changed, 21
e code has a
assert_rcu_or_wq_mutex() function which is called in for_each_wq(). This
series replaces that in favor of the built-in one.
Also in the future, we can extend these checks to list_entry_rcu() and other
list macros as well.
Joel Fernandes (Google) (6):
rcu: Add support for consolidated-RCU reader checking
, address
space changes can occur between reading the pagemap and reading the
bitmap. In virtual address indexing, the process's mmap_sem is held for
the duration of the access.
Cc: vdavydov@gmail.com
Cc: Brendan Gregg
Cc: kernel-t...@android.com
Signed-off-by: Joel Fernandes (Google
add a warning to catch it in the
future.
[1] https://lore.kernel.org/lkml/20190717172100.261204-1-j...@joelfernandes.org/
Signed-off-by: Joel Fernandes (Google)
---
kernel/signal.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/kernel/signal.c b/kernel/signal.c
index 91b789dd6e72
t;len field
should be the length of the done segment and not just used as a temporarily
variable.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/rcu_segcblist.c | 8 ++--
1 file changed, 6 insertions(+), 2 deletions(-)
diff --git a/kernel/rcu/rcu_segcblist.c b/kernel/rcu/rcu_segcblist.c
in the respective segment.
Signed-off-by: Joel Fernandes (Google)
---
include/trace/events/rcu.h | 25 +
kernel/rcu/rcu_segcblist.c | 27 +++
kernel/rcu/rcu_segcblist.h | 7 +++
kernel/rcu/tree.c | 23 +++
4 files changed, 82
n from 0 is confusing and error-prone IMHO.
This commit therefore explicitly counts have many callbacks were executed in
rcu_do_batch() itself, and uses that to update the per-CPU segcb list's len
field, without relying on the negativity of rcl->len.
Signed-off-by: Joel Fernandes (Google)
--
traces when segcblist counts updated.
Signed-off-by: Joel Fernandes (Google)
---
include/linux/rcu_segcblist.h | 2 +
kernel/rcu/rcu_segcblist.c| 82 +--
2 files changed, 81 insertions(+), 3 deletions(-)
diff --git a/include/linux/rcu_segcblist.h b/include
rnel.org/lkml/20200719034210.2382053-1-j...@joelfernandes.org/)
Joel Fernandes (Google) (4):
rcu/segcblist: Do not depend on rcl->len to store the segcb len during
merge
rcu/tree: Make rcu_do_batch count how many callbacks were executed
rcu/segcblist: Add counters to segcblist datastructure
rcu/tr
l E. McKenney
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 9 -
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
index 65e1b5e92319..a49fa3b60faa 100644
--- a/kernel/rcu/tree.c
+++ b/kernel/rcu/tree.c
@@ -3996,7 +3996
This series improves/adds to RCU's warnings about CPU hotplug and adds
documentation and testing.
v3->v4: Minor cleanups.
Joel Fernandes (Google) (5):
rcu/tree: Add a warning if CPU being onlined did not report QS already
rcu/tree: Clarify comments about FQS loop reporting quiescent states
is rather incomplete.
This commit therefore continues the section by describing how RCU's
design handles CPU hotplug in a deadlock-free way.
Signed-off-by: Joel Fernandes (Google)
---
.../RCU/Design/Requirements/Requirements.rst | 22 +++
1 file changed, 22 insertions(+)
At least since v4.19, the FQS loop no longer reports quiescent states
for offline CPUs unless it is an emergency.
This commit therefore fixes the comment in rcu_gp_init() to match the
current code.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 8 +---
1 file changed, 5
FQS loop scan happens and bring the problem to
everyone's attention.
Light testing with TREE03 and hotplug shows no warnings. Converted the
warning as well to WARN_ON_ONCE() to reduce log spam.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 22 ++
1 file changed,
synchronize callback. If anything locks up,
we expect stall warnings and/or other splats.
Obviously, we need not test for rcu_barrier from a notifier, since those
are not allowed from notifiers. This fact is already detailed in the
documentation as well.
Signed-off-by: Joel Fernandes (Google
e once it is set.
Signed-off-by: Vineeth Pillai
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 28
1 file changed, 16 insertions(+), 12 deletions(-)
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 5da5b2317b21..464493f3a759
From: Vineeth Pillai
During a CPU hotplug event, schedule would be called with the hotplugged CPU
not in the cpumask. So use for_each_cpu(_wrap)_or to include the current cpu in
the task pick loop.
Signed-off-by: Vineeth Pillai
Co-developed-by: Joel Fernandes (Google)
Signed-off-by: Joel
-by: Joel Fernandes (Google)
---
include/linux/sched.h | 12 +++
kernel/entry/common.c | 88 +++---
kernel/sched/core.c | 205 ++
kernel/sched/sched.h | 3 +
4 files changed, 277 insertions(+), 31 deletions(-)
diff --git a/include/linux
Make use of the generic_idle_{enter,exit} helper function added in
earlier patches to enter and exit kernel protection.
On exiting idle, protection will be reenabled.
Signed-off-by: Joel Fernandes (Google)
---
include/linux/entry-common.h | 6 ++
1 file changed, 6 insertions(+)
diff --git
o worse than smtoff.
Also a modified rcutorture was used to heavily stress the kernel to make sure
there is not crash or instability.
Joel Fernandes (Google) (5):
irq_work: Add support to detect if work is pending
entry/idle: Add a common function for activites during idle entry/exit
arch/x86: Add a
P1()
{
int r1;
int r2 = 0;
r1 = READ_ONCE(flag);
if (r1)
r2 = READ_ONCE(buf);
}
Cc: paul...@kernel.org
Signed-off-by: Joel Fernandes (Google)
---
include/linux/irq_work.h | 1 +
kernel/irq_work.c|
From: Vineeth Pillai
Similar to how user to kernel mode transitions are protected in earlier
patches, protect the entry into kernel from guest mode as well.
Signed-off-by: Joel Fernandes (Google)
---
arch/x86/kvm/x86.c| 3 +++
include/linux/entry-kvm.h | 12
kernel/entry
core_pick_seq per run-queue.
Signed-off-by: Vineeth Pillai
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 19 ++-
kernel/sched/sched.h | 2 +-
2 files changed, 11 insertions(+), 10 deletions(-)
diff --git a/kernel/sched/core.c b/kernel/sched/core.c
index 3e9df8221c62
From: Vineeth Pillai
Hotplug fixes to core-scheduling require a new bitops API.
Introduce a new API find_next_or_bit() which returns the bit number of
the next set bit in OR-ed bit masks of the given bit masks.
Signed-off-by: Vineeth Pillai
Signed-off-by: Joel Fernandes (Google)
---
include
.
Signed-off-by: Joel Fernandes (Google)
---
arch/x86/include/asm/thread_info.h | 2 ++
kernel/sched/sched.h | 6 ++
2 files changed, 8 insertions(+)
diff --git a/arch/x86/include/asm/thread_info.h
b/arch/x86/include/asm/thread_info.h
index 267701ae3d86..42e63969acb3 100644
--- a/arch
Currently only RCU hooks for idle entry/exit are called. In later
patches, kernel-entry protection functionality will be added.
Signed-off-by: Joel Fernandes (Google)
---
include/linux/entry-common.h | 16
kernel/sched/idle.c | 17 +
2 files changed, 25
From: Vineeth Pillai
Hotplug fixes to core-scheduling require a new cpumask iterator which iterates
through all online cpus in both the given cpumasks. This patch introduces it.
Signed-off-by: Vineeth Pillai
Signed-off-by: Joel Fernandes (Google)
---
include/linux/cpumask.h | 42
logic if smt_mask changes between the loops.
Reported-by: Joel Fernandes (Google)
Signed-off-by: Vineeth Pillai
Signed-off-by: Joel Fernandes (Google)
---
kernel/sched/core.c | 22 +-
1 file changed, 21 insertions(+), 1 deletion(-)
diff --git a/kernel/sched/core.c b/kernel
derstand.
Signed-off-by: Joel Fernandes (Google)
---
A sample output can be seen after applying patch:
https://hastebin.com/raw/ivinimaler
tools/perf/builtin-sched.c | 24 ++--
1 file changed, 14 insertions(+), 10 deletions(-)
diff --git a/tools/perf/builtin-sched.c b/tools
2053-1-j...@joelfernandes.org/)
Joel Fernandes (Google) (4):
rcu/tree: Make rcu_do_batch count how many callbacks were executed
rcu/segcblist: Add counters to segcblist datastructure
rcu/trace: Add tracing for how segcb list changes
rcu/segcblist: Remove useless rcupdate.h include
include
in the respective segment.
Signed-off-by: Joel Fernandes (Google)
---
include/trace/events/rcu.h | 25 +
kernel/rcu/rcu_segcblist.c | 34 ++
kernel/rcu/rcu_segcblist.h | 5 +
kernel/rcu/tree.c | 9 +
4 files changed, 73 insertions
related to using donecbs's ->len field as a
temporary variable to save the segmented callback list's length. This cannot be
done anymore and is not needed.
Signed-off-by: Joel Fernandes (Google)
---
include/linux/rcu_segcblist.h | 2 +
kernel/rcu/rcu_segcblist.c|
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/rcu_segcblist.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/kernel/rcu/rcu_segcblist.c b/kernel/rcu/rcu_segcblist.c
index df0f31e30947..b65ac8c85b56 100644
--- a/kernel/rcu/rcu_segcblist.c
+++ b/kernel/rcu/rcu_segcblist.c
@@ -10,7
from 0 is confusing and error-prone IMHO.
This commit therefore explicitly counts have many callbacks were executed in
rcu_do_batch() itself, and uses that to update the per-CPU segcb list's ->len
field, without relying on the negativity of rcl->len.
Signed-off-by: Joel Fernandes (Google)
---
-time
jitter.
Passed 30 minute tests of TREE01 through TREE09 each.
Cc: neer...@codeaurora.org
Cc: fweis...@gmail.com
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/tree.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
index
Memory barriers are needed when updating the full length of the
segcblist, however it is not fully clearly why one is needed before and
after. This patch therefore adds additional comments to the function
header to explain it.
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/rcu_segcblist.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/kernel/rcu/rcu_segcblist.c b/kernel/rcu/rcu_segcblist.c
index 2a03949d0b82..e9e72d72f7a6 100644
--- a/kernel/rcu/rcu_segcblist.c
+++ b/kernel/rcu/rcu_segcblist.c
@@ -10,7
Weisbecker
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/srcutree.c | 5 -
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/kernel/rcu/srcutree.c b/kernel/rcu/srcutree.c
index 0f23d20d485a..79b7081143a7 100644
--- a/kernel/rcu/srcutree.c
+++ b/kernel/rcu/srcutree.c
@@ -1160,6
This memory barrier is not needed as rcu_segcblist_add_len() already
includes a memory barrier *before* and *after* the length of the list is
updated.
Same reasoning for rcu_segcblist_enqueue().
Reviewed-by: Frederic Weisbecker
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu
el.org/lkml/20200719034210.2382053-1-joel@x/)
Joel Fernandes (Google) (7):
rcu/tree: Make rcu_do_batch count how many callbacks were executed
rcu/segcblist: Add counters to segcblist datastructure
srcu: Fix invoke_rcu_callbacks() segcb length adjustment
rcu/trace: Add tracing for how
d-by: Neeraj Upadhyay
Signed-off-by: Joel Fernandes (Google)
---
kernel/rcu/rcu_segcblist.c | 2 +-
kernel/rcu/rcu_segcblist.h | 1 +
kernel/rcu/tree.c | 11 +--
3 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/kernel/rcu/rcu_segcblist.c b/kernel/rcu/rcu_segcb
in the respective segment.
Reviewed-by: Frederic Weisbecker
Reviewed-by: Neeraj Upadhyay
Signed-off-by: Joel Fernandes (Google)
---
include/trace/events/rcu.h | 25 +
kernel/rcu/rcu_segcblist.c | 34 ++
kernel/rcu/rcu_segcblist.h | 5 +
kernel/rcu
related to using donecbs's ->len field as a
temporary variable to save the segmented callback list's length. This cannot be
done anymore and is not needed.
Reviewed-by: Frederic Weisbecker
Signed-off-by: Joel Fernandes (Google)
---
include/linux/rcu_segcblist.h | 1 +
kernel/
-off-by: Joel Fernandes (Google)
---
include/linux/rcu_sync.h | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/include/linux/rcu_sync.h b/include/linux/rcu_sync.h
index 9b83865d24f9..0027d4c8087c 100644
--- a/include/linux/rcu_sync.h
+++ b/include/linux/rcu_sync.h
@@ -31,9
es)
Joel Fernandes (Google) (9):
rcu/update: Remove useless check for debug_locks (v1)
rcu: Add support for consolidated-RCU reader checking (v3)
rcu/sync: Remove custom check for reader-section (v2)
ipv4: add lockdep condition to fix for_each_entry (v1)
driver/core: Convert to use built-in RCU list chec
This patch updates the documentation with information about
usage of lockdep with list_for_each_entry_rcu().
Signed-off-by: Joel Fernandes (Google)
---
Documentation/RCU/lockdep.txt | 15 +++
Documentation/RCU/whatisRCU.txt | 9 -
2 files changed, 19 insertions(+), 5
list_for_each_entry_rcu has built-in RCU and lock checking. Make use of
it in driver core.
Acked-by: Greg Kroah-Hartman
Signed-off-by: Joel Fernandes (Google)
---
drivers/base/base.h | 1 +
drivers/base/core.c | 10 ++
drivers/base/power/runtime.c | 15
list_for_each_entry_rcu has built-in RCU and lock checking. Make use of
it for acpi_ioremaps list traversal.
Signed-off-by: Joel Fernandes (Google)
---
drivers/acpi/osl.c | 6 --
1 file changed, 4 insertions(+), 2 deletions(-)
diff --git a/drivers/acpi/osl.c b/drivers/acpi/osl.c
index
need to pass the
optional fourth argument (cond) unless they are under some non-RCU
protection and needs to make lockdep check pass.
Signed-off-by: Joel Fernandes (Google)
---
include/linux/rculist.h | 28 -
include/linux/rcupdate.h | 7 +++
kernel/rcu/Kconfig.debug
Fernandes (Google)
---
arch/x86/pci/mmconfig-shared.c | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/arch/x86/pci/mmconfig-shared.c b/arch/x86/pci/mmconfig-shared.c
index 7389db538c30..6fa42e9c4e6f 100644
--- a/arch/x86/pci/mmconfig-shared.c
+++ b/arch/x86/pci/mmconfig
901 - 1000 of 1376 matches
Mail list logo