[PATCH] thunderbolt: fix a missing check of kmemdup

2019-03-13 Thread Kangjie Lu
kmemdup may fail and return NULL. The fix adds a check and returns NULL in case it fails to avoid NULL pointer dereferecen. Signed-off-by: Kangjie Lu --- drivers/thunderbolt/property.c | 4 1 file changed, 4 insertions(+) diff --git a/drivers/thunderbolt/property.c b/drivers/thunderbolt/pr

Re: [PATCH 1/2] cifs: remove unused status severity defines

2019-03-13 Thread Steve French
Since this file (smb2status.h) is intended to track the official protocol documentation (albeit smb2status.h probably needs to be updated), in this case the protocol document MS-ERREF. I would prefer to keep it closer to MS-ERREF and leave definitions in even if unused (if nothing else it helps so

Re: [PATCH 3/3] RISC-V: Allow booting kernel from any 4KB aligned address

2019-03-13 Thread Mike Rapoport
On Thu, Mar 14, 2019 at 02:36:01AM +0530, Anup Patel wrote: > On Thu, Mar 14, 2019 at 12:01 AM Mike Rapoport wrote: > > > > On Tue, Mar 12, 2019 at 10:08:22PM +, Anup Patel wrote: > > > Currently, we have to boot RISCV64 kernel from a 2MB aligned physical > > > address and RISCV32 kernel from

[PATCH] kvm/x86/vmx: switch MSR_MISC_FEATURES_ENABLES between host and guest

2019-03-13 Thread Xiaoyao Li
CPUID Faulting is a feature about CPUID instruction. When CPUID Faulting is enabled, all execution of the CPUID instruction outside system-management mode (SMM) cause a general-protection (#GP) if the CPL > 0. About this feature, detailed information can be found at https://www.intel.com/content/d

[PATCH] greybus: audio_manager: fix a missing check of ida_simple_get

2019-03-13 Thread Kangjie Lu
ida_simple_get could fail. The fix inserts a check for its return value. Signed-off-by: Kangjie Lu --- drivers/staging/greybus/audio_manager.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/staging/greybus/audio_manager.c b/drivers/staging/greybus/audio_manager.c index d44b070d8

[PATCH 2/7] ARM: smp: Update cpufreq transition notifier to handle multiple CPUs

2019-03-13 Thread Viresh Kumar
The cpufreq core currently calls the cpufreq transition notifier callback once for each affected CPU. This is going to change soon and the cpufreq core will call the callback only once for each cpufreq policy. The callback must look at the newly added field in struct cpufreq_freqs, "cpus", which co

[PATCH 5/7] x86/tsc: Update cpufreq transition notifier to handle multiple CPUs

2019-03-13 Thread Viresh Kumar
The cpufreq core currently calls the cpufreq transition notifier callback once for each affected CPU. This is going to change soon and the cpufreq core will call the callback only once for each cpufreq policy. The callback must look at the newly added field in struct cpufreq_freqs, "cpus", which co

[PATCH 6/7] KVM: x86: Update cpufreq transition notifier to handle multiple CPUs

2019-03-13 Thread Viresh Kumar
The cpufreq core currently calls the cpufreq transition notifier callback once for each affected CPU. This is going to change soon and the cpufreq core will call the callback only once for each cpufreq policy. The callback must look at the newly added field in struct cpufreq_freqs, "cpus", which co

[PATCH 7/7] cpufreq: Call transition notifiers only once for each policy

2019-03-13 Thread Viresh Kumar
Now that all the transition notifier callbacks are updated to not rely on freqs->cpu and perform actions for all CPUs in the freqs->cpus field, it is time to get rid of freqs->cpu field and call the notifiers only once for each cpufreq policy. Signed-off-by: Viresh Kumar --- drivers/cpufreq/cpuf

[PATCH 1/7] cpufreq: Pass policy->related_cpus to transition notifiers

2019-03-13 Thread Viresh Kumar
Currently we call these notifiers once for each CPU of the policy->cpus cpumask, which isn't that efficient. This patch adds a cpumask pointer to struct cpufreq_freqs and copies policy->related_cpus to it. The notifiers will have information about all the affected CPUs now with the first call itse

[PATCH 3/7] ARM: twd: Update cpufreq transition notifier to handle multiple CPUs

2019-03-13 Thread Viresh Kumar
The cpufreq core currently calls the cpufreq transition notifier callback once for each affected CPU. This is going to change soon and the cpufreq core will call the callback only once for each cpufreq policy. The callback must look at the newly added field in struct cpufreq_freqs, "cpus", which co

[PATCH 4/7] sparc64: Update cpufreq transition notifier to handle multiple CPUs

2019-03-13 Thread Viresh Kumar
The cpufreq core currently calls the cpufreq transition notifier callback once for each affected CPU. This is going to change soon and the cpufreq core will call the callback only once for each cpufreq policy. The callback must look at the newly added field in struct cpufreq_freqs, "cpus", which co

[PATCH 0/7] cpufreq: Call transition notifier only once for each policy

2019-03-13 Thread Viresh Kumar
Currently we call the cpufreq transition notifiers once for each CPU of the policy->cpus cpumask, which isn't that efficient. This patchset tries to simplify that by adding another field in struct cpufreq_freqs, cpus, so the callback has all the information available with a single call for each pol

[PATCH] spi: fix NULL pointer dereferences by checking dmaengine_prep_slave_sg

2019-03-13 Thread Kangjie Lu
In case dmaengine_prep_slave_sg fails, the fix returns to avoid NULL pointer dereference. Signed-off-by: Kangjie Lu --- drivers/spi/spi-s3c64xx.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/spi/spi-s3c64xx.c b/drivers/spi/spi-s3c64xx.c index 7b7151ec14c8..3a5f161ce558 100644 --

Re: [PATCH] mm/hotplug: fix notification in offline error path

2019-03-13 Thread Michal Hocko
On Wed 13-03-19 17:09:39, Qian Cai wrote: > When start_isolate_page_range() returned -EBUSY in __offline_pages(), it > calls memory_notify(MEM_CANCEL_OFFLINE, &arg) with an uninitialized > "arg". As the result, it triggers warnings below. Also, it is only > necessary to notify MEM_CANCEL_OFFLINE af

Re: [PATCH 2/4] OPP: Add support for parsing the interconnect bandwidth

2019-03-13 Thread Viresh Kumar
On 13-03-19, 11:00, Georgi Djakov wrote: > The OPP bindings now support bandwidth values, so add support to parse it > from device tree and store it into the new dev_pm_opp_icc_bw struct, which > is part of the dev_pm_opp. > > Also add and export the dev_pm_opp_set_path() and dev_pm_opp_put_path()

Re: [Qestion] Hit a WARN_ON_ONCE in try_to_unmap_one when runing syzkaller

2019-03-13 Thread Naoya Horiguchi
Hi, On Wed, Mar 13, 2019 at 12:03:20AM +0800, zhong jiang wrote: ... > > Minchan has changed the conditon check from BUG_ON to WARN_ON_ONCE in > try_to_unmap_one. > However, It is still an abnormal condition when PageSwapBacked is not equal > to PageSwapCache. > > But Is there any case it w

[PATCH V3 5/5] ARM: dts: imx7ulp-evk: Add backlight support

2019-03-13 Thread Anson Huang
This patch adds i.MX7ULP EVK board MIPI-DSI backlight support. Signed-off-by: Anson Huang --- No changes since V2. --- arch/arm/boot/dts/imx7ulp-evk.dts | 8 1 file changed, 8 insertions(+) diff --git a/arch/arm/boot/dts/imx7ulp-evk.dts b/arch/arm/boot/dts/imx7ulp-evk.dts index 3f5ea1

[PATCH V3 1/5] dt-bindings: pwm: Add i.MX TPM PWM binding

2019-03-13 Thread Anson Huang
Add i.MX TPM(Low Power Timer/Pulse Width Modulation Module) PWM binding. Signed-off-by: Anson Huang --- No changes since V2. --- Documentation/devicetree/bindings/pwm/imx-tpm-pwm.txt | 19 +++ 1 file changed, 19 insertions(+) create mode 100644 Documentation/devicetree/bindings/

[PATCH V3 3/5] ARM: imx_v6_v7_defconfig: Add TPM PWM support by default

2019-03-13 Thread Anson Huang
Select CONFIG_PWM_IMX_TPM by default to support i.MX7ULP TPM PWM. Signed-off-by: Anson Huang --- No changes since V2. --- arch/arm/configs/imx_v6_v7_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/configs/imx_v6_v7_defconfig b/arch/arm/configs/imx_v6_v7_defconfig index 55

[PATCH V3 2/5] pwm: Add i.MX TPM PWM driver support

2019-03-13 Thread Anson Huang
i.MX7ULP has TPM(Low Power Timer/Pulse Width Modulation Module) inside, add TPM PWM driver support. Signed-off-by: Anson Huang --- Changes since V2: - Add "IMX_" as prefix to macro define as TPM is already used; - Use macro define for channel registers address instead of calculati

[PATCH V3 4/5] ARM: dts: imx7ulp: Add pwm0 support

2019-03-13 Thread Anson Huang
Add i.MX7ULP EVK board PWM0 support. Signed-off-by: Anson Huang --- No changes since V2. --- arch/arm/boot/dts/imx7ulp-evk.dts | 12 arch/arm/boot/dts/imx7ulp.dtsi| 10 ++ 2 files changed, 22 insertions(+) diff --git a/arch/arm/boot/dts/imx7ulp-evk.dts b/arch/arm/boot/

[PATCH V3 0/5] Add i.MX7ULP EVK PWM backlight support

2019-03-13 Thread Anson Huang
i.MX7ULP EVK board has MIPI-DSI display, its backlight is supplied by TPM PWM module, this patch set enables i.MX7ULP TPM PWM driver support and also add backlight support for MIPI-DSI display. Anson Huang (5): dt-bindings: pwm: Add i.MX TPM PWM binding pwm: Add i.MX TPM PWM driver support A

Re: [PATCH] mm: fix a wrong flag in set_migratetype_isolate()

2019-03-13 Thread Michal Hocko
On Wed 13-03-19 17:25:07, Qian Cai wrote: > Due to has_unmovable_pages() takes an incorrect irqsave flag instead of > the isolation flag in set_migratetype_isolate(), it causes issues with > HWPOSION and error reporting where dump_page() is not called when there > is an unmoveable page. > > Fixes:

Re: [PATCH 1/4] dt-bindings: opp: Introduce opp-bw-MBs bindings

2019-03-13 Thread Viresh Kumar
On 13-03-19, 11:00, Georgi Djakov wrote: > In addition to frequency and voltage, some devices may have bandwidth > requirements for their interconnect throughput - for example a CPU > or GPU may also need to increase or decrease their bandwidth to DDR > memory based on the current operating perform

[PATCH 1/2] cifs: remove unused status severity defines

2019-03-13 Thread Sergey Senozhatsky
STATUS_SEVERITY_* do not appear to be used by anyone, so drop them. Besides, the name of __constant_cpu_to_le32() is misspelled there: __constanst_cpu_to_le32(). Signed-off-by: Sergey Senozhatsky --- fs/cifs/smb2status.h | 5 - 1 file changed, 5 deletions(-) diff --git a/fs/cifs/smb2status.

[PATCH] rapidio: fix a NULL pointer derefenrece when create_workqueue fails

2019-03-13 Thread Kangjie Lu
In case create_workqueue fails, the fix releases resources and returns -ENOMEM to avoid NULL pointer dereference. Signed-off-by: Kangjie Lu --- drivers/rapidio/rio_cm.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/rapidio/rio_cm.c b/drivers/rapidio/rio_cm.c index cf4582958

Re: [RFC][PATCH 00/16] sched: Core scheduling

2019-03-13 Thread Li, Aubrey
The original patch seems missing the following change for 32bit. Thanks, -Aubrey diff --git a/kernel/sched/cpuacct.c b/kernel/sched/cpuacct.c index 9fbb10383434..78de28ebc45d 100644 --- a/kernel/sched/cpuacct.c +++ b/kernel/sched/cpuacct.c @@ -111,7 +111,7 @@ static u64 cpuacct_cpuusage_read(stru

[PATCH] power: charger-manager: fix a potential NULL pointer dereference

2019-03-13 Thread Kangjie Lu
In case create_freezable_workqueue fails, the fix return -ENOMEM to avoid a potential NULL pointer dereference. Signed-off-by: Kangjie Lu --- drivers/power/supply/charger-manager.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/power/supply/charger-manager.c b/drivers/power/supp

[PATCH] pci: pcie-xilinx: fix a missing-check bug for __get_free_pages

2019-03-13 Thread Kangjie Lu
In case __get_free_pages fail, the fix returns to avoid NULL pointer dereference. Signed-off-by: Kangjie Lu --- drivers/pci/controller/pcie-xilinx.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/pci/controller/pcie-xilinx.c b/drivers/pci/controller/pcie-xilinx.c index 9bd1a35cd

[PATCH] pci: pci-tegra: fix a potential NULL pointer dereference

2019-03-13 Thread Kangjie Lu
In case __get_free_pages fails and returns NULL, the fix returns -ENOMEM and releases resources to avoid NULL pointer dereference. Signed-off-by: Kangjie Lu --- drivers/pci/controller/pci-tegra.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/drivers/pci/controller/pci-tegra.c b/driv

[PATCH] hyperv: a potential NULL pointer dereference

2019-03-13 Thread Kangjie Lu
In case alloc_page, the fix returns -ENOMEM to avoid the potential NULL pointer dereference. Signed-off-by: Kangjie Lu --- arch/x86/hyperv/hv_init.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/arch/x86/hyperv/hv_init.c b/arch/x86/hyperv/hv_init.c index 7abb09e2eeb8..

Re: [PATCH V3 07/10] mmc: tegra: add Tegra186 WAR for CQE

2019-03-13 Thread Ritesh Harjani
On 3/14/2019 3:15 AM, Sowjanya Komatineni wrote: Tegra186 CQHCI host has a known bug where CQHCI controller selects DATA_PRESENT_SELECT bit to 1 for DCMDs with R1B response type and since DCMD does not trigger any data transfer, DCMD task complete happens leaving the DATA FSM of host controller

[PATCH] infiniband: i40iw: fix potential NULL pointer dereferences

2019-03-13 Thread Kangjie Lu
alloc_ordered_workqueue may fail and return NULL. The fix captures the failure and handles it properly to avoid potential NULL pointer dereferences. Signed-off-by: Kangjie Lu --- V2: add return value to capture the error code drivers/infiniband/hw/i40iw/i40iw.h | 2 +- drivers/infiniband/

Re: [PATCH V3 06/10] mmc: cqhci: allow hosts to update dcmd cmd desc

2019-03-13 Thread Ritesh Harjani
On 3/14/2019 3:15 AM, Sowjanya Komatineni wrote: This patch adds update_dcmd_desc interface to cqhci_host_ops to allow hosts to update any of the DCMD task descriptor attributes and parameters. Tested-by: Jon Hunter Signed-off-by: Sowjanya Komatineni Thanks, Reviewed-by: Ritesh Harjani

[PATCH v3 7/7] mm: Remove stale comment from page struct

2019-03-13 Thread Tobin C. Harding
We now use the slab_list list_head instead of the lru list_head. This comment has become stale. Remove stale comment from page struct slab_list list_head. Reviewed-by: Roman Gushchin Acked-by: Christoph Lameter Signed-off-by: Tobin C. Harding --- include/linux/mm_types.h | 2 +- 1 file chang

[PATCH v3 4/7] slub: Add comments to endif pre-processor macros

2019-03-13 Thread Tobin C. Harding
SLUB allocator makes heavy use of ifdef/endif pre-processor macros. The pairing of these statements is at times hard to follow e.g. if the pair are further than a screen apart or if there are nested pairs. We can reduce cognitive load by adding a comment to the endif statement of form #ifd

[PATCH v3 0/7] mm: Use slab_list list_head instead of lru

2019-03-13 Thread Tobin C. Harding
Currently the slab allocators (ab)use the struct page 'lru' list_head. We have a list head for slab allocators to use, 'slab_list'. During v2 it was noted by Christoph that the SLOB allocator was reaching into a list_head, this version adds 2 patches to the front of the set to fix that. Clean up

[PATCH v3 1/7] list: Add function list_rotate_to_front()

2019-03-13 Thread Tobin C. Harding
Currently if we wish to rotate a list until a specific item is at the front of the list we can call list_move_tail(head, list). Note that the arguments are the reverse way to the usual use of list_move_tail(list, head). This is a hack, it depends on the developer knowing how the list_head operate

[PATCH v3 5/7] slub: Use slab_list instead of lru

2019-03-13 Thread Tobin C. Harding
Currently we use the page->lru list for maintaining lists of slabs. We have a list in the page structure (slab_list) that can be used for this purpose. Doing so makes the code cleaner since we are not overloading the lru list. Use the slab_list instead of the lru list for maintaining lists of sl

[PATCH v3 6/7] slab: Use slab_list instead of lru

2019-03-13 Thread Tobin C. Harding
Currently we use the page->lru list for maintaining lists of slabs. We have a list in the page structure (slab_list) that can be used for this purpose. Doing so makes the code cleaner since we are not overloading the lru list. Use the slab_list instead of the lru list for maintaining lists of sl

[PATCH v3 3/7] slob: Use slab_list instead of lru

2019-03-13 Thread Tobin C. Harding
Currently we use the page->lru list for maintaining lists of slabs. We have a list_head in the page structure (slab_list) that can be used for this purpose. Doing so makes the code cleaner since we are not overloading the lru list. The slab_list is part of a union within the page struct (include

[PATCH v3 2/7] slob: Respect list_head abstraction layer

2019-03-13 Thread Tobin C. Harding
Currently we reach inside the list_head. This is a violation of the layer of abstraction provided by the list_head. It makes the code fragile. More importantly it makes the code wicked hard to understand. The code logic is based on the page in which an allocation was made, we want to modify the

Re: [RFC][PATCH 00/16] sched: Core scheduling

2019-03-13 Thread Aubrey Li
On Thu, Mar 14, 2019 at 8:35 AM Tim Chen wrote: > >> > >> One more NULL pointer dereference: > >> > >> Mar 12 02:24:46 aubrey-ivb kernel: [ 201.916741] core sched enabled > >> [ 201.950203] BUG: unable to handle kernel NULL pointer dereference > >> at 0008 > >> [ 201.950254] ---

[PATCH v3] hid: logitech: check the return value of create_singlethread_workqueue

2019-03-13 Thread Kangjie Lu
create_singlethread_workqueue may fail and return NULL. The fix checks if it is NULL to avoid NULL pointer dereference. Also, the fix moves the call of create_singlethread_workqueue earlier to avoid resource-release issues. -- V3: do not introduce memory leaks. Signed-off-by: Kangjie Lu --- dri

Re: [PATCH v4] lib/string.c: implement a basic bcmp

2019-03-13 Thread Masahiro Yamada
On Thu, Mar 14, 2019 at 6:13 AM Nick Desaulniers wrote: > > A recent optimization in Clang (r355672) lowers comparisons of the > return value of memcmp against zero to comparisons of the return value > of bcmp against zero. This helps some platforms that implement bcmp > more efficiently than mem

[RFC PATCH v2 6/7] tracing: Use tracing error_log with probe events

2019-03-13 Thread Masami Hiramatsu
Use tracing error_log with probe events for logging error more precisely. This also makes all parse error returns -EINVAL (except for -ENOMEM), because user can see better error message in error_log file now. Signed-off-by: Masami Hiramatsu --- Changes in v2: - Update error message according t

[RFC PATCH v2 7/7] selftests/ftrace: Add error_log testcase for probe errors

2019-03-13 Thread Masami Hiramatsu
Add error_log testcase for error logs on probe events. This tests most of error cases and checks the error position is correct. Signed-off-by: Masami Hiramatsu --- Changes in v2: - Specify error position in command string by "^" - Clear error_log right before writing command - Add uprobe s

[RFC PATCH v2 5/7] tracing/probe: Verify alloc_trace_*probe() result

2019-03-13 Thread Masami Hiramatsu
Since alloc_trace_*probe() returns -EINVAL only if !event && !group, it should not happen in trace_*probe_create(). If we catch that case there is a bug. So use WARN_ON_ONCE() instead of pr_info(). Signed-off-by: Masami Hiramatsu --- kernel/trace/trace_kprobe.c |4 ++-- kernel/trace/trace_up

[RFC PATCH v2 2/7] tracing/probe: Check event name length correctly

2019-03-13 Thread Masami Hiramatsu
Ensure given name of event is not too long when parsing it, and fix to update event name offset correctly when the group name is given. For example, this makes probe event to check the "p:foo/" error case correctly. Signed-off-by: Masami Hiramatsu --- kernel/trace/trace_probe.c |8 +++-

[RFC PATCH v2 3/7] tracing/probe: Check the size of argument name and body

2019-03-13 Thread Masami Hiramatsu
Check the size of argument name and expression is not 0 and smaller than maximum length. Signed-off-by: Masami Hiramatsu --- kernel/trace/trace_probe.c |2 ++ kernel/trace/trace_probe.h |1 + 2 files changed, 3 insertions(+) diff --git a/kernel/trace/trace_probe.c b/kernel/trace/trace_p

[RFC PATCH v2 1/7] tracing/probe: Check maxactive error cases

2019-03-13 Thread Masami Hiramatsu
Check maxactive on kprobe error case, because maxactive is only for kretprobe, not for kprobe. Also, maxactive should not be 0, it should be at least 1. Signed-off-by: Masami Hiramatsu --- kernel/trace/trace_kprobe.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git

[RFC PATCH v2 4/7] tracing/probe: Check event/group naming rule at parsing

2019-03-13 Thread Masami Hiramatsu
Check event and group naming rule at parsing it instead of allocating probes. Signed-off-by: Masami Hiramatsu --- Changes in v2: - Update error message according to Steve's comment. --- kernel/trace/trace_kprobe.c |7 +-- kernel/trace/trace_probe.c |8 kernel/trace/trace

[RFC PATCH v2 0/7] tracing: Use common error_log with probe events

2019-03-13 Thread Masami Hiramatsu
Hi, Here is the 2nd version of using common error_log with probe events. Previous version is here. http://lkml.kernel.org/r/155248005229.10815.334731901778152247.stgit@devnote2 In this version, I've updated some error messages according to Steve's comment, adjust some error position, and update

Compiling error if CONFIG_CPU_SUP_INTEL is disabled

2019-03-13 Thread Alec Ari
If CONFIG_CPU_SUP_INTEL is disabled with either the 5.0.2 or 4.20.16 kernel, it errors out right away: In file included from arch/x86/events/amd/core.c:8: arch/x86/events/amd/../perf_event.h:1035:45: warning: ‘struct cpu_hw_event’ declared inside parameter list will not be visible outside of this

Re: [PATCH 0/3] userfaultfd: allow to forbid unprivileged users

2019-03-13 Thread Mike Kravetz
On 3/13/19 4:55 PM, Andrea Arcangeli wrote: > On Wed, Mar 13, 2019 at 01:01:40PM -0700, Mike Kravetz wrote: >> On 3/13/19 11:52 AM, Andrea Arcangeli wrote: >>> Unless somebody suggests a consistent way to make hugetlbfs "just >>> work" (like we could achieve clean with CRIU and KVM), I think Oracle

Re: [PATCH v2 4/5] slob: Use slab_list instead of lru

2019-03-13 Thread Tobin C. Harding
On Wed, Mar 13, 2019 at 07:05:02PM +, Christopher Lameter wrote: > On Wed, 13 Mar 2019, Tobin C. Harding wrote: > > > @@ -297,7 +297,7 @@ static void *slob_alloc(size_t size, gfp_t gfp, int > > align, int node) > > continue; > > > > /* Attempt to alloc */ > > -

[PATCH v2 1/1] initrd: move initrd_start calculate within linear mapping range check

2019-03-13 Thread pierre Kuo
in the previous case, initrd_start and initrd_end can be successfully returned either (base < memblock_start_of_DRAM()) or (base + size > memblock_start_of_DRAM() + linear_region_size). That means even linear mapping range check fail for initrd_start and initrd_end, it still can get virtual addres

Re: [PATCH v3 1/1] mm: introduce put_user_page*(), placeholder versions

2019-03-13 Thread John Hubbard
On 3/13/19 7:49 AM, Ira Weiny wrote: On Tue, Mar 12, 2019 at 05:38:55PM -0700, John Hubbard wrote: On 3/12/19 8:30 AM, Ira Weiny wrote: On Wed, Mar 06, 2019 at 03:54:55PM -0800, john.hubb...@gmail.com wrote: From: John Hubbard Introduces put_user_page(), which simply calls put_page(). This p

Re:Re:Re: Re:[PATCH 4.9 81/96] MIPS:Loongson: Introduce and use loongson_llsc_mb()

2019-03-13 Thread 陈华才
Hi, Greg, Patch for 4.9 (and below 4.9) is here: https://patchwork.linux-mips.org/patch/21375/ Huacai -- Original -- From: "陈华才"; Date: Thu, Mar 14, 2019 06:55 AM To: "gregkh"; Cc: "linux-kernel"; "stable"; "huangpei"; "Paul Burton"; "Ralf Baechle"; "ambro

Re: [PATCH v4] lib/string.c: implement a basic bcmp

2019-03-13 Thread Nathan Chancellor
On Wed, Mar 13, 2019 at 02:13:31PM -0700, Nick Desaulniers wrote: > A recent optimization in Clang (r355672) lowers comparisons of the > return value of memcmp against zero to comparisons of the return value > of bcmp against zero. This helps some platforms that implement bcmp > more efficiently t

Re: lib/test_overflow.c causes WARNING and tainted kernel

2019-03-13 Thread Kees Cook
Hi! On Wed, Mar 13, 2019 at 2:29 PM Randy Dunlap wrote: > > This is v5.0-11053-gebc551f2b8f9, MAR-12 around 4:00pm PT. > > In the first test_kmalloc() in test_overflow_allocation(): > > [54375.073895] test_overflow: ok: (s64)(0 << 63) == 0 > [54375.074228] WARNING: CPU: 2 PID: 5462 at ../mm/page_

Re: [PATCH v2 8/9] rtc: mt6397: fix alarm register overwrite

2019-03-13 Thread mtk14576
Hi, On Mon, 2019-03-11 at 13:50 -0700, Sean Wang wrote: > Hi, > > On Sun, Mar 10, 2019 at 8:49 PM Hsin-Hsiung Wang > wrote: > > > > From: Ran Bi > > > > Alarm registers high byte was reserved for other functions. > > This add mask in alarm registers operation functions. > > This also fix error

Re: [RFC PATCH 01/31] mm: migrate: Add exchange_pages to exchange two lists of pages.

2019-03-13 Thread Zi Yan
On 19 Feb 2019, at 20:38, Anshuman Khandual wrote: On 02/19/2019 06:26 PM, Matthew Wilcox wrote: On Tue, Feb 19, 2019 at 01:12:07PM +0530, Anshuman Khandual wrote: But the location of this temp page matters as well because you would like to saturate the inter node interface. It needs to be eit

Re: [LSF/MM TOPIC] Using XArray to manage the VMA

2019-03-13 Thread Matthew Wilcox
On Wed, Mar 13, 2019 at 02:06:03PM -0700, Davidlohr Bueso wrote: > On Wed, 13 Mar 2019, Laurent Dufour wrote: > > If this is not too late and if there is still place available, I would > > like to attend the MM track and propose a topic about using the XArray > > to replace the VMA's RB tree and li

Re: [PATCH] spi: mediatek: Attempt to address style issues in spi-mt7621.c

2019-03-13 Thread NeilBrown
On Thu, Mar 14 2019, Chuanhong Guo wrote: > Hi! > On Thu, Mar 14, 2019 at 6:14 AM NeilBrown wrote: >> >> [...] >> My only small concern is that this driver was backported to openwrt >> (4.14 based) and then reverted >> >> https://github.com/openwrt/openwrt/commit/749a29f76ca780d8df70a5163d43bbdc6

must hold the driver_input_lock in hid_debug_rdesc_show

2019-03-13 Thread He, Bo
we see the below kernel panic logs when run suspend resume test with usb mouse and usb keyboard connected. the scenario is the userspace call the hid_debug_rdesc_show to dump the input device while the device is removed. the patch hold the driver_input_lock to avoid the race. [ 5381.757295] selin

Re: [PATCH] spi: mediatek: Attempt to address style issues in spi-mt7621.c

2019-03-13 Thread Chuanhong Guo
Hi! On Thu, Mar 14, 2019 at 6:14 AM NeilBrown wrote: > > [...] > My only small concern is that this driver was backported to openwrt > (4.14 based) and then reverted > > https://github.com/openwrt/openwrt/commit/749a29f76ca780d8df70a5163d43bbdc6f13ba3f > > "This breaks some mt7621 devices." > > P

RE: [PATCH RESEND V2 1/4] dt-bindings: fsl: scu: add watchdog binding

2019-03-13 Thread Anson Huang
Hi, Rob Best Regards! Anson Huang > -Original Message- > From: Rob Herring [mailto:r...@kernel.org] > Sent: 2019年3月12日 5:26 > To: Aisheng Dong > Cc: Anson Huang ; Guenter Roeck us.net>; mark.rutl...@arm.com; ulf.hans...@linaro.org; he...@sntech.de; > catalin.mari...@arm.com; will.dea...

RE,

2019-03-13 Thread LUIS EDUARDO CEPEDA CABRERA
Hello, i have a deal for you, can we work together ?

Re: [PATCH 5/5] lib/list_sort: Optimize number of calls to comparison function

2019-03-13 Thread George Spelvin
On Thu, 14 Mar 2019 at 00:28:16 +0100, Rasmus Villemoes wrote: > On 05/03/2019 06.58, George Spelvin wrote: >> This patch avoids badly unbalanced merges on unlucky input sizes. >> It slightly increases the code size, but saves an average of 0.2*n >> calls to cmp(). >> > [snip] >> >> (I confess to

Re: [LKP] [ext4] fde872682e: fsmark.files_per_sec -38.0% regression

2019-03-13 Thread Huang, Ying
Theodore Ts'o writes: > On Wed, Mar 13, 2019 at 03:26:39PM +0800, huang ying wrote: >> > >> > >> > commit: fde872682e175743e0c3ef939c89e3c6008a1529 ("ext4: force inode >> > writes when nfsd calls commit_metadata()") >> > https://git.kernel.org/cgit/linux/kernel/git/torvalds/linux.git master >>

Re: [PATCH v3] lib/siphash.c: annotate implicit fall throughs

2019-03-13 Thread Joe Perches
On Wed, 2019-03-13 at 22:12 +0100, Mathieu Malaterre wrote: > There is a plan to build the kernel with -Wimplicit-fallthrough and > these places in the code produced warnings (W=1). Fix them up. > > This commit remove the following warnings: > > lib/siphash.c:71:12: warning: this statement may

Re: [PATCH v1 2/2] interconnect: qcom: Add tagging and wake/sleep support for sdm845

2019-03-13 Thread David Dai
On 3/8/2019 10:35 AM, Evan Green wrote: On Fri, Feb 8, 2019 at 9:22 AM Georgi Djakov wrote: From: David Dai Add support for wake and sleep commands by using a tag to indicate whether or not the aggregate and set requests are active only or dual context for a particular path. Signed-off-by:

(.text+0x79c): warning: Using 'getpwuid' in statically linked applications requires at runtime the shared libraries from the glibc version used for linking

2019-03-13 Thread kbuild test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master head: fa3d493f7a573b4e4e2538486e912093a0161c1b commit: 0053102a869f1b909904b1b85ac282e2744deaab um: Include sys/uio.h to have writev() date: 3 months ago config: um-allmodconfig (attached as .config) compiler: g

Re: [RFC][PATCH 00/16] sched: Core scheduling

2019-03-13 Thread Tim Chen
>> >> One more NULL pointer dereference: >> >> Mar 12 02:24:46 aubrey-ivb kernel: [ 201.916741] core sched enabled >> [ 201.950203] BUG: unable to handle kernel NULL pointer dereference >> at 0008 >> [ 201.950254] [ cut here ] >> [ 201.959045] #PF error: [n

Re: [PATCH v7 02/15] sched/core: uclamp: Enforce last task UCLAMP_MAX

2019-03-13 Thread Suren Baghdasaryan
On Wed, Mar 13, 2019 at 9:16 AM Patrick Bellasi wrote: > > On 13-Mar 15:12, Peter Zijlstra wrote: > > On Fri, Feb 08, 2019 at 10:05:41AM +, Patrick Bellasi wrote: > > > +static inline void uclamp_idle_reset(struct rq *rq, unsigned int > > > clamp_id, > > > +uns

Re: [PATCH 2/5] lib/sort: Use more efficient bottom-up heapsort variant

2019-03-13 Thread Rasmus Villemoes
On 14/03/2019 01.03, George Spelvin wrote: > On Wed, 13 Mar 2019 at 23:29:40 +0100, Rasmus Villemoes wrote: > >> Nice! > > Thank you. May I translate that into Acked-by? > Sort-of. I prefer first seeing the full rerolled series for context etc., even if (the important parts of) this patch woul

Re: [PATCH 2/5] lib/sort: Use more efficient bottom-up heapsort variant

2019-03-13 Thread George Spelvin
On Wed, 13 Mar 2019 at 23:29:40 +0100, Rasmus Villemoes wrote: > On 21/02/2019 09.21, George Spelvin wrote: >> +/** >> + * parent - given the offset of the child, find the offset of the parent. >> + * @i: the offset of the heap element whose parent is sought. Non-zero. >> + * @lsbit: a precomputed

Re: [PATCH v1] Bluetooth: hci_qca: Enable the ldisc for ROME for x86 platforms.

2019-03-13 Thread Matthias Kaehlcke
On Wed, Mar 13, 2019 at 05:43:14PM +0800, rjl...@codeaurora.org wrote: > 在 2019-03-12 23:52,Matthias Kaehlcke 写道: > > Hi Rocky, > > > > On Tue, Mar 12, 2019 at 05:01:59PM +0800, rjl...@codeaurora.org wrote: > > > 在 2019-03-09 02:52,Matthias Kaehlcke 写道: > > > > On Fri, Mar 08, 2019 at 10:43:14AM +

Re: [PATCH 0/3] userfaultfd: allow to forbid unprivileged users

2019-03-13 Thread Andrea Arcangeli
On Wed, Mar 13, 2019 at 01:01:40PM -0700, Mike Kravetz wrote: > On 3/13/19 11:52 AM, Andrea Arcangeli wrote: > > > > hugetlbfs is more complicated to detect, because even if you inherit > > it from fork(), the services that mounts the fs may be in a different > > container than the one that Oracle

[PATCH] Bluetooth: hci_qca: Fix crash with non-serdev devices

2019-03-13 Thread Matthias Kaehlcke
qca_set_baudrate() calls serdev_device_wait_until_sent() assuming that the HCI is always associated with a serdev device. This isn't true for ROME controllers instantiated through ldisc, where the call causes a crash due to a NULL pointer dereferentiation. Only call the function when we have a serd

Re: [PATCH 0/3] userfaultfd: allow to forbid unprivileged users

2019-03-13 Thread Andrea Arcangeli
Hi Paolo, On Wed, Mar 13, 2019 at 03:12:28PM -0400, Paolo Bonzini wrote: > > > On Wed, Mar 13, 2019 at 09:22:31AM +0100, Paolo Bonzini wrote: > > Unless somebody suggests a consistent way to make hugetlbfs "just > > work" (like we could achieve clean with CRIU and KVM), I think Oracle > > will ne

Re: INFO: rcu detected stall in sys_sendfile64 (2)

2019-03-13 Thread Eric Biggers
On Wed, Mar 13, 2019 at 07:43:38AM +0100, 'Dmitry Vyukov' via syzkaller-bugs wrote: > > Also, humans can sometimes find more simpler C reproducers from syzbot > > provided > > reproducers. It would be nice if syzbot can accept and use a user defined C > > reproducer for testing. > > It would be

[PATCH v2] MAINTAINERS: Add KVM selftests to existing KVM entry

2019-03-13 Thread Sean Christopherson
It's safe to assume Paolo and Radim are maintaining the KVM selftests given that the vast majority of commits have their SOBs. Play nice with get_maintainers and make it official. Signed-off-by: Sean Christopherson --- v2: add all KVM subdirectories MAINTAINERS | 2 ++ 1 file changed, 2 insert

Re: [PATCH 5/5] lib/list_sort: Optimize number of calls to comparison function

2019-03-13 Thread Rasmus Villemoes
On 05/03/2019 06.58, George Spelvin wrote: > CONFIG_RETPOLINE has severely degraded indirect function call > performance, so it's worth putting some effort into reducing > the number of times cmp() is called. > > This patch avoids badly unbalanced merges on unlucky input sizes. > It slightly incre

Re: [PATCHv8 07/10] acpi/hmat: Register processor domain to its memory

2019-03-13 Thread Rafael J. Wysocki
On Mon, Mar 11, 2019 at 9:55 PM Keith Busch wrote: > > If the HMAT Subsystem Address Range provides a valid processor proximity > domain for a memory domain, or a processor domain matches the performance > access of the valid processor proximity domain, register the memory > target with that initi

Re: Regression causes a hang on boot with a Comtrol PCI card

2019-03-13 Thread Bjorn Helgaas
Hi Jesse, On Wed, Mar 13, 2019 at 11:50:07AM -0500, Jesse Hathaway wrote: > Two regressions cause Linux to hang on boot when a Comtrol PCI card > is present. > > If I revert the following two commits, I can boot again and the card > operates without issue: > > 1302fcf0d03e (refs/bisect/bad) PCI:

Re: [RFC][Patch v9 2/6] KVM: Enables the kernel to isolate guest free pages

2019-03-13 Thread David Hildenbrand
On 13.03.19 23:54, Alexander Duyck wrote: > On Wed, Mar 13, 2019 at 9:39 AM David Hildenbrand wrote: >> >> On 13.03.19 17:37, Alexander Duyck wrote: >>> On Wed, Mar 13, 2019 at 5:18 AM David Hildenbrand wrote: On 13.03.19 12:54, Nitesh Narayan Lal wrote: > > On 3/12/19 5:13 PM,

Re: [PATCHv8 06/10] node: Add memory-side caching attributes

2019-03-13 Thread Rafael J. Wysocki
On Mon, Mar 11, 2019 at 9:55 PM Keith Busch wrote: > > System memory may have caches to help improve access speed to frequently > requested address ranges. While the system provided cache is transparent > to the software accessing these memory ranges, applications can optimize > their own access b

Re: [PATCH 1/5] lib/sort: Make swap functions more generic

2019-03-13 Thread George Spelvin
Thank you for your thoughtful comments! On Wed, 13 Mar 2019 at 23:23:44 +0100, Rasmus Villemoes wrote: > On 21/02/2019 07.30, George Spelvin wrote: > + * @align: required aignment (typically 4 or 8) > > typo aLignment Thanks; fixed! >> + * Returns true if elements can be copied using word loads

Re: [PATCHv8 05/10] node: Add heterogenous memory access attributes

2019-03-13 Thread Rafael J. Wysocki
On Mon, Mar 11, 2019 at 9:55 PM Keith Busch wrote: > > Heterogeneous memory systems provide memory nodes with different latency > and bandwidth performance attributes. Provide a new kernel interface > for subsystems to register the attributes under the memory target > node's initiator access class

Re: [PATCHv8 04/10] node: Link memory nodes to their compute nodes

2019-03-13 Thread Rafael J. Wysocki
On Mon, Mar 11, 2019 at 9:55 PM Keith Busch wrote: > > Systems may be constructed with various specialized nodes. Some nodes > may provide memory, some provide compute devices that access and use > that memory, and others may provide both. Nodes that provide memory are > referred to as memory targ

Re: [PATCH] percpu/module resevation: change resevation size iff X86_VSMP is set

2019-03-13 Thread Paul E. McKenney
On Wed, Mar 13, 2019 at 02:29:12PM -0700, Tejun Heo wrote: > Hello, > > On Wed, Mar 13, 2019 at 02:22:55PM -0700, Paul E. McKenney wrote: > > Should I define DEFINE_SRCU() and DEFINE_STATIC_SRCU() only if > > !defined(MODULE)? > > Yeah, that sounds like a great idea with comments explaining why i

Re: [PATCH] EDAC, {skx|i10nm}_edac: Fix randconfig build error

2019-03-13 Thread Luck, Tony
On Wed, Mar 06, 2019 at 09:15:13PM +0100, Arnd Bergmann wrote: > On Wed, Mar 6, 2019 at 6:58 PM Luck, Tony wrote: > > From: Qiuxu Zhuo > > > > This seems cleaner than adding all the EXPORTs to skx_common.c > > I also tried a build with the 0x8A152468-config.gz that Arnd > > supplied. > > It's st

Re: [PATCH 2/2] x86/mmap: handle worst-case heap randomization in mmap_base

2019-03-13 Thread Kees Cook
On Tue, Mar 12, 2019 at 10:33 AM Ali Saidi wrote: > > Increase mmap_base by the worst-case brk randomization so that > the stack and heap remain apart. > > In Linux 4.13 a change was committed that special cased the kernel ELF > loader when the loader is invoked directly (eab09532d400; binfmt_elf:

Re: overlayfs vs. fscrypt

2019-03-13 Thread Eric Biggers
On Wed, Mar 13, 2019 at 03:29:43PM -0700, James Bottomley wrote: > On Wed, 2019-03-13 at 15:13 -0700, Eric Biggers wrote: > > On Wed, Mar 13, 2019 at 02:04:29PM -0700, James Bottomley wrote: > > > On Wed, 2019-03-13 at 13:25 -0700, Eric Biggers wrote: > > > > On Wed, Mar 13, 2019 at 01:06:06PM -070

Re: [RFC][Patch v9 2/6] KVM: Enables the kernel to isolate guest free pages

2019-03-13 Thread Alexander Duyck
On Wed, Mar 13, 2019 at 9:39 AM David Hildenbrand wrote: > > On 13.03.19 17:37, Alexander Duyck wrote: > > On Wed, Mar 13, 2019 at 5:18 AM David Hildenbrand wrote: > >> > >> On 13.03.19 12:54, Nitesh Narayan Lal wrote: > >>> > >>> On 3/12/19 5:13 PM, Alexander Duyck wrote: > On Tue, Mar 12,

Re: [PATCH v3 1/1] mm: introduce put_user_page*(), placeholder versions

2019-03-13 Thread Ira Weiny
On Tue, Mar 12, 2019 at 05:38:55PM -0700, John Hubbard wrote: > On 3/12/19 8:30 AM, Ira Weiny wrote: > > On Wed, Mar 06, 2019 at 03:54:55PM -0800, john.hubb...@gmail.com wrote: > > > From: John Hubbard > > > > > > Introduces put_user_page(), which simply calls put_page(). > > > This provides a wa

Re: [RFC PATCH 4/7] tracing/probe: Check event/group naming rule at parsing

2019-03-13 Thread Masami Hiramatsu
On Wed, 13 Mar 2019 11:23:46 -0400 Steven Rostedt wrote: > On Thu, 14 Mar 2019 00:04:02 +0900 > Masami Hiramatsu wrote: > > > > > strlcpy(buf, event, slash - event + 1); > > > > + if (!is_good_name(buf)) { > > > > + pr_info("Group name must fo

  1   2   3   4   5   6   7   8   9   >