[PATCH v2 01/21] drm: core: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 16/21] drm: host1x: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 11/21] drm: rockchip: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 12/21] drm: tegra: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 18/21] xen: gntdev: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 15/21] drm: xen: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 10/21] drm: radeon: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 19/21] dmabuf: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 04/21] drm: etnaviv: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 13/21] drm: virtio: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 17/21] drm: rcar-du: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 21/21] staging: ion: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 14/21] drm: vmwgfx: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH 2/9] bdi: move bdi_dev_name out of line

2020-05-04 Thread Christoph Hellwig
bdi_dev_name is not a fast path function, move it out of line. This prepares for using it from modular callers without having to export an implementation detail like bdi_unknown_name. Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Reviewed-by: Greg Kroah-Hartman Reviewed-by: Bart Van A

[PATCH v2 20/21] media: pci: fix common ALSA DMA-mapping related code

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 07/21] drm: lima: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 03/21] drm: armada: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH 5/5] iommu/amd: Do not flush Device Table in iommu_map_page()

2020-05-04 Thread Joerg Roedel
From: Joerg Roedel The flush of the Device Table Entries for the domain has already happened in increase_address_space(), if necessary. Do no flush them again in iommu_map_page(). Tested-by: Qian Cai Signed-off-by: Joerg Roedel --- drivers/iommu/amd_iommu.c | 27 --- 1

[PATCH v2 05/21] drm: exynos: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH 2/5] iommu/amd: Do not loop forever when trying to increase address space

2020-05-04 Thread Joerg Roedel
From: Joerg Roedel When increase_address_space() fails to allocate memory, alloc_pte() will call it again until it succeeds. Do not loop forever while trying to increase the address space and just return an error instead. Tested-by: Qian Cai Signed-off-by: Joerg Roedel --- drivers/iommu/amd_i

[PATCH 0/5] iommu/amd: Fix race conditions around increase_address_space()

2020-05-04 Thread Joerg Roedel
Hi, Qian reported more race conditions around the dma-mapping code path in the AMD IOMMU driver. The race condtions are between increas_address_space() and fetch_pte(), there were two of them: 1) the 'pt_root' and 'mode' fields of 'struct protection_domain' relate to each other

[PATCH v2 08/21] drm: msm: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 09/21] drm: panfrost: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v2 02/21] drm: amdgpu: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH v4 01/11] iio: light: cm32181: Switch to new style i2c-driver probe function

2020-05-04 Thread Hans de Goede
Switch to the new style i2c-driver probe_new probe function and drop the unnecessary i2c_device_id table (we do not have any old style board files using this). This is a preparation patch for adding ACPI binding support. Signed-off-by: Hans de Goede --- Changes in v4: - Set indio_dev->name to "c

[PATCH 4/5] iommu/amd: Update Device Table in increase_address_space()

2020-05-04 Thread Joerg Roedel
From: Joerg Roedel The Device Table needs to be updated before the new page-table root can be published in domain->pt_root. Otherwise a concurrent call to fetch_pte might fetch a PTE which is not reachable through the Device Table Entry. Fixes: 92d420ec028d ("iommu/amd: Relax locking in dma_ops

[PATCH v2 06/21] drm: i915: fix sg_table nents vs. orig_nents misuse for dmabuf objects

2020-05-04 Thread Marek Szyprowski
The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entries passed to dma_map_sg. The sg_table->nents in

[PATCH 1/5] iommu/amd: Fix race in increase_address_space()/fetch_pte()

2020-05-04 Thread Joerg Roedel
From: Joerg Roedel The 'pt_root' and 'mode' struct members of 'struct protection_domain' need to be get/set atomically, otherwise the page-table of the domain can get corrupted. Merge the fields into one atomic64_t struct member which can be get/set atomically. Fixes: 92d420ec028d ("iommu/amd:

[PATCH v4 06/11] iio: light: cm32181: Handle CM3218 ACPI devices with 2 I2C resources

2020-05-04 Thread Hans de Goede
Some ACPI systems list 2 I2C resources for the CM3218 sensor. On these systems the first I2cSerialBus ACPI-resource points to the SMBus Alert Response Address (ARA, 0x0c) and the second I2cSerialBus ACPI-resource points to the actual CM3218 sensor address: Method (_CRS, 0, NotSerialized) // _CRS

[PATCH v4 08/11] iio: light: cm32181: Use units of 1/100000th for calibscale and lux_per_bit

2020-05-04 Thread Hans de Goede
Use units of 1/10th for calibscale and lux_per_bit. The similar cm3232 driver already uses 1/10th as unit for calibscale. This allows for higher-accuracy and makes it easier to add support for getting device-specific calibscale and lux_per_bit values from a device's ACPI tables, as the val

[PATCH v4 02/11] iio: light: cm32181: Add support for ACPI enumeration

2020-05-04 Thread Hans de Goede
Add support for ACPI enumeration, this has been tested on a HP HP Pavilion x2 Detachable 10 (Bay Trail model). Signed-off-by: Hans de Goede --- Changes in v3: - This is a new patch in v3 of this patch-set --- drivers/iio/light/cm32181.c | 9 + 1 file changed, 9 insertions(+) diff --git

[PATCH v4 05/11] iio: light: cm32181: Clean up the probe function a bit

2020-05-04 Thread Hans de Goede
3 small cleanups to cm32181_probe(): 1. Do not log an error when we fail to allocate memory (as a general rule drivers do not log errors for this as the kernel will already have complained loudly that it could not alloc the mem). 2. Remove the i2c_set_clientdata() call, we never use i2c_get_clien

[PATCH v4 07/11] iio: light: cm32181: Change reg_init to use a bitmap of which registers to init

2020-05-04 Thread Hans de Goede
This is a preparation patch for reading some ACPI tables which give init values for multiple registers. Reviewed-by: Andy Shevchenko Signed-off-by: Hans de Goede --- Changes in v2: - Use unsigned long for init_regs_bitmap - Use for_each_set_bit() --- drivers/iio/light/cm32181.c | 14 ++-

[PATCH v4 03/11] iio: light: cm32181: Add some extra register defines

2020-05-04 Thread Hans de Goede
These come from a newer version of cm32181.c, which is floating around the net, with a copyright of: * Copyright (C) 2014 Capella Microsystems Inc. * Author: Kevin Tsai * * This program is free software; you can redistribute it and/or modify it * under the terms of the GNU General Public Lic

Re: [PATCH 20/24] rcu/tree: Make kvfree_rcu() tolerate any alignment

2020-05-04 Thread Uladzislau Rezki
On Sun, May 03, 2020 at 08:31:06PM -0400, Joel Fernandes wrote: > On Sun, May 03, 2020 at 05:29:47PM -0700, Paul E. McKenney wrote: > > On Sun, May 03, 2020 at 08:24:37PM -0400, Joel Fernandes wrote: > > > On Fri, May 01, 2020 at 04:00:52PM -0700, Paul E. McKenney wrote: > > > > On Tue, Apr 28, 202

[PATCH v4 11/11] iio: light: cm32181: Fix integartion time typo

2020-05-04 Thread Hans de Goede
Fix integartion time typo and while at it improve the comment with the typo a bit in general. Reviewed-by: Andy Shevchenko Signed-off-by: Hans de Goede --- drivers/iio/light/cm32181.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/iio/light/cm32181.c b/drivers/iio/l

[PATCH v4 10/11] iio: light: cm32181: Add support for parsing CPM0 and CPM1 ACPI tables

2020-05-04 Thread Hans de Goede
On ACPI based systems the CPLM3218 ACPI device node describing the CM3218[1] sensor typically will have some extra tables with register init values for initializing the sensor and calibration info. This is based on a newer version of cm32181.c, with a copyright of: * Copyright (C) 2014 Capella M

[PATCH v4 09/11] iio: light: cm32181: Make lux_per_bit and lux_per_bit_base_it runtime settings

2020-05-04 Thread Hans de Goede
Make lux_per_bit and lux_per_bit_base_it settings stored in struct cm32181_chip instead of a hardcoded (defined) values. This is a preparation patch for reading some ACPI tables which specify a device specific lux_per_bit value. Reviewed-by: Andy Shevchenko Signed-off-by: Hans de Goede --- dri

[PATCH v4 04/11] iio: light: cm32181: Add support for the CM3218

2020-05-04 Thread Hans de Goede
Add support for the CM3218 which is an older version of the CM32181. This is based on a newer version of cm32181.c, with a copyright of: * Copyright (C) 2014 Capella Microsystems Inc. * Author: Kevin Tsai * * This program is free software; you can redistribute it and/or modify it * under th

[PATCH 8/9] bdi: simplify bdi_alloc

2020-05-04 Thread Christoph Hellwig
Merge the _node vs normal version and drop the superflous gfp_t argument. Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Reviewed-by: Greg Kroah-Hartman Reviewed-by: Bart Van Assche --- block/blk-core.c| 2 +- drivers/mtd/mtdcore.c | 2 +- fs/super.c

[PATCH 5/9] driver core: remove device_create_vargs

2020-05-04 Thread Christoph Hellwig
All external users of device_create_vargs are gone, so remove it and open code it in the only caller. Signed-off-by: Christoph Hellwig Reviewed-by: Greg Kroah-Hartman Reviewed-by: Jan Kara --- drivers/base/core.c| 37 ++--- include/linux/device.h | 4

[PATCH 9/9] bdi: remove the name field in struct backing_dev_info

2020-05-04 Thread Christoph Hellwig
The name is only printed for a not registered bdi in writeback. Use the device name there as is more useful anyway for the unlike case that the warning triggers. Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Reviewed-by: Greg Kroah-Hartman Reviewed-by: Bart Van Assche --- block/blk-

[PATCH 3/9] bdi: use bdi_dev_name() to get device name

2020-05-04 Thread Christoph Hellwig
From: Yufen Yu Use the common interface bdi_dev_name() to get device name. Signed-off-by: Yufen Yu Signed-off-by: Christoph Hellwig Reviewed-by: Greg Kroah-Hartman Reviewed-by: Jan Kara Reviewed-by: Bart Van Assche --- block/bfq-iosched.c| 5 +++-- block/blk-cgroup.c | 2 +-

Re: [PATCH 19/24] rcu/tree: Support reclaim for head-less object

2020-05-04 Thread Uladzislau Rezki
On Fri, May 01, 2020 at 03:39:09PM -0700, Paul E. McKenney wrote: > On Tue, Apr 28, 2020 at 10:58:58PM +0200, Uladzislau Rezki (Sony) wrote: > > Update the kvfree_call_rcu() with head-less support, it > > means an object without any rcu_head structure can be > > reclaimed after GP. > > > > To stor

[PATCH 7/9] bdi: remove bdi_register_owner

2020-05-04 Thread Christoph Hellwig
Split out a new bdi_set_owner helper to set the owner, and move the policy for creating the bdi name back into genhd.c, where it belongs. Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Reviewed-by: Greg Kroah-Hartman Reviewed-by: Bart Van Assche --- block/genhd.c | 8 ++

[PATCH 6/9] bdi: unexport bdi_register_va

2020-05-04 Thread Christoph Hellwig
bdi_register_va is only used by super.c, which can't be modular. Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Reviewed-by: Greg Kroah-Hartman Reviewed-by: Bart Van Assche --- mm/backing-dev.c | 1 - 1 file changed, 1 deletion(-) diff --git a/mm/backing-dev.c b/mm/backing-dev.c inde

[PATCH 3/5] iommu/amd: Call domain_flush_complete() in update_domain()

2020-05-04 Thread Joerg Roedel
From: Joerg Roedel The update_domain() function is expected to also inform the hardware about domain changes. This needs a COMPLETION_WAIT command to be sent to all IOMMUs which use the domain. Tested-by: Qian Cai Signed-off-by: Joerg Roedel --- drivers/iommu/amd_iommu.c | 1 + 1 file changed

[PATCH 4/9] bdi: add a ->dev_name field to struct backing_dev_info

2020-05-04 Thread Christoph Hellwig
Cache a copy of the name for the life time of the backing_dev_info structure so that we can reference it even after unregistering. Fixes: 68f23b89067f ("memcg: fix a crash in wb_workfn when a device disappears") Reported-by: Yufen Yu Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Review

Re: [PATCH v12 2/5] usb: renesas-xhci: Add the renesas xhci driver

2020-05-04 Thread Mathias Nyman
On 30.4.2020 19.59, Vinod Koul wrote: > From: Christian Lamparter > > This add a new driver for renesas xhci which is basically a firmware > loader for uPD720201 and uPD720202 w/o ROM. The xhci-pci driver will > invoke this driver for loading/unloading on relevant devices. > > This patch adds a

Re: [PATCH v2 09/10] ARM: dts: r8a7742-iwg21m: Add iWave RZ/G1H Qseven SOM

2020-05-04 Thread Geert Uytterhoeven
Hi Prabhakar, On Sun, May 3, 2020 at 11:48 PM Lad Prabhakar wrote: > Add support for iWave RZ/G1H Qseven System On Module. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Thanks for your patch! > --- /dev/null > +++ b/arch/arm/boot/dts/r8a7742-iwg21m.dtsi > @@ -0,0

Re: [PATCH v2 00/21] DRM: fix struct sg_table nents vs. orig_nents misuse

2020-05-04 Thread Marek Szyprowski
Hi Christoph, On 04.05.2020 14:52, Christoph Hellwig wrote: > On Mon, May 04, 2020 at 02:50:17PM +0200, Marek Szyprowski wrote: >> v2: >> - dropped most of the changes to drm/i915 >> - added fixes for rcar-du, xen, media and ion >> - fixed a few issues pointed by kbuild test robot >> - added wide

Re: [PATCH v2 10/10] ARM: dts: r8a7742-iwg21d-q7: Add support for iWave G21D-Q7 board based on RZ/G1H

2020-05-04 Thread Geert Uytterhoeven
On Sun, May 3, 2020 at 11:47 PM Lad Prabhakar wrote: > Add support for iWave RainboW-G21D-Qseven board based on RZ/G1H. > > Signed-off-by: Lad Prabhakar > Reviewed-by: Marian-Cristian Rotariu > Reviewed-by: Geert Uytterhoeven Gr{oetje,eeting}s, Geert -- Geert Uytte

Re: [PATCH v2 00/21] DRM: fix struct sg_table nents vs. orig_nents misuse

2020-05-04 Thread Christoph Hellwig
On Mon, May 04, 2020 at 03:05:30PM +0200, Marek Szyprowski wrote: > Hi Christoph, > > On 04.05.2020 14:52, Christoph Hellwig wrote: > > On Mon, May 04, 2020 at 02:50:17PM +0200, Marek Szyprowski wrote: > >> v2: > >> - dropped most of the changes to drm/i915 > >> - added fixes for rcar-du, xen, med

Re: [PATCH v2] KVM: nVMX: Skip IBPB when switching between vmcs01 and vmcs02

2020-05-04 Thread Paolo Bonzini
On 04/05/20 14:01, Alexander Graf wrote: > I like the WARN_ON :). It should be almost free during execution, but > helps us catch problems early. Yes, it's nice. I didn't mind the "buddy" argument either, but if we're going to get a bool I prefer positive logic so I'd like to squash this: diff

Re: [PATCH hmm v2 5/5] mm/hmm: remove the customizable pfn format from hmm_range_fault

2020-05-04 Thread Christoph Hellwig
Looks good, Reviewed-by: Christoph Hellwig

Re: [PATCH v2] ipmi:bt-bmc: Fix error handling and status check

2020-05-04 Thread Corey Minyard
On Sun, Apr 19, 2020 at 02:29:26PM +0800, Tang Bin wrote: > Hi, Corey: > > On 2020/4/18 21:49, Corey Minyard wrote: > > On Sat, Apr 18, 2020 at 04:02:29PM +0800, Tang Bin wrote: > > > If the function platform_get_irq() failed, the negative > > > value returned will not be detected here. So fix err

[PATCH v3] perf tools: fix detecting SMT at machines with more than 32 cpus

2020-05-04 Thread Konstantin Khlebnikov
Cpu bitmap is split into 32 bit words. For system with more than 32 cores threads are always in different words thus first word never has two bits: cpu0: ",0100,0001", cpu 79: "8000,0080,". Instead of parsing bitmap read "core_cpus_list" or "thread_siblings_list" and simply

Re: [PATCH 03/10] KVM: x86: Make kvm_x86_ops' {g,s}et_dr6() hooks optional

2020-05-04 Thread Paolo Bonzini
On 02/05/20 06:32, Sean Christopherson wrote: > Make get_dr6() and set_dr6() optional and drop the VMX implementations, > which are for all intents and purposes nops. This avoids a retpoline on > VMX when reading/writing DR6, at minimal cost (~1 uop) to SVM. Can't get_dr6 be killed off completely

Re: [PATCH] ASoC: qcom: Remove the unnecessary cast

2020-05-04 Thread Mark Brown
On Mon, May 04, 2020 at 03:35:58PM +0800, Tang Bin wrote: > It's not necessary to specify 'void const __force *' casting > for 'drvdata->lpaif'. This doesn't apply against current code, please check and resend. signature.asc Description: PGP signature

Re: [PATCH] usb: usbfs: correct kernel->user page attribute mismatch

2020-05-04 Thread Jeremy Linton
Hi, On 5/4/20 2:13 AM, Greg KH wrote: On Fri, May 01, 2020 at 10:47:22AM -0500, Jeremy Linton wrote: Hi, Thanks for taking a look at this. On 5/1/20 2:05 AM, Greg KH wrote: On Thu, Apr 30, 2020 at 04:19:22PM -0500, Jeremy Linton wrote: On arm64, and possibly other architectures, requesting

Re: [PATCH v5] ARM: DTS: Aspeed: Add YADRO Nicole BMC

2020-05-04 Thread Andrew Jeffery
On Mon, 4 May 2020, at 22:14, Joel Stanley wrote: > On Mon, 4 May 2020 at 11:04, Andrew Jeffery wrote: > > > > > > > > On Mon, 27 Apr 2020, at 20:41, Joel Stanley wrote: > > > On Fri, 24 Apr 2020 at 13:53, Alexander Filippov > > > wrote: > > > > > > > > Nicole is an OpenPower machine with an

Re: [PATCH 00/10] KVM: x86: Misc anti-retpoline optimizations

2020-05-04 Thread Paolo Bonzini
On 02/05/20 06:32, Sean Christopherson wrote: > A smattering of optimizations geared toward avoiding retpolines, though > IMO most of the patches are worthwhile changes irrespective of retpolines. > I can split this up into separate patches if desired, outside of the > obvious combos there are no d

Re: [PATCH v2 09/21] drm: panfrost: fix sg_table nents vs. orig_nents misuse

2020-05-04 Thread Steven Price
On 04/05/2020 13:53, Marek Szyprowski wrote: The Documentation/DMA-API-HOWTO.txt states that dma_map_sg returns the numer of the created entries in the DMA address space. However the subsequent calls to dma_sync_sg_for_{device,cpu} and dma_unmap_sg must be called with the original number of entri

Re: [PATCH net] net: dsa: Do not make user port errors fatal

2020-05-04 Thread Andrew Lunn
On Sun, May 03, 2020 at 08:50:57PM -0700, Florian Fainelli wrote: > Prior to 1d27732f411d ("net: dsa: setup and teardown ports"), we would > not treat failures to set-up an user port as fatal, but after this > commit we would, which is a regression for some systems where interfaces > may be declare

[PATCH 1/4] block/part_stat: remove rcu_read_lock() from part_stat_lock()

2020-05-04 Thread Konstantin Khlebnikov
RCU lock is required only in blk_account_io_start() to lookup partition. After that request holds reference to related hd_struct. Replace get_cpu() with preempt_disable() - returned cpu index is unused. Non-SMP case also needs preempt_disable, otherwise statistics update could be non-atomic. Prev

[PATCH 2/4] block/part_stat: use __this_cpu_add() instead of access by smp_processor_id()

2020-05-04 Thread Konstantin Khlebnikov
Most architectures have fast path to access percpu for current cpu. Required preempt_disable() is provided by part_stat_lock(). Signed-off-by: Konstantin Khlebnikov --- include/linux/part_stat.h |9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/include/linux/part_st

Re: [RFC PATCH] sched/fair: correct llc shared domain's number of busy CPUs

2020-05-04 Thread Vincent Guittot
On Mon, 4 May 2020 at 13:41, Hillf Danton wrote: > > > On Mon, 4 May 2020 09:53:36 Vincent Guittot wrote: > > > > On Mon, 4 May 2020 at 03:57, Hillf Danton wrote: > > > > > > The comment says, if there is an imbalance between LLC domains (IOW we > > > could increase the overall cache use), we nee

Re: [PATCH v5 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-04 Thread Michal Kubecek
On Mon, May 04, 2020 at 12:10:29PM +0200, Oleksij Rempel wrote: > > > diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c > > > index ac2784192472f..42dda9d2082ee 100644 > > > --- a/drivers/net/phy/phy_device.c > > > +++ b/drivers/net/phy/phy_device.c > > > @@ -1768,6 +1768,90

Re: [PATCH v6 2/3] drm: Add support for the LogiCVC display controller

2020-05-04 Thread Emil Velikov
Hi Paul, Just had a casual quick look for custom KMS properties, since new drivers made that mistake in the past. Thanks for not including any o/ I made a couple of trivial suggestions - if you agree, feel free to keep them as follow-up patches. On Thu, 30 Apr 2020 at 20:28, Paul Kocialkowski w

[PATCH 3/4] block/part_stat: account merge of two requests

2020-05-04 Thread Konstantin Khlebnikov
Also rename blk_account_io_merge() into blk_account_io_merge_request() to distinguish it from merging request and bio. Signed-off-by: Konstantin Khlebnikov --- block/blk-merge.c |7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/block/blk-merge.c b/block/blk-merge.c in

[PATCH 4/4] block/part_stat: add helper blk_account_io_merge_bio()

2020-05-04 Thread Konstantin Khlebnikov
Move non-"new_io" branch of blk_account_io_start() into separate function. Fix merge accounting for discards (they were counted as write merges). Also blk_account_io_merge_bio() doesn't call update_io_ticks() unlike to blk_account_io_start(), there is no reason for that. Signed-off-by: Konstantin

[PATCH] nvdimm: Avoid race between probe and reading device attributes

2020-05-04 Thread Richard Palethorpe
It is possible to cause a division error and use-after-free by querying the nmem device before the driver data is fully initialised in nvdimm_probe. E.g by doing (while true; do cat /sys/bus/nd/devices/nmem*/available_slots 2>&1 > /dev/null done) & while true; do for i in $(seq 0 4); d

[v1] drm/msm/dpu: update bandwidth threshold check

2020-05-04 Thread Krishna Manikandan
Maximum allowed bandwidth has no dependency on the type of panel used. Hence, cleanup the code to use max_bw_high as the threshold value for bandwidth checks. Update the maximum allowed bandwidth as 6.8Gbps for SC7180 target. Signed-off-by: Krishna Manikandan --- drivers/gpu/drm/msm/disp/dpu1/

Re: [PATCH v5 1/2] ethtool: provide UAPI for PHY master/slave configuration.

2020-05-04 Thread Michal Kubecek
On Mon, May 04, 2020 at 10:55:56AM +0200, Oleksij Rempel wrote: > On Mon, May 04, 2020 at 10:37:34AM +0200, Michal Kubecek wrote: > > On Mon, May 04, 2020 at 10:04:17AM +0200, Oleksij Rempel wrote: > > > @Michal, > > > > > > i noticed that linkmodes_fill_reply() some times get not enough > > > tai

Re: [RFC PATCH] dt-bindings: net: nxp,tja11xx: add compatible support

2020-05-04 Thread Andrew Lunn
On Mon, May 04, 2020 at 10:44:12AM +0200, Oleksij Rempel wrote: > Hi all, > > here is first attempt to rework this binding. So far I have following > questions and/or issues: > - currently this PHY is identified by ID, not by compatible. Should it > be probed by compatible? > Theoretically I c

Re: [PATCH v2 02/10] pinctrl: sh-pfc: r8a7790: Add r8a7742 PFC support

2020-05-04 Thread Lad, Prabhakar
Hi Geert, Thank you for the review. On Mon, May 4, 2020 at 11:20 AM Geert Uytterhoeven wrote: > > Hi Prabhakar, > > Thanks for the update! > > On Sun, May 3, 2020 at 11:47 PM Lad Prabhakar > wrote: > > Renesas RZ/G1H (R8A7742) is pin compatible with R-Car H2 (R8A7790), > > however it doesn't ha

Re: [PATCH v2 1/1] fs/splice: add missing callback for inaccessible pages

2020-05-04 Thread Ulrich Weigand
On Fri, May 01, 2020 at 09:32:45AM -0700, Dave Hansen wrote: > The larger point, though, is that the s390 code ensures no extra > references exist upon entering make_secure_pte(), but it still has no > mechanism to prevent future, new references to page cache pages from > being created. Hi Dave, I

Re: [PATCH 1/2] splice: export do_tee()

2020-05-04 Thread Jens Axboe
On 5/4/20 6:31 AM, Pavel Begunkov wrote: > On 04/05/2020 14:09, Jann Horn wrote: >> On Sat, May 2, 2020 at 2:10 PM Pavel Begunkov wrote: >>> export do_tee() for use in io_uring >> [...] >>> diff --git a/fs/splice.c b/fs/splice.c >> [...] >>> * The 'flags' used are the SPLICE_F_* variants, curren

Re: [PATCH v5 5/5] drivers/tty/serial: add LiteUART driver

2020-05-04 Thread Mateusz Holenko
On Tue, Apr 28, 2020 at 5:50 PM Andy Shevchenko wrote: > > On Sat, Apr 25, 2020 at 2:45 PM Mateusz Holenko wrote: > > > > From: Filip Kokosinski > > > > This commit adds driver for the FPGA-based LiteUART serial controller > > from LiteX SoC builder. > > > > The current implementation supports L

Re: [PATCH v2 04/10] dt-bindings: mmc: renesas,mmcif: Document r8a7742 DT bindings

2020-05-04 Thread Lad, Prabhakar
Hi Geert, Thank you for the review. On Mon, May 4, 2020 at 11:26 AM Geert Uytterhoeven wrote: > > Hi Prabhakar, > > On Sun, May 3, 2020 at 11:47 PM Lad Prabhakar > wrote: > > Add support for r8a7742 SoC. Renesas RZ/G1H (R8A7742) MMCIF is identical > > to the R-Car Gen2 family. > > > > Signed-of

[PATCH v3 3/7] net: macb: fix macb_get/set_wol() when moving to phylink

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre Keep previous function goals and integrate phylink actions to them. phylink_ethtool_get_wol() is not enough to figure out if Ethernet driver supports Wake-on-Lan. Initialization of "supported" and "wolopts" members is done in phylink function, no need to keep them in calling

[PATCH v3 2/7] net: macb: mark device wake capable when "magic-packet" property present

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre Change the way the "magic-packet" DT property is handled in the macb_probe() function, matching DT binding documentation. Now we mark the device as "wakeup capable" instead of calling the device_init_wakeup() function that would enable the wakeup source. For Ethernet WoL, ena

RE: Implement close-on-fork

2020-05-04 Thread Karstens, Nate
Thanks everyone for their comments, sorry for the delay in my reply. > As for the original problem... what kind of exclusion is used between the > reaction to netlink notifications (including closing every socket, > etc.) and actual IO done on those sockets? > Not an idle question, BTW - unlike

[PATCH v3 7/7] net: macb: Add WoL interrupt support for MACB type of Ethernet controller

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre Handle the Wake-on-Lan interrupt for the Cadence MACB Ethernet controller. As we do for the GEM version, we handle of WoL interrupt in a specialized interrupt handler for MACB version that is positionned just between suspend() and resume() calls. Cc: Claudiu Beznea Cc: Harin

[PATCH v3 6/7] net: macb: WoL support for GEM type of Ethernet controller

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre Adapt the Wake-on-Lan feature to the Cadence GEM Ethernet controller. This controller has different register layout and cannot be handled by previous code. We disable completely interrupts on all the queues but the queue 0. Handling of WoL interrupt is done in another interrup

[PATCH v3 4/7] net: macb: fix macb_suspend() by removing call to netif_carrier_off()

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre As we now use the phylink call to phylink_stop() in the non-WoL path, there is no need for this call to netif_carrier_off() anymore. It can disturb the underlying phylink FSM. Fixes: 7897b071ac3b ("net: macb: convert to phylink") Cc: Claudiu Beznea Cc: Harini Katakam Cc: An

[PATCH v3 0/7] net: macb: Wake-on-Lan magic packet fixes and GEM handling

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre Hi, Here is the 3rd series to fix WoL magic-packet on the current macb driver. I also add, in the second part of this series the feature to GEM types of IPs. Please tell me if they should be separated; but the two last patches cannot go without the 5 fixes first ones. MACB an

[PATCH v3 5/7] net: macb: fix call to pm_runtime in the suspend/resume functions

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre The calls to pm_runtime_force_suspend/resume() functions are only relevant if the device is not configured to act as a WoL wakeup source. Add the device_may_wakeup() test before calling them. Fixes: 3e2a5e153906 ("net: macb: add wake-on-lan support via magic packet") Cc: Clau

[PATCH v3 1/7] net: macb: fix wakeup test in runtime suspend/resume routines

2020-05-04 Thread nicolas.ferre
From: Nicolas Ferre Use the proper struct device pointer to check if the wakeup flag and wakeup source are positioned. Use the one passed by function call which is equivalent to &bp->dev->dev.parent. It's preventing the trigger of a spurious interrupt in case the Wake-on-Lan feature is used. Fi

Re: linux-5.7-rc4/fs/io_uring.c:2786: bad if test ?

2020-05-04 Thread Jens Axboe
On 5/4/20 2:12 AM, David Binderman wrote: > Hello there, > > linux-5.7-rc4/fs/io_uring.c:2786:6: warning: Identical condition > 'force_nonblock', second condition is always false > [identicalConditionAfterEarlyExit] > > Source code is > > if (force_nonblock) > return -EAGAIN; > >

Re: [PATCH] net: rtw88: fix an issue about leak system resources

2020-05-04 Thread Markus Elfring
> the related system resources were not released when pci_iomap() return > error in the rtw_pci_io_mapping() function. add pci_release_regions() to > fix it. How do you think about a wording variant like the following? Subject: [PATCH v2] net: rtw88: Complete exception handling in rtw_pci_i

Re: [PATCH] memcg: oom: ignore oom warnings from memory.max

2020-05-04 Thread Shakeel Butt
On Sun, May 3, 2020 at 11:56 PM Michal Hocko wrote: > > On Thu 30-04-20 11:27:12, Shakeel Butt wrote: > > Lowering memory.max can trigger an oom-kill if the reclaim does not > > succeed. However if oom-killer does not find a process for killing, it > > dumps a lot of warnings. > > It shouldn't dum

Re: [PATCH] memcg: oom: ignore oom warnings from memory.max

2020-05-04 Thread Shakeel Butt
On Sun, May 3, 2020 at 11:57 PM Michal Hocko wrote: > > On Thu 30-04-20 13:20:10, Shakeel Butt wrote: > > On Thu, Apr 30, 2020 at 12:29 PM Johannes Weiner wrote: > > > > > > On Thu, Apr 30, 2020 at 11:27:12AM -0700, Shakeel Butt wrote: > > > > Lowering memory.max can trigger an oom-kill if the re

[PATCH 6/8] hfsplus: stop using ioctl_by_bdev

2020-05-04 Thread Christoph Hellwig
Instead just call the CDROM layer functionality directly. Signed-off-by: Christoph Hellwig Reviewed-by: Damien Le Moal Reviewed-by: Hannes Reinecke s_bdev->bd_disk); /* default values */ *start = 0; *size = i_size_read(sb->s_bdev->bd_inode) >> 9; if (HFSPLUS_S

[PATCH 1/8] block: add a cdrom_device_info pointer to struct gendisk

2020-05-04 Thread Christoph Hellwig
Add a pointer to the CDROM information structure to struct gendisk. This will allow various removable media file systems to call directly into the CDROM layer instead of abusing ioctls with kernel pointers. Signed-off-by: Christoph Hellwig Reviewed-by: Damien Le Moal Reviewed-by: Hannes Reinecke

stop using ioctl_by_bdev for file system access to CDROMs v3

2020-05-04 Thread Christoph Hellwig
Hi Jens, can you pick up this series? Except for the DASD case under discussion the last users of ioctl_by_bdev are the file system drivers that want to query CDROM information using ioctls. This series switches them to use function calls directly into the CDROM midlayer instead, which implies:

[PATCH 2/8] ide-cd: rename cdrom_read_tocentry

2020-05-04 Thread Christoph Hellwig
Give the cdrom_read_tocentry function and ide_ prefix to not conflict with the soon to be added generic function. Signed-off-by: Christoph Hellwig Reviewed-by: Damien Le Moal Reviewed-by: Hannes Reinecke hdr, + stat = ide_cdrom_read_tocentry(drive, 0, 1, 0, (char *) &toc->hdr,

[PATCH 7/8] isofs: stop using ioctl_by_bdev

2020-05-04 Thread Christoph Hellwig
Instead just call the CDROM layer functionality directly, and turn the hot mess in isofs_get_last_session into remotely readable code. Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Reviewed-by: Damien Le Moal Reviewed-by: Hannes Reinecke s_bdev; - int i; + struct cdrom_devi

[PATCH 8/8] udf: stop using ioctl_by_bdev

2020-05-04 Thread Christoph Hellwig
Instead just call the CDROM layer functionality directly. Signed-off-by: Christoph Hellwig Reviewed-by: Jan Kara Reviewed-by: Damien Le Moal Reviewed-by: Hannes Reinecke --- fs/udf/lowlevel.c | 29 + 1 file changed, 13 insertions(+), 16 deletions(-) diff --git a/f

[PATCH 5/8] hfs: stop using ioctl_by_bdev

2020-05-04 Thread Christoph Hellwig
Instead just call the CDROM layer functionality directly. Signed-off-by: Christoph Hellwig --- fs/hfs/mdb.c | 32 +++- 1 file changed, 19 insertions(+), 13 deletions(-) diff --git a/fs/hfs/mdb.c b/fs/hfs/mdb.c index 460281b1299eb..cdf0edeeb2781 100644 --- a/fs/hfs/md

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