Re: [PATCH v2 08/22] PCI: dwc: designware: Add EP mode support

2017-03-08 Thread Christoph Hellwig
On Wed, Mar 08, 2017 at 03:32:03PM +, Joao Pinto wrote: > #define PCIE_GET_ATU_INB_UNR_REG_ADDR(region, register) \ > ((0x3 << 20) | (region << 9) | \ > (0x1 << 8) Can you turn this and any similar

Re: [PATCH v2 08/22] PCI: dwc: designware: Add EP mode support

2017-03-08 Thread Christoph Hellwig
On Wed, Mar 08, 2017 at 03:32:03PM +, Joao Pinto wrote: > #define PCIE_GET_ATU_INB_UNR_REG_ADDR(region, register) \ > ((0x3 << 20) | (region << 9) | \ > (0x1 << 8) Can you turn this and any similar

[PATCH] usb: hub: Fix crash after failure to read BOS descriptor

2017-03-08 Thread Guenter Roeck
If usb_get_bos_descriptor() returns an error, usb->bos will be NULL. Nevertheless, it is dereferenced unconditionally in hub_set_initial_usb2_lpm_policy() if usb2_hw_lpm_capable is set. This results in a crash. usb 5-1: unable to get BOS descriptor ... Unable to handle kernel NULL pointer

[PATCH] usb: hub: Fix crash after failure to read BOS descriptor

2017-03-08 Thread Guenter Roeck
If usb_get_bos_descriptor() returns an error, usb->bos will be NULL. Nevertheless, it is dereferenced unconditionally in hub_set_initial_usb2_lpm_policy() if usb2_hw_lpm_capable is set. This results in a crash. usb 5-1: unable to get BOS descriptor ... Unable to handle kernel NULL pointer

Re: v4.10: kernel stack frame pointer .. has bad value (null)

2017-03-08 Thread Andy Lutomirski
On Wed, Mar 8, 2017 at 10:25 AM, Linus Torvalds wrote: > On Wed, Mar 8, 2017 at 9:37 AM, Josh Poimboeuf wrote: > Yeah. At some point we might even upgrade the compiler requirements to > no longer accept the mcount model. > > I think the fentry

Re: v4.10: kernel stack frame pointer .. has bad value (null)

2017-03-08 Thread Andy Lutomirski
On Wed, Mar 8, 2017 at 10:25 AM, Linus Torvalds wrote: > On Wed, Mar 8, 2017 at 9:37 AM, Josh Poimboeuf wrote: > Yeah. At some point we might even upgrade the compiler requirements to > no longer accept the mcount model. > > I think the fentry model is gcc-4.6.0 and up. Currently I guess we >

Re: [Xen-devel] [PATCH 4/7] xen/9pfs: connect to the backend

2017-03-08 Thread Stefano Stabellini
On Wed, 8 Mar 2017, Julien Grall wrote: > Hi Stefano, > > On 08/03/17 00:49, Stefano Stabellini wrote: > > On Tue, 7 Mar 2017, Julien Grall wrote: > > > On 03/06/2017 08:01 PM, Stefano Stabellini wrote: > > > > + if (ring->bytes == NULL) > > > > + goto error; > > > > +

Re: [Xen-devel] [PATCH 4/7] xen/9pfs: connect to the backend

2017-03-08 Thread Stefano Stabellini
On Wed, 8 Mar 2017, Julien Grall wrote: > Hi Stefano, > > On 08/03/17 00:49, Stefano Stabellini wrote: > > On Tue, 7 Mar 2017, Julien Grall wrote: > > > On 03/06/2017 08:01 PM, Stefano Stabellini wrote: > > > > + if (ring->bytes == NULL) > > > > + goto error; > > > > +

[PATCH 3/6] kvm: x86: MMU support for EPT accessed/dirty bits

2017-03-08 Thread Paolo Bonzini
This prepares the MMU paging code for EPT accessed and dirty bits, which can be enabled optionally at runtime. Code that updates the accessed and dirty bits will need a pointer to the struct kvm_mmu. Signed-off-by: Paolo Bonzini --- arch/x86/kvm/paging_tmpl.h | 23

[PATCH 3/6] kvm: x86: MMU support for EPT accessed/dirty bits

2017-03-08 Thread Paolo Bonzini
This prepares the MMU paging code for EPT accessed and dirty bits, which can be enabled optionally at runtime. Code that updates the accessed and dirty bits will need a pointer to the struct kvm_mmu. Signed-off-by: Paolo Bonzini --- arch/x86/kvm/paging_tmpl.h | 23 +++ 1

[PATCH 2/2 v3] dt-bindings: display: imx: entry for AUS mode

2017-03-08 Thread Martin Kaiser
Allow setting the AUS mode for a display from the device tree. Use an optional boolean property. AUS mode can be set only on imx21 and compatible chipsets. Signed-off-by: Martin Kaiser --- v3: use a boolean DT property instead of the register value separate patches for DT

[PATCH 2/2 v3] dt-bindings: display: imx: entry for AUS mode

2017-03-08 Thread Martin Kaiser
Allow setting the AUS mode for a display from the device tree. Use an optional boolean property. AUS mode can be set only on imx21 and compatible chipsets. Signed-off-by: Martin Kaiser --- v3: use a boolean DT property instead of the register value separate patches for DT binding and code

[PATCH v3 0/2] Enable mss rproc support on msm8996

2017-03-08 Thread Avaneesh Kumar Dwivedi
This Patch series fix the comment received on v2 patchset. Major changes w.r.t. patchset v2 is as below. 1- move majority of hypervisor call related changes into scm driver which were earlier in q6v5 rproc driver, which was not compatible to existing design.

[PATCH v3 2/2] remoteproc: qcom: Enable mss rproc support on msm8996

2017-03-08 Thread Avaneesh Kumar Dwivedi
This patch add msm8996 mss reset sequence and other minor changes for enabling mss rproc support. Signed-off-by: Avaneesh Kumar Dwivedi --- .../devicetree/bindings/remoteproc/qcom,q6v5.txt | 1 + drivers/remoteproc/qcom_q6v5_pil.c | 161

[PATCH v3 1/2] soc: qcom: Add support of scm call for mss rproc to share access of ddr

2017-03-08 Thread Avaneesh Kumar Dwivedi
This patch add scm call support to make hypervisor call to enable access of fw regions in ddr to mss subsystem on arm-v8 arch soc's. Signed-off-by: Avaneesh Kumar Dwivedi --- drivers/firmware/qcom_scm-64.c | 25 +++ drivers/firmware/qcom_scm.c| 93

[PATCH v3 0/2] Enable mss rproc support on msm8996

2017-03-08 Thread Avaneesh Kumar Dwivedi
This Patch series fix the comment received on v2 patchset. Major changes w.r.t. patchset v2 is as below. 1- move majority of hypervisor call related changes into scm driver which were earlier in q6v5 rproc driver, which was not compatible to existing design.

[PATCH v3 2/2] remoteproc: qcom: Enable mss rproc support on msm8996

2017-03-08 Thread Avaneesh Kumar Dwivedi
This patch add msm8996 mss reset sequence and other minor changes for enabling mss rproc support. Signed-off-by: Avaneesh Kumar Dwivedi --- .../devicetree/bindings/remoteproc/qcom,q6v5.txt | 1 + drivers/remoteproc/qcom_q6v5_pil.c | 161 ++--- 2 files

[PATCH v3 1/2] soc: qcom: Add support of scm call for mss rproc to share access of ddr

2017-03-08 Thread Avaneesh Kumar Dwivedi
This patch add scm call support to make hypervisor call to enable access of fw regions in ddr to mss subsystem on arm-v8 arch soc's. Signed-off-by: Avaneesh Kumar Dwivedi --- drivers/firmware/qcom_scm-64.c | 25 +++ drivers/firmware/qcom_scm.c| 93 ++

Re: counting file descriptors with a cgroup controller

2017-03-08 Thread Tejun Heo
On Wed, Mar 08, 2017 at 10:52:18AM +0100, Krzysztof Opasiak wrote: > Well detecting failures of open is not enough and it has couple of problems: > > 1) open(2) is not the only syscall which creates fd. In addition to other > syscalls like socket(2), dup(2), some ioctl() on drivers (for example

Re: counting file descriptors with a cgroup controller

2017-03-08 Thread Tejun Heo
On Wed, Mar 08, 2017 at 10:52:18AM +0100, Krzysztof Opasiak wrote: > Well detecting failures of open is not enough and it has couple of problems: > > 1) open(2) is not the only syscall which creates fd. In addition to other > syscalls like socket(2), dup(2), some ioctl() on drivers (for example

Re: v4.10: kernel stack frame pointer .. has bad value (null)

2017-03-08 Thread Linus Torvalds
On Wed, Mar 8, 2017 at 9:37 AM, Josh Poimboeuf wrote: > > It does seem to make it bigger. With Pavel's config on gcc 6, if I add > -maccumulate-outgoing-args: > > That's 3.8% more text on x86-32. That's even more than I expected. I would have expected the -mregparm=3 to

Re: v4.10: kernel stack frame pointer .. has bad value (null)

2017-03-08 Thread Linus Torvalds
On Wed, Mar 8, 2017 at 9:37 AM, Josh Poimboeuf wrote: > > It does seem to make it bigger. With Pavel's config on gcc 6, if I add > -maccumulate-outgoing-args: > > That's 3.8% more text on x86-32. That's even more than I expected. I would have expected the -mregparm=3 to catch so much of our

Dell Inspiron 5558/0VNM2T hangs at resume from suspend when USB 3 is enabled

2017-03-08 Thread Diego Viola
It hangs on resume from suspend if I have USB 3.0 enabled on the BIOS, it works fine with ehci_hcd or USB 2.0. The way I reproduce the problem is with this command: $ i3lock && systemctl suspend This is what I see on the screen when it hangs:

Dell Inspiron 5558/0VNM2T hangs at resume from suspend when USB 3 is enabled

2017-03-08 Thread Diego Viola
It hangs on resume from suspend if I have USB 3.0 enabled on the BIOS, it works fine with ehci_hcd or USB 2.0. The way I reproduce the problem is with this command: $ i3lock && systemctl suspend This is what I see on the screen when it hangs:

SGX notes from KS/LPC

2017-03-08 Thread Andy Lutomirski
Hi- Here are my notes on SGX issues from KS/LPC. It seems that I never emailed it out to a public list -- oops. It may contain any number of typos or outright errors. +++ cut here +++ === Background and terminology === An enclave is an SGX enclave. Once launched, unless the enclave is

SGX notes from KS/LPC

2017-03-08 Thread Andy Lutomirski
Hi- Here are my notes on SGX issues from KS/LPC. It seems that I never emailed it out to a public list -- oops. It may contain any number of typos or outright errors. +++ cut here +++ === Background and terminology === An enclave is an SGX enclave. Once launched, unless the enclave is

Re: [PATCH 0/6] Enable parallel page migration

2017-03-08 Thread Anshuman Khandual
On 02/17/2017 04:54 PM, Anshuman Khandual wrote: > This patch series is base on the work posted by Zi Yan back in > November 2016 (https://lkml.org/lkml/2016/11/22/457) but includes some > amount clean up and re-organization. This series depends on THP migration > optimization patch series

Re: [PATCH 0/6] Enable parallel page migration

2017-03-08 Thread Anshuman Khandual
On 02/17/2017 04:54 PM, Anshuman Khandual wrote: > This patch series is base on the work posted by Zi Yan back in > November 2016 (https://lkml.org/lkml/2016/11/22/457) but includes some > amount clean up and re-organization. This series depends on THP migration > optimization patch series

Re: [PATCH 22/29] drivers, scsi: convert iscsi_task.refcount from atomic_t to refcount_t

2017-03-08 Thread Chris Leech
On Mon, Mar 06, 2017 at 04:21:09PM +0200, Elena Reshetova wrote: > refcount_t type and corresponding API should be > used instead of atomic_t when the variable is used as > a reference counter. This allows to avoid accidental > refcounter overflows that might lead to use-after-free > situations. >

Re: [PATCH 22/29] drivers, scsi: convert iscsi_task.refcount from atomic_t to refcount_t

2017-03-08 Thread Chris Leech
On Mon, Mar 06, 2017 at 04:21:09PM +0200, Elena Reshetova wrote: > refcount_t type and corresponding API should be > used instead of atomic_t when the variable is used as > a reference counter. This allows to avoid accidental > refcounter overflows that might lead to use-after-free > situations. >

Re: [PATCH v2 6/9] mm: set mapping error when launder_pages fails

2017-03-08 Thread Jeff Layton
On Wed, 2017-03-08 at 18:01 +, Trond Myklebust wrote: > On Wed, 2017-03-08 at 11:29 -0500, Jeff Layton wrote: > > If launder_page fails, then we hit a problem writing back some inode > > data. Ensure that we communicate that fact in a subsequent fsync > > since > > another task could still

Re: [PATCH v2 6/9] mm: set mapping error when launder_pages fails

2017-03-08 Thread Jeff Layton
On Wed, 2017-03-08 at 18:01 +, Trond Myklebust wrote: > On Wed, 2017-03-08 at 11:29 -0500, Jeff Layton wrote: > > If launder_page fails, then we hit a problem writing back some inode > > data. Ensure that we communicate that fact in a subsequent fsync > > since > > another task could still

[PATCH] [media] solo6x10: release vb2 buffers in solo_stop_streaming()

2017-03-08 Thread Anton Sviridenko
Fixes warning that appears in dmesg after closing V4L2 userspace application that plays video from the display device (first device from V4L2 device nodes provided by solo, usually /dev/video0 when no other V4L2 devices are present). Encoder device nodes are not affected. Can be reproduced by

[PATCH] [media] solo6x10: release vb2 buffers in solo_stop_streaming()

2017-03-08 Thread Anton Sviridenko
Fixes warning that appears in dmesg after closing V4L2 userspace application that plays video from the display device (first device from V4L2 device nodes provided by solo, usually /dev/video0 when no other V4L2 devices are present). Encoder device nodes are not affected. Can be reproduced by

Re: [PATCH 5/6] PCI/ASPM: Actually configure the L1 substate settings to the device

2017-03-08 Thread James Morse
Hi! On 03/01/17 06:34, Rajat Jain wrote: > Add code to actually configure the L1 substate settigns on the > upstream and downstream device, while taking care of the rules > dictated by the PCIe spec. While testing hibernate on an arm64 juno with v4.11-rc1, I get a NULL pointer dereference from

Re: [PATCH 5/6] PCI/ASPM: Actually configure the L1 substate settings to the device

2017-03-08 Thread James Morse
Hi! On 03/01/17 06:34, Rajat Jain wrote: > Add code to actually configure the L1 substate settigns on the > upstream and downstream device, while taking care of the rules > dictated by the PCIe spec. While testing hibernate on an arm64 juno with v4.11-rc1, I get a NULL pointer dereference from

[resend PATCH 2/2] eventpoll.h: add missing epoll event masks

2017-03-08 Thread Greg KH
[resend due to me forgetting to cc: linux-api the first time around I posted these back on Feb 23] From: Greg Kroah-Hartman For some reason these values are not in the uapi header file, so any libc has to define it themselves. To prevent them from needing to do

[resend PATCH 2/2] eventpoll.h: add missing epoll event masks

2017-03-08 Thread Greg KH
[resend due to me forgetting to cc: linux-api the first time around I posted these back on Feb 23] From: Greg Kroah-Hartman For some reason these values are not in the uapi header file, so any libc has to define it themselves. To prevent them from needing to do this, just have the kernel

Re: [PATCH] x86, kasan: add KASAN checks to atomic operations

2017-03-08 Thread Will Deacon
On Wed, Mar 08, 2017 at 03:20:41PM +, Mark Rutland wrote: > On Wed, Mar 08, 2017 at 02:42:10PM +0100, Dmitry Vyukov wrote: > > I think if we scope compiler atomic builtins to KASAN/KTSAN/KMSAN (and > > consequently x86/arm64) initially, it becomes more realistic. For the > > tools we don't

Re: [PATCH] x86, kasan: add KASAN checks to atomic operations

2017-03-08 Thread Will Deacon
On Wed, Mar 08, 2017 at 03:20:41PM +, Mark Rutland wrote: > On Wed, Mar 08, 2017 at 02:42:10PM +0100, Dmitry Vyukov wrote: > > I think if we scope compiler atomic builtins to KASAN/KTSAN/KMSAN (and > > consequently x86/arm64) initially, it becomes more realistic. For the > > tools we don't

[PATCH 1/2] i2c: do not leave semaphore armed when copying properties fails

2017-03-08 Thread Dmitry Torokhov
We should not leave i2c_register_board_info() early, without unlocking the __i2c_board_lock. Fixes: b0c1e95ab44f ("i2c: copy device properties when using ...") Signed-off-by: Dmitry Torokhov --- drivers/i2c/i2c-boardinfo.c | 6 -- 1 file changed, 4 insertions(+),

[PATCH 1/2] i2c: do not leave semaphore armed when copying properties fails

2017-03-08 Thread Dmitry Torokhov
We should not leave i2c_register_board_info() early, without unlocking the __i2c_board_lock. Fixes: b0c1e95ab44f ("i2c: copy device properties when using ...") Signed-off-by: Dmitry Torokhov --- drivers/i2c/i2c-boardinfo.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git

[PATCH 2/2] i2c: allow attaching IRQ resources to i2c_board_info

2017-03-08 Thread Dmitry Torokhov
Simple integer for interrupt number is not expressive enough, as it does not convey interrupt trigger type that should be used. Let's allow attaching array of resources to the board info and have i2c core parse first IRQ resource and set up interrupt trigger as needed. Signed-off-by: Dmitry

[PATCH 2/2] i2c: allow attaching IRQ resources to i2c_board_info

2017-03-08 Thread Dmitry Torokhov
Simple integer for interrupt number is not expressive enough, as it does not convey interrupt trigger type that should be used. Let's allow attaching array of resources to the board info and have i2c core parse first IRQ resource and set up interrupt trigger as needed. Signed-off-by: Dmitry

[PATCH 4/6] kvm: nVMX: support EPT accessed/dirty bits

2017-03-08 Thread Paolo Bonzini
Now use bit 6 of EPTP to optionally enable A/D bits for EPTP. Another thing to change is that, when EPT accessed and dirty bits are not in use, VMX treats accesses to guest paging structures as data reads. When they are in use (bit 6 of EPTP is set), they are treated as writes and the

[PATCH 4/6] kvm: nVMX: support EPT accessed/dirty bits

2017-03-08 Thread Paolo Bonzini
Now use bit 6 of EPTP to optionally enable A/D bits for EPTP. Another thing to change is that, when EPT accessed and dirty bits are not in use, VMX treats accesses to guest paging structures as data reads. When they are in use (bit 6 of EPTP is set), they are treated as writes and the

[PATCH 2/6] KVM: VMX: cleanup check for invalid EPT violation

2017-03-08 Thread Paolo Bonzini
handle_ept_violation is checking for "guest-linear-address invalid" + "paging-structure walk", which is a sign of a bug in KVM. However, _all_ EPT violations without a valid guest linear address are paging structure walks, because those EPT violations happen when loading the guest PDPTEs. So

[PATCH 2/6] KVM: VMX: cleanup check for invalid EPT violation

2017-03-08 Thread Paolo Bonzini
handle_ept_violation is checking for "guest-linear-address invalid" + "paging-structure walk", which is a sign of a bug in KVM. However, _all_ EPT violations without a valid guest linear address are paging structure walks, because those EPT violations happen when loading the guest PDPTEs. So

[PATCH 1/6] KVM: nVMX: we support 1GB EPT pages

2017-03-08 Thread Paolo Bonzini
Large pages at the PDPE level can be emulated by the MMU, so the bit can be set unconditionally in the EPT capabilities MSR. The same is true of 2MB EPT pages, though all Intel processors with EPT in practice support those. Signed-off-by: Paolo Bonzini ---

[PATCH 1/6] KVM: nVMX: we support 1GB EPT pages

2017-03-08 Thread Paolo Bonzini
Large pages at the PDPE level can be emulated by the MMU, so the bit can be set unconditionally in the EPT capabilities MSR. The same is true of 2MB EPT pages, though all Intel processors with EPT in practice support those. Signed-off-by: Paolo Bonzini --- arch/x86/kvm/vmx.c | 6 +++--- 1 file

[PATCH v2 5/7] PCI: dwc: all: Modify dbi accessors to access data of 4/2/1 bytes

2017-03-08 Thread Kishon Vijay Abraham I
Previously dbi accessors can be used to access data of size 4 bytes. But there might be situations (like accessing MSI_MESSAGE_CONTROL in order to set/get the number of required MSI interrupts in EP mode) where dbi accessors must be used to access data of size 2. This is in preparation for adding

Re: [musl] Re: [PATCH resent] uapi libc compat: allow non-glibc to opt out of uapi definitions

2017-03-08 Thread Carlos O'Donell
On 03/08/2017 11:25 AM, Rich Felker wrote: > On Wed, Mar 08, 2017 at 10:53:00AM -0500, Carlos O'Donell wrote: >> On 11/11/2016 07:08 AM, Felix Janda wrote: >>> Currently, libc-compat.h detects inclusion of specific glibc headers, >>> and defines corresponding _UAPI_DEF_* macros, which in turn are

Re: [musl] Re: [PATCH resent] uapi libc compat: allow non-glibc to opt out of uapi definitions

2017-03-08 Thread Carlos O'Donell
On 03/08/2017 11:25 AM, Rich Felker wrote: > On Wed, Mar 08, 2017 at 10:53:00AM -0500, Carlos O'Donell wrote: >> On 11/11/2016 07:08 AM, Felix Janda wrote: >>> Currently, libc-compat.h detects inclusion of specific glibc headers, >>> and defines corresponding _UAPI_DEF_* macros, which in turn are

[PATCH v2 5/7] PCI: dwc: all: Modify dbi accessors to access data of 4/2/1 bytes

2017-03-08 Thread Kishon Vijay Abraham I
Previously dbi accessors can be used to access data of size 4 bytes. But there might be situations (like accessing MSI_MESSAGE_CONTROL in order to set/get the number of required MSI interrupts in EP mode) where dbi accessors must be used to access data of size 2. This is in preparation for adding

Re: [PATCH] mm: drop "wait" parameter from write_one_page

2017-03-08 Thread John Hubbard
On 03/08/2017 03:30 AM, Jeff Layton wrote: [...] Thanks for having a look. That blurb in the changelog refers to the kerneldoc comment over write_one_page below... No existing caller uses this on normal files, so none of them need it. Signed-off-by: Jeff Layton [...]

Re: [PATCH] mm: drop "wait" parameter from write_one_page

2017-03-08 Thread John Hubbard
On 03/08/2017 03:30 AM, Jeff Layton wrote: [...] Thanks for having a look. That blurb in the changelog refers to the kerneldoc comment over write_one_page below... No existing caller uses this on normal files, so none of them need it. Signed-off-by: Jeff Layton [...] /** - *

[resend PATCH 1/2] eventpoll.h: fix epoll event masks

2017-03-08 Thread Greg KH
[resend due to me forgetting to cc: linux-api the first time around I posted these back on Feb 23] From: Greg Kroah-Hartman When userspace tries to use these defines, it complains that it needs to be an unsigned 1 that is shifted, so libc implementations have to

[resend PATCH 1/2] eventpoll.h: fix epoll event masks

2017-03-08 Thread Greg KH
[resend due to me forgetting to cc: linux-api the first time around I posted these back on Feb 23] From: Greg Kroah-Hartman When userspace tries to use these defines, it complains that it needs to be an unsigned 1 that is shifted, so libc implementations have to create their own version. Fix

[PATCH 6/6] KVM: nVMX: support RDRAND and RDSEED exiting

2017-03-08 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- arch/x86/include/asm/vmx.h | 2 ++ arch/x86/kvm/vmx.c | 5 + 2 files changed, 7 insertions(+) diff --git a/arch/x86/include/asm/vmx.h b/arch/x86/include/asm/vmx.h index cc54b7026567..b2b6e5b1782b 100644 ---

[PATCH 6/6] KVM: nVMX: support RDRAND and RDSEED exiting

2017-03-08 Thread Paolo Bonzini
Signed-off-by: Paolo Bonzini --- arch/x86/include/asm/vmx.h | 2 ++ arch/x86/kvm/vmx.c | 5 + 2 files changed, 7 insertions(+) diff --git a/arch/x86/include/asm/vmx.h b/arch/x86/include/asm/vmx.h index cc54b7026567..b2b6e5b1782b 100644 --- a/arch/x86/include/asm/vmx.h +++

Re: [PATCH v3] Input: sparse-keymap - use a managed allocation for keymap copy

2017-03-08 Thread Dmitry Torokhov
On Wed, Mar 08, 2017 at 09:22:17AM +0100, Michał Kępień wrote: > Some platform drivers use devm_input_allocate_device() together with > sparse_keymap_setup() in their .probe callbacks. While using the former > simplifies error handling, using the latter necessitates calling > sparse_keymap_free()

Re: [PATCH v3] Input: sparse-keymap - use a managed allocation for keymap copy

2017-03-08 Thread Dmitry Torokhov
On Wed, Mar 08, 2017 at 09:22:17AM +0100, Michał Kępień wrote: > Some platform drivers use devm_input_allocate_device() together with > sparse_keymap_setup() in their .probe callbacks. While using the former > simplifies error handling, using the latter necessitates calling > sparse_keymap_free()

[PATCH 0/6] KVM: nVMX: nested EPT improvements and A/D bits, RDRAND and RDSEED exits

2017-03-08 Thread Paolo Bonzini
Patches 1-4 implement nested EPT A/D bits and GB pages. As a side effect, this fixes one vmx.flat failure on machines with EPT A/D bits. It should be possible to implement PML on top of this with host support for A/D bits only. Patches 5-6 implement nested RDRAND and RDSEED exiting. Tested

[PATCH 5/6] KVM: VMX: add missing exit reasons

2017-03-08 Thread Paolo Bonzini
In order to simplify adding exit reasons in the future, the array of exit reason names is now also sorted by exit reason code. Signed-off-by: Paolo Bonzini --- arch/x86/include/uapi/asm/vmx.h | 25 ++--- 1 file changed, 18 insertions(+), 7 deletions(-)

[PATCH 0/6] KVM: nVMX: nested EPT improvements and A/D bits, RDRAND and RDSEED exits

2017-03-08 Thread Paolo Bonzini
Patches 1-4 implement nested EPT A/D bits and GB pages. As a side effect, this fixes one vmx.flat failure on machines with EPT A/D bits. It should be possible to implement PML on top of this with host support for A/D bits only. Patches 5-6 implement nested RDRAND and RDSEED exiting. Tested

[PATCH 5/6] KVM: VMX: add missing exit reasons

2017-03-08 Thread Paolo Bonzini
In order to simplify adding exit reasons in the future, the array of exit reason names is now also sorted by exit reason code. Signed-off-by: Paolo Bonzini --- arch/x86/include/uapi/asm/vmx.h | 25 ++--- 1 file changed, 18 insertions(+), 7 deletions(-) diff --git

Re: [tpmdd-devel] [PATCH] vTPM: Fix missing NULL check

2017-03-08 Thread Jason Gunthorpe
On Tue, Mar 07, 2017 at 11:12:43PM -0500, Hon Ching(Vicky) Lo wrote: > On Mon, 2017-03-06 at 16:19 -0700, Jason Gunthorpe wrote: > > Also, how does locking work here? Does the vio core prevent > > tpm_ibmvtpm_get_desired_dma and tpm_ibmvtpm_remove from running > > concurrently? > > No, vio core

Re: [tpmdd-devel] [PATCH] vTPM: Fix missing NULL check

2017-03-08 Thread Jason Gunthorpe
On Tue, Mar 07, 2017 at 11:12:43PM -0500, Hon Ching(Vicky) Lo wrote: > On Mon, 2017-03-06 at 16:19 -0700, Jason Gunthorpe wrote: > > Also, how does locking work here? Does the vio core prevent > > tpm_ibmvtpm_get_desired_dma and tpm_ibmvtpm_remove from running > > concurrently? > > No, vio core

Re: [Question] devm_kmalloc() for DMA ?

2017-03-08 Thread Masahiro Yamada
Hi Robin, 2017-03-08 20:15 GMT+09:00 Robin Murphy : > On 08/03/17 10:59, Masahiro Yamada wrote: >> Hi experts, >> >> I have a question about >> how to allocate DMA-safe buffer. >> >> >> In my understanding, kmalloc() returns >> memory with DMA safe alignment >> in order to

Re: [Question] devm_kmalloc() for DMA ?

2017-03-08 Thread Masahiro Yamada
Hi Robin, 2017-03-08 20:15 GMT+09:00 Robin Murphy : > On 08/03/17 10:59, Masahiro Yamada wrote: >> Hi experts, >> >> I have a question about >> how to allocate DMA-safe buffer. >> >> >> In my understanding, kmalloc() returns >> memory with DMA safe alignment >> in order to avoid cache-sharing

Re: Subject: [PATCH v4] USB:Core: BugFix: Proper handling of Race Condition when two USB class drivers try to call init_usb_class simultaneously

2017-03-08 Thread gre...@linuxfoundation.org
On Tue, Mar 07, 2017 at 04:35:37AM +, Ajay Kaher wrote: >   >   >   > > On Fri, 3 Mar 2017, Ajay Kaher wrote: > >  > > > > usb_class->kref is not accessible outside the file.c > > > > as usb_class is _static_ inside the file.c and > > > > pointer of usb_class->kref is not passed anywhere. > >

Re: linux-next: build failure after merge of the rcu tree

2017-03-08 Thread Paul E. McKenney
On Wed, Mar 08, 2017 at 12:16:05PM +1100, Stephen Rothwell wrote: > Hi Paul, > > On Mon, 13 Feb 2017 17:43:24 +1100 Stephen Rothwell > wrote: > > > > On Sun, 12 Feb 2017 20:37:48 -0800 "Paul E. McKenney" > > wrote: > > > > > > I chickened out

Re: Subject: [PATCH v4] USB:Core: BugFix: Proper handling of Race Condition when two USB class drivers try to call init_usb_class simultaneously

2017-03-08 Thread gre...@linuxfoundation.org
On Tue, Mar 07, 2017 at 04:35:37AM +, Ajay Kaher wrote: >   >   >   > > On Fri, 3 Mar 2017, Ajay Kaher wrote: > >  > > > > usb_class->kref is not accessible outside the file.c > > > > as usb_class is _static_ inside the file.c and > > > > pointer of usb_class->kref is not passed anywhere. > >

Re: linux-next: build failure after merge of the rcu tree

2017-03-08 Thread Paul E. McKenney
On Wed, Mar 08, 2017 at 12:16:05PM +1100, Stephen Rothwell wrote: > Hi Paul, > > On Mon, 13 Feb 2017 17:43:24 +1100 Stephen Rothwell > wrote: > > > > On Sun, 12 Feb 2017 20:37:48 -0800 "Paul E. McKenney" > > wrote: > > > > > > I chickened out on that commit for this merge window, so it will

[TRIVIAL PATCH 0/2] kprobes: a couple of trivial changes

2017-03-08 Thread Naveen N. Rao
Two trivial fixes for kprobes: - one, to document NOKPROBE_SYMBOL() in kprobe tracer doc - two, change __kprobes to NOKPROBE_SYMBOL() for kprobe_exceptions_notify() I noticed the latter while making this change for arch/powerpc. - Naveen Naveen N. Rao (2): doc: trace/kprobes: add

[TRIVIAL PATCH 0/2] kprobes: a couple of trivial changes

2017-03-08 Thread Naveen N. Rao
Two trivial fixes for kprobes: - one, to document NOKPROBE_SYMBOL() in kprobe tracer doc - two, change __kprobes to NOKPROBE_SYMBOL() for kprobe_exceptions_notify() I noticed the latter while making this change for arch/powerpc. - Naveen Naveen N. Rao (2): doc: trace/kprobes: add

Re: [PATCH v5] NTB: Add IDT 89HPESxNTx PCIe-switches support

2017-03-08 Thread Jon Mason
On Tue, Mar 07, 2017 at 05:02:38AM +0300, Serge Semin wrote: > IDT 89HPESxNTx device series is PCIe-switches, which support > Non-Transparent bridging between domains connected to the device ports. > Since new NTB API exposes multi-port interface and messaging API, the > IDT NT-functions can be

Re: [PATCH v5] NTB: Add IDT 89HPESxNTx PCIe-switches support

2017-03-08 Thread Jon Mason
On Tue, Mar 07, 2017 at 05:02:38AM +0300, Serge Semin wrote: > IDT 89HPESxNTx device series is PCIe-switches, which support > Non-Transparent bridging between domains connected to the device ports. > Since new NTB API exposes multi-port interface and messaging API, the > IDT NT-functions can be

Re: opaque types instead of union epoll_data

2017-03-08 Thread Greg KH
On Wed, Mar 08, 2017 at 12:34:07PM -0500, Carlos O'Donell wrote: > On 03/07/2017 12:59 PM, Greg KH wrote: > > On Tue, Mar 07, 2017 at 09:33:57AM -0500, Carlos O'Donell wrote: > >> I don't know anyone else who is working on this problem. Though I > >> have a vested interested in it as a glibc

Re: [PATCH v2 6/9] mm: set mapping error when launder_pages fails

2017-03-08 Thread Trond Myklebust
On Wed, 2017-03-08 at 11:29 -0500, Jeff Layton wrote: > If launder_page fails, then we hit a problem writing back some inode > data. Ensure that we communicate that fact in a subsequent fsync > since > another task could still have it open for write. > > Signed-off-by: Jeff Layton

Re: opaque types instead of union epoll_data

2017-03-08 Thread Greg KH
On Wed, Mar 08, 2017 at 12:34:07PM -0500, Carlos O'Donell wrote: > On 03/07/2017 12:59 PM, Greg KH wrote: > > On Tue, Mar 07, 2017 at 09:33:57AM -0500, Carlos O'Donell wrote: > >> I don't know anyone else who is working on this problem. Though I > >> have a vested interested in it as a glibc

Re: [PATCH v2 6/9] mm: set mapping error when launder_pages fails

2017-03-08 Thread Trond Myklebust
On Wed, 2017-03-08 at 11:29 -0500, Jeff Layton wrote: > If launder_page fails, then we hit a problem writing back some inode > data. Ensure that we communicate that fact in a subsequent fsync > since > another task could still have it open for write. > > Signed-off-by: Jeff Layton > --- >  

Re: [PATCH 1/1] x86/cqm: Cqm requirements

2017-03-08 Thread David Carrillo-Cisneros
On Wed, Mar 8, 2017 at 12:30 AM, Thomas Gleixner wrote: > Stephane, > > On Tue, 7 Mar 2017, Stephane Eranian wrote: >> On Tue, Mar 7, 2017 at 12:04 PM, Luck, Tony wrote: >> >> That's all nice and good, but I still have no coherent explanation why >> >>

Re: [PATCH 1/1] x86/cqm: Cqm requirements

2017-03-08 Thread David Carrillo-Cisneros
On Wed, Mar 8, 2017 at 12:30 AM, Thomas Gleixner wrote: > Stephane, > > On Tue, 7 Mar 2017, Stephane Eranian wrote: >> On Tue, Mar 7, 2017 at 12:04 PM, Luck, Tony wrote: >> >> That's all nice and good, but I still have no coherent explanation why >> >> measuring across allocation domains makes

Re: RFC: SysRq nice-all-RT-tasks is broken

2017-03-08 Thread Steven Rostedt
On Wed, 8 Mar 2017 12:40:12 -0500 Steven Rostedt wrote: > I wonder if we should just have a special flag sent by that sysrq > trigger. Since it is causing all tasks to go "nice" there's no need to > do the pi chain walk in __sched_setscheduler(). Hah, there already is a

Re: RFC: SysRq nice-all-RT-tasks is broken

2017-03-08 Thread Steven Rostedt
On Wed, 8 Mar 2017 12:40:12 -0500 Steven Rostedt wrote: > I wonder if we should just have a special flag sent by that sysrq > trigger. Since it is causing all tasks to go "nice" there's no need to > do the pi chain walk in __sched_setscheduler(). Hah, there already is a flag! Laurent, can you

Re: [PATCH v11 2/9] mmc: cavium: Add core MMC driver for Cavium SOCs

2017-03-08 Thread Jan Glauber
On Wed, Mar 08, 2017 at 10:45:19AM +0100, Ulf Hansson wrote: [...] > > May I ask why you dislike the bitfields? Or maybe it is easier when I > > explain why I decided to keep them: > > My main concern is that is different compared to how we deal with > endian issues in the kernel. > > I just

Re: [PATCH v11 2/9] mmc: cavium: Add core MMC driver for Cavium SOCs

2017-03-08 Thread Jan Glauber
On Wed, Mar 08, 2017 at 10:45:19AM +0100, Ulf Hansson wrote: [...] > > May I ask why you dislike the bitfields? Or maybe it is easier when I > > explain why I decided to keep them: > > My main concern is that is different compared to how we deal with > endian issues in the kernel. > > I just

problem with block: Move bdi_unregister() to del_gendisk() commit 165a5e22fafb127ecb5914e12e8c32a1f0d3f820

2017-03-08 Thread Arthur Marsh
On one of my pc's I have 2 PATA disks (one, WDC below is used for booting, the other SAMSUNG is not mounted), plus an IBM SCSI disk using a DPT 2044W controller with eata driver and sometimes a Verbatim Storengo USB stick. On recent 4.10.0+ kernel builds (i386), the resulting kernel would

problem with block: Move bdi_unregister() to del_gendisk() commit 165a5e22fafb127ecb5914e12e8c32a1f0d3f820

2017-03-08 Thread Arthur Marsh
On one of my pc's I have 2 PATA disks (one, WDC below is used for booting, the other SAMSUNG is not mounted), plus an IBM SCSI disk using a DPT 2044W controller with eata driver and sometimes a Verbatim Storengo USB stick. On recent 4.10.0+ kernel builds (i386), the resulting kernel would

Re: XTS Crypto Not Found In /proc/crypto Even After Compiled for 4.10.1.

2017-03-08 Thread Krzysztof Kozlowski
On Mon, Mar 06, 2017 at 03:29:48PM -0600, Nathan Royce wrote: > OK, I just tried 4.10.0 and the output is looking the same. > > I can't say my setup is all that odd. The cryptographic use is only > with the swap partition found in my original email (seen in Herbert's > reply). You have quite

Re: XTS Crypto Not Found In /proc/crypto Even After Compiled for 4.10.1.

2017-03-08 Thread Krzysztof Kozlowski
On Mon, Mar 06, 2017 at 03:29:48PM -0600, Nathan Royce wrote: > OK, I just tried 4.10.0 and the output is looking the same. > > I can't say my setup is all that odd. The cryptographic use is only > with the swap partition found in my original email (seen in Herbert's > reply). You have quite

Re: [Xen-devel] [PATCH 29/29] drivers, xen: convert grant_map.users from atomic_t to refcount_t

2017-03-08 Thread Boris Ostrovsky
On 03/08/2017 08:49 AM, Reshetova, Elena wrote: >> On 03/06/2017 09:21 AM, Elena Reshetova wrote: >>> refcount_t type and corresponding API should be >>> used instead of atomic_t when the variable is used as >>> a reference counter. This allows to avoid accidental >>> refcounter overflows that

Re: [Xen-devel] [PATCH 29/29] drivers, xen: convert grant_map.users from atomic_t to refcount_t

2017-03-08 Thread Boris Ostrovsky
On 03/08/2017 08:49 AM, Reshetova, Elena wrote: >> On 03/06/2017 09:21 AM, Elena Reshetova wrote: >>> refcount_t type and corresponding API should be >>> used instead of atomic_t when the variable is used as >>> a reference counter. This allows to avoid accidental >>> refcounter overflows that

Re: v4.10: kernel stack frame pointer .. has bad value (null)

2017-03-08 Thread Josh Poimboeuf
On Tue, Mar 07, 2017 at 10:40:14AM -0800, Linus Torvalds wrote: > On Tue, Mar 7, 2017 at 10:28 AM, Josh Poimboeuf wrote: > > > > Also, the gcc documentation says -maccumulate-outgoing-args is > > "generally beneficial for performance and size." > > Hmm. I wonder how true

Re: v4.10: kernel stack frame pointer .. has bad value (null)

2017-03-08 Thread Josh Poimboeuf
On Tue, Mar 07, 2017 at 10:40:14AM -0800, Linus Torvalds wrote: > On Tue, Mar 7, 2017 at 10:28 AM, Josh Poimboeuf wrote: > > > > Also, the gcc documentation says -maccumulate-outgoing-args is > > "generally beneficial for performance and size." > > Hmm. I wonder how true that is. I'm pretty sure

[PATCH v2] mm, page_alloc: Add missing check for memory holes

2017-03-08 Thread Luck, Tony
From: Tony Luck commit 13ad59df67f19788f6c22985b1a33e466eceb643 ("mm, page_alloc: avoid page_to_pfn() when merging buddies") moved the check for memory holes out of page_is_buddy() and had the callers do the check. But this wasn't done correctly in one place which caused

[PATCH v2] mm, page_alloc: Add missing check for memory holes

2017-03-08 Thread Luck, Tony
From: Tony Luck commit 13ad59df67f19788f6c22985b1a33e466eceb643 ("mm, page_alloc: avoid page_to_pfn() when merging buddies") moved the check for memory holes out of page_is_buddy() and had the callers do the check. But this wasn't done correctly in one place which caused ia64 to crash very

Re: linux-next: build failure after merge of the rcu tree

2017-03-08 Thread Paul E. McKenney
On Wed, Mar 08, 2017 at 11:13:38AM +0100, Daniel Vetter wrote: > On Wed, Mar 08, 2017 at 12:16:45PM +1100, Stephen Rothwell wrote: > > Hi Paul, > > > > After merging the rcu tree, today's linux-next build (x86_64 allmodconfig) > > failed like this: > > > > In file included from

Re: linux-next: build failure after merge of the rcu tree

2017-03-08 Thread Paul E. McKenney
On Wed, Mar 08, 2017 at 11:13:38AM +0100, Daniel Vetter wrote: > On Wed, Mar 08, 2017 at 12:16:45PM +1100, Stephen Rothwell wrote: > > Hi Paul, > > > > After merging the rcu tree, today's linux-next build (x86_64 allmodconfig) > > failed like this: > > > > In file included from

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