[PATCH v5 43/80] drm/vc4: hdmi: Move accessors to vc4_hdmi

2020-09-03 Thread Maxime Ripard
The current driver only supports a single HDMI controller, and part of the issue is that the main vc4_dev structure holds a pointer to its (only) HDMI controller, and the HDMI registers accessors will use it to retrieve the mapped addresses. Let's modify those accessors to use directly the vc4_hdm

[PATCH v5 51/80] drm/vc4: hdmi: Implement a register layout abstraction

2020-09-03 Thread Maxime Ripard
The HDMI controllers found in the BCM2711 have most of the registers reorganized in multiple registers areas and at different offsets than previously found. The logic however remains pretty much the same, so it doesn't really make sense to create a whole new driver and we should share the code as

[PATCH v5 36/80] dt-bindings: display: vc4: pv: Add BCM2711 pixel valves

2020-09-03 Thread Maxime Ripard
The BCM2711 comes with other pixelvalves that have different requirements and capabilities. Let's document their compatible. Reviewed-by: Rob Herring Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- Documentat

[PATCH v5 38/80] drm/vc4: hdmi: Use debugfs private field

2020-09-03 Thread Maxime Ripard
We're calling vc4_debugfs_add_file with our struct vc4_hdmi pointer set in the private field, but we don't use that field and go through the main struct vc4_dev to get it. Let's use the private field directly, that will save us some trouble later on. Reviewed-by: Eric Anholt Tested-by: Chanwoo C

[PATCH v5 47/80] drm/vc4: hdmi: Retrieve the vc4_hdmi at unbind using our device

2020-09-03 Thread Maxime Ripard
The unbind function needs to retrieve a vc4_hdmi structure pointer through the struct device that we're given since we want to support multiple HDMI controllers. However, our optional ASoC support doesn't make that trivial since it will overwrite the device drvdata if we use it, but obviously won'

[PATCH v5 48/80] drm/vc4: hdmi: Remove vc4_dev hdmi pointer

2020-09-03 Thread Maxime Ripard
Now that we don't have any users anymore, we can kill that pointer. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_drv.h | 1 - drivers/gpu/drm/vc4/vc4_hdmi.c | 7 --- 2 files cha

Re: [PATCH v6 09/20] gpiolib: cdev: support edge detection for uAPI v2

2020-09-03 Thread Kent Gibson
On Thu, Sep 03, 2020 at 09:55:22AM +0200, Bartosz Golaszewski wrote: > On Mon, Aug 31, 2020 at 5:22 AM Kent Gibson wrote: > > > > Add support for edge detection to lines requested using > > GPIO_V2_GET_LINE_IOCTL. > > > > The edge_detector implementation is based on the v1 lineevent > > implementa

[PATCH v5 27/80] drm/vc4: crtc: Move HVS channel init before the PV initialisation

2020-09-03 Thread Maxime Ripard
In order to avoid stale pixels getting stuck in an intermediate FIFO between the HVS and the pixelvalve on BCM2711, we need to configure the HVS channel before the pixelvalve is reset and configured. Reviewed-by: Dave Stevenson Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan W

[PATCH v5 22/80] drm/vc4: crtc: Move HVS init and close to a function

2020-09-03 Thread Maxime Ripard
In order to make further refactoring easier, let's move the HVS channel setup / teardown to their own function. Reviewed-by: Dave Stevenson Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_hvs.c | 104 ++

[PATCH v5 26/80] drm/vc4: crtc: Remove redundant pixelvalve reset

2020-09-03 Thread Maxime Ripard
Since we moved the pixelvalve configuration to atomic_enable, we're now first calling the function that resets the pixelvalve and then the one that configures it. However, the first thing the latter is doing is calling the reset function, meaning that we reset twice our pixelvalve. Let's remove th

[PATCH v5 29/80] drm/vc4: crtc: Add a delay after disabling the PixelValve output

2020-09-03 Thread Maxime Ripard
In order to avoid pixels getting stuck in the (unflushable) FIFO between the HVS and the PV, we need to add some delay after disabling the PV output and before disabling the HDMI controller. 20ms seems to be good enough so let's use that. Reviewed-by: Dave Stevenson Tested-by: Chanwoo Choi Teste

[PATCH v5 30/80] drm/vc4: crtc: Clear the PixelValve FIFO on disable

2020-09-03 Thread Maxime Ripard
In order to avoid a stale pixel getting stuck on mode change or a disable / enable cycle, we need to make sure to flush the PV FIFO on disable. Reviewed-by: Dave Stevenson Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/dr

[PATCH v5 28/80] drm/vc4: encoder: Add finer-grained encoder callbacks

2020-09-03 Thread Maxime Ripard
In the BCM2711, the setup of the HVS, pixelvalve and HDMI controller requires very precise ordering and timing that the regular atomic callbacks don't provide. Let's add new callbacks on top of the regular ones to be able to split the configuration as needed. Reviewed-by: Dave Stevenson Tested-by

[PATCH v5 21/80] drm/vc4: crtc: Move PV dump to config_pv

2020-09-03 Thread Maxime Ripard
Now that we only configure the PixelValve in vc4_crtc_config_pv, it doesn't really make much sense to dump its register content in its caller. Reviewed-by: Dave Stevenson Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/drm

[PATCH v5 23/80] drm/vc4: crtc: Move the HVS gamma LUT setup to our init function

2020-09-03 Thread Maxime Ripard
Since most of the HVS channel is setup in the init function, let's move the gamma setup there too. As this makes the HVS mode_set function empty, let's remove it in the process. Reviewed-by: Dave Stevenson Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by:

[PATCH v5 25/80] drm/vc4: crtc: Remove mode_set_nofb

2020-09-03 Thread Maxime Ripard
On BCM2711 to avoid stale pixels getting stuck in intermediate FIFOs, the pixelvalve needs to be setup each time there's a mode change or enable / disable sequence. Therefore, we can't really use mode_set_nofb anymore to configure it, but we need to move it to atomic_enable. Reviewed-by: Dave Ste

[PATCH v5 19/80] drm/vc4: crtc: Disable color management for HVS5

2020-09-03 Thread Maxime Ripard
The HVS5 uses different color matrices. Disable color management support for now. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_crtc.c | 17 +++-- drivers/gpu/drm/vc4/vc4_

[PATCH v5 18/80] drm/vc4: crtc: Add HDMI1 encoder type

2020-09-03 Thread Maxime Ripard
The BCM2711 sports a second HDMI controller, so let's add that second HDMI encoder type. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_drv.h | 1 + 1 file changed, 1 insertion(+) dif

Re: [PATCH] mmc: sdhci-msm: Prefer asynchronous probe

2020-09-03 Thread Ulf Hansson
On Thu, 3 Sep 2020 at 01:43, Douglas Anderson wrote: > > Turning on initcall debug on one system showed this: > initcall sdhci_msm_driver_init+0x0/0x28 returned 0 after 34782 usecs > > The lion's share of this time (~33 ms) was in mmc_power_up(). This > shouldn't be terribly surprising since th

Re: [PATCH 2/3] mmc: s3cmci: Use proper printk format for iomem pointer

2020-09-03 Thread Ulf Hansson
On Wed, 2 Sep 2020 at 22:49, Krzysztof Kozlowski wrote: > > iomem pointers should be printed with pointer format to hide the > actual value and fix warnings when compile testing for 64-bit > architecture: > > drivers/mmc/host/s3cmci.c:1355:46: warning: > cast from pointer to integer of diffe

[PATCH v5 17/80] drm/vc4: crtc: Rename HDMI encoder type to HDMI0

2020-09-03 Thread Maxime Ripard
The previous generations were only supporting a single HDMI controller, but that's about to change, so put an index as well to differentiate between the two controllers. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripa

Re: [PATCH] irqchip/tango: Fix possible null ptr reference in tangox_irq_init

2020-09-03 Thread Marc Zyngier
On 2020-09-03 02:59, Ye Bin wrote: In tangox_irq_init allocate chip but not test. Signed-off-by: Ye Bin --- drivers/irqchip/irq-tango.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/irqchip/irq-tango.c b/drivers/irqchip/irq-tango.c index 34290f09b853..25da120230ad 100644 --- a/

Re: [PATCH v2] mmc: sdhci-of-esdhc: Don't walk device-tree on every interrupt

2020-09-03 Thread Ulf Hansson
On Thu, 3 Sep 2020 at 03:20, Chris Packham wrote: > > Commit b214fe592ab7 ("mmc: sdhci-of-esdhc: add erratum eSDHC7 support") > added code to check for a specific compatible string in the device-tree > on every esdhc interrupat. Instead of doing this record the quirk in > struct sdhci_esdhc and lo

Re: [PATCH 1/3] mmc: davinci: Fix -Wpointer-to-int-cast on compile test

2020-09-03 Thread Ulf Hansson
On Wed, 2 Sep 2020 at 22:48, Krzysztof Kozlowski wrote: > > Store in interrupt service routine always '1' in end_command, not the > value of host->cmd to fix compile test warnings on RISC-V: > > drivers/mmc/host/davinci_mmc.c:999:17: warning: > cast from pointer to integer of different size

Re: [RFT 06/11] mmc: sdhci-brcmstb: Simplify with optional clock and dev_err_probe()

2020-09-03 Thread Ulf Hansson
On Wed, 2 Sep 2020 at 21:58, Florian Fainelli wrote: > > > > On 9/2/2020 12:36 PM, Krzysztof Kozlowski wrote: > > Only -ENOENT from devm_clk_get() means that clock is not present in > > device tree. Other errors have their own meaning and should not be > > ignored. > > > > Simplify getting the cl

Re: [PATCH] mmc: s3cmci: Drop unused variables in dbg_dumpregs

2020-09-03 Thread Ulf Hansson
On Thu, 3 Sep 2020 at 07:43, Krzysztof Kozlowski wrote: > > The 'imask' and 'bsize' are not used in dbg_dumpregs: > > drivers/mmc/host/s3cmci.c:149:36: warning: variable 'imask' set but not > used [-Wunused-but-set-variable] > drivers/mmc/host/s3cmci.c:148:63: warning: variable 'bsize' set bu

Re: [PATCH v2] mmc: mmc_spi: Allow the driver to be built when CONFIG_HAS_DMA is unset

2020-09-03 Thread Ulf Hansson
On Thu, 3 Sep 2020 at 02:41, Rich Felker wrote: > > On Wed, Sep 02, 2020 at 05:51:16PM +0200, Geert Uytterhoeven wrote: > > Hi Rich, > > > > On Wed, Sep 2, 2020 at 5:43 PM Rich Felker wrote: > > > On Wed, Sep 02, 2020 at 10:31:47AM +0200, Ulf Hansson wrote: > > > > On Tue, 1 Sep 2020 at 17:40, Ch

Re: [PATCH 3/3] mmc: s3cmci: Cast driver data through long

2020-09-03 Thread Ulf Hansson
On Wed, 2 Sep 2020 at 22:49, Krzysztof Kozlowski wrote: > > Since driver data is a pointer, direct casting to integer causes > warning when compile testing for 64-bit architecture: > > drivers/mmc/host/s3cmci.c:1495:17: warning: cast from pointer to integer of > different size [-Wpointer-to-int

Re: [PATCH 00/11] mmc: Minor cleanups and compile test

2020-09-03 Thread Ulf Hansson
On Wed, 2 Sep 2020 at 21:37, Krzysztof Kozlowski wrote: > > Hi, > > Set of minor cleanups. Patches requiring more attention: > - 6/11: Testing and review would be appreciated, > - 11/11: I build tested multiple architectures but not all and >definitely no all possible configs. This one coul

[PATCH v5 31/80] drm/vc4: crtc: Clear the PixelValve FIFO during configuration

2020-09-03 Thread Maxime Ripard
Even though it's not really clear why we need to flush the PV FIFO during the configuration even though we started by flushing it, experience shows that without it we get a stale pixel stuck in the FIFO between the HVS and the PV. Reviewed-by: Dave Stevenson Tested-by: Chanwoo Choi Tested-by: Ho

Re: [PATCH v6 00/20] gpio: cdev: add uAPI v2

2020-09-03 Thread Bartosz Golaszewski
On Mon, Aug 31, 2020 at 5:21 AM Kent Gibson wrote: > > This patchset defines and implements a new version of the > GPIO CDEV uAPI to address existing 32/64-bit alignment issues, add > support for debounce, event sequence numbers, and allow for requested > lines with different configurations. > It

[PATCH v5 16/80] drm/vc4: crtc: Add function to compute FIFO level bits

2020-09-03 Thread Maxime Ripard
The longer FIFOs in vc5 pixelvalves means that the FIFO full level doesn't fit in the original register field and that we also have a secondary field. In order to prepare for this, let's move the registers fill part to a helper function. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by

[PATCH v5 20/80] drm/vc4: crtc: Turn pixelvalve reset into a function

2020-09-03 Thread Maxime Ripard
The driver resets the pixelvalve FIFO in a number of occurences without always using the same sequence. Since this will be critical for BCM2711, let's move that sequence to a function so that we are consistent. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by:

[PATCH 17/19] z2ram: reindent

2020-09-03 Thread Christoph Hellwig
reindent the driver using Lident as the code style was far away from normal Linux code. Signed-off-by: Christoph Hellwig --- drivers/block/z2ram.c | 493 -- 1 file changed, 236 insertions(+), 257 deletions(-) diff --git a/drivers/block/z2ram.c b/drivers/b

[PATCH 15/19] amiflop: use separate gendisks for Amiga vs MS-DOS mode

2020-09-03 Thread Christoph Hellwig
Use separate gendisks (which share a tag_set) for the native Amgiga vs the MS-DOS mode instead of redirecting the gendisk lookup using a probe callback. This avoids potential problems with aliased block_device instances and will eventually allow for removing the blk_register_region framework. Sig

[PATCH v5 13/80] drm/vc4: kms: Convert to for_each_new_crtc_state

2020-09-03 Thread Maxime Ripard
The vc4 atomic commit loop has an handrolled loop that is basically identical to for_each_new_crtc_state, let's convert it to that helper. Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_kms.c | 10 ++ 1

[PATCH 02/19] block: merge drivers/base/map.c into block/genhd.c

2020-09-03 Thread Christoph Hellwig
Now that there is just a single user of the kobj_map functionality left, merge it into the user to prepare for additional simplications. Signed-off-by: Christoph Hellwig Reviewed-by: Greg Kroah-Hartman --- block/genhd.c| 130 + drivers/base/Makefile

[PATCH 01/19] char_dev: replace cdev_map with an xarray

2020-09-03 Thread Christoph Hellwig
None of the complicated overlapping regions bits of the kobj_map are required for the character device lookup, so just a trivial xarray instead. Signed-off-by: Christoph Hellwig Reviewed-by: Greg Kroah-Hartman --- fs/char_dev.c | 94 +-- fs/dcache

[PATCH 19/19] block: switch gendisk lookup to a simple xarray

2020-09-03 Thread Christoph Hellwig
Now that bdev_map is only used for finding gendisks, we can use a simple xarray instead of the regions tracking structure for it. Signed-off-by: Christoph Hellwig Reviewed-by: Greg Kroah-Hartman --- block/genhd.c | 208 -- include/linux/genhd.h |

[PATCH v5 07/80] drm/vc4: crtc: Deal with different number of pixel per clock

2020-09-03 Thread Maxime Ripard
Some of the HDMI pixelvalves in vc5 output two pixels per clock cycle. Let's put the number of pixel output per clock cycle in the CRTC data and update the various calculations to reflect that. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Si

[PATCH v5 01/80] dt-bindings: display: Add support for the BCM2711 HVS

2020-09-03 Thread Maxime Ripard
The HVS found in the BCM2711 is slightly different from the previous generations, let's add a compatible for it. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- Documentation/devicetree/bindings/display/brcm,b

[PATCH v5 05/80] drm/vc4: plane: Optimize the LBM allocation size

2020-09-03 Thread Maxime Ripard
From: Dave Stevenson The current code is using the maximum of the source line size and the destination line size to compute the size of the LBM to allocate. While this is simpler, it starts to be an issue with modes such as 4k with a quite long that will consume all the available memory, so we n

[PATCH v5 00/80] drm/vc4: Support BCM2711 Display Pipeline

2020-09-03 Thread Maxime Ripard
Hi everyone, Here's a (pretty long) series to introduce support in the VC4 DRM driver for the display pipeline found in the BCM2711 (and thus the RaspberryPi 4). The main differences are that there's two HDMI controllers and that there's more pixelvalve now. Those pixelvalve come with a mux in th

[PATCH v5 08/80] drm/vc4: crtc: Use a shared interrupt

2020-09-03 Thread Maxime Ripard
Some pixelvalves in vc5 use the same interrupt line so let's register our interrupt handler as a shared one. Reviewed-by: Eric Anholt Tested-by: Chanwoo Choi Tested-by: Hoegeun Kwon Tested-by: Stefan Wahren Signed-off-by: Maxime Ripard --- drivers/gpu/drm/vc4/vc4_crtc.c | 4 +++- 1 file chan

[PATCH v5 10/80] drm/vc4: crtc: Rename HVS channel to output

2020-09-03 Thread Maxime Ripard
In vc5, the HVS has 6 outputs and 3 FIFOs (or channels), with pixelvalves each being assigned to a given output, but each output can then be muxed to feed from multiple FIFOs. Since vc4 had that entirely static, both were probably equivalent, but since that changes, let's rename hvs_channel to hvs

Re: [PATCH] sh: fix syscall tracing

2020-09-03 Thread John Paul Adrian Glaubitz
Hi Rich! On 9/3/20 7:48 AM, Rich Felker wrote: > Addition of SECCOMP_FILTER exposed a longstanding bug in > do_syscall_trace_enter, whereby r0 (the 5th argument register) was > mistakenly used where r3 (syscall_nr) was intended. By overwriting r0 > rather than r3 with -1 when attempting to block a

[PATCH 13/19] ide: switch to __register_blkdev for command set probing

2020-09-03 Thread Christoph Hellwig
ide is the last user of the blk_register_region framework except for the tracking of allocated gendisk. Switch to __register_blkdev, even if that doesn't allow us to trivially find out which command set to probe for. That means we now always request all modules when a user tries to access an uncla

[PATCH 12/19] md: use __register_blkdev to allocate devices on demand

2020-09-03 Thread Christoph Hellwig
Use the simpler mechanism attached to major_name to allocate a brd device when a currently unregistered minor is accessed. Signed-off-by: Christoph Hellwig Acked-by: Song Liu --- drivers/md/md.c | 21 - 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/drivers/m

[PATCH 14/19] floppy: use a separate gendisk for each media format

2020-09-03 Thread Christoph Hellwig
The floppy driver usually autodetects the media when used with the normal /dev/fd? devices, which also are the only nodes created by udev. But it also supports various aliases that force a given media format. That is currently supported using the blk_register_region framework which finds the floppy

Re: [PATCH v6 09/20] gpiolib: cdev: support edge detection for uAPI v2

2020-09-03 Thread Bartosz Golaszewski
On Thu, Sep 3, 2020 at 10:09 AM Kent Gibson wrote: > > On Thu, Sep 03, 2020 at 09:55:22AM +0200, Bartosz Golaszewski wrote: > > On Mon, Aug 31, 2020 at 5:22 AM Kent Gibson wrote: > > > > > > Add support for edge detection to lines requested using > > > GPIO_V2_GET_LINE_IOCTL. > > > > > > The edge

[PATCH 11/19] loop: use __register_blkdev to allocate devices on demand

2020-09-03 Thread Christoph Hellwig
Use the simpler mechanism attached to major_name to allocate a brd device when a currently unregistered minor is accessed. Signed-off-by: Christoph Hellwig --- drivers/block/loop.c | 30 -- 1 file changed, 8 insertions(+), 22 deletions(-) diff --git a/drivers/block/l

[PATCH 08/19] swim: don't call blk_register_region

2020-09-03 Thread Christoph Hellwig
The swim driver (unlike various other floppy drivers) doesn't have magic device nodes for certain modes, and already registers a gendisk for each of the floppies supported by a device. Thus the region registered is a no-op and can be removed. Signed-off-by: Christoph Hellwig --- drivers/block/s

Re: [PATCH 2/2] iommu: amd: Use cmpxchg_double() when updating 128-bit IRTE

2020-09-03 Thread Suravee Suthikulpanit
Hi, I'll send out V2 with fixes to the review comments below ... On 9/2/20 10:26 PM, Joao Martins wrote: On 9/2/20 5:51 AM, Suravee Suthikulpanit wrote: When using 128-bit interrupt-remapping table entry (IRTE) (a.k.a GA mode), current driver disables interrupt remapping when it updates the IR

Re: [PATCH 16/19] ataflop: use a separate gendisk for each media format

2020-09-03 Thread John Paul Adrian Glaubitz
Hi Christoph! On 9/3/20 10:01 AM, Christoph Hellwig wrote: > The Atari floppy driver usually autodetects the media when used with the > ormal /dev/fd? devices, which also are the only nodes created by udev. typo? Adrian -- .''`. John Paul Adrian Glaubitz : :' : Debian Developer - gl

simplify gendisk lookup and remove struct block_device aliases v3

2020-09-03 Thread Christoph Hellwig
Hi all, this series removes the annoying struct block_device aliases, which can happen for a bunch of old floppy drivers (and z2ram). In that case multiple struct block device instances for different dev_t's can point to the same gendisk, without being partitions. The cause for that is the probe

[PATCH 09/19] sd: use __register_blkdev to avoid a modprobe for an unregistered dev_t

2020-09-03 Thread Christoph Hellwig
Switch from using blk_register_region to the probe callback passed to __register_blkdev to disable the request_module call for an unclaimed dev_t in the SD majors. Signed-off-by: Christoph Hellwig --- drivers/scsi/sd.c | 19 +-- 1 file changed, 5 insertions(+), 14 deletions(-) d

[PATCH 07/19] ide: remove ide_{,un}register_region

2020-09-03 Thread Christoph Hellwig
There is no need to ever register the fake gendisk used for ide-tape. Signed-off-by: Christoph Hellwig Reviewed-by: Hannes Reinecke --- drivers/ide/ide-probe.c | 32 drivers/ide/ide-tape.c | 2 -- include/linux/ide.h | 3 --- 3 files changed, 37 deletions

[PATCH v8 5/6] media: i2c: imx319: Support probe while the device is off

2020-09-03 Thread Sakari Ailus
From: Rajmohan Mani Tell ACPI device PM code that the driver supports the device being powered off when the driver's probe function is entered. Signed-off-by: Rajmohan Mani Signed-off-by: Sakari Ailus --- drivers/media/i2c/imx319.c | 74 +++--- 1 file changed,

linux-next: Tree for Sep 3

2020-09-03 Thread Stephen Rothwell
Hi all, News: There will be no linux-next release tomorrow or Monday. Changes since 20200902: The tip tree merged badly today so I had to apply a merge fix patch. The scsi-mkp tree gained a conflict against Linus' tree. Non-merge commits (relative to Linus' tree): 4011 5122 files changed, 145

[PATCH v8 1/6] i2c: Allow an ACPI driver to manage the device's power state during probe

2020-09-03 Thread Sakari Ailus
Enable drivers to tell ACPI that there's no need to power on a device for probe. Drivers should still perform this by themselves if there's a need to. In some cases powering on the device during probe is undesirable, and this change enables a driver to choose what fits best for it. Add a field cal

[PATCH v8 6/6] at24: Support probing while off

2020-09-03 Thread Sakari Ailus
In certain use cases (where the chip is part of a camera module, and the camera module is wired together with a camera privacy LED), powering on the device during probe is undesirable. Add support for the at24 to execute probe while being powered off. For this to happen, a hint in form of a device

[PATCH v8 4/6] ov5670: Support probe whilst the device is in a low power state

2020-09-03 Thread Sakari Ailus
Tell ACPI device PM code that the driver supports the device being in a low power state when the driver's probe function is entered. Also do identification on the first access of the device, whether in probe or when starting streaming. Signed-off-by: Sakari Ailus --- drivers/media/i2c/ov5670.c

[PATCH v8 2/6] Documentation: ACPI: Document i2c-allow-low-power-probe _DSD property

2020-09-03 Thread Sakari Ailus
Document the probe-low-power _DSD property and how it is used with I²C drivers. Signed-off-by: Sakari Ailus --- .../acpi/dsd/i2c-allow-low-power-probe.rst| 60 +++ Documentation/firmware-guide/acpi/index.rst | 1 + 2 files changed, 61 insertions(+) create mode 100644 Doc

[PATCH 06/19] block: add an optional probe callback to major_names

2020-09-03 Thread Christoph Hellwig
Add a callback to the major_names array that allows a driver to override how to probe for dev_t that doesn't currently have a gendisk registered. This will help separating the lookup of the gendisk by dev_t vs probe action for a not currently registered dev_t. Signed-off-by: Christoph Hellwig ---

[PATCH 03/19] block: cleanup del_gendisk a bit

2020-09-03 Thread Christoph Hellwig
Merge three hidden gendisk checks into one. Signed-off-by: Christoph Hellwig --- block/genhd.c | 15 --- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/block/genhd.c b/block/genhd.c index 44f69f4b2c5aa6..ec9b64207d9c2e 100644 --- a/block/genhd.c +++ b/block/genhd.c @@

Re: [PATCH 1/1] iommu/vt-d: Fix NULL pointer dereference in dev_iommu_priv_set()

2020-09-03 Thread Torsten Hilbrich
On 03.09.20 08:51, Lu Baolu wrote: > The dev_iommu_priv_set() must be called after probe_device(). This fixes > a NULL pointer deference bug when booting a system with kernel cmdline > "intel_iommu=on,igfx_off", where the dev_iommu_priv_set() is abused. [...] > > Fixes: 01b9d4e21148c ("iommu/vt-d

[PATCH 04/19] block: split block_class_lock

2020-09-03 Thread Christoph Hellwig
Split the block_class_lock mutex into one each to protect bdev_map and major_names. Signed-off-by: Christoph Hellwig --- block/genhd.c | 29 +++-- 1 file changed, 15 insertions(+), 14 deletions(-) diff --git a/block/genhd.c b/block/genhd.c index ec9b64207d9c2e..034e90899

[PATCH v8 0/6] Support running driver's probe for a device powered off

2020-09-03 Thread Sakari Ailus
Hi all, These patches enable calling (and finishing) a driver's probe function without powering on the respective device on busses where the practice is to power on the device for probe. While it generally is a driver's job to check the that the device is there, there are cases where it might be

[PATCH v8 3/6] ACPI: Add a convenience function to tell a device is in low power state

2020-09-03 Thread Sakari Ailus
Add a convenience function to tell whether a device is in low power state, primarily for use in drivers' probe or remove functions on busses where the custom is to power on the device for the duration of both. Returns false on non-ACPI systems. Suggested-by: Mika Westerberg Signed-off-by: Sakari

Re: [PATCH v4 1/4] mm/pageblock: mitigation cmpxchg false sharing in pageblock flags

2020-09-03 Thread David Hildenbrand
On 03.09.20 09:01, Alex Shi wrote: > pageblock_flags is used as long, since every pageblock_flags is just 4 > bits, 'long' size will include 8(32bit machine) or 16 pageblocks' flags, > that flag setting has to sync in cmpxchg with 7 or 15 other pageblock > flags. It would cause long waiting for syn

Re: [PATCH 2/9] block: add a bdev_is_partition helper

2020-09-03 Thread Ulf Hansson
On Thu, 3 Sep 2020 at 07:42, Christoph Hellwig wrote: > > Add a littler helper to make the somewhat arcane bd_contains checks a > little more obvious. > > Signed-off-by: Christoph Hellwig Not sure why we have both "bd_contains" and "bd_partno", nevertheless, feel free to add: Acked-by: Ulf Hans

Re: [PATCH v2 2/3] remoteproc: qcom: Add capability to collect minidumps

2020-09-03 Thread kernel test robot
use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Gurbir-Arora/Introduce-mini-dump-support-for-remoteproc/20200903-105359 base: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds

Re: [RESEND PATCH v2] mfd: syscon: Use a unique name with regmap_config

2020-09-03 Thread Marc Zyngier
On 2020-08-27 21:32, Suman Anna wrote: Hi Marc, + Mark Brown On 8/27/20 3:06 PM, Marc Zyngier wrote: Hi Suman, On 2020-08-27 19:28, Suman Anna wrote: Hi Marc, On 8/27/20 9:46 AM, Marc Zyngier wrote: [...] This patch triggers some illegal memory accesses when debugfs is enabled, as regma

Re: [PATCH 2/9] block: add a bdev_is_partition helper

2020-09-03 Thread Christoph Hellwig
On Thu, Sep 03, 2020 at 10:19:34AM +0200, Ulf Hansson wrote: > On Thu, 3 Sep 2020 at 07:42, Christoph Hellwig wrote: > > > > Add a littler helper to make the somewhat arcane bd_contains checks a > > little more obvious. > > > > Signed-off-by: Christoph Hellwig > > Not sure why we have both "bd_c

Re: [PATCH v3 0/2] MIPS: Add support for ZSTD v3

2020-09-03 Thread Thomas Bogendoerfer
On Tue, Sep 01, 2020 at 04:26:49PM +0200, Paul Cercueil wrote: > Hi, > > This small patchset adds support for self-extracting kernels compressed > with ZSTD. > > Nick: > I dropped your Reviewed-by on patch [1/2] since the code changed. > > Cheers, > -Paul > > Paul Cercueil (2): > lib: decompr

Re: [PATCH] MIPS: perf: Fix wrong check condition of Loongson event IDs

2020-09-03 Thread Thomas Bogendoerfer
On Thu, Aug 27, 2020 at 04:03:08PM +0800, Tiezhu Yang wrote: > According to the user's manual chapter 8.2.1 of Loongson 3A2000 CPU [1] > and 3A3000 CPU [2], we should take some event IDs such as 274, 358, 359 > and 360 as valid in the check condition, otherwise they are recognized > as "not support

Re: [RESEND PATCH v2] dt-bindings: renesas,rcar-dmac: Document r8a7742 support

2020-09-03 Thread Vinod Koul
On 03-09-20, 08:38, Lad Prabhakar wrote: > Renesas RZ/G SoC also have the R-Car gen2/3 compatible DMA controllers. > Document RZ/G1H (also known as R8A7742) SoC bindings. Applied, thanks -- ~Vinod

Re: [PATCH] MIPS: SNI: Fix SCSI interrupt

2020-09-03 Thread Thomas Bogendoerfer
On Wed, Sep 02, 2020 at 11:32:14PM +0200, Thomas Bogendoerfer wrote: > On RM400(a20r) machines ISA and SCSI interrupts share the same interrupt > line. Commit 49e6e07e3c80 ("MIPS: pass non-NULL dev_id on shared > request_irq()") accidently dropped the IRQF_SHARED bit, which breaks > registering SCS

Re: [PATCH] MIPS: Use rcu to lookup a task in mipsmt_sys_sched_setaffinity()

2020-09-03 Thread Thomas Bogendoerfer
On Mon, Aug 31, 2020 at 01:14:02PM -0700, Davidlohr Bueso wrote: > The call simply looks up the corresponding task (without iterating > the tasklist), which is safe under rcu instead of the tasklist_lock. > In addition, the setaffinity counter part already does this. > > Signed-off-by: Davidlohr B

Re: [PATCH 00/11] mmc: Minor cleanups and compile test

2020-09-03 Thread Krzysztof Kozlowski
On Thu, 3 Sep 2020 at 10:10, Ulf Hansson wrote: > > Series applied for next, except 11, thanks! Thanks. I will fix pointed compile-test issues and send later a follow up, also removing the MMC dependency as pointed by Michał. Best regards, Krzysztof

Re: [PATCH v2 1/2] mm: use add_page_to_lru_list()/page_lru()/page_off_lru()

2020-09-03 Thread Michal Hocko
On Mon 31-08-20 11:50:41, Yu Zhao wrote: [...] > @@ -1860,16 +1859,11 @@ static unsigned noinline_for_stack > move_pages_to_lru(struct lruvec *lruvec, > lruvec = mem_cgroup_page_lruvec(page, pgdat); > > SetPageLRU(page); > - lru = page_lru(page); > - > -

[PATCH] dasd: remove the unused dasd_enable_device export

2020-09-03 Thread Christoph Hellwig
Signed-off-by: Christoph Hellwig --- drivers/s390/block/dasd.c | 1 - 1 file changed, 1 deletion(-) diff --git a/drivers/s390/block/dasd.c b/drivers/s390/block/dasd.c index eb17fea8075c6f..6ab992b3eed004 100644 --- a/drivers/s390/block/dasd.c +++ b/drivers/s390/block/dasd.c @@ -683,7 +683,6 @@ v

Re: [PATCH 3/6] ARM: dts: am335x: lxm: Fix PCA9539 GPIO expander properties

2020-09-03 Thread Tony Lindgren
* Krzysztof Kozlowski [200829 09:40]: > The PCA9539 GPIO expander requires GPIO controller properties to operate > properly. Best to merge this with the rest of the series: Acked-by: Tony Lindgren

Re: [PATCH v4 1/4] mm/pageblock: mitigation cmpxchg false sharing in pageblock flags

2020-09-03 Thread Alex Shi
在 2020/9/3 下午3:24, Mel Gorman 写道: > On Thu, Sep 03, 2020 at 03:01:20PM +0800, Alex Shi wrote: >> pageblock_flags is used as long, since every pageblock_flags is just 4 >> bits, 'long' size will include 8(32bit machine) or 16 pageblocks' flags, >> that flag setting has to sync in cmpxchg with 7 o

[PATCH] crypto: s5p-sss: remove redundant null check

2020-09-03 Thread Xu Wang
Because clk_disable_unprepare already checked NULL clock parameter, so the additional checks are unnecessary, just remove them. Signed-off-by: Xu Wang --- drivers/crypto/s5p-sss.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/drivers/crypto/s5p-sss.c b/drivers/crypto/

Re: [PATCH v6 00/20] gpio: cdev: add uAPI v2

2020-09-03 Thread Kent Gibson
On Thu, Sep 03, 2020 at 10:02:04AM +0200, Bartosz Golaszewski wrote: > On Mon, Aug 31, 2020 at 5:21 AM Kent Gibson wrote: > > > > This patchset defines and implements a new version of the > > GPIO CDEV uAPI to address existing 32/64-bit alignment issues, add > > support for debounce, event sequenc

[PATCH] Bluetooth: hci_qca: remove redundant null check

2020-09-03 Thread Xu Wang
Because clk_disable_unprepare already checked NULL clock parameter, so the additional check is unnecessary, just remove it. Signed-off-by: Xu Wang --- drivers/bluetooth/hci_qca.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/drivers/bluetooth/hci_qca.c b/drivers/bluetooth

INFO: task hung in io_uring_setup

2020-09-03 Thread syzbot
Hello, syzbot found the following issue on: HEAD commit:4442749a Add linux-next specific files for 20200902 git tree: linux-next console output: https://syzkaller.appspot.com/x/log.txt?x=12f9e91590 kernel config: https://syzkaller.appspot.com/x/.config?x=39134fcec6c78e33 dashboard

Re: linux-next: Tree for Aug 26

2020-09-03 Thread Anders Roxell
Hi Paul, On Sat, 29 Aug 2020 at 00:59, Paul E. McKenney wrote: > > On Fri, Aug 28, 2020 at 09:24:19PM +0200, Anders Roxell wrote: > > On Fri, 28 Aug 2020 at 15:29, Paul E. McKenney wrote: > > > > > > On Fri, Aug 28, 2020 at 09:37:17AM +0200, Anders Roxell wrote: > > > > On Wed, 26 Aug 2020 at 21

Re: Packet gets stuck in NOLOCK pfifo_fast qdisc

2020-09-03 Thread Paolo Abeni
On Wed, 2020-09-02 at 22:01 -0700, Cong Wang wrote: > Can you test the attached one-line fix? I think we are overthinking, > probably all > we need here is a busy wait. I think that will solve, but I also think that will kill NOLOCK performances due to really increased contention. At this point I

Re: [PATCH v2] soundwire: fix double free of dangling pointer

2020-09-03 Thread Vinod Koul
On 02-09-20, 13:26, t...@redhat.com wrote: > From: Tom Rix > > clang static analysis flags this problem > > stream.c:844:9: warning: Use of memory after > it is freed > kfree(bus->defer_msg.msg->buf); > ^~~ > > This happens in an error handler cleanin

Re: [PATCH v4 1/4] mm/pageblock: mitigation cmpxchg false sharing in pageblock flags

2020-09-03 Thread Alex Shi
在 2020/9/3 下午4:32, Alex Shi 写道: >> > I have run thpscale with 'always' defrag setting of THP. The Amean stddev is > much > larger than a very little average run time reducing. > > But the left patch 4 could show the cmpxchg retry reduce from thousands to > hundreds > or less. > > Subject: [P

Re: [PATCH 22/28] sgiseeq: convert from dma_cache_sync to dma_sync_single_for_device

2020-09-03 Thread Christoph Hellwig
On Wed, Sep 02, 2020 at 11:38:09PM +0200, Thomas Bogendoerfer wrote: > the patch below fixes the problem. But is very wrong unfortunately. > static inline void dma_sync_desc_cpu(struct net_device *dev, void *addr) > { > - dma_cache_sync(dev->dev.parent, addr, sizeof(struct sgiseeq_rx_desc

Re: [PATCH 22/28] sgiseeq: convert from dma_cache_sync to dma_sync_single_for_device

2020-09-03 Thread Christoph Hellwig
On Tue, Sep 01, 2020 at 07:38:10PM +0200, Thomas Bogendoerfer wrote: > this is the problem: > >/* Always check for received packets. */ > sgiseeq_rx(dev, sp, hregs, sregs); > > so the driver will look at the rx descriptor on every interrupt, so > we cache the rx descriptor on the

linux-next: Fixes tag needs some work in the mips-fixes tree

2020-09-03 Thread Stephen Rothwell
Hi all, In commit f8a005e1632c ("MIPS: add missing MSACSR and upper MSA initialization") Fixes tag Fixes: cc97ab235f ("MIPS: Simplify FP context initialization") has these problem(s): - SHA1 should be at least 12 digits long Can be fixed by setting core.abbrev to 12 (or more) or (fo

Re: [Re-send][PATCH] gpu/drm: remove drm_modeset_lock protection for drm_error

2020-09-03 Thread Daniel Vetter
On Wed, Sep 02, 2020 at 09:17:02PM +0800, Bernard wrote: > In function drm_atomic_helper_shutdown, maybe there is no need > to protect DRM_ERROR log in DRM_MODESET_LOCK_ALL_BEGIN & > DRM_MODESET_LOCK_ALL_END. This change is to make code run a bit > fast. > > Signed-off-by: Bernard Zhao This is o

Re: [PATCH v2 6/9] spi: spi-s3c64xx: Check return values

2020-09-03 Thread Lukasz Stelmach
It was <2020-09-02 śro 10:14>, when Sylwester Nawrocki wrote: > On 9/1/20 17:21, Lukasz Stelmach wrote: >> It was <2020-08-25 wto 21:06>, when Sylwester Nawrocki wrote: >>> On 8/21/20 18:13, Łukasz Stelmach wrote: Check return values in prepare_dma() and s3c64xx_spi_config() and propagate

Re: [PATCH 22/28] sgiseeq: convert from dma_cache_sync to dma_sync_single_for_device

2020-09-03 Thread Christoph Hellwig
On Thu, Sep 03, 2020 at 10:43:02AM +0200, Christoph Hellwig wrote: > On Tue, Sep 01, 2020 at 07:38:10PM +0200, Thomas Bogendoerfer wrote: > > this is the problem: > > > >/* Always check for received packets. */ > > sgiseeq_rx(dev, sp, hregs, sregs); > > > > so the driver will look

linux-next: Fixes tag needs some work in the scsi-fixes tree

2020-09-03 Thread Stephen Rothwell
Hi all, In commit b614d55b970d ("scsi: mpt3sas: Don't call disable_irq from IRQ poll handler") Fixes tag Fixes: 320e77acb3 scsi: mpt3sas: Irq poll to avoid CPU hard lockups has these problem(s): - SHA1 should be at least 12 digits long In commit d2af39141eea ("scsi: megaraid_sas: Do

[PATCH] mmc: host: omap-hsmmc: remove redundant null check

2020-09-03 Thread Xu Wang
Because clk_disable_unprepare already checked NULL clock parameter, so the additional checks are unnecessary, just remove them. Signed-off-by: Xu Wang --- drivers/mmc/host/omap_hsmmc.c | 18 ++ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/drivers/mmc/host/omap_h

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