[PATCH][resend] perf x86 kvm-stat: support to analyze kvm msr

2021-04-15 Thread Li RongQing
:W 67007 98.17% 98.31% 0.59us 10.69us 0.90us ( +- 0.10% ) 0x830:W1186 1.74%1.60% 0.53us 108.34us 0.82us ( +- 11.02% ) 0x3b:R 66 0.10%0.09% 0.56us1.26us 0.80us ( +- 3.24% ) Total Samples:68259, Total events handled time:61150.95us. Signed-off-by: Li

[PATCH] perf x86 kvm-stat: support to analyze kvm msr

2021-03-24 Thread Li RongQing
:W 67007 98.17% 98.31% 0.59us 10.69us 0.90us ( +- 0.10% ) 0x830:W1186 1.74%1.60% 0.53us 108.34us 0.82us ( +- 11.02% ) 0x3b:R 66 0.10%0.09% 0.56us1.26us 0.80us ( +- 3.24% ) Total Samples:68259, Total events handled time:61150.95us. Signed-off-by: Li

[PATCH] alarmtimer: Do not mess with an enqueued hrtimer

2021-01-06 Thread Li RongQing
tions for timerfd support") Signed-off-by: Li RongQing --- kernel/time/alarmtimer.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c index f4ace1bf8382..3b34995ab8d2 100644 --- a/kernel/time/alarmtimer.c +++ b/kernel/time/al

[PATCH] random: get rid of dead codes from credit_entropy_bits

2020-06-28 Thread Li RongQing
After commit 90ea1c6436d2 ("random: remove the blocking pool"), has_initialized is zero always, and initialized of struct entropy_store is not used Signed-off-by: Li RongQing --- drivers/char/random.c | 8 +--- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/dr

[PATCH][v7] KVM: X86: support APERF/MPERF registers

2020-06-08 Thread Li RongQing
inned vcpu And a per-VM capability is added to configure aperfmperf mode Signed-off-by: Li RongQing Signed-off-by: Chai Wen Signed-off-by: Jia Lina --- diff v6: drop the unneed check from kvm_update_cpuid and __do_cpuid_func add the validation check in kvm_vm_ioctl_enable_cap thank for Jim Matts

答复: [PATCH][v6] KVM: X86: support APERF/MPERF registers

2020-06-06 Thread Li,Rongqing
> -邮件原件- > 发件人: Paolo Bonzini [mailto:pbonz...@redhat.com] > 发送时间: 2020年6月6日 1:22 > 收件人: Jim Mattson > 抄送: Xiaoyao Li ; Li,Rongqing ; > LKML ; kvm list ; the > arch/x86 maintainers ; H . Peter Anvin ; > Borislav Petkov ; Ingo Molnar ; Thomas > Gleixner ; Wanp

答复: 答复: [PATCH][v6] KVM: X86: support APERF/MPERF registers

2020-06-05 Thread Li,Rongqing
> -邮件原件- > 发件人: Like Xu [mailto:like...@linux.intel.com] > 发送时间: 2020年6月5日 13:29 > 收件人: Li,Rongqing ; like...@intel.com > 抄送: linux-kernel@vger.kernel.org; k...@vger.kernel.org; x...@kernel.org; > h...@zytor.com; b...@alien8.de; mi...@redhat.com; t...@linutronix.de; >

答复: [PATCH][v6] KVM: X86: support APERF/MPERF registers

2020-06-04 Thread Li,Rongqing
> -邮件原件- > 发件人: Xu, Like [mailto:like...@intel.com] > 发送时间: 2020年6月5日 10:32 > 收件人: Li,Rongqing > 抄送: linux-kernel@vger.kernel.org; k...@vger.kernel.org; x...@kernel.org; > h...@zytor.com; b...@alien8.de; mi...@redhat.com; t...@linutronix.de; > jmatt...@google.com;

[PATCH][v6] KVM: X86: support APERF/MPERF registers

2020-06-04 Thread Li RongQing
S_REALTIME, Because that hint guarantees we have a 1:1 vCPU:CPU binding and guaranteed no over-commit. And a per-VM capability is added to configure aperfmperf mode Signed-off-by: Li RongQing Signed-off-by: Chai Wen Signed-off-by: Jia Lina --- diff v5: return error if guest is configured with m

答复: 答复: [PATCH][v5] KVM: X86: support APERF/MPERF registers

2020-06-04 Thread Li,Rongqing
> IMO, If we really want to ensure the correctness of userspace provided CPUID > settings, we need to return ERROR to userspace instead of fixing it siliently. > Ok , I will make it return a error Thanks -Li > - Xiaoyao

答复: [PATCH][v5] KVM: X86: support APERF/MPERF registers

2020-05-30 Thread Li,Rongqing
> -邮件原件- > 发件人: Xiaoyao Li [mailto:xiaoyao...@intel.com] > 发送时间: 2020年5月30日 18:40 > 收件人: Li,Rongqing ; linux-kernel@vger.kernel.org; > k...@vger.kernel.org; x...@kernel.org; h...@zytor.com; b...@alien8.de; > mi...@redhat.com; t...@linutronix.de; jmatt...@go

[PATCH][v5] KVM: X86: support APERF/MPERF registers

2020-05-29 Thread Li RongQing
S_REALTIME, Because that hint guarantees we have a 1:1 vCPU:CPU binding and guaranteed no over-commit. And a per-VM capability is added to configure aperfmperf mode Signed-off-by: Li RongQing Signed-off-by: Chai Wen Signed-off-by: Jia Lina --- diff v4: fix maybe-uninitialized warning di

答复: [PATCH] [v4] KVM: X86: support APERF/MPERF registers

2020-05-07 Thread Li,Rongqing
tree, please drop us a > note to > help improve the system. BTW, we also suggest to use '--base' option to > specify > the base tree in git format-patch, please see > https://stackoverflow.com/a/37406982] > > url: > https://github.com/0day-ci/linux/commits/Li-RongQing/KVM-

[PATCH] [v4] KVM: X86: support APERF/MPERF registers

2020-05-06 Thread Li RongQing
S_REALTIME, Because that hint guarantees we have a 1:1 vCPU:CPU binding and guaranteed no over-commit. and a per-VM capability is added to configure aperfmperf mode Signed-off-by: Li RongQing Signed-off-by: Chai Wen Signed-off-by: Jia Lina --- diff v3: fix interception of MSR_IA32_MPERF/APERF in

答复: [PATCH] [v3] kvm: x86: support APERF/MPERF registers

2020-05-03 Thread Li,Rongqing
> -邮件原件- > 发件人: Wei Huang [mailto:wei.hua...@amd.com] > 发送时间: 2020年5月2日 5:31 > 收件人: Li,Rongqing > 抄送: linux-kernel@vger.kernel.org; k...@vger.kernel.org; x...@kernel.org; > h...@zytor.com; b...@alien8.de; mi...@redhat.com; t...@linutronix.de; > jmatt...@google.com;

[PATCH] [v3] kvm: x86: support APERF/MPERF registers

2020-04-30 Thread Li RongQing
S_REALTIME, Because that hint guarantees we have a 1:1 vCPU:CPU binding and guaranteed no over-commit. and a per-VM capability is added to configure aperfmperf mode Signed-off-by: Li RongQing Signed-off-by: Chai Wen Signed-off-by: Jia Lina --- diff v2: support aperfmperf pass though move co

答复: [PATCH][v2] kvm: x86: emulate APERF/MPERF registers

2020-04-30 Thread Li,Rongqing
> -邮件原件- > 发件人: Xiaoyao Li [mailto:xiaoyao...@intel.com] > 发送时间: 2020年4月30日 14:49 > 收件人: Li,Rongqing ; linux-kernel@vger.kernel.org; > k...@vger.kernel.org; x...@kernel.org; h...@zytor.com; b...@alien8.de; > mi...@redhat.com; t...@linutronix.de; j...@8bytes.org; >

答复: [PATCH][v2] kvm: x86: emulate APERF/MPERF registers

2020-04-29 Thread Li,Rongqing
> -邮件原件- > 发件人: Paolo Bonzini [mailto:pbonz...@redhat.com] > 发送时间: 2020年4月29日 18:21 > 收件人: Peter Zijlstra ; Li,Rongqing > > 抄送: linux-kernel@vger.kernel.org; k...@vger.kernel.org; x...@kernel.org; > h...@zytor.com; b...@alien8.de; mi...@redhat.com; t...@linutronix.

答复: [PATCH][v2] kvm: x86: emulate APERF/MPERF registers

2020-04-29 Thread Li,Rongqing
> > Would it make sense to provide a pass-through APERF/MPERF for > KVM_HINTS_REALTIME ? Because that hint guarantees we have a 1:1 > vCPU:CPU binding and guaranteed no over-commit. Make sense I think this can be done in a separate patch for KVM_HINTS_REALTIME Thanks =Li

答复: [PATCH] x86: move turbo_disabled() out of intel_set_max_freq_ratio

2020-04-29 Thread Li,Rongqing
> Hello, > > the problem is that turbo can be enabled/disabled by the firmware at runtime, > after the machine has booted. > > This happens for example with the Dell XPS 13, where turbo gets disabled by > the firmware if the machine is disconnected from AC power and runs on battery. > The

[PATCH][v2] kvm: x86: emulate APERF/MPERF registers

2020-04-28 Thread Li RongQing
to achieve it the period of aperf/mperf in guest mode are accumulated as emulated value, and add per-VM knod to enable emulate mperfaperf diff v1: 1. support AMD 2. support per-vm capability to enable Signed-off-by: Li RongQing Signed-off-by: Chai Wen Signed-off-by: Jia Lina --- Documentatio

[PATCH] x86: move turbo_disabled() out of intel_set_max_freq_ratio

2020-04-28 Thread Li RongQing
move the turbo_disabled before intel_set_max_freq_ratio, when turbo is disabled, the max frequency ratio is a const value, it is unnecessary to read MSR_TURBO_RATIO* msr to compute Signed-off-by: Li RongQing --- arch/x86/kernel/smpboot.c | 5 - 1 file changed, 4 insertions(+), 1 deletion

答复: [PATCH][v2] watchdog/hardlockup: reassign last_timestamp when enable nmi event

2019-10-22 Thread Li,Rongqing
Ping Thanks -Li > -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Li RongQing > 发送时间: 2019年10月15日 14:34 > 收件人: a...@linux-foundation.org; sergey.senozhatsky.w...@gmail.com; > linux-kernel@vger.kernel.org; t...@lin

[PATCH] mm: remove VM_ACCT(PAGE_SIZE) when charge and uncharge

2019-10-17 Thread Li RongQing
VM_ACCT(PAGE_SIZE) is one, and it is unnecessary to multiply by it Signed-off-by: Li RongQing --- mm/shmem.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/mm/shmem.c b/mm/shmem.c index cd570cc79c76..f01df46ef2ff 100644 --- a/mm/shmem.c +++ b/mm/shmem.c @@ -202,14

[PATCH][v2] watchdog/hardlockup: reassign last_timestamp when enable nmi event

2019-10-15 Thread Li RongQing
chdog: Prevent false positives with turbo modes") Signed-off-by: Li RongQing Signed-off-by: Zhang Yu --- v1-->v2: make it be able to be compiled on no CONFIG_HARDLOCKUP_CHECK_TIMESTAMP platform kernel/watchdog_hld.c | 18 +- 1 file changed, 17 insertions(+), 1 deletion(-

[PATCH] watchdog/hardlockup: reassign last_timestamp when enable nmi event

2019-10-12 Thread Li RongQing
chdog: Prevent false positives with turbo modes") Signed-off-by: Li RongQing --- kernel/watchdog_hld.c | 9 - 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/kernel/watchdog_hld.c b/kernel/watchdog_hld.c index 247bf0b1582c..fc3a5c7ccd82 100644 --- a/kernel/watchdog_hld.c ++

[PATCH][RFC] perf/x86: avoid false-positives hard lockup

2019-10-10 Thread Li RongQing
period, computed by set_sample_period Signed-off-by: Li RongQing --- arch/x86/events/core.c | 4 1 file changed, 4 insertions(+) diff --git a/arch/x86/events/core.c b/arch/x86/events/core.c index 7b21455d7504..1f5309456d4c 100644 --- a/arch/x86/events/core.c +++ b/arch/x86/events/core.c

[tip: timers/urgent] timer: Read jiffies once when forwarding base clk

2019-09-19 Thread tip-bot2 for Li RongQing
The following commit has been merged into the timers/urgent branch of tip: Commit-ID: e430d802d6a3aaf61bd3ed03d9404888a29b9bf9 Gitweb: https://git.kernel.org/tip/e430d802d6a3aaf61bd3ed03d9404888a29b9bf9 Author:Li RongQing AuthorDate:Thu, 19 Sep 2019 20:04:47 +08:00

[PATCH] timer: read jiffies once when forwarding base clk

2019-09-19 Thread Li RongQing
jiffies + HZ); } further investigation shows jiffies maybe change when advence this base clk, twice read of jiffies maybe lead to that base clk is bigger than truely next event, and fire timer is skipped, so read jiffies once, Signed-off-by: Li RongQing Signed-off-by: Liang ZhiCheng --- kernel/tim

答复: [PATCH] TTY: serial_core, add ->install

2019-04-17 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Jiri Slaby > 发送时间: 2019年4月17日 16:59 > 收件人: gre...@linuxfoundation.org > 抄送: linux-ser...@vger.kernel.org; linux-kernel@vger.kernel.org; Jiri Slaby > ; Li,Rongqin

[PATCH] mm, slab: remove unneed check in cpuup_canceled

2019-03-21 Thread Li RongQing
nc is a member of percpu allocation memory, and impossible NULL Signed-off-by: Li RongQing --- mm/slab.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/mm/slab.c b/mm/slab.c index 28652e4218e0..f1420e14875a 100644 --- a/mm/slab.c +++ b/mm/slab.c @@ -990,10 +990,8

[PATCH][v2] ipc: prevent lockup on alloc_msg and free_msg

2019-03-07 Thread Li RongQing
From: Li Rongqing msgctl10 of ltp triggers the following lockup When CONFIG_KASAN is enabled on large memory SMP systems, the pages initialization can take a long time, if msgctl10 requests a huge block memory, and it will block rcu scheduler, so release cpu actively. After adding schedule

答复: [PATCH] ipc: prevent lockup on alloc_msg and free_msg

2019-03-07 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Andrew Morton > 发送时间: 2019年3月8日 2:10 > 收件人: Li,Rongqing > 抄送: linux-kernel@vger.kernel.org; Davidlohr Bueso ; > Dominik Brodowski ; Manfred Spraul > ; Arnd Bergman

[PATCH] ipc: prevent lockup on alloc_msg and free_msg

2019-03-07 Thread Li RongQing
From: Li Rongqing msgctl10 of ltp triggers the following lockup When CONFIG_KASAN is enabled on large memory SMP systems, the pages initialization can take a long time, if msgctl10 requests a huge block memory, and it will block rcu scheduler, so release cpu actively. [79441.630467] rcu: INFO

答复: [PATCH] audit: fix a memleak caused by auditing load module

2019-03-05 Thread Li,Rongqing
> -邮件原件- > 发件人: Paul Moore [mailto:p...@paul-moore.com] > 发送时间: 2019年3月5日 22:18 > 收件人: Li,Rongqing > 抄送: Eric Paris ; linux-au...@redhat.com; > linux-kernel@vger.kernel.org > 主题: Re: [PATCH] audit: fix a memleak caused by auditing load module > > On Tue

[PATCH] audit: fix a memleak caused by auditing load module

2019-03-05 Thread Li RongQing
t;00d4a478>] do_syscall_64+0x117/0x400 [<4924ded8>] entry_SYSCALL_64_after_hwframe+0x49/0xbe [<7dc331dd>] 0x Fixes: ca86cad7380e3 ("audit: log module name on init_module") Signed-off-by: Zhang Yu Signed-off-by: Li RongQing

[PATCH][v2] time: Introduce jiffies64_to_msecs()

2019-02-27 Thread Li RongQing
there is a similar helper in net/netfilter/nf_tables_api.c, this maybe become a common request someday, so move it to time.c Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- v1-->v2: using jiffies64_to_msecs in nf_tables_api.c include/linux/jiffies.h | 1 + kernel/time/tim

答复: [PATCH] time: Introduce jiffies64_to_msecs()

2019-02-27 Thread Li,Rongqing
> -邮件原件- > 发件人: Thomas Gleixner [mailto:t...@linutronix.de] > 发送时间: 2019年2月27日 19:18 > 收件人: Li,Rongqing > 抄送: netfilter-de...@vger.kernel.org; linux-kernel@vger.kernel.org; > sb...@kernel.org; john.stu...@linaro.org > 主题: Re: [PATCH] time: Introduce jiffies64_to_ms

[PATCH] time: Introduce jiffies64_to_msecs()

2019-02-27 Thread Li RongQing
there is a similar helper in net/netfilter/nf_tables_api.c, this maybe become a common request someday. and avoid to call div_64 at some condition Signed-off-by: Li RongQing --- include/linux/jiffies.h | 1 + kernel/time/time.c | 10 ++ 2 files changed, 11 insertions(+) diff

答复: [PATCH] XArray tests: allocation has to be GFP_ATOMIC under rcu_read_lock

2019-02-10 Thread Li,Rongqing
> -邮件原件- > 发件人: Matthew Wilcox [mailto:wi...@infradead.org] > 发送时间: 2019年2月3日 7:20 > 收件人: Li,Rongqing > 抄送: linux-kernel@vger.kernel.org > 主题: Re: [PATCH] XArray tests: allocation has to be GFP_ATOMIC under > rcu_read_lock > > On Tue, Jan 29, 2019 at 07:08:42

答复: [PATCH][V5] tty: fix race between flush_to_ldisc and tty_open

2019-01-31 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Greg Kroah-Hartman > 发送时间: 2019年1月31日 18:55 > 收件人: Li,Rongqing > 抄送: linux-ser...@vger.kernel.org; linux-kernel@vger.kernel.org; > jsl...@suse.com; gko...@codeaurora

[PATCH][V5] tty: fix race between flush_to_ldisc and tty_open

2019-01-31 Thread Li RongQing
when receiving, and return if tty->driver_data is NULL, and n_tty_receive_buf_common maybe calls uart_unthrottle, so add the same check Signed-off-by: Wang Li Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- V5: move check into uart_start from n_tty_receive_buf_common V4: add version inf

答复: 答复: 答复: [PATCH][v4] tty: fix race between flush_to_ldisc and tty_open

2019-01-30 Thread Li,Rongqing
> -邮件原件- > 发件人: Greg KH [mailto:gre...@linuxfoundation.org] > 发送时间: 2019年1月31日 14:52 > 收件人: Li,Rongqing > 抄送: jsl...@suse.com; linux-kernel@vger.kernel.org; gko...@codeaurora.org; > linux-ser...@vger.kernel.org > 主题: Re: 答复: 答复: [PATCH][v4] tty: fix race b

答复: 答复: [PATCH][v4] tty: fix race between flush_to_ldisc and tty_open

2019-01-30 Thread Li,Rongqing
> -邮件原件- > 发件人: Greg KH [mailto:gre...@linuxfoundation.org] > 发送时间: 2019年1月30日 21:17 > 收件人: Li,Rongqing > 抄送: jsl...@suse.com; linux-kernel@vger.kernel.org; gko...@codeaurora.org; > linux-ser...@vger.kernel.org > 主题: Re: 答复: [PATCH][v4] tty: fix race between flush_

答复: [PATCH][v4] tty: fix race between flush_to_ldisc and tty_open

2019-01-30 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Greg KH > 发送时间: 2019年1月30日 18:19 > 收件人: Li,Rongqing > 抄送: jsl...@suse.com; linux-kernel@vger.kernel.org; gko...@codeaurora.org > 主题: Re: [PATCH][v4] tty: fix race b

答复: [PATCH][v4] tty: fix race between flush_to_ldisc and tty_open

2019-01-30 Thread Li,Rongqing
> -邮件原件- > 发件人: Kohli, Gaurav [mailto:gko...@codeaurora.org] > 发送时间: 2019年1月18日 20:51 > 收件人: Li,Rongqing ; gre...@linuxfoundation.org; > jsl...@suse.com; linux-kernel@vger.kernel.org > 主题: Re: [PATCH][v4] tty: fix race between flush_to_ldisc and tty_open > > &

[PATCH] XArray tests: allocation has to be GFP_ATOMIC under rcu_read_lock

2019-01-29 Thread Li RongQing
Signed-off-by: Li RongQing --- lib/test_xarray.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/test_xarray.c b/lib/test_xarray.c index c596a957f764..5b671c83b73d 100644 --- a/lib/test_xarray.c +++ b/lib/test_xarray.c @@ -108,7 +108,7 @@ static noinline void

[PATCH][v4] tty: fix race between flush_to_ldisc and tty_open

2019-01-18 Thread Li RongQing
when receiving, and return if tty->driver_data is NULL Signed-off-by: Wang Li Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- V4: add version information V3: not used ldisc semaphore lock, only checking tty->driver_data with NULL V2: fix building error by EXPORT_SYMBOL tty_ldisc

[PATCH][v3] tty: fix race between flush_to_ldisc and tty_open

2019-01-18 Thread Li RongQing
when receiving, and return if tty->driver_data is NULL Signed-off-by: Wang Li Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- drivers/tty/tty_port.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/tty/tty_port.c b/drivers/tty/tty_port.c index 044c3cbdcfa4..86d0bec3832

答复: [PATCH][v2] tty: fix race between flush_to_ldisc and tty_open

2019-01-13 Thread Li,Rongqing
> -邮件原件- > 发件人: Kohli, Gaurav [mailto:gko...@codeaurora.org] > 发送时间: 2019年1月11日 21:57 > 收件人: Li,Rongqing ; linux-kernel@vger.kernel.org; > jsl...@suse.com; gre...@linuxfoundation.org; a...@linux.intel.com > 主题: Re: [PATCH][v2] tty: fix race between flush_to_ldisc an

[PATCH][V2][resend] tty: fix race between flush_to_ldisc and tty_open

2019-01-10 Thread Li RongQing
uart_start /*tty->driver_data is NULL*/ tty->ops->open /*init tty->driver_data*/ Extending ldisc semaphore lock in tty_init_dev to driver_data initialized completely after tty->ops->open(). Signed-off-

[PATCH][v2] tty: fix race between flush_to_ldisc and tty_open

2018-12-23 Thread Li RongQing
t /*tty->driver_data is NULL*/ tty->ops->open /*init tty->driver_data*/ Extending ldisc semaphore lock in tty_init_dev to driver_data initialized completely after tty->ops->open(). Signed-off-by: Zhang

[PATCH] tty: fix race between flush_to_ldisc and tty_open

2018-12-21 Thread Li RongQing
rt Extending ldisc semaphore lock in tty_init_dev till driver_data initializes completely after tty->ops->open(). Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- we see this bug in centos 7.4, and think b027e2298bd588 can not fix it, since driver_data is NULL; the trace is that:

[PATCH] memcg: remove congestion wait when force empty

2018-09-12 Thread Li RongQing
of isolated page, so remove this wait to reduce unnecessary delay Signed-off-by: Li RongQing --- mm/memcontrol.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 4ead5a4817de..35bd43eaa97e 100644 --- a/mm/memcontrol.c +++ b/mm

[PATCH] memcg: remove congestion wait when force empty

2018-09-12 Thread Li RongQing
of isolated page, so remove this wait to reduce unnecessary delay Signed-off-by: Li RongQing --- mm/memcontrol.c | 6 +- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/mm/memcontrol.c b/mm/memcontrol.c index 4ead5a4817de..35bd43eaa97e 100644 --- a/mm/memcontrol.c +++ b/mm

[PATCH] mm: introduce kvvirt_to_page() helper

2018-08-16 Thread Li RongQing
The new helper returns address mapping page, which has several users in individual subsystem, like mem_to_page in xfs_buf.c and pgv_to_page in af_packet.c, after this, they can be unified Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- include/linux/mm.h | 8 1 file changed, 8

[PATCH] mm: introduce kvvirt_to_page() helper

2018-08-16 Thread Li RongQing
The new helper returns address mapping page, which has several users in individual subsystem, like mem_to_page in xfs_buf.c and pgv_to_page in af_packet.c, after this, they can be unified Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- include/linux/mm.h | 8 1 file changed, 8

[PATCH 1/2] mm: add a function to return a bdi_writeback dirty page statistic

2018-08-01 Thread Li RongQing
this is a preparation to optimise a full writeback when reclaim memory Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- include/linux/memcontrol.h | 2 +- mm/memcontrol.c| 6 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/include/linux/memcontrol.h b

[PATCH 1/2] mm: add a function to return a bdi_writeback dirty page statistic

2018-08-01 Thread Li RongQing
this is a preparation to optimise a full writeback when reclaim memory Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- include/linux/memcontrol.h | 2 +- mm/memcontrol.c| 6 ++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/include/linux/memcontrol.h b

[PATCH 2/2] fs/writeback: do memory cgroup related writeback firstly

2018-08-01 Thread Li RongQing
since when hadoop reclaims memory, it will wake all memory cgroup writeback. Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- fs/fs-writeback.c | 31 +++ 1 file changed, 31 insertions(+) diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index 471d86

[PATCH 2/2] fs/writeback: do memory cgroup related writeback firstly

2018-08-01 Thread Li RongQing
since when hadoop reclaims memory, it will wake all memory cgroup writeback. Signed-off-by: Zhang Yu Signed-off-by: Li RongQing --- fs/fs-writeback.c | 31 +++ 1 file changed, 31 insertions(+) diff --git a/fs/fs-writeback.c b/fs/fs-writeback.c index 471d86

[PATCH] x86/acpi: fix the comments in acpi_parse_lapic

2018-06-07 Thread Li RongQing
This should be permit to preallocate memory for all NR_CPUS Signed-off-by: Li RongQing --- arch/x86/kernel/acpi/boot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index 3b20607d581b..8ae88605a5eb 100644

[PATCH] x86/acpi: fix the comments in acpi_parse_lapic

2018-06-07 Thread Li RongQing
This should be permit to preallocate memory for all NR_CPUS Signed-off-by: Li RongQing --- arch/x86/kernel/acpi/boot.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/x86/kernel/acpi/boot.c b/arch/x86/kernel/acpi/boot.c index 3b20607d581b..8ae88605a5eb 100644

[PATCH] sched/fair: remove stale comments about tg_unthrottle_up

2018-04-10 Thread Li RongQing
After commit 82958366cfea ("sched: Replace update_shares weight distribution with per-entity computation"), tg_unthrottle_up did not update the weight Signed-off-by: Li RongQing <lirongq...@baidu.com> --- kernel/sched/fair.c | 1 - 1 file changed, 1 deletion(-) diff --git a/ker

[PATCH] sched/fair: remove stale comments about tg_unthrottle_up

2018-04-10 Thread Li RongQing
After commit 82958366cfea ("sched: Replace update_shares weight distribution with per-entity computation"), tg_unthrottle_up did not update the weight Signed-off-by: Li RongQing --- kernel/sched/fair.c | 1 - 1 file changed, 1 deletion(-) diff --git a/kernel/sched/fair.c b/kernel/sc

[tip:x86/urgent] x86/apic: Fix signedness bug in APIC ID validity checks

2018-04-10 Thread tip-bot for Li RongQing
Commit-ID: a774635db5c430cbf21fa5d2f2df3d23aaa8e782 Gitweb: https://git.kernel.org/tip/a774635db5c430cbf21fa5d2f2df3d23aaa8e782 Author: Li RongQing <lirongq...@baidu.com> AuthorDate: Tue, 10 Apr 2018 09:16:06 +0800 Committer: Thomas Gleixner <t...@linutronix.de> CommitDate:

[tip:x86/urgent] x86/apic: Fix signedness bug in APIC ID validity checks

2018-04-10 Thread tip-bot for Li RongQing
Commit-ID: a774635db5c430cbf21fa5d2f2df3d23aaa8e782 Gitweb: https://git.kernel.org/tip/a774635db5c430cbf21fa5d2f2df3d23aaa8e782 Author: Li RongQing AuthorDate: Tue, 10 Apr 2018 09:16:06 +0800 Committer: Thomas Gleixner CommitDate: Tue, 10 Apr 2018 16:46:39 +0200 x86/apic: Fix

[tip:x86/urgent] x86/apic: Fix signedness bug in APIC ID validity checks

2018-04-10 Thread tip-bot for Li RongQing
Commit-ID: 57e95bee9f89560c5952409be8b41a4a2b7e384c Gitweb: https://git.kernel.org/tip/57e95bee9f89560c5952409be8b41a4a2b7e384c Author: Li RongQing <lirongq...@baidu.com> AuthorDate: Tue, 10 Apr 2018 09:16:06 +0800 Committer: Thomas Gleixner <t...@linutronix.de> CommitDate:

[tip:x86/urgent] x86/apic: Fix signedness bug in APIC ID validity checks

2018-04-10 Thread tip-bot for Li RongQing
Commit-ID: 57e95bee9f89560c5952409be8b41a4a2b7e384c Gitweb: https://git.kernel.org/tip/57e95bee9f89560c5952409be8b41a4a2b7e384c Author: Li RongQing AuthorDate: Tue, 10 Apr 2018 09:16:06 +0800 Committer: Thomas Gleixner CommitDate: Tue, 10 Apr 2018 16:33:21 +0200 x86/apic: Fix

[PATCH][V2] x86/acpi: Prevent all the X2APIC Id from being parsed in non-x2apic mode

2018-04-09 Thread Li RongQing
accounted This fixes a bug that some Purley platform displays many possible cpu Signed-off-by: Li RongQing <lirongq...@baidu.com> Cc: Dou Liyang <douly.f...@cn.fujitsu.com> Cc: Peter Zijlstra <pet...@infradead.org> Cc: Thomas Gleixner <t...@linutronix.de> --- arch/x86/include/

[PATCH][V2] x86/acpi: Prevent all the X2APIC Id from being parsed in non-x2apic mode

2018-04-09 Thread Li RongQing
accounted This fixes a bug that some Purley platform displays many possible cpu Signed-off-by: Li RongQing Cc: Dou Liyang Cc: Peter Zijlstra Cc: Thomas Gleixner --- arch/x86/include/asm/apic.h | 4 ++-- arch/x86/kernel/acpi/boot.c | 13 - arch/x86/kernel/apic

答复: 答复: [RFC PATCH] x86/acpi: Prevent x2apic id -1 from being accounted

2018-04-09 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org [mailto:linux-kernel- > ow...@vger.kernel.org] 代表 Dou Liyang > 发送时间: 2018年4月9日 16:47 > 收件人: Li,Rongqing <lirongq...@baidu.com>; linux-kernel@vger.kernel.org; > t...@linutronix.de; mi...@redhat.com; h...@zytor.c

答复: 答复: [RFC PATCH] x86/acpi: Prevent x2apic id -1 from being accounted

2018-04-09 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org [mailto:linux-kernel- > ow...@vger.kernel.org] 代表 Dou Liyang > 发送时间: 2018年4月9日 16:47 > 收件人: Li,Rongqing ; linux-kernel@vger.kernel.org; > t...@linutronix.de; mi...@redhat.com; h...@zytor.com; jgr...@suse.com; >

[RFC PATCH] x86/acpi: Prevent x2apic id -1 from being accounted

2018-04-08 Thread Li RongQing
too many possible cpu Signed-off-by: Li RongQing <lirongq...@baidu.com> Cc: Peter Zijlstra <pet...@infradead.org> Cc: Thomas Gleixner <t...@linutronix.de> Cc: Dou Liyang <douly.f...@cn.fujitsu.com> --- arch/x86/include/asm/apic.h | 4 ++-- arch/x86/kernel/a

[RFC PATCH] x86/acpi: Prevent x2apic id -1 from being accounted

2018-04-08 Thread Li RongQing
too many possible cpu Signed-off-by: Li RongQing Cc: Peter Zijlstra Cc: Thomas Gleixner Cc: Dou Liyang --- arch/x86/include/asm/apic.h | 4 ++-- arch/x86/kernel/acpi/boot.c | 10 ++ arch/x86/kernel/apic/apic_common.c | 2 +- arch/x86/kernel/apic/apic_numachip.c

re: [PATCH] mm: avoid the unnecessary waiting when force empty a cgroup

2018-04-03 Thread Li,Rongqing
> -邮件原件- > 发件人: Michal Hocko [mailto:mho...@kernel.org] > 发送时间: 2018年4月3日 16:05 > 收件人: Li,Rongqing <lirongq...@baidu.com> > 抄送: han...@cmpxchg.org; vdavydov@gmail.com; > cgro...@vger.kernel.org; linux...@kvack.org; > linux-kernel@vger.kernel.org

re: [PATCH] mm: avoid the unnecessary waiting when force empty a cgroup

2018-04-03 Thread Li,Rongqing
> -邮件原件- > 发件人: Michal Hocko [mailto:mho...@kernel.org] > 发送时间: 2018年4月3日 16:05 > 收件人: Li,Rongqing > 抄送: han...@cmpxchg.org; vdavydov@gmail.com; > cgro...@vger.kernel.org; linux...@kvack.org; > linux-kernel@vger.kernel.org > 主题: Re: [PATCH] mm: avoid the

[PATCH] mm: avoid the unnecessary waiting when force empty a cgroup

2018-04-03 Thread Li RongQing
The number of writeback and dirty page can be read out from memcg, the unnecessary waiting can be avoided by these counts Signed-off-by: Li RongQing <lirongq...@baidu.com> --- mm/memcontrol.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/mm/memcontrol.

[PATCH] mm: avoid the unnecessary waiting when force empty a cgroup

2018-04-03 Thread Li RongQing
The number of writeback and dirty page can be read out from memcg, the unnecessary waiting can be avoided by these counts Signed-off-by: Li RongQing --- mm/memcontrol.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/mm/memcontrol.c b/mm/memcontrol.c index

[PATCH] genirq: only scan the present CPUs

2018-04-01 Thread Li RongQing
on Purley platform which has 56 present CPUs, and 224 possible CPUs Signed-off-by: Li RongQing <lirongq...@baidu.com> --- kernel/irq/irqdesc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/irq/irqdesc.c b/kernel/irq/irqdesc.c index 49b54e9979cc..8f489b73733e

[PATCH] genirq: only scan the present CPUs

2018-04-01 Thread Li RongQing
on Purley platform which has 56 present CPUs, and 224 possible CPUs Signed-off-by: Li RongQing --- kernel/irq/irqdesc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/kernel/irq/irqdesc.c b/kernel/irq/irqdesc.c index 49b54e9979cc..8f489b73733e 100644 --- a/kernel/irq

[PATCH] mm: limit a process RSS

2018-03-29 Thread Li RongQing
we cannot limit a process RSS although there is ulimit -m, not sure why and when ulimit -m is not working, make it work similar requirement: https://stackoverflow.com/questions/3360348/why-ulimit-cant-limit-resident-memory-successfully-and-how Signed-off-by: Li RongQing <lirongq...@baidu.

[PATCH] mm: limit a process RSS

2018-03-29 Thread Li RongQing
we cannot limit a process RSS although there is ulimit -m, not sure why and when ulimit -m is not working, make it work similar requirement: https://stackoverflow.com/questions/3360348/why-ulimit-cant-limit-resident-memory-successfully-and-how Signed-off-by: Li RongQing --- mm/memory.c | 14

[PATCH] mm/list_lru: replace spinlock with RCU in __list_lru_count_one

2018-03-27 Thread Li RongQing
echo 1 >/cgroup/memory/test/memory.limit_in_bytes Before: 0m0.415s ===> after: 0m0.395s Signed-off-by: Li RongQing <lirongq...@baidu.com> --- include/linux/list_lru.h | 2 ++ mm/list_lru.c| 69 ++-- 2 files changed, 5

[PATCH] mm/list_lru: replace spinlock with RCU in __list_lru_count_one

2018-03-27 Thread Li RongQing
echo 1 >/cgroup/memory/test/memory.limit_in_bytes Before: 0m0.415s ===> after: 0m0.395s Signed-off-by: Li RongQing --- include/linux/list_lru.h | 2 ++ mm/list_lru.c| 69 ++-- 2 files changed, 51 insertions(+), 20 deletions(-)

答复: 答复: 答复: [PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-23 Thread Li,Rongqing
> -邮件原件- > 发件人: Michal Hocko [mailto:mho...@kernel.org] > 发送时间: 2018年3月23日 18:09 > 收件人: Li,Rongqing <lirongq...@baidu.com> > 抄送: linux-kernel@vger.kernel.org; linux...@kvack.org; > cgro...@vger.kernel.org; han...@cmpxchg.org; Andrey Ryabinin > <aryabi...@v

答复: 答复: 答复: [PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-23 Thread Li,Rongqing
> -邮件原件- > 发件人: Michal Hocko [mailto:mho...@kernel.org] > 发送时间: 2018年3月23日 18:09 > 收件人: Li,Rongqing > 抄送: linux-kernel@vger.kernel.org; linux...@kvack.org; > cgro...@vger.kernel.org; han...@cmpxchg.org; Andrey Ryabinin > > 主题: Re: 答复: 答复: [PATCH] mm/memcont

答复: 答复: [PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-22 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Li,Rongqing > 发送时间: 2018年3月19日 18:52 > 收件人: Michal Hocko <mho...@kernel.org> > 抄送: linux-kernel@vger.kernel.org; linux...@kvack.org; > cgro...@vger.kernel.org;

答复: 答复: [PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-22 Thread Li,Rongqing
> -邮件原件- > 发件人: linux-kernel-ow...@vger.kernel.org > [mailto:linux-kernel-ow...@vger.kernel.org] 代表 Li,Rongqing > 发送时间: 2018年3月19日 18:52 > 收件人: Michal Hocko > 抄送: linux-kernel@vger.kernel.org; linux...@kvack.org; > cgro...@vger.kernel.org; han...@cmpxchg.org; Andrey

答复: 答复: [PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-19 Thread Li,Rongqing
> -邮件原件- > 发件人: Michal Hocko [mailto:mho...@kernel.org] > 发送时间: 2018年3月19日 18:38 > 收件人: Li,Rongqing <lirongq...@baidu.com> > 抄送: linux-kernel@vger.kernel.org; linux...@kvack.org; > cgro...@vger.kernel.org; han...@cmpxchg.org; Andrey Ryabinin > <aryabi.

答复: 答复: [PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-19 Thread Li,Rongqing
> -邮件原件- > 发件人: Michal Hocko [mailto:mho...@kernel.org] > 发送时间: 2018年3月19日 18:38 > 收件人: Li,Rongqing > 抄送: linux-kernel@vger.kernel.org; linux...@kvack.org; > cgro...@vger.kernel.org; han...@cmpxchg.org; Andrey Ryabinin > > 主题: Re: 答复: [PATCH] mm/memcontrol.c:

[PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-19 Thread Li RongQing
test show: $dd if=aaa of=bbb bs=1k count=3886080 $rm -f bbb $time echo 1 >/cgroup/memory/test/memory.limit_in_bytes Before: 0m0.252s ===> after: 0m0.178s Signed-off-by: Li RongQing <lirongq...@baidu.com> --- mm/memcontrol.c | 4 ++-- 1 file changed, 2 insertions(+),

[PATCH] mm/memcontrol.c: speed up to force empty a memory cgroup

2018-03-19 Thread Li RongQing
test show: $dd if=aaa of=bbb bs=1k count=3886080 $rm -f bbb $time echo 1 >/cgroup/memory/test/memory.limit_in_bytes Before: 0m0.252s ===> after: 0m0.178s Signed-off-by: Li RongQing --- mm/memcontrol.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --gi

[tip:x86/urgent] Documentation, x86, resctrl: Make text and sample command match

2018-02-28 Thread tip-bot for Li RongQing
Commit-ID: 30009746168da0f1f648881f77083c40e226a8a0 Gitweb: https://git.kernel.org/tip/30009746168da0f1f648881f77083c40e226a8a0 Author: Li RongQing <lirongq...@baidu.com> AuthorDate: Tue, 27 Feb 2018 14:17:51 +0800 Committer: Thomas Gleixner <t...@linutronix.de> CommitDate:

[tip:x86/urgent] Documentation, x86, resctrl: Make text and sample command match

2018-02-28 Thread tip-bot for Li RongQing
Commit-ID: 30009746168da0f1f648881f77083c40e226a8a0 Gitweb: https://git.kernel.org/tip/30009746168da0f1f648881f77083c40e226a8a0 Author: Li RongQing AuthorDate: Tue, 27 Feb 2018 14:17:51 +0800 Committer: Thomas Gleixner CommitDate: Wed, 28 Feb 2018 19:59:05 +0100 Documentation, x86

[PATCH] Documentation: fix the wrong path in intel_rdt_ui.txt

2018-02-26 Thread Li RongQing
the note says "Move the cpus 4-7 over to p1", but echo command writes f0 to p0/cpus Signed-off-by: Li RongQing <lirongq...@baidu.com> Cc: Fenghua Yu <fenghua...@intel.com> --- Documentation/x86/intel_rdt_ui.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --g

[PATCH] Documentation: fix the wrong path in intel_rdt_ui.txt

2018-02-26 Thread Li RongQing
the note says "Move the cpus 4-7 over to p1", but echo command writes f0 to p0/cpus Signed-off-by: Li RongQing Cc: Fenghua Yu --- Documentation/x86/intel_rdt_ui.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Documentation/x86/intel_rdt_ui.txt b/Documen

Re: high latency in CFS when disable autogroup, bug or not?

2017-10-23 Thread Li RongQing
wakeup_preempt_entity(cfs_rq->last, left) < 1) se = cfs_rq->last; /* * Someone really wants this to run. If it's not unfair, run it. */ if (cfs_rq->next && wakeup_preempt_entity(cfs_rq->next, left) < 1) se = cfs_rq->next; clea

Re: high latency in CFS when disable autogroup, bug or not?

2017-10-23 Thread Li RongQing
wakeup_preempt_entity(cfs_rq->last, left) < 1) se = cfs_rq->last; /* * Someone really wants this to run. If it's not unfair, run it. */ if (cfs_rq->next && wakeup_preempt_entity(cfs_rq->next, left) < 1) se = cfs_rq->next; clea

high latency in CFS when disable autogroup, bug or not?

2017-08-31 Thread Li RongQing
I have a programe to test CFS latency or fairness on high load, the test shows CFS has high latency when disable autogroup the program is in https://gist.github.com/anonymous/af21ae289cfa5c6310eeac73b7a478ff. the programe creates many threads, every thread does thing like: do { now

  1   2   >