ize RESTORE_CR3") for
User CR3.
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Link:
https://lore.kernel.org/lkml/20200525145102.122557-1-la...@linux.alibaba.com
Lai Jiangshan (2):
x86/entry: Don't write to CR3 when restoring to kernel CR3
x86/entry: a
RESTORE_CR3 is called when CPL==0 or #DF, it is unlikely
CPL==0==userCR3 and #DF itself is unlikely case.
There is no much overhead to always flush userCR3.
Signed-off-by: Lai Jiangshan
---
arch/x86/entry/calling.h | 27 ++-
arch/x86/entry/entry_64.S | 6 +++---
2
Skip resuming KERNEL pages since it is already KERNEL CR3
Signed-off-by: Lai Jiangshan
---
arch/x86/entry/calling.h | 13 -
1 file changed, 4 insertions(+), 9 deletions(-)
diff --git a/arch/x86/entry/calling.h b/arch/x86/entry/calling.h
index 1c7f13bb6728..505246185624 100644
On Tue, May 26, 2020 at 12:21 PM Andy Lutomirski wrote:
>
> On Mon, May 25, 2020 at 6:42 PM Lai Jiangshan wrote:
> >
> > The percpu user_pcid_flush_mask is used for CPU entry
> > If a data breakpoint on it, it will cause an unwanted #DB.
> > Protect the full cpu
On Mon, May 25, 2020 at 11:27 PM Peter Zijlstra wrote:
>
> On Mon, May 25, 2020 at 02:50:57PM +0000, Lai Jiangshan wrote:
> > Hello
> >
> > The patchset is based on (tag: entry-v9-the-rest, tglx-devel/x86/entry).
> > And it is complement of 3ea11ac991d
> &g
(espfix_waddr, espfix_stack).
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 11 +++
1 file changed, 11 insertions(+)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86
...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 30 ++
1 file changed, 22 insertions(+), 8 deletions(-)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel/hw_breakpoint.c
index c149c7b29ac3..f859095c1b6c 100644
--- a/arch/x86/kernel
IST-shift code is removed from entry code, #DB will stick to
DB stack only. So we remove the DB1 stack and the DB2 hole.
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/include/asm/cpu_entry_area.h | 12
IST-shift code is removed from entry code, #DB will not
at DB1 stack. So we remove the check of DB1 stack in
is_debug_stack().
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/nmi.c | 7 +--
1 file
: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 13 +++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel/hw_breakpoint.c
index 9ddf441ccaa8..c149c7b29ac3 100644
--- a/arch/x86/kernel
debug_enter() will disable #DB, there should be no recursive #DB.
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/entry/entry_64.S| 17 -
arch/x86/kernel/asm-offsets_64.c | 1 -
2 files
structure to be sure. Suggested
by Peter.
Drop the last patch of the V1 because debug_idt_table is removed
in Peter's patchset[3].
remove IST-shifting
Lai Jiangshan (7):
x86/hw_breakpoint: add within_area() to check data breakpoints
x86/hw_breakpoint: Prevent data breakpoints on
-shifting, is done).
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 13 +
1 file changed, 13 insertions(+)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel
: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 13 +++--
1 file changed, 11 insertions(+), 2 deletions(-)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel/hw_breakpoint.c
index 9ddf441ccaa8..c149c7b29ac3 100644
--- a/arch/x86/kernel
rigger #DB
(espfix related).
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 14 ++
1 file changed, 14 insertions(+)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/
...@kernel.org
Signed-off-by: Lai Jiangshan
---
Please drop this patch when Peter's work to remove debug_idt_table
is merged.
arch/x86/kernel/hw_breakpoint.c | 5 +
1 file changed, 5 insertions(+)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel/hw_breakpoint.c
index 9579bd6fb589
...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 30 ++
1 file changed, 22 insertions(+), 8 deletions(-)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel/hw_breakpoint.c
index c149c7b29ac3..f859095c1b6c 100644
--- a/arch/x86/kernel
-shifting, is done).
Cc: Andy Lutomirski
Cc: Peter Zijlstra (Intel)
Cc: Thomas Gleixner
Cc: x...@kernel.org
Signed-off-by: Lai Jiangshan
---
arch/x86/kernel/hw_breakpoint.c | 13 +
1 file changed, 13 insertions(+)
diff --git a/arch/x86/kernel/hw_breakpoint.c b/arch/x86/kernel
ise it may cause
dangerous/recursive/unwanted #DB.
Lai Jiangshan (5):
x86/hw_breakpoint: add within_area() to check data breakpoints
x86/hw_breakpoint: Prevent data breakpoints on direct GDT
x86/hw_breakpoint: Prevent data breakpoints on per_cpu cpu_tss_rw
x86/hw_breakpoint: Prevent data b
On Tue, May 19, 2020 at 5:04 PM Peter Zijlstra wrote:
> +#ifdef CONFIG_DEBUG_ENTRY
> /* Begin/end of an instrumentation safe region */
> -#define instrumentation_begin() ({
> \
> +#define instrumentation_begin() ({
On Sat, May 16, 2020 at 12:01 AM Lai Jiangshan wrote:
>
> lib/rbtree.c has ensured that there is not possible to
> inadvertently cause (temporary) loops in the tree structure
> as seen in program order of the modifier. But loop is still
> possible to be seen in searcher due to C
On Sat, May 16, 2020 at 12:28 PM Michel Lespinasse wrote:
>
> On Fri, May 15, 2020 at 03:59:09PM +0000, Lai Jiangshan wrote:
> > latch_tree_find() should be protected by caller via RCU or so.
> > When it find a node in an attempt, the node must be a valid one
> > in RC
parent->rb_right
The long loop won't stop until the modifer's CPU flushes
its writes. Too avoid it, we should limit the searching depth.
There are no more than (1<
Cc: Paul E. McKenney
Cc: Oleg Nesterov
Cc: Michel Lespinasse
Cc: Andrea Arcangeli
Cc: Rik van Riel
Cc: Mathieu Desnoyers
Nesterov
Cc: Michel Lespinasse
Cc: Andrea Arcangeli
Cc: Rik van Riel
Cc: Mathieu Desnoyers
Acked-by: Peter Zijlstra (Intel)
Signed-off-by: Lai Jiangshan
---
include/linux/rbtree_latch.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/rbtree_latch.h b/include
On Fri, May 15, 2020 at 9:04 PM Peter Zijlstra wrote:
>
> On Fri, May 15, 2020 at 12:47:06PM +0000, Lai Jiangshan wrote:
> > lib/rbtree.c has ensured that there is not possible to
> > inadvertently cause (temporary) loops in the tree structure
> > as seen in progr
Signed-off-by: Lai Jiangshan
---
include/linux/rbtree_latch.h | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/include/linux/rbtree_latch.h b/include/linux/rbtree_latch.h
index b012bd95eabf..09a3c05d1c5b 100644
--- a/include/linux/rbtree_latch.h
+++ b/include/linux/rbtree_latch.h
Cc: Mathieu Desnoyers
Signed-off-by: Lai Jiangshan
---
include/linux/rbtree_latch.h | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/include/linux/rbtree_latch.h b/include/linux/rbtree_latch.h
index 7d012faa509a..b012bd95eabf 100644
--- a/include/linux/rbtree_latch.h
+++
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: f0bdf6d473cf12a488a78422e15aafdfe77cf853
Gitweb:
https://git.kernel.org/tip/f0bdf6d473cf12a488a78422e15aafdfe77cf853
Author:Lai Jiangshan
AuthorDate:Sat, 15 Feb 2020 14:52:32 -08:00
Committer
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 07b4a930fc44a537efecf73c1fd2b4937f64caaa
Gitweb:
https://git.kernel.org/tip/07b4a930fc44a537efecf73c1fd2b4937f64caaa
Author:Lai Jiangshan
AuthorDate:Sat, 15 Feb 2020 14:37:26 -08:00
Committer
The following commit has been merged into the core/rcu branch of tip:
Commit-ID: 5f5fa7ea89dc82d34ed458f4d7a8634e8e9eefce
Gitweb:
https://git.kernel.org/tip/5f5fa7ea89dc82d34ed458f4d7a8634e8e9eefce
Author:Lai Jiangshan
AuthorDate:Sat, 15 Feb 2020 15:23:26 -08:00
Committer
Hello
On Mon, May 11, 2020 at 10:35 PM Thomas Gleixner wrote:
>
> Lai,
>
> Lai Jiangshan writes:
> > On Tue, May 5, 2020 at 10:23 PM Thomas Gleixner wrote:
> >> +SYM_CODE_START(irq_entries_start)
> >> +vector=FIRST_EXTERNAL_VECTOR
On Sun, May 10, 2020 at 11:49 PM Paul E. McKenney wrote:
>
> On Sun, May 10, 2020 at 05:59:27PM +0800, Lai Jiangshan wrote:
> > On Tue, Mar 17, 2020 at 6:03 AM Steven Rostedt wrote:
> > >
> > > On Mon, 16 Mar 2020 17:45:40 -0400
> > > Joel Fernandes
Reviewed-by: Lai Jiangshan
On Fri, May 8, 2020 at 11:07 PM Dan Carpenter wrote:
>
> We need to preserve error code before freeing "rescuer".
>
> Fixes: f187b6974f6df ("workqueue: Use IS_ERR and PTR_ERR instead of
> PTR_ERR_OR_ZERO.")
> Signed-off-by: Dan C
On Tue, Mar 17, 2020 at 6:03 AM Steven Rostedt wrote:
>
> On Mon, 16 Mar 2020 17:45:40 -0400
> Joel Fernandes wrote:
>
> > >
> > > Same for the function side (if not even more so). This would require
> > > adding
> > > a srcu_read_lock() to all functions that can be traced! That would be a
> >
On Thu, Apr 16, 2020 at 2:19 AM wrote:
>
> From: "Paul E. McKenney"
>
> This code-movement-only commit is in preparation for adding an additional
> flavor of Tasks RCU, which relies on workqueues to detect grace periods.
>
> Signed-off-by: Paul E. McKenney
> ---
> kernel/rcu/tasks.h | 370
>
On Tue, May 5, 2020 at 10:19 PM Thomas Gleixner wrote:
>
> Device interrupt handlers and system vector handlers are executed on the
> interrupt stack. The stack switch happens in the low level assembly entry
> code. This conflicts with the efforts to consolidate the exit code in C to
> ensure
On Tue, May 5, 2020 at 10:23 PM Thomas Gleixner wrote:
> +/*
> + * ASM code to emit the common vector entry stubs where each stub is
> + * packed into 8 bytes.
> + *
> + * Note, that the 'pushq imm8' is emitted via '.byte 0x6a, vector' because
> + * GCC treats the local vector variable as
On Tue, May 5, 2020 at 10:15 PM Thomas Gleixner wrote:
>
> From: Andy Lutomirski
>
> A data breakpoint near the top of an IST stack will cause unresoverable
> recursion. A data breakpoint on the GDT, IDT, or TSS is terrifying.
> Prevent either of these from happening.
>
What happen when a data
(CPU_ENTRY_AREA_ARRAY_SIZE + PAGE_SIZE)
^ sizeof PER_CPU ^ RO_IDT
Reviewed-by: Lai Jiangshan
> +
> static int arch_build_bp_info(struct perf_event *bp,
> const struct perf_event_attr *attr,
>
The following commit has been merged into the x86/entry branch of tip:
Commit-ID: f642aebc9d2a51775d86eaa79da9d90aa5dff0f7
Gitweb:
https://git.kernel.org/tip/f642aebc9d2a51775d86eaa79da9d90aa5dff0f7
Author:Lai Jiangshan
AuthorDate:Sun, 19 Apr 2020 14:40:47
Committer
The following commit has been merged into the x86/entry branch of tip:
Commit-ID: 4446d96d7ba7eaac54f9ef968bbe858097441d50
Gitweb:
https://git.kernel.org/tip/4446d96d7ba7eaac54f9ef968bbe858097441d50
Author:Lai Jiangshan
AuthorDate:Sun, 19 Apr 2020 14:40:49
Committer
The following commit has been merged into the x86/entry branch of tip:
Commit-ID: 3dcdb8e0c83b9502f669106e17bfa795f19f8d9b
Gitweb:
https://git.kernel.org/tip/3dcdb8e0c83b9502f669106e17bfa795f19f8d9b
Author:Lai Jiangshan
AuthorDate:Sun, 19 Apr 2020 14:40:48
Committer
On 2019/10/16 11:54 上午, Paul E. McKenney wrote:
On Tue, Oct 15, 2019 at 10:28:48AM +, Lai Jiangshan wrote:
CONFIG_PREEMPTION and CONFIG_PREEMPT_RCU are always identical,
but some code depends on CONFIG_PREEMPTION to access to
rcu_preempt functionalitis. This patch changes
On 2019/10/16 11:38 上午, Paul E. McKenney wrote:
On Tue, Oct 15, 2019 at 10:23:57AM +, Lai Jiangshan wrote:
"rcu_wait" is incorrct here, use "rcu_run" instead.
Signed-off-by: Lai Jiangshan
Signed-off-by: Lai Jiangshan
---
kernel/rcu/tree.c | 4 ++--
1 file c
Only tree_stall.h needs to get name from GP state.
Signed-off-by: Lai Jiangshan
Signed-off-by: Lai Jiangshan
---
kernel/rcu/tree.c | 10 --
kernel/rcu/tree.h | 12
kernel/rcu/tree_stall.h | 22 ++
3 files changed, 22 insertions(+), 22
call_rcu() is external RCU API declared in include/linux/,
and doesn't need to be (re-)declared in internal files again.
Signed-off-by: Lai Jiangshan
Signed-off-by: Lai Jiangshan
---
kernel/rcu/tree.h | 1 -
1 file changed, 1 deletion(-)
diff --git a/kernel/rcu/tree.h b/kernel/rcu/tree.h
CONFIG_PREEMPTION and CONFIG_PREEMPT_RCU are always identical,
but some code depends on CONFIG_PREEMPTION to access to
rcu_preempt functionalitis. This patch changes CONFIG_PREEMPTION
to CONFIG_PREEMPT_RCU in these cases.
Signed-off-by: Lai Jiangshan
Signed-off-by: Lai Jiangshan
---
kernel/rcu
declaration
and call-site are also (forced) changed. Nothing else is changed.
./scripts/checkpatch.pl gives four warnings, but they don't
need to be fixed.
Signed-off-by: Lai Jiangshan
Signed-off-by: Lai Jiangshan
---
kernel/rcu/Makefile | 1 +
kernel/rcu/tasks.c | 395
The notations include "Start" and "End", it is better
when there are paired.
Signed-off-by: Lai Jiangshan
Signed-off-by: Lai Jiangshan
---
kernel/rcu/tree.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.
"rcu_wait" is incorrct here, use "rcu_run" instead.
Signed-off-by: Lai Jiangshan
Signed-off-by: Lai Jiangshan
---
kernel/rcu/tree.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/kernel/rcu/tree.c b/kernel/rcu/tree.c
index 278798e58698..c351fc280945
wrongly used, which are always non-defined,
which makes "!defined(TINY_RCU)" always true, which means
the code block is always inclued, and the included code block
doesn't cause any compilation error so far when CONFIG_TINY_RCU.
It is also the reason this change doesn't need for stable.
Signed
All are minimal independent cleanups, expect that patch 3 depends
on patch 2.
Lai Jiangshan (7):
rcu: fix incorrect conditional compilation
rcu: fix tracepoint string when RCU CPU kthread runs
rcu: trace_rcu_utilization() paired
rcu: remove the declaration of call_rcu() in tree.h
rcu
On 2019/10/15 10:45 上午, Lai Jiangshan wrote:
On 2019/10/15 10:00 上午, Paul E. McKenney wrote:
On Tue, Oct 15, 2019 at 09:50:21AM +0800, Lai Jiangshan wrote:
On Tue, Oct 15, 2019 at 9:46 AM Paul E. McKenney
wrote:
On Mon, Oct 14, 2019 at 02:48:32PM -0400, Joel Fernandes wrote:
On Sun
Currently PREEMPT_RCU and TREE_RCU are "contrary" configs
when they can't be both on. But PREEMPT_RCU is actually a kind
of TREE_RCU in the implementation. It seams to be appropriate
to make PREEMPT_RCU to be a decorative option of TREE_RCU.
Signed-off-by: Lai Jiangshan
Signed-o
On 2019/10/15 10:00 上午, Paul E. McKenney wrote:
On Tue, Oct 15, 2019 at 09:50:21AM +0800, Lai Jiangshan wrote:
On Tue, Oct 15, 2019 at 9:46 AM Paul E. McKenney wrote:
On Mon, Oct 14, 2019 at 02:48:32PM -0400, Joel Fernandes wrote:
On Sun, Oct 13, 2019 at 12:59:57PM +, Lai Jiangshan
On Tue, Oct 15, 2019 at 9:46 AM Paul E. McKenney wrote:
>
> On Mon, Oct 14, 2019 at 02:48:32PM -0400, Joel Fernandes wrote:
> > On Sun, Oct 13, 2019 at 12:59:57PM +, Lai Jiangshan wrote:
> > > Currently PREEMPT_RCU and TREE_RCU are "contrary" config
Currently PREEMPT_RCU and TREE_RCU are "contrary" configs
when they can't be both on. But PREEMPT_RCU is actually a kind
of TREE_RCU in the implementation. It seams to be appropriate
to make PREEMPT_RCU to be a decorative option of TREE_RCU.
Signed-off-by: Lai Jiangshan
Signed-o
"""
And document "/* MD: rescue worker */" might be better
than current "/* I: rescue worker */", although ->rescuer can
be accessed without wq_mayday_lock lock in some code.
Reviewed-by: Lai Jiangshan
On Thu, Sep 19, 2019 at 9:43 AM Tejun Heo wrote:
>
> Before
On Tue, Dec 25, 2018 at 1:32 PM Lai Jiangshan
wrote:
>
> Is it possible to avoid adding any syscall?
>
> Since holding /proc/pid/reg_file can also hold the pid.
> With this guarantee, /proc/pid/uuid (universally unique identifier ) can be
> introduced to identify tasks, th
Is it possible to avoid adding any syscall?
Since holding /proc/pid/reg_file can also hold the pid.
With this guarantee, /proc/pid/uuid (universally unique identifier ) can be
introduced to identify tasks, the kernel generates
a uuid for every task when created.
On Thu, Sep 13, 2018 at 9:51 AM wrote:
>
> >> From: Liu Song
> >>
> >> Although the 'need_to_create_worker' has been determined to be
> >> true before entering the function. However, adjusting the order
> >> of judgment can combine two judgments in the loop. Also improve
> >> the matching
On Thu, Sep 13, 2018 at 9:51 AM wrote:
>
> >> From: Liu Song
> >>
> >> Although the 'need_to_create_worker' has been determined to be
> >> true before entering the function. However, adjusting the order
> >> of judgment can combine two judgments in the loop. Also improve
> >> the matching
On Fri, Jul 13, 2018 at 8:02 AM, Paul E. McKenney
wrote:
> Hello!
>
> I now have a semi-reasonable prototype of changes consolidating the
> RCU-bh, RCU-preempt, and RCU-sched update-side APIs in my -rcu tree.
> There are likely still bugs to be fixed and probably other issues as well,
> but a
On Fri, Jul 13, 2018 at 8:02 AM, Paul E. McKenney
wrote:
> Hello!
>
> I now have a semi-reasonable prototype of changes consolidating the
> RCU-bh, RCU-preempt, and RCU-sched update-side APIs in my -rcu tree.
> There are likely still bugs to be fixed and probably other issues as well,
> but a
On Thu, May 17, 2018 at 12:34 PM, Tejun Heo wrote:
> For historical reasons, the worker attach/detach functions don't
> currently manage worker->pool and the callers are manually and
> inconsistently updating it.
>
> This patch moves worker->pool updates into the worker
On Thu, May 17, 2018 at 12:34 PM, Tejun Heo wrote:
> For historical reasons, the worker attach/detach functions don't
> currently manage worker->pool and the callers are manually and
> inconsistently updating it.
>
> This patch moves worker->pool updates into the worker attach/detach
> functions.
On Tue, Mar 20, 2018 at 12:45 AM, Tejun Heo <t...@kernel.org> wrote:
> Hello, Lai.
>
> On Fri, Mar 16, 2018 at 02:01:35PM +0800, Lai Jiangshan wrote:
>> > +bool flush_rcu_work(struct rcu_work *rwork)
>> > +{
>> > + if (test_bit(WORK_STRU
On Tue, Mar 20, 2018 at 12:45 AM, Tejun Heo wrote:
> Hello, Lai.
>
> On Fri, Mar 16, 2018 at 02:01:35PM +0800, Lai Jiangshan wrote:
>> > +bool flush_rcu_work(struct rcu_work *rwork)
>> > +{
>> > + if (test_bit(WORK_STRUCT_PEN
The manager_arb mutex doesn't exist any more.
Signed-off-by: Lai Jiangshan <jiangshan...@gmail.com>
---
kernel/workqueue.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index 19785a092026..698b6f1ecddd 100644
--- a/kernel/workqueue.c
+++ b/
The manager_arb mutex doesn't exist any more.
Signed-off-by: Lai Jiangshan
---
kernel/workqueue.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index 19785a092026..698b6f1ecddd 100644
--- a/kernel/workqueue.c
+++ b/kernel/workqueue.c
@@ -165,7 +165,6
Since the worker rebinding behavior was refactored, there is
no idle worker off the idle_list now. The comment is outdated
and can be just removed.
It also groups nr_workers and nr_idle together.
Signed-off-by: Lai Jiangshan <jiangshan...@gmail.com>
---
kernel/workqueue.c | 5 ++---
Since the worker rebinding behavior was refactored, there is
no idle worker off the idle_list now. The comment is outdated
and can be just removed.
It also groups nr_workers and nr_idle together.
Signed-off-by: Lai Jiangshan
---
kernel/workqueue.c | 5 ++---
1 file changed, 2 insertions(+), 3
refcount of the pool in
manage_workers(). "indirect" means it gets a refcount of
the first involved pwq which holds a refcount of the pool.
This refcount can prevent the pool from being destroyed.
The original synchronization mechanism (wq_manager_wait)
is also removed.
Signed-off-by: Lai
refcount of the pool in
manage_workers(). "indirect" means it gets a refcount of
the first involved pwq which holds a refcount of the pool.
This refcount can prevent the pool from being destroyed.
The original synchronization mechanism (wq_manager_wait)
is also removed.
Signed-off-by: Lai
n __queue_work() */
> + local_irq_disable();
> + __queue_work(WORK_CPU_UNBOUND, rwork->wq, >work);
> + local_irq_enable();
> +}
> +
> +/**
> + * queue_rcu_work - queue work after a RCU grace period
> + * @wq: workqueue to use
> + * @rwork: work to queue
k);
> + local_irq_enable();
> +}
> +
> +/**
> + * queue_rcu_work - queue work after a RCU grace period
> + * @wq: workqueue to use
> + * @rwork: work to queue
> + *
> + * Return: %false if @rwork was already pending, %true otherwise. Note
> + * that a full R
Commit-ID: 17a2f1ced0280068897990b0dd25ce70555b8ac7
Gitweb: https://git.kernel.org/tip/17a2f1ced0280068897990b0dd25ce70555b8ac7
Author: Lai Jiangshan <jiangshan...@gmail.com>
AuthorDate: Fri, 1 Dec 2017 21:50:05 +0800
Committer: Thomas Gleixner <t...@linutronix.de>
CommitD
Commit-ID: 17a2f1ced0280068897990b0dd25ce70555b8ac7
Gitweb: https://git.kernel.org/tip/17a2f1ced0280068897990b0dd25ce70555b8ac7
Author: Lai Jiangshan
AuthorDate: Fri, 1 Dec 2017 21:50:05 +0800
Committer: Thomas Gleixner
CommitDate: Wed, 14 Mar 2018 16:38:43 +0100
cpu/hotplug: Merge
On Tue, Mar 6, 2018 at 12:14 AM, Paul E. McKenney
wrote:
> On Mon, Mar 05, 2018 at 08:33:20AM -0600, Eric W. Biederman wrote:
>>
>> Moving this discussion to a public list as discussing how to reduce the
>> number of rcu variants does not make sense in private. We
On Tue, Mar 6, 2018 at 12:14 AM, Paul E. McKenney
wrote:
> On Mon, Mar 05, 2018 at 08:33:20AM -0600, Eric W. Biederman wrote:
>>
>> Moving this discussion to a public list as discussing how to reduce the
>> number of rcu variants does not make sense in private. We should have
>> an archive of
On Wed, Mar 7, 2018 at 10:54 PM, Paul E. McKenney
<paul...@linux.vnet.ibm.com> wrote:
> On Wed, Mar 07, 2018 at 10:49:49AM +0800, Lai Jiangshan wrote:
>> On Wed, Mar 7, 2018 at 1:33 AM, Tejun Heo <t...@kernel.org> wrote:
>>
>> > +/**
>> > + * queue_r
On Wed, Mar 7, 2018 at 10:54 PM, Paul E. McKenney
wrote:
> On Wed, Mar 07, 2018 at 10:49:49AM +0800, Lai Jiangshan wrote:
>> On Wed, Mar 7, 2018 at 1:33 AM, Tejun Heo wrote:
>>
>> > +/**
>> > + * queue_rcu_work_on - queue work on specific CPU after a RCU grace
On Wed, Mar 7, 2018 at 1:33 AM, Tejun Heo wrote:
> +/**
> + * queue_rcu_work_on - queue work on specific CPU after a RCU grace period
> + * @cpu: CPU number to execute work on
> + * @wq: workqueue to use
> + * @rwork: work to queue
For many people, "RCU grace period" is clear
On Wed, Mar 7, 2018 at 1:33 AM, Tejun Heo wrote:
> +/**
> + * queue_rcu_work_on - queue work on specific CPU after a RCU grace period
> + * @cpu: CPU number to execute work on
> + * @wq: workqueue to use
> + * @rwork: work to queue
For many people, "RCU grace period" is clear enough, but not
On Tue, Jan 23, 2018 at 3:59 PM, wrote:
> From: Heng Zhang
>
> This RCU implementation (PRCU) is based on a fast consensus protocol
> published in the following paper:
>
> Fast Consensus Using Bounded Staleness for Scalable Read-mostly
>
On Tue, Jan 23, 2018 at 3:59 PM, wrote:
> From: Heng Zhang
>
> This RCU implementation (PRCU) is based on a fast consensus protocol
> published in the following paper:
>
> Fast Consensus Using Bounded Staleness for Scalable Read-mostly
> Synchronization.
> Haibo Chen, Heng Zhang, Ran Liu,
On Mon, Jan 29, 2018 at 12:41 PM, Mike Galbraith <efa...@gmx.de> wrote:
> On Mon, 2018-01-29 at 12:15 +0800, Lai Jiangshan wrote:
>> I think adding priority boost to workqueue(flush_work()) is the best
>> way to fix the problem.
>
> I disagree, priority boosting is
On Mon, Jan 29, 2018 at 12:41 PM, Mike Galbraith wrote:
> On Mon, 2018-01-29 at 12:15 +0800, Lai Jiangshan wrote:
>> I think adding priority boost to workqueue(flush_work()) is the best
>> way to fix the problem.
>
> I disagree, priority boosting is needlessly invasi
policy=1 prio=1 nice=0
> # cat /sys/devices/virtual/workqueue/system_percpu_highpri/sched_attr
> policy=0 prio=0 nice=-20
> # echo "policy=1 prio=2 nice=0" >
> /sys/devices/virtual/workqueue/system_percpu_highpri/s
al/workqueue/system_percpu/sched_attr
> policy=0 prio=0 nice=0
> # echo "policy=1 prio=1 nice=0" >
> /sys/devices/virtual/workqueue/system_percpu/sched_attr
> # cat /sys/devices/virtual/workqueue/system_percpu/sched_attr
> policy=1 prio=1 nice=0
>
On Wed, Jan 17, 2018 at 4:08 AM, Neeraj Upadhyay wrote:
>
>
> On 01/16/2018 11:05 PM, Tejun Heo wrote:
>>
>> Hello, Neeraj.
>>
>> On Mon, Jan 15, 2018 at 02:08:12PM +0530, Neeraj Upadhyay wrote:
>>>
>>> - kworker/0:0 gets chance to run on cpu1; while processing
>>>a
On Wed, Jan 17, 2018 at 4:08 AM, Neeraj Upadhyay wrote:
>
>
> On 01/16/2018 11:05 PM, Tejun Heo wrote:
>>
>> Hello, Neeraj.
>>
>> On Mon, Jan 15, 2018 at 02:08:12PM +0530, Neeraj Upadhyay wrote:
>>>
>>> - kworker/0:0 gets chance to run on cpu1; while processing
>>>a work, it goes to sleep.
On Sun, Dec 3, 2017 at 2:33 PM, Paul E. McKenney
<paul...@linux.vnet.ibm.com> wrote:
> On Fri, Dec 01, 2017 at 09:50:05PM +0800, Lai Jiangshan wrote:
>> cpuhp_bp_states_ap_states have diffent set of steps
>> without any conflicting configed steps, so that they can
>> be
On Sun, Dec 3, 2017 at 2:33 PM, Paul E. McKenney
wrote:
> On Fri, Dec 01, 2017 at 09:50:05PM +0800, Lai Jiangshan wrote:
>> cpuhp_bp_states_ap_states have diffent set of steps
>> without any conflicting configed steps, so that they can
>> be merged.
>>
>>
but it doesn't hurt to
> change it and doing so avoids script-generated noise.
>
> Reported-by: Tobin C. Harding <m...@tobin.cc>
> Signed-off-by: Paul E. McKenney <paul...@linux.vnet.ibm.com>
Reviewed-by: Lai Jiangshan <jiangshan...@gmail.com>
> ---
> kernel/r
it and doing so avoids script-generated noise.
>
> Reported-by: Tobin C. Harding
> Signed-off-by: Paul E. McKenney
Reviewed-by: Lai Jiangshan
> ---
> kernel/rcu/srcutree.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/rcu/srcutr
aul E. McKenney <paul...@linux.vnet.ibm.com>
> Cc: Tejun Heo <t...@kernel.org>
> Cc: Lai Jiangshan <jiangshan...@gmail.com>
Reviewed-by: Lai Jiangshan <jiangshan...@gmail.com>
> ---
> kernel/workqueue.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion
jun Heo
> Cc: Lai Jiangshan
Reviewed-by: Lai Jiangshan
> ---
> kernel/workqueue.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/kernel/workqueue.c b/kernel/workqueue.c
> index 8fdb710bfdd7..aee7eaab05cb 100644
> --- a/kernel/workqueue.c
>
Sine the cpu/hotplug refactor is done, the hotplug
callbacks are called properly. So the workaround is
useless.
Signed-off-by: Lai Jiangshan <jiangshan...@gmail.com>
---
kernel/workqueue.c | 10 --
1 file changed, 10 deletions(-)
diff --git a/kernel/workqueue.c b/kernel/workq
Sine the cpu/hotplug refactor is done, the hotplug
callbacks are called properly. So the workaround is
useless.
Signed-off-by: Lai Jiangshan
---
kernel/workqueue.c | 10 --
1 file changed, 10 deletions(-)
diff --git a/kernel/workqueue.c b/kernel/workqueue.c
index 5c99beb8577d
201 - 300 of 2229 matches
Mail list logo