Re: [PATCH 3/3] net: cleanly handle kernel vs user buffers for ->msg_control

2020-05-13 Thread Christoph Hellwig
On Wed, May 13, 2020 at 08:41:57AM -0700, Eric Dumazet wrote: > > +* recv* side when msg_control_is_user is set, msg_control is the kernel > > +* buffer used for all other cases. > > +*/ > > + union { > > + void*msg_control; > > + void __user *msg_c

Re: [PATCH 2/3] input: serio: allow more than one byte to be sent at once

2020-05-13 Thread Sean Young
On Wed, May 13, 2020 at 10:16:46AM +0200, Greg KH wrote: > On Tue, May 12, 2020 at 10:07:24AM +0100, Sean Young wrote: > > So this device is the infrared kind which rc-core (in drivers/media/rc/) > > supports, remotes and such things (not for serial IR). So by using a > > rc-core driver, it can us

Re: [PATCH 2/3] security: add symbol namespace for reading file data

2020-05-13 Thread Greg KH
On Wed, May 13, 2020 at 10:40:31AM -0500, Eric W. Biederman wrote: > Luis Chamberlain writes: > > > Certain symbols are not meant to be used by everybody, the security > > helpers for reading files directly is one such case. Use a symbol > > namespace for them. > > > > This will prevent abuse of

Re: [PATCH 3/3] fs: move kernel_read*() calls to its own symbol namespace

2020-05-13 Thread Greg KH
On Wed, May 13, 2020 at 03:21:08PM +, Luis Chamberlain wrote: > Signed-off-by: Luis Chamberlain I can't take patches without any changelog text at all, sorry. greg k-h

RE: gcc-10: kernel stack is corrupted and fails to boot

2020-05-13 Thread David Laight
From: Arnd Bergmann > Sent: 13 May 2020 17:00 > On Wed, May 13, 2020 at 5:31 PM Kalle Valo wrote: ... > I investigated a little more: This does happen with 'defconfig' > after all, in my first try I must have missed the '-smp 2' argument > to qemu, and it ended up working correctly with just one C

Re: [PATCH] staging: greybus: Replace zero-length array with flexible-array

2020-05-13 Thread Greg Kroah-Hartman
On Wed, May 13, 2020 at 05:48:07PM +0200, Johan Hovold wrote: > On Wed, May 13, 2020 at 05:39:18PM +0200, Greg Kroah-Hartman wrote: > > On Wed, May 13, 2020 at 05:03:43PM +0200, Johan Hovold wrote: > > > On Thu, May 07, 2020 at 01:53:18PM -0500, Gustavo A. R. Silva wrote: > > > > The current codeba

Re: [PATCH v4] kernel: add panic_on_taint

2020-05-13 Thread Rafael Aquini
On Wed, May 13, 2020 at 03:47:22PM +, Luis Chamberlain wrote: > On Wed, May 13, 2020 at 11:00:26AM -0400, Rafael Aquini wrote: > > Analogously to the introduction of panic_on_warn, this patch > > introduces a kernel option named panic_on_taint in order to > > provide a simple and generic way to

Re: I disabled more compiler warnings..

2020-05-13 Thread Paul Smith
On Wed, 2020-05-13 at 15:53 +, David Laight wrote: > > If we don't have pselect() we use the close() in the signal > > handler. In that case we're just waiting in the read(), we're not > > using select() or poll() or whatever. It's definitely the case > > that if we're waiting in read() and so

Re: [PATCH 2/3] drm/etnaviv: Don't ignore errors on getting clocks

2020-05-13 Thread Fabio Estevam
Hi Lubomir, On Wed, May 13, 2020 at 12:08 PM Lubomir Rintel wrote: > /* Get Clocks: */ > - gpu->clk_reg = devm_clk_get(&pdev->dev, "reg"); > + gpu->clk_reg = devm_clk_get_optional(&pdev->dev, "reg"); > DBG("clk_reg: %p", gpu->clk_reg); > if (IS_ERR(gpu->clk_re

Re: [PATCH v5 1/2] dt-bindings: usb: qcom,dwc3: Convert USB DWC3 bindings

2020-05-13 Thread Matthias Kaehlcke
Hi Sandeep, I would suggest to send v6 with the changes Rob and Stephen requested, except for the 'assigned-clock-rate' constraints. A description instead of the constraints is not ideal, but the constraints could be also be added at a later time. Hopefully Rob can either ack with the description

Re: [PATCH] arm64: dts: qcom: disable the new cti nodes on devices with broken coresight

2020-05-13 Thread Jeffrey Hugo
On Wed, May 13, 2020 at 9:53 AM wrote: > > From: Michael Srba > > Attempting to enable these devices causes a "synchronous > external abort". Suspected cause is that the debug power > domain is not enabled by default on this device. > Disable these devices for now to avoid the crash. > > See: htt

Re: [PATCH v2] dma-buf: fix use-after-free in dmabuffs_dname

2020-05-13 Thread Sumit Semwal
On Wed, 13 May 2020 at 21:16, Daniel Vetter wrote: > > On Wed, May 13, 2020 at 02:51:12PM +0200, Greg KH wrote: > > On Wed, May 13, 2020 at 05:40:26PM +0530, Charan Teja Kalla wrote: > > > > > > Thank you Greg for the comments. > > > On 5/12/2020 2:22 PM, Greg KH wrote: > > > > On Fri, May 08, 202

[ANNOUNCE] xfs-linux: vfs-for-next updated to 2c567af418e3

2020-05-13 Thread Darrick J. Wong
Hi folks, The vfs-for-next branch of the xfs-linux repository at: git://git.kernel.org/pub/scm/fs/xfs/xfs-linux.git has just been updated. Patches often get missed, so please check if your outstanding patches were in this update. If they have not been in this update, please resubmit the

Re: [PATCH] wcn36xx: Replace zero-length array with flexible-array

2020-05-13 Thread Kalle Valo
"Gustavo A. R. Silva" wrote: > The current codebase makes use of the zero-length array language > extension to the C90 standard, but the preferred mechanism to declare > variable-length types such as these ones is a flexible array member[1][2], > introduced in C99: > > struct foo { > int

[PATCH 05/18] maccess: update the top of file comment

2020-05-13 Thread Christoph Hellwig
This file now also contains several helpers for accessing user memory. Signed-off-by: Christoph Hellwig --- mm/maccess.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/maccess.c b/mm/maccess.c index 747581ac50dc9..65880ba2ca376 100644 --- a/mm/maccess.c +++ b/mm/maccess.c

[PATCH 08/18] maccess: rename strnlen_unsafe_user to strnlen_user_nofault

2020-05-13 Thread Christoph Hellwig
This matches the naming of strnlen_user, and also makes it more clear what the function is supposed to do. Signed-off-by: Christoph Hellwig --- include/linux/uaccess.h | 2 +- kernel/trace/trace_kprobe.c | 2 +- mm/maccess.c| 4 ++-- 3 files changed, 4 insertions(+), 4 deleti

Re: [PATCH v3] sched/fair: enqueue_task_fair optimization

2020-05-13 Thread Vincent Guittot
On Wed, 13 May 2020 at 17:51, Tao Zhou wrote: > > Hi Vincent, > > Sorry for the duplicate. > > On Wed, May 13, 2020 at 03:55:02PM +0200, Vincent Guittot wrote: > > enqueue_task_fair jumps to enqueue_throttle label when cfs_rq_of(se) is > > throttled which means that se can't be NULL in such case a

[PATCH 02/18] maccess: remove various unused weak aliases

2020-05-13 Thread Christoph Hellwig
maccess tends to define lots of underscore prefixed symbols that then have other weak aliases. But except for two cases they are never actually used, so remove them. Signed-off-by: Christoph Hellwig --- include/linux/uaccess.h | 3 --- mm/maccess.c| 19 +++ 2 files

[PATCH 12/18] maccess: always use strict semantics for probe_kernel_read

2020-05-13 Thread Christoph Hellwig
Except for historical confusion in the kprobes/uprobes and bpf tracers there is no good reason to ever allow user memory accesses from probe_kernel_read. Make the tracers fall back to a probe_user_read if the probe_kernel_read falls to keep the core API clean. Signed-off-by: Christoph Hellwig Re

Re: [PATCH] sctp: check assoc before SCTP_ADDR_{MADE_PRIM,ADDED} event

2020-05-13 Thread Marcelo Ricardo Leitner
On Wed, May 13, 2020 at 04:52:16PM +0200, Jonas Falkevik wrote: > Do not generate SCTP_ADDR_{MADE_PRIM,ADDED} events for SCTP_FUTURE_ASSOC > assocs. How did you get them? I'm thinking you're fixing a side-effect of another issue here. For example, in sctp_assoc_update(), it first calls sctp_asso

[PATCH 13/18] maccess: move user access routines together

2020-05-13 Thread Christoph Hellwig
Move kernel access vs user access routines together to ease upcoming ifdefs. Signed-off-by: Christoph Hellwig --- mm/maccess.c | 110 +-- 1 file changed, 55 insertions(+), 55 deletions(-) diff --git a/mm/maccess.c b/mm/maccess.c index 05c44d490b4e

[PATCH 14/18] maccess: allow architectures to provide kernel probing directly

2020-05-13 Thread Christoph Hellwig
Provide alternative versions of probe_kernel_read, probe_kernel_write and strncpy_from_kernel_unsafe that don't need set_fs magic, but instead use arch hooks that are modelled after unsafe_{get,put}_user to access kernel memory in an exception safe way. Signed-off-by: Christoph Hellwig --- mm/ma

Re: [PATCH v2 0/7] mm: Get rid of vmalloc_sync_(un)mappings()

2020-05-13 Thread Andy Lutomirski
On Wed, May 13, 2020 at 8:21 AM Joerg Roedel wrote: > > Hi, > > here is the next post of this series with these changes to the first > version: > > - Rebased to v5.7-rc5 > > - As a result of the rebase, also removed the > vmalloc_sync_mappings() call from tracing code > >

[PATCH 18/18] maccess: rename probe_kernel_address to get_kernel_nofault

2020-05-13 Thread Christoph Hellwig
Better describe what this helper does, and match the naming of copy_from_kernel_nofault. Signed-off-by: Christoph Hellwig --- arch/arm/kernel/traps.c | 2 +- arch/arm/mm/alignment.c | 4 ++-- arch/arm64/kernel/traps.c | 2 +- arch/ia64/include/asm/sections.h

[PATCH 17/18] maccess: rename probe_user_{read,write} to copy_{from,to}_user_nofault

2020-05-13 Thread Christoph Hellwig
Better describe what these functions do. Suggested-by: Linus Torvalds Signed-off-by: Christoph Hellwig --- arch/powerpc/kernel/process.c | 3 ++- arch/powerpc/kvm/book3s_64_mmu_radix.c | 4 ++-- arch/powerpc/mm/fault.c| 2 +- arch/powerpc/oprofile/backtrace.c |

[PATCH 16/18] maccess: rename probe_kernel_{read,write} to copy_{from,to}_kernel_nofault

2020-05-13 Thread Christoph Hellwig
Better describe what these functions do. Suggested-by: Linus Torvalds Signed-off-by: Christoph Hellwig --- arch/arm/kernel/ftrace.c | 3 +- arch/arm/kernel/kgdb.c | 2 +- arch/arm64/kernel/insn.c | 4 +-- arch/csky/kernel/ftrace.c | 5 ++-- arch/ia64

[PATCH 15/18] x86: use non-set_fs based maccess routines

2020-05-13 Thread Christoph Hellwig
Provide arch_kernel_read and arch_kernel_write routines to implement the maccess routines without messing with set_fs and without stac/clac that opens up access to user space. Signed-off-by: Christoph Hellwig --- arch/x86/include/asm/uaccess.h | 16 1 file changed, 16 insertions

[PATCH 11/18] maccess: remove strncpy_from_unsafe

2020-05-13 Thread Christoph Hellwig
All three callers really should try the explicit kernel and user copies instead. One has already deprecated the somewhat dangerous either kernel or user address concept, the other two still need to follow up eventually. Signed-off-by: Christoph Hellwig Reviewed-by: Masami Hiramatsu --- include

[PATCH 10/18] maccess: unify the probe kernel arch hooks

2020-05-13 Thread Christoph Hellwig
Currently architectures have to override every routine that probes kernel memory, which includes a pure read and strcpy, both in strict and not strict variants. Just provide a single arch hooks instead to make sure all architectures cover all the cases. Signed-off-by: Christoph Hellwig --- arch

[PATCH 09/18] maccess: remove probe_read_common and probe_write_common

2020-05-13 Thread Christoph Hellwig
Each of the helpers has just two callers, which also different in dealing with kernel or userspace pointers. Just open code the logic in the callers. Signed-off-by: Christoph Hellwig --- mm/maccess.c | 63 1 file changed, 29 insertions(+), 34

[PATCH 07/18] maccess: rename strncpy_from_unsafe_strict to strncpy_from_kernel_nofault

2020-05-13 Thread Christoph Hellwig
This matches the naming of strncpy_from_user_nofault, and also makes it more clear what the function is supposed to do. Signed-off-by: Christoph Hellwig --- arch/x86/mm/maccess.c| 2 +- include/linux/uaccess.h | 4 ++-- kernel/trace/bpf_trace.c | 2 +- mm/maccess.c | 6 +++--- 4

[PATCH 01/18] maccess: unexport probe_kernel_write and probe_user_write

2020-05-13 Thread Christoph Hellwig
These two functions are not used by any modular code. Signed-off-by: Christoph Hellwig --- mm/maccess.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/mm/maccess.c b/mm/maccess.c index 3ca8d97e50106..cf21e604f78cb 100644 --- a/mm/maccess.c +++ b/mm/maccess.c @@ -121,7 +121,6 @@ long __prob

[PATCH 04/18] maccess: clarify kerneldoc comments

2020-05-13 Thread Christoph Hellwig
Add proper kerneldoc comments for probe_kernel_read_strict and probe_kernel_read strncpy_from_unsafe_strict and explain the different versus the non-strict version. Signed-off-by: Christoph Hellwig --- mm/maccess.c | 61 1 file changed, 43 ins

[PATCH 06/18] maccess: rename strncpy_from_unsafe_user to strncpy_from_user_nofault

2020-05-13 Thread Christoph Hellwig
This matches the naming of strncpy_from_user, and also makes it more clear what the function is supposed to do. Signed-off-by: Christoph Hellwig --- include/linux/uaccess.h | 4 ++-- kernel/trace/bpf_trace.c| 2 +- kernel/trace/trace_kprobe.c | 2 +- mm/maccess.c| 4 ++--

[PATCH 03/18] maccess: remove duplicate kerneldoc comments

2020-05-13 Thread Christoph Hellwig
Many of the maccess routines have a copy of the kerneldoc comment in the header. Remove it as it is not useful and will get out of sync sooner or later. Signed-off-by: Christoph Hellwig --- include/linux/uaccess.h | 38 -- 1 file changed, 38 deletions(-) dif

Re: gcc-10: kernel stack is corrupted and fails to boot

2020-05-13 Thread Arnd Bergmann
On Wed, May 13, 2020 at 5:31 PM Kalle Valo wrote: > Arnd Bergmann writes: > > On Wed, May 13, 2020 at 2:57 PM Kalle Valo wrote: > >> > >> Arnd Bergmann writes: > >> > >> > If you share your .config, I can try reproducing with that as well. > >> > Once there is a reproducer in qemu, it should be

clean up and streamline probe_kernel_* and friends v2

2020-05-13 Thread Christoph Hellwig
Hi all, this series start cleaning up the safe kernel and user memory probing helpers in mm/maccess.c, and then allows architectures to implement the kernel probing without overriding the address space limit and temporarily allowing access to user memory. It then switches x86 over to this new mec

Re: [PATCH v1] net: phy: at803x: add cable test support

2020-05-13 Thread Oleksij Rempel
On Wed, May 13, 2020 at 05:49:53PM +0200, Andrew Lunn wrote: > > Uff.. i missed this. Then I'll need only to add some changes on top of > > his patch. > > I've been chatting with mwalle on IRC today. There should be a repost > of the patches soon. Cool! @Michael, please CC me. you can include su

Re: [PATCH v4 0/3] arch/x86: Enable MPK feature on AMD

2020-05-13 Thread Babu Moger
On 5/13/20 10:35 AM, Paolo Bonzini wrote: > On 13/05/20 01:58, Babu Moger wrote: >> AMD's next generation of EPYC processors support the MPK (Memory >> Protection Keys) feature. >> >> This series enables the feature on AMD and updates config parameters >> and documentation to reflect the MPK sup

Re: [RFC][PATCH 4/5] objtool: Enable compilation of objtool for all architectures

2020-05-13 Thread Matt Helsley
On Tue, May 12, 2020 at 06:04:56PM +0100, Julien Thierry wrote: > Hi Matt, > > On 5/11/20 6:35 PM, Matt Helsley wrote: > > objtool currently only compiles for x86 architectures. This is > > fine as it presently does not support tooling for other > > architectures. However, we would like to be able

RE: [PATCH v11 00/13] SMMUv3 Nested Stage Setup (IOMMU part)

2020-05-13 Thread Shameerali Kolothum Thodi
Hi Eric, > -Original Message- > From: Auger Eric [mailto:eric.au...@redhat.com] > Sent: 13 May 2020 14:29 > To: Shameerali Kolothum Thodi ; > Zhangfei Gao ; eric.auger@gmail.com; > io...@lists.linux-foundation.org; linux-kernel@vger.kernel.org; > k...@vger.kernel.org; kvm...@lists.cs.c

Re: [PATCH v4 1/3] arch/x86: Update config and kernel doc for MPK feature on AMD

2020-05-13 Thread Babu Moger
On 5/13/20 10:09 AM, Dave Hansen wrote: > On 5/12/20 4:58 PM, Babu Moger wrote: >> +config X86_MEMORY_PROTECTION_KEYS >> +# Both Intel and AMD platforms support "Memory Protection Keys" >> +# feature. So add a generic option X86_MEMORY_PROTECTION_KEYS >> +# and set the option wheneve

Re: [PATCH -next v2] rtl8187: Remove unused variable rtl8225z2_tx_power_ofdm

2020-05-13 Thread Kalle Valo
ChenTao wrote: > Fix the following warning: > > drivers/net/wireless/realtek/rtl818x/rtl8187/rtl8225.c:609:17: warning: > ‘rtl8225z2_tx_power_ofdm’ defined but not used > static const u8 rtl8225z2_tx_power_ofdm[] = { > > Acked-by: Hin-Tak Leung > Acked-by: Larry Finger > Reported-by: Hulk Ro

RE: I disabled more compiler warnings..

2020-05-13 Thread David Laight
From: Paul Smith > Sent: 13 May 2020 16:33 > On Wed, 2020-05-13 at 08:21 +, David Laight wrote: ... > If we don't have pselect() we use the close() in the signal handler. > In that case we're just waiting in the read(), we're not using select() > or poll() or whatever. It's definitely the case

[PATCH net v2] net: broadcom: Select BROADCOM_PHY for BCMGENET

2020-05-13 Thread Florian Fainelli
The GENET controller on the Raspberry Pi 4 (2711) is typically interfaced with an external Broadcom PHY via a RGMII electrical interface. To make sure that delays are properly configured at the PHY side, ensure that we the dedicated Broadcom PHY driver (CONFIG_BROADCOM_PHY) is enabled for this to h

[PATCH] arm64: dts: qcom: disable the new cti nodes on devices with broken coresight

2020-05-13 Thread michael . srba
From: Michael Srba Attempting to enable these devices causes a "synchronous external abort". Suspected cause is that the debug power domain is not enabled by default on this device. Disable these devices for now to avoid the crash. See: https://lore.kernel.org/linux-arm-msm/20190618202623.ga53..

Re: [PATCH] kobject: Make sure the parent does not get released before its children

2020-05-13 Thread Rafael J. Wysocki
On Wed, May 13, 2020 at 5:42 PM Greg Kroah-Hartman wrote: > > On Wed, May 13, 2020 at 06:18:40PM +0300, Heikki Krogerus wrote: > > In the function kobject_cleanup(), kobject_del(kobj) is > > called before the kobj->release(). That makes it possible to > > release the parent of the kobject before t

Re: [PATCH v1] net: phy: at803x: add cable test support

2020-05-13 Thread Andrew Lunn
> Uff.. i missed this. Then I'll need only to add some changes on top of > his patch. I've been chatting with mwalle on IRC today. There should be a repost of the patches soon. Andrew

Re: gcc-10: kernel stack is corrupted and fails to boot

2020-05-13 Thread Arvind Sankar
On Wed, May 13, 2020 at 09:50:03AM +0300, Kalle Valo wrote: > (trimming CC, changing title) > > Kalle Valo writes: > > > Kalle Valo writes: > > > >> Arnd Bergmann writes: > >> > >>> gcc-10 correctly points out a bug with a zero-length array in > >>> struct ath10k_pci: > >>> > >>> drivers/net/w

RE: [PATCH v7 RESEND 07/13] spi: imx: fix ERR009165

2020-05-13 Thread Robin Gong
On 2020/05/13 Sascha Hauer wrote: > On Wed, May 13, 2020 at 08:52:39AM +, Robin Gong wrote: > > On 2020/05/13 16:48 Sascha Hauer wrote: > > > On Wed, May 13, 2020 at 08:38:26AM +, Robin Gong wrote: > > > > On 2020/05/13 Sascha Hauer wrote: > > > > > This patch is the one bisecting will e

Re: [PATCH] staging: greybus: Replace zero-length array with flexible-array

2020-05-13 Thread Johan Hovold
On Wed, May 13, 2020 at 05:39:18PM +0200, Greg Kroah-Hartman wrote: > On Wed, May 13, 2020 at 05:03:43PM +0200, Johan Hovold wrote: > > On Thu, May 07, 2020 at 01:53:18PM -0500, Gustavo A. R. Silva wrote: > > > The current codebase makes use of the zero-length array language > > > extension to the

Re: [PATCH v4] kernel: add panic_on_taint

2020-05-13 Thread Luis Chamberlain
On Wed, May 13, 2020 at 11:00:26AM -0400, Rafael Aquini wrote: > Analogously to the introduction of panic_on_warn, this patch > introduces a kernel option named panic_on_taint in order to > provide a simple and generic way to stop execution and catch > a coredump when the kernel gets tainted by any

Re: [PATCH v8 0/4] USB: pci-quirks: Add Raspberry Pi 4 quirk

2020-05-13 Thread Lorenzo Pieralisi
On Tue, May 05, 2020 at 06:13:13PM +0200, Nicolas Saenz Julienne wrote: > On the Raspberry Pi 4, after a PCI reset, VL805's firmware may either be > loaded directly from an EEPROM or, if not present, by the SoC's > co-processor, VideoCore. This series adds support for the later. > > Note that ther

Re: [PATCH v2] dma-buf: fix use-after-free in dmabuffs_dname

2020-05-13 Thread Daniel Vetter
On Wed, May 13, 2020 at 02:51:12PM +0200, Greg KH wrote: > On Wed, May 13, 2020 at 05:40:26PM +0530, Charan Teja Kalla wrote: > > > > Thank you Greg for the comments. > > On 5/12/2020 2:22 PM, Greg KH wrote: > > > On Fri, May 08, 2020 at 12:11:03PM +0530, Charan Teja Reddy wrote: > > >> The follow

Re: [PATCH v2 7/7] x86/mm: Remove vmalloc faulting

2020-05-13 Thread Andy Lutomirski
On Wed, May 13, 2020 at 8:21 AM Joerg Roedel wrote: > > From: Joerg Roedel > > Remove fault handling on vmalloc areas, as the vmalloc code now takes > care of synchronizing changes to all page-tables in the system. You should also remove sync_current_stack_to_mm().

Re: [PATCH v1] net: phy: at803x: add cable test support

2020-05-13 Thread Oleksij Rempel
On Wed, May 13, 2020 at 08:23:42AM -0700, Florian Fainelli wrote: > > > On 5/13/2020 5:06 AM, Oleksij Rempel wrote: > > The cable test seems to be support by all of currently support Atherso > > PHYs, so add support for all of them. This patch was tested only on > > AR9331 PHY with following resu

Re: [PATCH] coresight: dynamic-replicator: Fix handling of multiple connections

2020-05-13 Thread Sai Prakash Ranjan
On 2020-05-13 07:19, Stephen Boyd wrote: Quoting Mike Leach (2020-05-12 14:52:33) HI Sai, On Tue, 12 May 2020 at 18:46, Sai Prakash Ranjan wrote: > > Hi Mike, > > On 2020-05-12 17:19, Mike Leach wrote: > [...] > > >> >> > >> >> Sorry for hurrying up and sending the patch - > >> >> https://lore

Re: [PATCH v3 1/4] dma-buf: add support for virtio exported objects

2020-05-13 Thread Daniel Vetter
On Wed, Mar 11, 2020 at 12:20 PM David Stevens wrote: > > This change adds a new dma-buf operation that allows dma-bufs to be used > by virtio drivers to share exported objects. The new operation allows > the importing driver to query the exporting driver for the UUID which > identifies the underl

Re: [PATCH 2/3] security: add symbol namespace for reading file data

2020-05-13 Thread Eric W. Biederman
Luis Chamberlain writes: > Certain symbols are not meant to be used by everybody, the security > helpers for reading files directly is one such case. Use a symbol > namespace for them. > > This will prevent abuse of use of these symbols in places they were > not inteded to be used, and provides a

Re: [PATCH] kobject: Make sure the parent does not get released before its children

2020-05-13 Thread Greg Kroah-Hartman
On Wed, May 13, 2020 at 06:18:40PM +0300, Heikki Krogerus wrote: > In the function kobject_cleanup(), kobject_del(kobj) is > called before the kobj->release(). That makes it possible to > release the parent of the kobject before the kobject itself. > > To fix that, adding function __kboject_del()

Re: [PATCH 3/3] net: cleanly handle kernel vs user buffers for ->msg_control

2020-05-13 Thread Eric Dumazet
On 5/11/20 4:59 AM, Christoph Hellwig wrote: > The msg_control field in struct msghdr can either contain a user > pointer when used with the recvmsg system call, or a kernel pointer > when used with sendmsg. To complicate things further kernel_recvmsg > can stuff a kernel pointer in and then us

[RFC PATCH] arm: Don't trap conditional UDF instructions

2020-05-13 Thread Fredrik Strupe
Hi, This is more of a question than a patch, but I hope the attached patch makes the issue a bit clearer. The arm port of Linux supports hooking/trapping of undefined instructions. Some parts of the code use this to trap UDF instructions with certain immediates in order to use them for other purp

Re: [PATCH v2 1/2] perf expr: Test parsing of floating point numbers

2020-05-13 Thread Arnaldo Carvalho de Melo
Em Tue, May 12, 2020 at 11:27:51PM -0700, Ian Rogers escreveu: > Add test for fix in: > commit 5741da3dee4c ("perf expr: Parse numbers as doubles") > > Signed-off-by: Ian Rogers > --- > tools/perf/tests/expr.c | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/tools/perf/tests/expr.c b/to

Re: [PATCH 06/14] arm64: dts: sparx5: Add basic cpu support

2020-05-13 Thread Marc Zyngier
On 2020-05-13 13:55, Lars Povlsen wrote: This adds the basic DT structure for the Microchip Sparx5 SoC, and the reference boards, pcb125, pcb134 and pcb135. The two latter have a NAND vs a eMMC centric variant (as a mount option), Reviewed-by: Alexandre Belloni Signed-off-by: Lars Povlsen ---

Re: [PATCH v2 2/2] perf test: Improve pmu event metric testing

2020-05-13 Thread Arnaldo Carvalho de Melo
Em Tue, May 12, 2020 at 11:27:52PM -0700, Ian Rogers escreveu: > Break pmu-events test into 2 and add a test to verify that all pmu metric > expressions simply parse. Try to parse all metric ids/events, warning if > metrics for the current architecture fail to parse. > > Tested on power9, skylakex

Re: [PATCH] staging: greybus: Replace zero-length array with flexible-array

2020-05-13 Thread Greg Kroah-Hartman
On Wed, May 13, 2020 at 05:03:43PM +0200, Johan Hovold wrote: > On Thu, May 07, 2020 at 01:53:18PM -0500, Gustavo A. R. Silva wrote: > > The current codebase makes use of the zero-length array language > > extension to the C90 standard, but the preferred mechanism to declare > > variable-length typ

Re: [PATCH v5 3/6] fs: Enable to enforce noexec mounts or file exec through O_MAYEXEC

2020-05-13 Thread Stephen Smalley
On Tue, May 5, 2020 at 11:33 AM Mickaël Salaün wrote: > > Enable to forbid access to files open with O_MAYEXEC. Thanks to the > noexec option from the underlying VFS mount, or to the file execute > permission, userspace can enforce these execution policies. This may > allow script interpreters t

Re: [PATCH v6 2/2] mtd: rawnand: Add NAND controller support on Intel LGM SoC

2020-05-13 Thread Andy Shevchenko
On Wed, May 13, 2020 at 06:34:05PM +0300, Andy Shevchenko wrote: > On Wed, May 13, 2020 at 06:46:15PM +0800, Ramuthevar,Vadivel MuruganX wrote: ... > > +static int ebu_nand_remove(struct platform_device *pdev) > > +{ > > + struct ebu_nand_controller *ebu_host = platform_get_drvdata(pdev); > > +

Re: [PATCH v4 0/3] arch/x86: Enable MPK feature on AMD

2020-05-13 Thread Paolo Bonzini
On 13/05/20 01:58, Babu Moger wrote: > AMD's next generation of EPYC processors support the MPK (Memory > Protection Keys) feature. > > This series enables the feature on AMD and updates config parameters > and documentation to reflect the MPK support on x86 platforms. > > AMD documentation for M

Re: [PATCH v6 2/2] mtd: rawnand: Add NAND controller support on Intel LGM SoC

2020-05-13 Thread Andy Shevchenko
On Wed, May 13, 2020 at 06:46:15PM +0800, Ramuthevar,Vadivel MuruganX wrote: > From: Ramuthevar Vadivel Murugan > > This patch adds the new IP of Nand Flash Controller(NFC) support > on Intel's Lightning Mountain(LGM) SoC. > > DMA is used for burst data transfer operation, also DMA HW supports >

Re: [PATCH] coresight: dynamic-replicator: Fix handling of multiple connections

2020-05-13 Thread Sai Prakash Ranjan
Hi Mike, On 2020-05-13 03:22, Mike Leach wrote: [...] Looking at the AMBA driver there is a comment there that AMBA does not lose state when clocks are removed. This is consistent with the AMBA protocol spec which states that AMBA slaves can only be accessed / read / write on various strobe s

Re: I disabled more compiler warnings..

2020-05-13 Thread Paul Smith
On Wed, 2020-05-13 at 08:21 +, David Laight wrote: > > GNU make uses pselect(), on systems that support it. On systems > > that don't support pselect() it uses a trick I described in another > > email: we dup() the FD, read() on the dup, then in the SIGCHLD > > handler we close() the dup. > >

Re: [PATCH] ASoC: tlv320adcx140: Add controls for PDM clk and edge

2020-05-13 Thread Mark Brown
On Wed, May 13, 2020 at 09:47:46AM -0500, Dan Murphy wrote: > +static const char * const pdmclk_text[] = { > + "2.8224 MHz", "1.4112 MHz", "705.6 kHz", "5.6448 MHz" > +}; > + > +static SOC_ENUM_SINGLE_DECL(pdmclk_select_enum, ADCX140_PDMCLK_CFG, 0, > + pdmclk_text); > +

Re: [PATCH v4 3/4] perf stat: Copy counts from prev_raw_counts to evsel->counts

2020-05-13 Thread Jiri Olsa
On Fri, May 08, 2020 at 03:58:16PM +0800, Jin Yao wrote: > It would be useful to support the overall statistics for perf-stat > interval mode. For example, report the summary at the end of > "perf-stat -I" output. > > But since perf-stat can support many aggregation modes, such as > --per-thread,

Re: gcc-10: kernel stack is corrupted and fails to boot

2020-05-13 Thread Kalle Valo
Arnd Bergmann writes: > On Wed, May 13, 2020 at 2:57 PM Kalle Valo wrote: >> >> Arnd Bergmann writes: >> >> > On Wed, May 13, 2020 at 8:50 AM Kalle Valo wrote: >> >> >> >> Kalle Valo writes: >> > >> > At least if it fails reproducibly, it's probably not too hard to drill >> > down further. So

Re: [PATCH 00/13] Reconcile NUMA balancing decisions with the load balancer v6

2020-05-13 Thread Mel Gorman
On Wed, May 13, 2020 at 04:57:15PM +0200, Jirka Hladky wrote: > Hi Mel, > > we have tried the kernel with adjust_numa_imbalance() crippled to just > return the imbalance it's given. > > It has solved all the performance problems I have reported. > Performance is the same as with 5.6 kernel (befor

Re: [PATCH v10 1/5] usb: xhci: Change the XHCI link order in the Makefile

2020-05-13 Thread Florian Fainelli
On 5/13/2020 8:26 AM, Andy Shevchenko wrote: > On Wed, May 13, 2020 at 08:08:07AM -0700, Florian Fainelli wrote: >> On 5/13/2020 5:26 AM, Greg Kroah-Hartman wrote: >>> On Tue, May 12, 2020 at 11:00:15AM -0400, Al Cooper wrote: Some BRCMSTB USB chips have an XHCI, EHCI and OHCI controller >>

Re: [PATCH v6 5/6] Optionally flush L1D on context switch

2020-05-13 Thread Thomas Gleixner
Balbir Singh writes: > Implement a mechanism to selectively flush the L1D cache. The goal is to > allow tasks that are paranoid due to the recent snoop assisted data sampling > vulnerabilites, to flush their L1D on being switched out. This protects > their data from being snooped or leaked via s

Re: [PATCH 2/2] perf test: Improve pmu event metric testing

2020-05-13 Thread John Garry
On 13/05/2020 07:22, Ian Rogers wrote: Break pmu-events test into 2 and add a test to verify that all pmu metric expressions simply parse. Try to parse all metric ids/events, failing if metrics for the current architecture fail to parse. Tested on power9, skylakex, haswell, broadwell, westmere,

Re: [PATCH] keys: Make the KEY_NEED_* perms an enum rather than a mask

2020-05-13 Thread Casey Schaufler
On 5/12/2020 3:33 PM, David Howells wrote: > Since the meaning of combining the KEY_NEED_* constants is undefined, make > it so that you can't do that by turning them into an enum. > > The enum is also given some extra values to represent special > circumstances, such as: > > (1) The '0' value is

Re: [PATCH v10 1/5] usb: xhci: Change the XHCI link order in the Makefile

2020-05-13 Thread Andy Shevchenko
On Wed, May 13, 2020 at 08:08:07AM -0700, Florian Fainelli wrote: > On 5/13/2020 5:26 AM, Greg Kroah-Hartman wrote: > > On Tue, May 12, 2020 at 11:00:15AM -0400, Al Cooper wrote: > >> Some BRCMSTB USB chips have an XHCI, EHCI and OHCI controller > >> on the same port where XHCI handles 3.0 devices,

KMSAN: uninit-value in hash_ip6_test

2020-05-13 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:14bcee29 DO-NOT-SUBMIT: kmsan: block: nullb: handle read r.. git tree: https://github.com/google/kmsan.git master console output: https://syzkaller.appspot.com/x/log.txt?x=14f266a410 kernel config: https://syzkaller.appspot.co

Re: [PATCH v10 2/3] i2c: npcm7xx: Add Nuvoton NPCM I2C controller driver

2020-05-13 Thread Andy Shevchenko
On Mon, May 11, 2020 at 02:28:50PM +0300, Tali Perry wrote: > On Mon, May 11, 2020 at 12:18 PM Andy Shevchenko > wrote: > > On Sun, May 10, 2020 at 01:23:29PM +0300, Tali Perry wrote: ... > > > +#if IS_ENABLED(CONFIG_DEBUG_FS) > > > > Why? > > We wanted to add an optional feature to track i2c s

KMSAN: kernel-infoleak in _copy_to_iter (5)

2020-05-13 Thread syzbot
Hello, syzbot found the following crash on: HEAD commit:14bcee29 DO-NOT-SUBMIT: kmsan: block: nullb: handle read r.. git tree: https://github.com/google/kmsan.git master console output: https://syzkaller.appspot.com/x/log.txt?x=1752af7c10 kernel config: https://syzkaller.appspot.co

Re: [v1,1/1] watchdog: (nct7904) Fix enable watchdog incorrectly

2020-05-13 Thread Guenter Roeck
On Wed, May 13, 2020 at 11:00:15AM +, yuechao.z...@advantech.com.cn wrote: > From: Yuechao Zhao > > Use incorrect register to enable watchdog in nct7904_wdt_ping() > > Signed-off-by: Yuechao Zhao I merged this patch into the patch introducing watchdog support. Thanks, Guenter > --- > dr

Re: [PATCH v1] net: phy: at803x: add cable test support

2020-05-13 Thread Florian Fainelli
On 5/13/2020 5:06 AM, Oleksij Rempel wrote: > The cable test seems to be support by all of currently support Atherso > PHYs, so add support for all of them. This patch was tested only on > AR9331 PHY with following results: > - No cable is detected as short > - A 15m long cable connected only on

[PATCH v2 1/7] mm: Add functions to track page directory modifications

2020-05-13 Thread Joerg Roedel
From: Joerg Roedel Add page-table allocation functions which will keep track of changed directory entries. They are needed for new PGD, P4D, PUD, and PMD entries and will be used in vmalloc and ioremap code to decide whether any changes in the kernel mappings need to be synchronized between page-

[PATCH 0/3] fs: reduce export usage of kerne_read*() calls

2020-05-13 Thread Luis Chamberlain
ile tested with allyesconfig and allmodconfig on x86_64. 0-day should have a report on build status with other configs later of my branch [1]. [0] https://lkml.kernel.org/r/20200508002739.19360-1-scott.bran...@broadcom.com [1] https://git.kernel.org/pub/scm/linux/kernel/git/mcgrof/linux-next.git/

[PATCH 2/3] security: add symbol namespace for reading file data

2020-05-13 Thread Luis Chamberlain
Certain symbols are not meant to be used by everybody, the security helpers for reading files directly is one such case. Use a symbol namespace for them. This will prevent abuse of use of these symbols in places they were not inteded to be used, and provides an easy way to audit where these types

[PATCH v2 6/7] mm: Remove vmalloc_sync_(un)mappings()

2020-05-13 Thread Joerg Roedel
From: Joerg Roedel These functions are not needed anymore because the vmalloc and ioremap mappings are now synchronized when they are created or teared down. Remove all callers and function definitions. Tested-by: Steven Rostedt (VMware) Signed-off-by: Joerg Roedel --- arch/x86/mm/fault.c

[PATCH v2 2/7] mm/vmalloc: Track which page-table levels were modified

2020-05-13 Thread Joerg Roedel
From: Joerg Roedel Track at which levels in the page-table entries were modified by vmap/vunmap. After the page-table has been modified, use that information do decide whether the new arch_sync_kernel_mappings() needs to be called. Signed-off-by: Joerg Roedel --- include/linux/vmalloc.h | 16 +

[PATCH v2 0/7] mm: Get rid of vmalloc_sync_(un)mappings()

2020-05-13 Thread Joerg Roedel
Hi, here is the next post of this series with these changes to the first version: - Rebased to v5.7-rc5 - As a result of the rebase, also removed the vmalloc_sync_mappings() call from tracing code - Added a comment that we rely on the compiler optimizing calls

[PATCH v2 4/7] x86/mm/64: Implement arch_sync_kernel_mappings()

2020-05-13 Thread Joerg Roedel
From: Joerg Roedel Implement the function to sync changes in vmalloc and ioremap ranges to all page-tables. Signed-off-by: Joerg Roedel --- arch/x86/include/asm/pgtable_64_types.h | 2 ++ arch/x86/mm/init_64.c | 5 + 2 files changed, 7 insertions(+) diff --git a/arch/x86

[PATCH v2 3/7] mm/ioremap: Track which page-table levels were modified

2020-05-13 Thread Joerg Roedel
From: Joerg Roedel Track at which levels in the page-table entries were modified by ioremap_page_range(). After the page-table has been modified, use that information do decide whether the new arch_sync_kernel_mappings() needs to be called. The iounmap path re-uses vunmap(), which has already bee

[PATCH v2 5/7] x86/mm/32: Implement arch_sync_kernel_mappings()

2020-05-13 Thread Joerg Roedel
From: Joerg Roedel Implement the function to sync changes in vmalloc and ioremap ranges to all page-tables. Signed-off-by: Joerg Roedel --- arch/x86/include/asm/pgtable-2level_types.h | 2 ++ arch/x86/include/asm/pgtable-3level_types.h | 2 ++ arch/x86/mm/fault.c | 25

[PATCH v2 7/7] x86/mm: Remove vmalloc faulting

2020-05-13 Thread Joerg Roedel
From: Joerg Roedel Remove fault handling on vmalloc areas, as the vmalloc code now takes care of synchronizing changes to all page-tables in the system. Signed-off-by: Joerg Roedel --- arch/x86/include/asm/switch_to.h | 23 -- arch/x86/kernel/setup_percpu.c | 6 +- arch/x86/mm/fault.c

[PATCH 1/3] fs: unexport kernel_read_file()

2020-05-13 Thread Luis Chamberlain
There are no modular uses of kernel_read_file(), so just unexport it. Suggested-by: Al Viro Signed-off-by: Luis Chamberlain --- fs/exec.c | 1 - 1 file changed, 1 deletion(-) diff --git a/fs/exec.c b/fs/exec.c index 23dc2b45d590..9791b9eef9ce 100644 --- a/fs/exec.c +++ b/fs/exec.c @@ -988,7 +9

[PATCH 3/3] fs: move kernel_read*() calls to its own symbol namespace

2020-05-13 Thread Luis Chamberlain
Signed-off-by: Luis Chamberlain --- drivers/base/firmware_loader/main.c | 1 + fs/exec.c | 6 +++--- kernel/kexec_file.c | 2 ++ kernel/module.c | 1 + security/integrity/digsig.c | 3 +++ security/integrity/ima/ima_fs.c |

Re: [v1,1/1] hwmon: (nct7904) Fix the incorrect rang of temperature limitation registers.

2020-05-13 Thread Guenter Roeck
On Tue, May 12, 2020 at 09:38:06AM +, amy.s...@advantech.com.tw wrote: > From: Amy Shih > > The format of temperature limitation registers are 8-bit 2's complement > and the range is -128~127. > Converts the reading value to signed char to fix the incorrect range > of temperature limitation r

Re: [PATCH] kobject: Make sure the parent does not get released before its children

2020-05-13 Thread Rafael J. Wysocki
On Wed, May 13, 2020 at 5:18 PM Heikki Krogerus wrote: > > In the function kobject_cleanup(), kobject_del(kobj) is > called before the kobj->release(). That makes it possible to > release the parent of the kobject before the kobject itself. > > To fix that, adding function __kboject_del() that doe

<    3   4   5   6   7   8   9   10   11   12   >