dw_mmc: IDMAC Invalidate cache after read

2018-11-20 Thread JABLONSKY Jan
CPU may not see most up-to-date and correct copy of DMA buffer, when internal DMA controller is in use. Problem appears on The Altera SoC FPGA (uses integrated DMA controller), during higher CPU and system memory load Signed-off-by: Jan Jablonsky --- drivers/mmc/host/dw_mmc.c | 3 +-- 1 file cha

perf tools: remove option --tail-synthesize ?

2018-11-20 Thread Song Liu
Hi, I found perf-record --tail-synthesize without --overwrite breaks symbols for perf-script, perf-report, etc. For example: [root@]# ~/perf record -ag --tail-synthesize -- sleep 1 [ perf record: Woken up 1 times to write data ] [ perf record: Captured and wrote 1.129 MB perf.data (3531 samples)

[PATCH 4/4] perf intel-pt/bts: fix potential NULL pointer dereference in intel_bts_process_auxtrace_info

2018-11-20 Thread Wen Yang
This patch fixes a possible null pointer dereference in intel_bts_process_auxtrace_info, detected by the semantic patch deref_null.cocci, with the following warning: ./tools/perf/util/intel-bts.c:921:32-49: ERROR: session -> itrace_synth_opts is NULL but dereferenced. Signed-off-by: Wen Yang Re

[PATCH 1/4] perf intel-pt: fix potential NULL pointer dereference in intel_pt_process_auxtrace_info

2018-11-20 Thread Wen Yang
This patch fixes a possible null pointer dereference in intel_pt_process_auxtrace_info, detected by the semantic patch deref_null.cocci, with the following warning: ./tools/perf/util/intel-pt.c:2579:32-49: ERROR: session -> itrace_synth_opts is NULL but dereferenced. Signed-off-by: Wen Yang Rev

Re: [PATCH v2] tee: optee: log message if dynamic shm is enabled

2018-11-20 Thread Jens Wiklander
Hi Victor, On Tue, Sep 11, 2018 at 06:09:02PM +0900, Victor Chong wrote: > When dynamic shared memory support is enabled in the OP-TEE Trusted > OS, it doesn't mean that the driver supports it, which can confuse > users during debugging. Log a message when dynamic shared memory is > enabled in the

Re: linux-next: manual merge of the mlx5-next tree with the rdma tree

2018-11-20 Thread Leon Romanovsky
On Wed, Nov 21, 2018 at 11:04:32AM +1100, Stephen Rothwell wrote: > Hi Leon, > > Today's linux-next merge of the mlx5-next tree got a conflict in: > > drivers/infiniband/hw/mlx5/main.c > > between commit: > > 9afc97c29b03 ("mlx5: remove support for ib_get_vector_affinity") > > from the rdma tre

Re: [RFC PATCH 3/3] mm, fault_around: do not take a reference to a locked page

2018-11-20 Thread Michal Hocko
On Tue 20-11-18 17:47:21, Hugh Dickins wrote: > On Tue, 20 Nov 2018, Michal Hocko wrote: > > > From: Michal Hocko > > > > filemap_map_pages takes a speculative reference to each page in the > > range before it tries to lock that page. While this is correct it > > also can influence page migratio

Re: [RFC PATCH 3/3] mm, fault_around: do not take a reference to a locked page

2018-11-20 Thread Michal Hocko
On Tue 20-11-18 21:51:39, William Kucharski wrote: > > > > On Nov 20, 2018, at 7:12 AM, Michal Hocko wrote: > > > > + /* > > +* Check the locked pages before taking a reference to not > > +* go in the way of migration. > > +*/ > > Could you make th

Re: [RFC PATCH 1/3] mm, proc: be more verbose about unstable VMA flags in /proc//smaps

2018-11-20 Thread Michal Hocko
On Tue 20-11-18 10:32:07, Dan Williams wrote: > On Tue, Nov 20, 2018 at 2:35 AM Michal Hocko wrote: > > > > From: Michal Hocko > > > > Even though vma flags exported via /proc//smaps are explicitly > > documented to be not guaranteed for future compatibility the warning > > doesn't go far enough

[PATCH] ARM: dts: imx6sll-evk: add debug LED support

2018-11-20 Thread Anson Huang
On i.MX6SLL EVK board, there is a debug LED controlled by MX6SLL_PAD_EPDC_VCOM1__GPIO2_IO04 pin, add support for it. Signed-off-by: Anson Huang --- arch/arm/boot/dts/imx6sll-evk.dts | 18 ++ 1 file changed, 18 insertions(+) diff --git a/arch/arm/boot/dts/imx6sll-evk.dts b/arch/

Re: Backed up kernels

2018-11-20 Thread Masahiro Yamada
Hi Jean, On Tue, Nov 20, 2018 at 10:40 PM Jean Delvare wrote: > > Hi Masahiro, Michal, > > When I run "make install", if a kernel by the same version number + > flavor string already exists, a backup is created with ".old" appended. > Over time, this adds many entries to my boot menu, makes some

Re: [RFC PATCH 1/3] mm, proc: be more verbose about unstable VMA flags in /proc//smaps

2018-11-20 Thread Michal Hocko
On Tue 20-11-18 16:01:47, David Rientjes wrote: > On Tue, 20 Nov 2018, Jan Kara wrote: > > > > Even though vma flags exported via /proc//smaps are explicitly > > > documented to be not guaranteed for future compatibility the warning > > > doesn't go far enough because it doesn't mention semantic c

Re: [PATCH 4/4] PM / Domains: Propagate performance state updates

2018-11-20 Thread Rajendra Nayak
On 11/21/2018 12:06 PM, Viresh Kumar wrote: On 21-11-18, 11:12, Rajendra Nayak wrote: And the reason for that seems to be that we update the genpd status to GPD_STATE_ACTIVE *after* we try to set the performance state, so we always hit this check which bails out thinking the genpd is not ON

Re: [PATCH v5] tpm: add support for partial reads

2018-11-20 Thread Jarkko Sakkinen
On Tue, Nov 20, 2018 at 03:13:59PM -0800, Tadeusz Struk wrote: > On 11/20/18 3:07 PM, Jarkko Sakkinen wrote: > +/* Holds the resul of the last successful call to > tpm_transmit() */ > >>> This comment is cruft. > >> Do you want me to remove it? This is the comment you proposed. >

Re: [PATCH 4/4] PM / Domains: Propagate performance state updates

2018-11-20 Thread Viresh Kumar
On 21-11-18, 11:12, Rajendra Nayak wrote: > And the reason for that seems to be that we update the genpd status to > GPD_STATE_ACTIVE > *after* we try to set the performance state, so we always hit this check > which bails out > thinking the genpd is not ON. Thanks for looking at it. Here is the

Re: [PATCH] x86: only use ERMS for user copies for larger sizes

2018-11-20 Thread Ingo Molnar
[ Cc:-ed a few other gents and lkml. ] * Jens Axboe wrote: > Hi, > > So this is a fun one... While I was doing the aio polled work, I noticed > that the submitting process spent a substantial amount of time copying > data to/from userspace. For aio, that's iocb and io_event, which are 64 > an

Re: [PATCH] thermal: tegra: add get_trend ops

2018-11-20 Thread Wei Ni
On 20/11/2018 11:38 PM, Thierry Reding wrote: > On Tue, Nov 20, 2018 at 05:11:17PM +0800, Wei Ni wrote: >> Add support for get_trend ops that allows soctherm >> sensors to be used with the step-wise governor. >> >> Signed-off-by: Wei Ni >> --- >> drivers/thermal/tegra/soctherm.c | 34 +

Re: [PATCH] modpost: validate symbol names also in find_elf_symbol

2018-11-20 Thread Masahiro Yamada
On Wed, Oct 24, 2018 at 7:15 AM Sami Tolvanen wrote: > > If an ARM mapping symbol shares an address with a valid symbol, > find_elf_symbol can currently return the mapping symbol instead, as the > symbol is not validated. This can result in confusing warnings: > > WARNING: vmlinux.o(.text+0x18f4

[PATCH RFC v3 1/4] mm: gup: rename "nonblocking" to "locked" where proper

2018-11-20 Thread Peter Xu
There's plenty of places around __get_user_pages() that has a parameter "nonblocking" which does not really mean that "it won't block" (because it can really block) but instead it shows whether the mmap_sem is released by up_read() during the page fault handling mostly when VM_FAULT_RETRY is return

[PATCH RFC v3 2/4] mm: userfault: return VM_FAULT_RETRY on signals

2018-11-20 Thread Peter Xu
There was a special path in handle_userfault() in the past that we'll return a VM_FAULT_NOPAGE when we detected non-fatal signals when waiting for userfault handling. We did that by reacquiring the mmap_sem before returning. However that brings a risk in that the vmas might have changed when we r

[PATCH RFC v3 3/4] mm: allow VM_FAULT_RETRY for multiple times

2018-11-20 Thread Peter Xu
The idea comes from a discussion between Linus and Andrea [1]. Before this patch we only allow a page fault to retry once. We achieved this by clearing the FAULT_FLAG_ALLOW_RETRY flag when doing handle_mm_fault() the second time. This was majorly used to avoid unexpected starvation of the system

[PATCH RFC v3 4/4] mm: gup: allow VM_FAULT_RETRY for multiple times

2018-11-20 Thread Peter Xu
This is the gup counterpart of the change that allows the VM_FAULT_RETRY to happen for more than once. Signed-off-by: Peter Xu --- mm/gup.c | 17 + 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/mm/gup.c b/mm/gup.c index a40111c742ba..7c3b3ab6be88 100644 --- a/mm/

[PATCH RFC v3 0/4] mm: some enhancements to the page fault mechanism

2018-11-20 Thread Peter Xu
v3: - fix up issues that krobot reported, rebase This is an RFC series as cleanup and enhancements to current page fault logic. The whole idea comes from the discussion between Andrea and Linus on the bug reported by syzbot here: https://lkml.org/lkml/2017/11/2/833 Basically it does two thing

Re: [PATCH 1/4] OPP: Add dev_pm_opp_xlate_performance_state() helper

2018-11-20 Thread Rajendra Nayak
On 11/21/2018 11:36 AM, Viresh Kumar wrote: On 21-11-18, 10:47, Viresh Kumar wrote: On 21-11-18, 10:34, Rajendra Nayak wrote: On 11/5/2018 12:06 PM, Viresh Kumar wrote: Introduce a new helper dev_pm_opp_xlate_performance_state() which will be used to translate from pstate of a device to a

Re: [Patch v6 14/16] x86/speculation: Use STIBP to restrict speculation on non-dumpable task

2018-11-20 Thread Jiri Kosina
On Tue, 20 Nov 2018, Linus Torvalds wrote: > > Implements arch_update_spec_restriction() for x86. Use STIBP to > > restrict speculative execution when running a task set to non-dumpable, > > or clear the restriction if the task is set to dumpable. > > I don't think this necessarily makes sense.

Re: [PATCH v2 1/2] modpost: drop unused command line switches

2018-11-20 Thread Masahiro Yamada
On Thu, Nov 15, 2018 at 9:56 AM Paul Walmsley wrote: > > Drop modpost command line switches that are no longer used by > makefile.modpost, upon request from Sam Ravnborg , > who wrote: > > modpost is not supposed to be used outside the kernel build. [...] > I checked if there were any opti

Re: [PATCH v2 2/2] modpost: skip ELF local symbols by default during section mismatch check

2018-11-20 Thread Masahiro Yamada
Hi Paul, On Thu, Nov 15, 2018 at 9:57 AM Paul Walmsley wrote: > > During development of a serial console driver with a gcc 8.2.0 > toolchain for RISC-V, the following modpost warning appeared: > > > WARNING: vmlinux.o(.data+0x19b10): Section mismatch in reference from the > variable .LANCH

Re: [PATCH] staging: greybus: Parenthesis alignment

2018-11-20 Thread Greg Kroah-Hartman
On Tue, Nov 20, 2018 at 11:42:05PM +0100, Cristian Sicilia wrote: > Thanks for note > > Can make sense do the patch for function that stay in the line but is not > aligned, or is better doesn't change anything? > Like this: > > static ssize_t gb_camera_debugfs_capabilities(struct gb_camera *gcam

Re: [PATCH v2 0/6] RFC: gup+dma: tracking dma-pinned pages

2018-11-20 Thread John Hubbard
On 11/19/18 10:57 AM, Tom Talpey wrote: > John, thanks for the discussion at LPC. One of the concerns we > raised however was the performance test. The numbers below are > rather obviously tainted. I think we need to get a better baseline > before concluding anything... > > Here's my main concern:

Re: [PATCH 1/4] OPP: Add dev_pm_opp_xlate_performance_state() helper

2018-11-20 Thread Viresh Kumar
On 21-11-18, 10:47, Viresh Kumar wrote: > On 21-11-18, 10:34, Rajendra Nayak wrote: > > > > > > On 11/5/2018 12:06 PM, Viresh Kumar wrote: > > > Introduce a new helper dev_pm_opp_xlate_performance_state() which will > > > be used to translate from pstate of a device to another one. > > > > > > I

Re: [RFCv3 PATCH 1/6] uacce: Add documents for WarpDrive/uacce

2018-11-20 Thread Kenneth Lee
On Mon, Nov 19, 2018 at 08:29:39PM -0700, Jason Gunthorpe wrote: > Date: Mon, 19 Nov 2018 20:29:39 -0700 > From: Jason Gunthorpe > To: Kenneth Lee > CC: Leon Romanovsky , Kenneth Lee , > Tim Sell , linux-...@vger.kernel.org, Alexander > Shishkin , Zaibo Xu > , zhangfei@foxmail.com, linux..

Re: [PATCH V2] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread kbuild test robot
Hi Anson, Thank you for the patch! Perhaps something to improve: [auto build test WARNING on soc-thermal/next] [also build test WARNING on v4.20-rc3 next-20181120] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system] url: https://github.com

Re: [PATCH V5 1/2] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Viresh Kumar
On 21-11-18, 05:49, Anson Huang wrote: > The thermal driver is a standalone driver for monitoring SoC temperature > by enabling thermal sensor, so it can be enabled even when CONFIG_CPU_FREQ > is NOT set. So remove the dependency with CPU_THERMAL. > > Introduce dummy function of legacy cooling reg

Re: [PATCH V5 2/2] thermal: imx: save one condition block for normal case of nvmem initialization

2018-11-20 Thread Viresh Kumar
On 21-11-18, 05:49, Anson Huang wrote: > Put return value checks of calling imx_init_from_nvmem_cells() > into one block to save one condition block for normal case. > > Signed-off-by: Anson Huang > --- > drivers/thermal/imx_thermal.c | 5 +++-- > 1 file changed, 3 insertions(+), 2 deletions(-)

[PATCH V5 2/2] thermal: imx: save one condition block for normal case of nvmem initialization

2018-11-20 Thread Anson Huang
Put return value checks of calling imx_init_from_nvmem_cells() into one block to save one condition block for normal case. Signed-off-by: Anson Huang --- drivers/thermal/imx_thermal.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/thermal/imx_thermal.c b/drivers

[PATCH V5 1/2] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Anson Huang
The thermal driver is a standalone driver for monitoring SoC temperature by enabling thermal sensor, so it can be enabled even when CONFIG_CPU_FREQ is NOT set. So remove the dependency with CPU_THERMAL. Introduce dummy function of legacy cooling register/unregister to make thermal driver probe suc

Re: [PATCH v2] PCI: mediatek: Use devm_of_pci_get_host_bridge_resources() to parse DT

2018-11-20 Thread Ryder Lee
On Thu, 2018-11-08 at 10:56 +0800, honghui.zh...@mediatek.com wrote: > From: Honghui Zhang > > Use the devm_of_pci_get_host_bridge_resources() API in place of the PCI OF > DT parser. > > Signed-off-by: Honghui Zhang > --- > drivers/pci/controller/pcie-mediatek.c | 98 > +--

Re: [PATCH 4/4] PM / Domains: Propagate performance state updates

2018-11-20 Thread Rajendra Nayak
On 11/21/2018 11:01 AM, Rajendra Nayak wrote: On 11/21/2018 10:46 AM, Viresh Kumar wrote: On 21-11-18, 10:33, Rajendra Nayak wrote: Hi Viresh, On 11/5/2018 12:06 PM, Viresh Kumar wrote: This commit updates genpd core to start propagating performance state updates to master domains that ha

Re: [PATCH 4/4] PM / Domains: Propagate performance state updates

2018-11-20 Thread Viresh Kumar
On 21-11-18, 11:01, Rajendra Nayak wrote: > I would think this is analogous to a driver calling clk_set_rate() first and > then a clk_enable(), which is certainly valid. > So my question is, if calling a dev_pm_genpd_set_performance_state() > and then runtime enabling the device would work (and tak

Re: [PATCH 4/4] PM / Domains: Propagate performance state updates

2018-11-20 Thread Rajendra Nayak
On 11/21/2018 10:46 AM, Viresh Kumar wrote: On 21-11-18, 10:33, Rajendra Nayak wrote: Hi Viresh, On 11/5/2018 12:06 PM, Viresh Kumar wrote: This commit updates genpd core to start propagating performance state updates to master domains that have their set_performance_state() callback set.

Re: [PATCH V4] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Viresh Kumar
On 21-11-18, 05:28, Anson Huang wrote: > Since there is similar case of DEFER PROBE for the case of > imx_init_from_nvmem_cells > check, should I create another patch of same fix for it in V5 patch set? Send that as a separate patch please. Thanks. -- viresh

RE: [PATCH V4] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Anson Huang
Best Regards! Anson Huang > -Original Message- > From: Viresh Kumar [mailto:viresh.ku...@linaro.org] > Sent: 2018年11月21日 13:21 > To: Anson Huang > Cc: rui.zh...@intel.com; edubez...@gmail.com; daniel.lezc...@linaro.org; > linux...@vger.kernel.org; linux-kernel@vger.kernel.org; > l.st...

Re: [PATCH V4] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Viresh Kumar
On 21-11-18, 05:08, Anson Huang wrote: > +static void imx_thermal_unregister_legacy_cooling(struct imx_thermal_data > *data) > +{ > + cpufreq_cooling_unregister(data->cdev); > + cpufreq_cpu_put(data->policy); > +} > +#else > +static inline int imx_thermal_register_legacy_cooling(struct >

Re: [PATCH V4] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Viresh Kumar
On 21-11-18, 05:08, Anson Huang wrote: > The thermal driver is a standalone driver for monitoring SoC temperature > by enabling thermal sensor, so it can be enabled even when CONFIG_CPU_FREQ > is NOT set. So remove the dependency with CPU_THERMAL. > > Introduce dummy function of legacy cooling reg

Re: RFC: userspace exception fixups

2018-11-20 Thread Jethro Beekman
On 2018-11-21 04:25, Jarkko Sakkinen wrote: On Tue, Nov 20, 2018 at 07:19:37AM -0800, Andy Lutomirski wrote: general by mucking with some regs and retrying -- that will infinite loop and confuse everyone. I'm not even 100% convinced that decoding the insn stream is useful -- AEP can point to so

Re: [PATCH 1/4] OPP: Add dev_pm_opp_xlate_performance_state() helper

2018-11-20 Thread Viresh Kumar
On 21-11-18, 10:34, Rajendra Nayak wrote: > > > On 11/5/2018 12:06 PM, Viresh Kumar wrote: > > Introduce a new helper dev_pm_opp_xlate_performance_state() which will > > be used to translate from pstate of a device to another one. > > > > Initially this will be used by genpd to find pstate of a

Re: [PATCH 4/4] PM / Domains: Propagate performance state updates

2018-11-20 Thread Viresh Kumar
On 21-11-18, 10:33, Rajendra Nayak wrote: > Hi Viresh, > > On 11/5/2018 12:06 PM, Viresh Kumar wrote: > > This commit updates genpd core to start propagating performance state > > updates to master domains that have their set_performance_state() > > callback set. > > > > A genpd handles two type

Re: [PATCH] iio: st_sensors: Fix the sleep time for sampling

2018-11-20 Thread Jian-Hong Pan
Denis CIOCCA 於 2018年11月20日 週二 上午3:05寫道: > > Hi Jian, > > Not clear to me why should be + instead of *. > > ODR is expressed in Hz, so (1/Hz) = period in seconds (1 sample sampling > time) [s] > 1000 * (1/Hz) = period in milliseconds (1 sample sampling time) [ms] > n * 1000 * (1/Hz) = n times peri

RE: [PATCH V3] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Anson Huang
Best Regards! Anson Huang > -Original Message- > From: Viresh Kumar [mailto:viresh.ku...@linaro.org] > Sent: 2018年11月21日 11:54 > To: Anson Huang > Cc: Zhang Rui ; Eduardo Valentin > ; Daniel Lezcano ; Linux > PM list ; Linux Kernel Mailing List > ; l.st...@pengutronix.de; dl-linux-imx >

[PATCH V4] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Anson Huang
The thermal driver is a standalone driver for monitoring SoC temperature by enabling thermal sensor, so it can be enabled even when CONFIG_CPU_FREQ is NOT set. So remove the dependency with CPU_THERMAL. Introduce dummy function of legacy cooling register/unregister to make thermal driver probe suc

Re: [PATCH] RISC-V: Build flat and compressed kernel images

2018-11-20 Thread Bin Meng
On Mon, Nov 12, 2018 at 1:55 PM Anup Patel wrote: > > This patch extends Linux RISC-V build system to build and install: > Image - Flat uncompressed kernel image > Image.gz - Flat and GZip compressed kernel image > > Quiet a few bootloaders (such as Uboot, UEFI, etc) are capable of nits: U-Boot

Re: [PATCH 1/4] OPP: Add dev_pm_opp_xlate_performance_state() helper

2018-11-20 Thread Rajendra Nayak
On 11/5/2018 12:06 PM, Viresh Kumar wrote: Introduce a new helper dev_pm_opp_xlate_performance_state() which will be used to translate from pstate of a device to another one. Initially this will be used by genpd to find pstate of a master domain using its sub-domain's pstate. Signed-off-by:

Re: [PATCH 4/4] PM / Domains: Propagate performance state updates

2018-11-20 Thread Rajendra Nayak
Hi Viresh, On 11/5/2018 12:06 PM, Viresh Kumar wrote: This commit updates genpd core to start propagating performance state updates to master domains that have their set_performance_state() callback set. A genpd handles two type of performance states now. The first one is the performance state

Re: [PATCH] staging: greybus: Parenthesis alignment

2018-11-20 Thread NeilBrown
On Sun, Nov 18 2018, Joe Perches wrote: > On Sun, 2018-11-18 at 20:28 +0100, Cristian Sicilia wrote: >> Some parameters are aligned with parentheses. >> Some parentheses are opened at end of line. > > Given the very long identifier lengths, I wouldn't > consider many of these appropriate. > > 80 c

Re: [PATCH 4/6] zram: support idle page writeback

2018-11-20 Thread Sergey Senozhatsky
On (11/16/18 16:20), Minchan Kim wrote: > + zram_set_flag(zram, index, ZRAM_UNDER_WB); > + zram_slot_unlock(zram, index); > + if (zram_bvec_read(zram, &bvec, index, 0, NULL)) { > + zram_slot_lock(zram, index); > + zram_clea

linux-next: Tree for Nov 21

2018-11-20 Thread Stephen Rothwell
Hi all, Changes since 20181120: The mlx5-next tree gained a conflict against the rdma tree. The regulator tree lost its build failure. The tip tree lost its build failure. Non-merge commits (relative to Linus' tree): 3982 4165 files changed, 184299 insertions(+), 123219 dele

Re: [RFC PATCH 3/3] mm, fault_around: do not take a reference to a locked page

2018-11-20 Thread William Kucharski
> On Nov 20, 2018, at 7:12 AM, Michal Hocko wrote: > > + /* > + * Check the locked pages before taking a reference to not > + * go in the way of migration. > + */ Could you make this a tiny bit more explanative, something like: +

Re: dyntick-idle CPU and node's qsmask

2018-11-20 Thread Joel Fernandes
On Tue, Nov 20, 2018 at 06:41:07PM -0800, Paul E. McKenney wrote: [...] > > > > I was thinking if we could simplify rcu_note_context_switch (the parts > > > > that > > > > call rcu_momentary_dyntick_idle), if we did the following in > > > > rcu_implicit_dynticks_qs. > > > > > > > > Since we alre

RE: [PATCH 03/14] ARM: milbeaut: Add Milbeaut M10V early printk

2018-11-20 Thread sugaya.taichi
Hi Rob Thank you for your comment. > -Original Message- > From: Rob Herring [mailto:robh...@kernel.org] > Sent: Tuesday, November 20, 2018 12:21 AM > To: Sugaya, Taichi/菅谷 太一 > Cc: linux-clk; devicet...@vger.kernel.org; moderated list:ARM/FREESCALE > IMX / MXC ARM ARCHITECTURE; linux-kern

[PATCH v6 01/10] Fix "x86/alternatives: Lockdep-enforce text_mutex in text_poke*()"

2018-11-20 Thread Nadav Amit
text_mutex is currently expected to be held before text_poke() is called, but we kgdb does not take the mutex, and instead *supposedly* ensures the lock is not taken and will not be acquired by any other core while text_poke() is running. The reason for the "supposedly" comment is that it is not e

[PATCH v6 10/10] x86/alternative: remove the return value of text_poke_*()

2018-11-20 Thread Nadav Amit
The return value of text_poke_early() and text_poke_bp() is useless. Remove it. Cc: Andy Lutomirski Cc: Kees Cook Cc: Peter Zijlstra Cc: Dave Hansen Cc: Masami Hiramatsu Signed-off-by: Nadav Amit --- arch/x86/include/asm/text-patching.h | 4 ++-- arch/x86/kernel/alternative.c| 11 +

[PATCH v6 03/10] x86/mm: temporary mm struct

2018-11-20 Thread Nadav Amit
From: Andy Lutomirski Sometimes we want to set a temporary page-table entries (PTEs) in one of the cores, without allowing other cores to use - even speculatively - these mappings. There are two benefits for doing so: (1) Security: if sensitive PTEs are set, temporary mm prevents their use in ot

Re: [PATCH V3] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Viresh Kumar
On Wed, Nov 21, 2018 at 8:11 AM Anson Huang wrote: > @@ -830,8 +851,7 @@ static int imx_thermal_probe(struct platform_device *pdev) > clk_disable: > clk_disable_unprepare(data->thermal_clk); > cpufreq_put: While at it, rename this label as well to something like legacy_cleanup. > -

[PATCH v6 00/10] x86/alternative: text_poke() fixes

2018-11-20 Thread Nadav Amit
This patch-set addresses some issues that might affect the security and the correctness of code patching. The main issue that the patches deal with is the fact that the fixmap PTEs that are used for patching are available for access from other cores and might be exploited. They are not even flushe

[PATCH v6 04/10] fork: provide a function for copying init_mm

2018-11-20 Thread Nadav Amit
Provide a function for copying init_mm. This function will be later used for setting a temporary mm. Cc: Andy Lutomirski Cc: Kees Cook Cc: Peter Zijlstra Cc: Dave Hansen Reviewed-by: Masami Hiramatsu Tested-by: Masami Hiramatsu Signed-off-by: Nadav Amit --- include/linux/sched/task.h | 1

[PATCH v6 02/10] x86/jump_label: Use text_poke_early() during early init

2018-11-20 Thread Nadav Amit
There is no apparent reason not to use text_poke_early() while we are during early-init and we do not patch code that might be on the stack (i.e., we'll return to the middle of the patched code). This appears to be the case of jump-labels, so do so. This is required for the next patches that would

[PATCH v6 07/10] x86/kgdb: avoid redundant comparison of patched code

2018-11-20 Thread Nadav Amit
text_poke() already ensures that the written value is the correct one and fails if that is not the case. There is no need for an additional comparison. Remove it. Signed-off-by: Nadav Amit --- arch/x86/kernel/kgdb.c | 14 +- 1 file changed, 1 insertion(+), 13 deletions(-) diff --git

[PATCH v6 06/10] x86/alternative: use temporary mm for text poking

2018-11-20 Thread Nadav Amit
text_poke() can potentially compromise the security as it sets temporary PTEs in the fixmap. These PTEs might be used to rewrite the kernel code from other cores accidentally or maliciously, if an attacker gains the ability to write onto kernel memory. Moreover, since remote TLBs are not flushed a

[PATCH v6 08/10] x86: avoid W^X being broken during modules loading

2018-11-20 Thread Nadav Amit
When modules and BPF filters are loaded, there is a time window in which some memory is both writable and executable. An attacker that has already found another vulnerability (e.g., a dangling pointer) might be able to exploit this behavior to overwrite kernel code. This patch prevents having writa

[PATCH v6 09/10] x86/jump-label: remove support for custom poker

2018-11-20 Thread Nadav Amit
There are only two types of poking: early and breakpoint based. The use of a function pointer to perform poking complicates the code and is probably inefficient due to the use of indirect branches. Cc: Andy Lutomirski Cc: Kees Cook Cc: Peter Zijlstra Cc: Dave Hansen Cc: Masami Hiramatsu Signe

[PATCH v6 05/10] x86/alternative: initializing temporary mm for patching

2018-11-20 Thread Nadav Amit
To prevent improper use of the PTEs that are used for text patching, we want to use a temporary mm struct. We initailize it by copying the init mm. The address that will be used for patching is taken from the lower area that is usually used for the task memory. Doing so prevents the need to freque

[PATCH v2 15/15] MAINTAINERS: Add entry for RDA Micro SoC architecture

2018-11-20 Thread Manivannan Sadhasivam
Add MAINTAINERS entry for RDA Micro SoC architecture with myself and Andreas Färber as the maintainers. Signed-off-by: Manivannan Sadhasivam --- MAINTAINERS | 14 ++ 1 file changed, 14 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index 6c3fbbb361f8..7a5ae685a638 100644 --- a

[PATCH v2 11/15] clocksource: Add clock driver for RDA8810PL SoC

2018-11-20 Thread Manivannan Sadhasivam
Add clock driver for RDA Micro RDA8810PL SoC supporting OSTIMER and HWTIMER. RDA8810PL has two independent timers: OSTIMER (56 bit) and HWTIMER (64 bit). Each timer provides optional interrupt support. In this driver, OSTIMER is used for clockevents and HWTIMER is used for clocksource. Signed-off

[PATCH v2 10/15] arm: dts: rda8810pl: Add timer support

2018-11-20 Thread Manivannan Sadhasivam
Add timer support for RDA Micro RDA8810PL SoC. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- arch/arm/boot/dts/rda8810pl.dtsi | 10 ++ 1 file changed, 10 insertions(+) diff --git a/arch/arm/boot/dts/rda8810pl.dtsi b/arch/arm/boot/dts/rda8810pl.dtsi index ab85ee

[PATCH v2 13/15] arm: dts: rda8810pl: Add interrupt support for UART

2018-11-20 Thread Manivannan Sadhasivam
Add interrupt support for UART in RDA Micro RDA8810PL SoC. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- arch/arm/boot/dts/rda8810pl.dtsi | 3 +++ 1 file changed, 3 insertions(+) diff --git a/arch/arm/boot/dts/rda8810pl.dtsi b/arch/arm/boot/dts/rda8810pl.dtsi index 17a

[PATCH v2 12/15] dt-bindings: serial: Document RDA Micro UART

2018-11-20 Thread Manivannan Sadhasivam
From: Andreas Färber Add an initial binding for the UART in RDA Micro RDA8810PL SoC. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- .../bindings/serial/rda,8810pl-uart.txt | 15 +++ 1 file changed, 15 insertions(+) create mode 100644 Documentatio

[PATCH v2 14/15] tty: serial: Add RDA8810PL UART driver

2018-11-20 Thread Manivannan Sadhasivam
Add UART driver for RDA Micro RDA8810PL SoC. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- .../admin-guide/kernel-parameters.txt | 6 + drivers/tty/serial/Kconfig| 19 + drivers/tty/serial/Makefile | 1 + drivers/tty/se

[PATCH v2 09/15] dt-bindings: timer: Document RDA8810PL SoC timer

2018-11-20 Thread Manivannan Sadhasivam
Document RDA Micro RDA8810PL SoC timer. Signed-off-by: Manivannan Sadhasivam --- .../bindings/timer/rda,8810pl-timer.txt | 21 +++ 1 file changed, 21 insertions(+) create mode 100644 Documentation/devicetree/bindings/timer/rda,8810pl-timer.txt diff --git a/Documentation/d

[PATCH v2 08/15] irqchip: Add RDA8810PL interrupt driver

2018-11-20 Thread Manivannan Sadhasivam
Add interrupt driver for RDA Micro RDA8810PL SoC. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- arch/arm/mach-rda/Kconfig | 1 + drivers/irqchip/Kconfig| 4 ++ drivers/irqchip/Makefile | 1 + drivers/irqchip/irq-rda-intc.c | 113

[PATCH v2 06/15] arm: dts: Add devicetree for OrangePi 2G IoT board

2018-11-20 Thread Manivannan Sadhasivam
Add initial devicetree support for OrangePi 2G IoT board from Xunlong. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- arch/arm/boot/dts/Makefile| 2 + .../boot/dts/rda8810pl-orangepi-2g-iot.dts| 40 +++ 2 files changed, 42 inserti

[PATCH v2 07/15] arm: dts: Add devicetree for OrangePi i96 board

2018-11-20 Thread Manivannan Sadhasivam
Add initial devicetree for Orange Pi i96 board from Xunlong. It is one of the 96Boards IoT Edition board. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- arch/arm/boot/dts/Makefile | 3 +- arch/arm/boot/dts/rda8810pl-orangepi-i96.dts | 40 ++

[PATCH v2 05/15] arm: dts: Add devicetree for RDA8810PL SoC

2018-11-20 Thread Manivannan Sadhasivam
Add initial device tree for RDA8810PL SoC from RDA Microelectronics. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- arch/arm/boot/dts/rda8810pl.dtsi | 86 1 file changed, 86 insertions(+) create mode 100644 arch/arm/boot/dts/rda8810pl.dt

[PATCH v2 03/15] ARM: Prepare RDA8810PL SoC

2018-11-20 Thread Manivannan Sadhasivam
From: Andreas Färber Introduce ARCH_RDA and mach-rda for RDA Micro SoCs. Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- arch/arm/Kconfig | 2 ++ arch/arm/Makefile | 1 + arch/arm/mach-rda/Kconfig | 7 +++ arch/arm/mach-rda/Makefile | 1 + 4 file

[PATCH v2 04/15] dt-bindings: interrupt-controller: Document RDA8810PL intc

2018-11-20 Thread Manivannan Sadhasivam
Document interrupt controller in RDA Micro RDA8810PL SoC. Signed-off-by: Manivannan Sadhasivam --- .../interrupt-controller/rda,8810pl-intc.txt | 61 +++ 1 file changed, 61 insertions(+) create mode 100644 Documentation/devicetree/bindings/interrupt-controller/rda,8810pl-intc.

[PATCH v2 01/15] dt-bindings: Add RDA Micro vendor prefix

2018-11-20 Thread Manivannan Sadhasivam
From: Andreas Färber Add vendor prefix for RDA Micro which now merged into Unisoc Communications Inc. Cc: overseas.sa...@unisoc.com Signed-off-by: Andreas Färber Signed-off-by: Manivannan Sadhasivam --- Documentation/devicetree/bindings/vendor-prefixes.txt | 1 + 1 file changed, 1 insertion(+

[PATCH v2 02/15] dt-bindings: arm: Document RDA8810PL and reference boards

2018-11-20 Thread Manivannan Sadhasivam
From: Andreas Färber Add bindings for RDA Micro RDA8810PL SoC and below reference boards: 1. Orange Pi 2G-IoT - http://www.orangepi.org/OrangePi2GIOT/ 2. Orange Pi i96 - https://www.96boards.org/product/orangepi-i96/ Cc: overseas.sa...@unisoc.com Cc: zhao_ste...@263.net Signed-off-by: Andreas F

[PATCH v2 00/15] Add initial RDA8810PL SoC and Orange Pi boards support

2018-11-20 Thread Manivannan Sadhasivam
Hello, This patchset adds initial RDA8810PL SoC and Orange Pi boards (2G IoT and i96) support. RDA8810PL is an ARM Cortex A5 based SoC with Vivante's GC860 GPU. The SoC has been added as a new ARM sub architecture with myself and Andreas as the maintainers. More information about the boards can b

RE: [PATCH V3 1/1] can: flexcan: Add self wakeup support

2018-11-20 Thread Aisheng DONG
> -Original Message- > From: Joakim Zhang [...] > > If wakeup is enabled, enter stop mode, else enter disabled mode.Self wake can > only work on stop mode. > > Starting from IMX6, the flexcan stop mode control bits is SoC specific, move > it > out of IP driver and parse it from devicetre

Re: [PATCH V10 09/19] block: introduce bio_bvecs()

2018-11-20 Thread Sagi Grimberg
Not sure I understand the 'blocking' problem in this case. We can build a bvec table from this req, and send them all in send(), I would like to avoid growing bvec tables and keep everything preallocated. Plus, a bvec_iter operates on a bvec which means we'll need a table there as well... No

Re: Memory hotplug softlock issue

2018-11-20 Thread Hugh Dickins
On Tue, 20 Nov 2018, Hugh Dickins wrote: > On Tue, 20 Nov 2018, Vlastimil Babka wrote: > > > > > > finish_wait(q, wait); > > > > ... the code continues by: > > > > if (thrashing) { > > if (!PageSwapBacked(page)) > > > > So maybe we should not set 'thrashing' true when

Re: [PATCH net-next v3] wireless-drivers: rtnetlink wifi simulation device

2018-11-20 Thread Cody Schuffelen
> 1. Do not EVER submit HTML mails, mailing lists will automatically >reject them. So your mail didn't reach the lists and I only got it >because I was in the Cc field. I apologize, my mistake. > 2. Do not top post, it's really annoying: > > > https://wireless.wiki.kernel.org/en/devel

Re: [PATCH] mm: use this_cpu_cmpxchg_double in put_cpu_partial

2018-11-20 Thread Wengang Wang
Hi Wei, I think you will receive my reply to Zhong, But I am copying my comments for that patch here (again): Copy starts ==> I am not sure if the patch you mentioned intended to fix the problem here. With that patch the negative page->pobjects would become a large positive value, it will wi

Re: [PATCH] mm: use managed_zone() for more exact check in zone iteration

2018-11-20 Thread Wei Yang
On Fri, Nov 16, 2018 at 11:24:05AM +0100, Michal Hocko wrote: >On Thu 15-11-18 07:50:40, Wei Yang wrote: >[...] >> @@ -1193,8 +1196,8 @@ static unsigned int count_free_highmem_pages(void) >> struct zone *zone; >> unsigned int cnt = 0; >> >> -for_each_populated_zone(zone) >> -

Re: [PATCH] mm: use this_cpu_cmpxchg_double in put_cpu_partial

2018-11-20 Thread Wei Yang
On Tue, Nov 20, 2018 at 09:58:58AM -0800, Wengang Wang wrote: >Hi Wei, > > >On 2018/11/17 17:02, Wei Yang wrote: >> On Fri, Nov 16, 2018 at 05:33:35PM -0800, Wengang Wang wrote: >> > The this_cpu_cmpxchg makes the do-while loop pass as long as the >> > s->cpu_slab->partial as the same value. It doe

hello@

2018-11-20 Thread sas . budget
Hi, Please can you respond to my last enquiry. Thanks Wayne.

Re: [PATCH v2 1/2] Makefile: Fix distcc compilation with x86 macros

2018-11-20 Thread Masahiro Yamada
On Tue, Nov 20, 2018 at 2:21 AM Nadav Amit wrote: > > at 8:20 PM, Masahiro Yamada wrote: > > > On Sat, Nov 17, 2018 at 6:02 AM Nadav Amit wrote: > >> From: Masahiro Yamada > >> Sent: November 16, 2018 at 7:45:45 AM GMT > >>> To: Nadav Amit > >>> Cc: Ingo Molnar , Michal Marek > >>> , Thomas Gl

Re: dyntick-idle CPU and node's qsmask

2018-11-20 Thread Paul E. McKenney
On Tue, Nov 20, 2018 at 06:06:12PM -0800, Joel Fernandes wrote: > On Tue, Nov 20, 2018 at 02:28:14PM -0800, Paul E. McKenney wrote: > > On Tue, Nov 20, 2018 at 12:42:43PM -0800, Joel Fernandes wrote: > > > On Sun, Nov 11, 2018 at 10:36:18AM -0800, Paul E. McKenney wrote: > > > > On Sun, Nov 11, 201

[PATCH V3] thermal: imx: fix for dependency on cpu-freq

2018-11-20 Thread Anson Huang
The thermal driver is a standalone driver for monitoring SoC temperature by enabling thermal sensor, so it can be enabled even when CONFIG_CPU_FREQ is NOT set. So remove the dependency with CPU_THERMAL. Introduce dummy function of legacy cooling register/unregister to make thermal driver probe suc

RE: [PATCH 12/14] ARM: dts: milbeaut: Add device tree set for the Milbeaut M10V board

2018-11-20 Thread sugaya.taichi
Hi Rob Thank you for your comments. > -Original Message- > From: Rob Herring [mailto:robh...@kernel.org] > Sent: Tuesday, November 20, 2018 12:46 AM > To: Sugaya, Taichi; ARM-SoC Maintainers > Cc: linux-clk; devicet...@vger.kernel.org; moderated list:ARM/FREESCALE > IMX / MXC ARM ARCHITEC

[PATCH v4] debugobjects: scale the static pool size

2018-11-20 Thread Qian Cai
The current value of the early boot static pool size is not big enough for systems with large number of CPUs with timer or/and workqueue objects selected. As the results, systems have 60+ CPUs with both timer and workqueue objects enabled could trigger "ODEBUG: Out of memory. ODEBUG disabled". Henc

  1   2   3   4   5   6   7   8   9   >