[PATCH v3 1/1] drm/mm: add ig_frag selftest

2020-06-07 Thread Nirmoy Das
This patch introduces fragmentation in the address range and measures time taken by 10k and 20k insertions. ig_frag() will fail if the time taken by 20k insertions takes more than 4 times of 10k insertions as we know that insertions should at most scale quadratically. v2: introduce fragmentation b

Re: [PATCH 02/16] ACPI / LPSS: Save Cherry Trail PWM ctx registers only once (at activation)

2020-06-07 Thread Hans de Goede
Hi, On 6/7/20 7:03 PM, Andy Shevchenko wrote: On Sat, Jun 06, 2020 at 10:25:47PM +0200, Hans de Goede wrote: The DSDTs on most Cherry Trail devices have an ugly clutch where the PWM controller gets turned off from the _PS3 method of the graphics-card dev: Method (_PS3, 0, Serializ

Re: pwm/i915: Convert pwm-crc and i915 driver's PWM code to use the atomic PWM API

2020-06-07 Thread Hans de Goede
Hi All, I forgot the [PATCH 0/16] part of the subject here and I accidentally left a patch adding some debugging printk-s in the series. I will send out a v2 addressing this. Regards, Hans On 6/6/20 10:25 PM, Hans de Goede wrote: Hi All, This patch series converts the i915 driver's cpde for

[PATCH v2 00/15] pwm/i915: Convert pwm-crc and i915 driver's PWM code to use the atomic PWM API

2020-06-07 Thread Hans de Goede
Hi All, Here is v2 dropping a debugging-patch which I accidentally kept for v1 and addressing a minor review remark from Andy for the 2nd patch. This patch series converts the i915 driver's code for controlling the panel's backlight with an external PWM controller to use the atomic PWM API. Init

[PATCH v2 03/15] pwm: lpss: Add range limit check for the base_unit register value

2020-06-07 Thread Hans de Goede
When the user requests a high enough period ns value, then the calculations in pwm_lpss_prepare() might result in a base_unit value of 0. But according to the data-sheet the way the PWM controller works is that each input clock-cycle the base_unit gets added to a N bit counter and that counter ove

[PATCH v2 07/15] pwm: crc: Fix off-by-one error in the clock-divider calculations

2020-06-07 Thread Hans de Goede
The CRC PWM controller has a clock-divider which divides the clock with a value between 1-128. But as can seen from the PWM_DIV_CLK_xxx defines, this range maps to a register value of 0-127. So after calculating the clock-divider we must subtract 1 to get the register value, unless the requested f

[PATCH v2 04/15] pwm: lpss: Fix off by one error in base_unit math in pwm_lpss_prepare()

2020-06-07 Thread Hans de Goede
According to the data-sheet the way the PWM controller works is that each input clock-cycle the base_unit gets added to a N bit counter and that counter overflowing determines the PWM output frequency. So assuming e.g. a 16 bit counter this means that if base_unit is set to 1, after 65535 input cl

[PATCH v2 02/15] ACPI / LPSS: Save Cherry Trail PWM ctx registers only once (at activation)

2020-06-07 Thread Hans de Goede
The DSDTs on most Cherry Trail devices have an ugly clutch where the PWM controller gets turned off from the _PS3 method of the graphics-card dev: Method (_PS3, 0, Serialized) // _PS3: Power State 3 { ... PWMB = PWMC /* \_SB_.PCI

[PATCH v2 01/15] ACPI / LPSS: Resume Cherry Trail PWM controller in no-irq phase

2020-06-07 Thread Hans de Goede
The DSDTs on most Cherry Trail devices have an ugly clutch where the PWM controller gets poked from the _PS0 method of the graphics-card device: Local0 = PSAT /* \_SB_.PCI0.GFX0.PSAT */ If (((Local0 & 0x03) == 0x03)) { PSAT &= 0xFFFC Local1 = PSA

[PATCH v2 10/15] pwm: crc: Implement apply() method to support the new atomic PWM API

2020-06-07 Thread Hans de Goede
Replace the enable, disable and config pwm_ops with an apply op, to support the new atomic PWM API. Signed-off-by: Hans de Goede --- drivers/pwm/pwm-crc.c | 107 +++--- 1 file changed, 59 insertions(+), 48 deletions(-) diff --git a/drivers/pwm/pwm-crc.c b/dri

[PATCH v2 05/15] pwm: lpss: Set SW_UPDATE bit when enabling the PWM

2020-06-07 Thread Hans de Goede
On the LPSS PWM controller found on Bay Trail (BYT) and Cherry Trail (CHT) platforms, the following sequence results in an output duty-cycle of 100% independent of what the duty-cycle requested in the ctrl-reg is: 1. Clear ENABLE bit in ctrl register 2. Let the machine reach a S0i3 low power state

[PATCH v2 06/15] pwm: crc: Fix period / duty_cycle times being off by a factor of 256

2020-06-07 Thread Hans de Goede
While looking into adding atomic-pwm support to the pwm-crc driver I noticed something odd, there is a PWM_BASE_CLK define of 6 MHz and there is a clock-divider which divides this with a value between 1-128, and there are 256 duty-cycle steps. The pwm-crc code before this commit assumed that a clo

[PATCH v2 14/15] drm/i915: panel: Honor the VBT PWM min setting for devs with an external PWM controller

2020-06-07 Thread Hans de Goede
So far for devices using an external PWM controller (devices using pwm_setup_backlight()), we have been hardcoding the minimum allowed PWM level to 0. But several of these devices specify a non 0 minimum setting in their VBT. Change pwm_setup_backlight() to use get_backlight_min_vbt() to get the m

[PATCH v2 08/15] pwm: crc: Fix period changes not having any effect

2020-06-07 Thread Hans de Goede
The pwm-crc code is using 2 different enable bits: 1. bit 7 of the PWM0_CLK_DIV (PWM_OUTPUT_ENABLE) 2. bit 0 of the BACKLIGHT_EN register I strongly suspect that the BACKLIGHT_EN register at address 0x51 really controls a separate output-only GPIO which is connected to the LCD panels backlight-ena

[PATCH v2 12/15] drm/i915: panel: Add get_vbt_pwm_freq() helper

2020-06-07 Thread Hans de Goede
Factor the code which checks and drm_dbg_kms-s the VBT PWM frequency out of get_backlight_max_vbt(). This is a preparation patch for honering the VBT PWM frequency for devices which use an external PWM controller (devices using pwm_setup_backlight()). Signed-off-by: Hans de Goede --- drivers/gp

[PATCH v2 11/15] pwm: crc: Implement get_state() method

2020-06-07 Thread Hans de Goede
Implement the pwm_ops.get_state() method to complete the support for the new atomic PWM API. Signed-off-by: Hans de Goede --- drivers/pwm/pwm-crc.c | 29 + 1 file changed, 29 insertions(+) diff --git a/drivers/pwm/pwm-crc.c b/drivers/pwm/pwm-crc.c index 58c7e9ef7278.

[PATCH v2 15/15] drm/i915: panel: Use atomic PWM API for devs with an external PWM controller

2020-06-07 Thread Hans de Goede
Now that the PWM drivers which we use have been converted to the atomic PWM API, we can move the i915 panel code over to using the atomic PWM API. The removes a long standing FIXME and this removes a flicker where the backlight brightness would jump to 100% when i915 loads even if using the fastse

[PATCH v2 13/15] drm/i915: panel: Honor the VBT PWM frequency for devs with an external PWM controller

2020-06-07 Thread Hans de Goede
So far for devices using an external PWM controller (devices using pwm_setup_backlight()), we have been hardcoding the period-time passed to pwm_config() to 21333 ns. I suspect this was done because many VBTs set the PWM frequency to 200 which corresponds to a period-time of 500 ns, which grea

[PATCH v2 09/15] pwm: crc: Enable/disable PWM output on enable/disable

2020-06-07 Thread Hans de Goede
The pwm-crc code is using 2 different enable bits: 1. bit 7 of the PWM0_CLK_DIV (PWM_OUTPUT_ENABLE) 2. bit 0 of the BACKLIGHT_EN register So far we've kept the PWM_OUTPUT_ENABLE bit set when disabling the PWM, this commit makes crc_pwm_disable() clear it on disable and makes crc_pwm_enable() set i

[RFC PATCH 4/4] gpu/drm: Add Ilitek ILI9341 DBI panel driver

2020-06-07 Thread Paul Cercueil
This driver is for the Ilitek ILI9341 based YX240QV29-T 2.4" 240x320 TFT LCD panel from Adafruit. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/panel/Kconfig| 9 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-ilitek-ili9341.c | 347 ++

[RFC PATCH 3/4] gpu/drm: Add TinyDRM for DSI/DBI panels

2020-06-07 Thread Paul Cercueil
The new API function mipi_dsi_maybe_register_tiny_driver() is supposed to be called by DSI/DBI panel drivers at the end of their probe. If it is detected that the panel is not connected to any controller, because it has no port #0 node in Device Tree that points back to it, then a TinyDRM driver i

[PATCH v3 21/39] dt-bindings: memory: tegra30: emc: Document new interconnect property

2020-06-07 Thread Dmitry Osipenko
External memory controller is interconnected with memory controller and with external memory. Document new interconnect property which turns external memory controller into interconnect provider. Acked-by: Rob Herring Signed-off-by: Dmitry Osipenko --- .../bindings/memory-controllers/nvidia,teg

[PATCH v3 38/39] ARM: tegra: Enable interconnect API in tegra_defconfig

2020-06-07 Thread Dmitry Osipenko
Tegra now has interconnect providers that are used for memory bandwidth allocation. Signed-off-by: Dmitry Osipenko --- arch/arm/configs/tegra_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/configs/tegra_defconfig b/arch/arm/configs/tegra_defconfig index aa94369bdd0f..0029

[PATCH v2] fbdev: geode: Add the missed pci_disable_device() in gx1fb_map_video_memory()

2020-06-07 Thread Chuhong Yuan
Although gx1fb_probe() has handled the failure of gx1fb_map_video_memory() partly, it does not call pci_disable_device() as gx1fb_map_video_memory() calls pci_enable_device(). Add the missed function call to fix the bug. Fixes: 53eed4ec8bcd ("[PATCH] fbdev: geode updates]") Signed-off-by: Chuhong

[PATCH v3 35/39] drm/tegra: dc: Support memory bandwidth management

2020-06-07 Thread Dmitry Osipenko
Display controller (DC) performs isochronous memory transfers, and thus, has a requirement for a minimum memory bandwidth that shall be fulfilled, otherwise framebuffer data can't be fetched fast enough and this results in a DC's data-FIFO underflow that follows by a visual corruption. The Memory

Re: [PATCH v2 00/91] drm/vc4: Support BCM2711 Display Pipelin

2020-06-07 Thread Jian-Hong Pan
Maxime Ripard 於 2020年6月2日 週二 下午7:04寫道: > > Hi, > > On Mon, Jun 01, 2020 at 03:58:26PM +0800, Jian-Hong Pan wrote: > > Maxime Ripard 於 2020年5月28日 週四 下午3:30寫道: > > > > > > Hi Daniel, > > > > > > On Wed, May 27, 2020 at 05:15:12PM +0800, Daniel Drake wrote: > > > > On Wed, May 27, 2020 at 5:13 PM Ma

Re: [PATCH v3 070/105] drm/vc4: hdmi: rework connectors and encoders

2020-06-07 Thread Maxime Ripard
Hi Stefan, On Wed, Jun 03, 2020 at 07:32:30PM +0200, Stefan Wahren wrote: > Am 02.06.20 um 17:54 schrieb Maxime Ripard: > > On Wed, May 27, 2020 at 11:41:24AM -0700, Eric Anholt wrote: > >> On Wed, May 27, 2020 at 8:51 AM Maxime Ripard wrote: > >>> the vc4_hdmi driver has some custom structures t

[PATCH v3 01/39] clk: Export clk_hw_reparent()

2020-06-07 Thread Dmitry Osipenko
We're going to turn Tegra124 Memory Controller driver into a loadable kernel module. The driver uses clk_hw_reparent(), which isn't an exported kernel symbol. Let's export that function in order to allow modularization of the Tegra driver. Signed-off-by: Dmitry Osipenko --- drivers/clk/clk.c | 1

[PATCH v3 15/39] PM / devfreq: tegra30: Add error messages to tegra_devfreq_target()

2020-06-07 Thread Dmitry Osipenko
It's useful to now when something goes wrong instead of failing silently, so let's add error messages to tegra_devfreq_target() to prevent situation where it fails silently. Signed-off-by: Dmitry Osipenko --- drivers/devfreq/tegra30-devfreq.c | 8 ++-- 1 file changed, 6 insertions(+), 2 dele

[PATCH v3 28/39] memory: tegra: Register as interconnect provider

2020-06-07 Thread Dmitry Osipenko
Now memory controller is a memory interconnection provider. This allows us to use interconnect API in order to change memory configuration. Signed-off-by: Dmitry Osipenko --- drivers/memory/tegra/mc.c | 118 ++ drivers/memory/tegra/mc.h | 8 +++ include/soc/

[RFC PATCH 1/4] gpu/drm: dsi: Let host and device specify supported bus

2020-06-07 Thread Paul Cercueil
The current MIPI DSI framework can very well be used to support MIPI DBI panels. In order to add support for the various bus types supported by DBI, the DRM panel drivers should specify the bus type they will use, and the DSI host drivers should specify the bus types they are compatible with. The

Re: [PATCH v3 09/13] device core: Introduce multiple dma pfn offsets

2020-06-07 Thread Nicolas Saenz Julienne
Hi Christoph, a question arouse, is there a real value to dealing with PFNs (as opposed to real addresses) in the core DMA code/structures? I see that in some cases it eases interacting with mm, but the overwhelming usage of say, dev->dma_pfn_offset, involves shifting it. Hi Jim, On Thu, 2020-06-0

[PATCH v3 22/39] dt-bindings: host1x: Document new interconnect properties

2020-06-07 Thread Dmitry Osipenko
Most of Host1x devices have at least one memory client. These clients are directly connected to the memory controller. The new interconnect properties represent the memory client's connection to the memory controller. Signed-off-by: Dmitry Osipenko --- .../display/tegra/nvidia,tegra20-host1x.txt

Re: [PATCH v4 08/12] device core: Introduce multiple dma pfn offsets

2020-06-07 Thread Andy Shevchenko
On Fri, Jun 05, 2020 at 05:26:48PM -0400, Jim Quinlan wrote: > The new field in struct device 'dma_pfn_offset_map' is used to facilitate > the use of single or multiple pfn offsets between cpu addrs and dma addrs. > It subsumes the role of dev->dma_pfn_offset -- a uniform offset. > > The function

[PATCH v3 23/39] dt-bindings: memory: tegra20: Add memory client IDs

2020-06-07 Thread Dmitry Osipenko
Each memory client have a unique hardware ID, this patch adds these IDs. Signed-off-by: Dmitry Osipenko --- include/dt-bindings/memory/tegra20-mc.h | 53 + 1 file changed, 53 insertions(+) diff --git a/include/dt-bindings/memory/tegra20-mc.h b/include/dt-bindings/memory

Re: [PATCH v3 004/105] clk: bcm: Add BCM2711 DVP driver

2020-06-07 Thread Maxime Ripard
Hi Nicolas, On Thu, Jun 04, 2020 at 07:26:07PM +0200, Nicolas Saenz Julienne wrote: > On Wed, 2020-05-27 at 17:47 +0200, Maxime Ripard wrote: > > The HDMI block has a block that controls clocks and reset signals to the > > HDMI0 and HDMI1 controllers. > > Why not having two separate drivers? The

[PATCH v3 32/39] memory: tegra20-emc: Create tegra20-devfreq device

2020-06-07 Thread Dmitry Osipenko
The tegra20-devfreq driver provides memory frequency scaling functionality and it uses EMC clock for the scaling. Since tegra20-devfreq is a software driver, the device for the driver needs to be created manually. Let's do it from EMC driver since it provides the clk rate-change functionality. Sig

Re: [PATCH v5 0/8] drm: rcar-du: Add Color Management Module (CMM)

2020-06-07 Thread Eugeniu Rosca
Hi Jacopo, On Fri, Jun 05, 2020 at 03:29:00PM +0200, Jacopo Mondi wrote: > On Wed, May 27, 2020 at 09:15:55AM +0200, Eugeniu Rosca wrote: > > Could you kindly share the cross compilation steps for your kmsxx fork? > > I usually build it on the target :) Interesting approach. With ARM getting mor

[PATCH v3 31/39] memory: tegra20-emc: Register as interconnect provider

2020-06-07 Thread Dmitry Osipenko
Now memory controller is a memory interconnection provider. This allows us to use interconnect API in order to change memory configuration. Signed-off-by: Dmitry Osipenko --- drivers/memory/tegra/tegra20-emc.c | 115 + 1 file changed, 115 insertions(+) diff --git a/d

[PATCH v3 16/39] PM / devfreq: tegra20: Adjust clocks conversion ratio and polling interval

2020-06-07 Thread Dmitry Osipenko
The current conversion ratio results in a higher frequency than needed, that is not very actual now since the Display Controller driver got support for memory bandwidth management and hence memory frequency can go lower now without bad consequences. Since memory freq now goes to a lower rates, the

[PATCH v3 30/39] memory: tegra20-emc: Continue probing if timings are missing in device-tree

2020-06-07 Thread Dmitry Osipenko
EMC driver will become mandatory after turning it into interconnect provider because interconnect users, like display controller driver, will fail to probe using newer device-trees that have interconnect properties. Thus make EMC driver to probe even if timings are missing in device-tree. Signed-o

[PATCH v3 11/39] PM / devfreq: tegra30: Silence deferred probe error

2020-06-07 Thread Dmitry Osipenko
Tegra EMC driver was turned into a regular kernel driver, it also could be compiled as a loadable kernel module now. Hence EMC clock isn't guaranteed to be available and clk_get("emc") may return -EPROBE_DEFER and there is no good reason to spam KMSG with a error about missing EMC clock in this cas

[RFC PATCH 2/4] gpu/drm: Add SPI DBI host driver

2020-06-07 Thread Paul Cercueil
This driver will register a DBI host driver for panels connected over SPI. For now, only DBI type c3 is supported, which is a SPI protocol with 8 bits per word, with the data/command information carried by a separate GPIO. Signed-off-by: Paul Cercueil --- drivers/gpu/drm/bridge/Kconfig | 8

[PATCH v3 00/39] Introduce memory interconnect for NVIDIA Tegra SoCs

2020-06-07 Thread Dmitry Osipenko
Hello, This series brings initial support for memory interconnect to Tegra20 and Tegra30 SoCs. For the starter only display controllers are getting interconnect API support, others could be supported later on. The display controllers have the biggest demand for interconnect API right now because

[PATCH v3 14/39] PM / devfreq: tegra20: Add error messages to tegra_devfreq_target()

2020-06-07 Thread Dmitry Osipenko
It's useful to now when something goes wrong instead of failing silently, so let's add error messages to tegra_devfreq_target() to prevent situation where it fails silently. Signed-off-by: Dmitry Osipenko --- drivers/devfreq/tegra20-devfreq.c | 12 +--- 1 file changed, 9 insertions(+), 3

[PATCH v3 29/39] memory: tegra20-emc: Use devm_platform_ioremap_resource

2020-06-07 Thread Dmitry Osipenko
Utilize that relatively new helper which makes code a bit cleaner. Signed-off-by: Dmitry Osipenko --- drivers/memory/tegra/tegra20-emc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/memory/tegra/tegra20-emc.c b/drivers/memory/tegra/tegra20-emc.c index a95522020

[PATCH v3 17/39] PM / devfreq: tegra20: Relax Kconfig dependency

2020-06-07 Thread Dmitry Osipenko
The Tegra EMC driver now could be compiled as a loadable kernel module. Currently devfreq driver depends on the EMC/MC drivers in Kconfig, and thus, devfreq is forced to be a kernel module if EMC is compiled as a module. This build dependency could be relaxed since devfreq driver checks MC/EMC pres

[PATCH v3 19/39] dt-bindings: memory: tegra20: emc: Document new interconnect property

2020-06-07 Thread Dmitry Osipenko
External memory controller is interconnected with memory controller and with external memory. Document new interconnect property which turns external memory controller into interconnect provider. Acked-by: Rob Herring Signed-off-by: Dmitry Osipenko --- .../bindings/memory-controllers/nvidia,teg

[PATCH v3 18/39] dt-bindings: memory: tegra20: mc: Document new interconnect property

2020-06-07 Thread Dmitry Osipenko
Memory controller is interconnected with memory clients and with the external memory controller. Document new interconnect property which turns memory controller into interconnect provider. Acked-by: Rob Herring Signed-off-by: Dmitry Osipenko --- .../bindings/memory-controllers/nvidia,tegra20-m

[PATCH v3 07/39] memory: tegra124-emc: Use devm_platform_ioremap_resource

2020-06-07 Thread Dmitry Osipenko
Utilize that relatively new helper which makes code a bit cleaner. Signed-off-by: Dmitry Osipenko --- drivers/memory/tegra/tegra124-emc.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/memory/tegra/tegra124-emc.c b/drivers/memory/tegra/tegra124-emc.c index 95afb0

[PATCH v3 34/39] memory: tegra30-emc: Register as interconnect provider

2020-06-07 Thread Dmitry Osipenko
Now external memory controller is a memory interconnection provider. This allows us to use interconnect API to change memory configuration. Signed-off-by: Dmitry Osipenko --- drivers/memory/tegra/tegra30-emc.c | 115 + 1 file changed, 115 insertions(+) diff --git a/d

[PATCH v3 08/39] soc/tegra: fuse: Export tegra_read_ram_code()

2020-06-07 Thread Dmitry Osipenko
The tegra_read_ram_code() is used by EMC drivers and we're going to make these driver modular, hence this function needs to be exported. Signed-off-by: Dmitry Osipenko --- drivers/soc/tegra/fuse/tegra-apbmisc.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/soc/tegra/fuse/tegra-ap

Re: [PATCH 3/3] drm/mipi: use dcs write for mipi_dsi_dcs_set_tear_scanline

2020-06-07 Thread Vinay Simha B N
hi emil, On Wed, May 13, 2020 at 3:17 PM Emil Velikov wrote: > > Hi Vinay, > > On Thu, 7 May 2020 at 17:18, Emil Velikov wrote: > > > > On Thu, 7 May 2020 at 13:29, Vinay Simha B N wrote: > > > > > > Emil, > > > > > > Reply inline > > > > > > On Tue, 5 May 2020 at 9:35 PM, Emil Velikov > > >

Re: [PATCH 02/16] ACPI / LPSS: Save Cherry Trail PWM ctx registers only once (at activation)

2020-06-07 Thread Andy Shevchenko
On Sat, Jun 06, 2020 at 10:25:47PM +0200, Hans de Goede wrote: > The DSDTs on most Cherry Trail devices have an ugly clutch where the PWM > controller gets turned off from the _PS3 method of the graphics-card dev: > > Method (_PS3, 0, Serialized) // _PS3: Power State 3 > {

[PATCH v3 02/39] clk: tegra: Remove Memory Controller lock

2020-06-07 Thread Dmitry Osipenko
The shared Memory Controller lock isn't needed since the time when Memory Clock was made read-only. The lock could be removed safely now. Hence let's remove it, this will help a tad to make further patches cleaner. Signed-off-by: Dmitry Osipenko --- drivers/clk/tegra/clk-divider.c | 4 ++-- dri

[PATCH v3 05/39] memory: tegra30-emc: Make driver modular

2020-06-07 Thread Dmitry Osipenko
This patch adds modularization support to the Tegra30 EMC driver. Driver now can be compiled as a loadable kernel module. Signed-off-by: Dmitry Osipenko --- drivers/memory/tegra/Kconfig | 2 +- drivers/memory/tegra/mc.c | 3 +++ drivers/memory/tegra/tegra30-emc.c | 16 ++

[PATCH v3 09/39] memory: tegra20-emc: Initialize MC timings

2020-06-07 Thread Dmitry Osipenko
We're going to add interconnect support to the EMC driver. Once this support will be added, the Tegra20 devfreq driver will no longer be able to use clk_round_rate(emc) for building up OPP table. It's quite handy that struct tegra_mc contains memory timings which could be used by the devfreq driver

[PATCH v3 06/39] memory: tegra124-emc: Make driver modular

2020-06-07 Thread Dmitry Osipenko
This patch adds modularization support to the Tegra124 EMC driver. Driver now can be compiled as a loadable kernel module. Signed-off-by: Dmitry Osipenko --- drivers/clk/tegra/clk-tegra124-emc.c | 63 +--- drivers/clk/tegra/clk-tegra124.c | 3 +- drivers/clk/tegra/cl

Re: [PATCH] drm/i915/gvt: print actionable error message when gm runs out

2020-06-07 Thread Julian Stecklina
On Fri, 2020-06-05 at 12:54 +0800, Zhenyu Wang wrote: > On 2020.06.03 14:33:21 +0200, Julian Stecklina wrote: > > + gvt_err("vgpu%d: failed to allocate %s gm space from host\n", > > + vgpu->id, high_gm ? "high" : "low"); > > + gvt_err("vgpu%d: destroying vGPUs,

[PATCH v3 37/39] drm/tegra: dc: Extend debug stats with total number of events

2020-06-07 Thread Dmitry Osipenko
It's useful to know the total number of underflow events and currently the debug stats are getting reset each time CRTC is being disabled. Let's account the overall number of events that doesn't get reset. Signed-off-by: Dmitry Osipenko --- drivers/gpu/drm/tegra/dc.c | 10 ++ drivers/gpu

[PATCH v3 36/39] drm/tegra: dc: Tune up high priority request controls for Tegra20

2020-06-07 Thread Dmitry Osipenko
Tegra20 has a high-priority-request control that allows to configure when display's memory client should perform read requests with a higher priority (Tegra30+ uses other means like Latency Allowance). This patch changes the controls configuration in order to get a more aggressive memory prefetchi

[PATCH v3 20/39] dt-bindings: memory: tegra30: mc: Document new interconnect property

2020-06-07 Thread Dmitry Osipenko
Memory controller is interconnected with memory clients and with the external memory controller. Document new interconnect property which turns memory controller into interconnect provider. Acked-by: Rob Herring Signed-off-by: Dmitry Osipenko --- .../bindings/memory-controllers/nvidia,tegra30-m

[PATCH v3 13/39] PM / devfreq: tegra30: Use MC timings for building OPP table

2020-06-07 Thread Dmitry Osipenko
The clk_round_rate() won't be usable for building OPP table once interconnect support will be added to the EMC driver because that CLK API function limits the rounded rate based on the clk rate that is imposed by active clk-users, and thus, the rounding won't work as expected if interconnect will s

[PATCH v3 26/39] ARM: tegra: Add interconnect properties to Tegra30 device-tree

2020-06-07 Thread Dmitry Osipenko
Add interconnect properties to the memory controller, external memory controller and the display controller nodes in order to describe hardware interconnection. Signed-off-by: Dmitry Osipenko --- arch/arm/boot/dts/tegra30.dtsi | 23 ++- 1 file changed, 22 insertions(+), 1 del

[PATCH v3 04/39] memory: tegra20-emc: Make driver modular

2020-06-07 Thread Dmitry Osipenko
This patch adds modularization support to the Tegra20 EMC driver. Driver now can be compiled as a loadable kernel module. Signed-off-by: Dmitry Osipenko --- drivers/memory/tegra/Kconfig | 2 +- drivers/memory/tegra/tegra20-emc.c | 16 +++- 2 files changed, 12 insertions(+), 6

[PATCH v3 24/39] dt-bindings: memory: tegra30: Add memory client IDs

2020-06-07 Thread Dmitry Osipenko
Each memory client have a unique hardware ID, this patch adds these IDs. Signed-off-by: Dmitry Osipenko --- include/dt-bindings/memory/tegra30-mc.h | 67 + 1 file changed, 67 insertions(+) diff --git a/include/dt-bindings/memory/tegra30-mc.h b/include/dt-bindings/memory

[PATCH v3 12/39] PM / devfreq: tegra20: Use MC timings for building OPP table

2020-06-07 Thread Dmitry Osipenko
The clk_round_rate() won't be usable for building OPP table once interconnect support will be added to the EMC driver because that CLK API function limits the rounded rate based on the clk rate that is imposed by active clk-users, and thus, the rounding won't work as expected if interconnect will s

Re: [PATCH v3 004/105] clk: bcm: Add BCM2711 DVP driver

2020-06-07 Thread Nicolas Saenz Julienne
On Fri, 2020-06-05 at 19:43 +0200, Maxime Ripard wrote: > Hi Nicolas, > > On Thu, Jun 04, 2020 at 07:26:07PM +0200, Nicolas Saenz Julienne wrote: > > On Wed, 2020-05-27 at 17:47 +0200, Maxime Ripard wrote: > > > The HDMI block has a block that controls clocks and reset signals to the > > > HDMI0 a

[PATCH v3 03/39] clk: tegra: Export Tegra20 EMC kernel symbols

2020-06-07 Thread Dmitry Osipenko
We're going to modularize Tegra EMC drivers and some of the EMC clk driver symbols need to be exported, let's export them. Signed-off-by: Dmitry Osipenko --- drivers/clk/tegra/clk-tegra20-emc.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/drivers/clk/tegra/clk-tegra20-emc.c b/drivers/

[PATCH v3 33/39] memory: tegra30-emc: Continue probing if timings are missing in device-tree

2020-06-07 Thread Dmitry Osipenko
EMC driver will become mandatory after turning it into interconnect provider because interconnect users, like display controller driver, will fail to probe using newer device-trees that have interconnect properties. Thus make EMC driver to probe even if timings are missing in device-tree. Signed-o

[PATCH v3 27/39] interconnect: Relax requirement in of_icc_get_from_provider()

2020-06-07 Thread Dmitry Osipenko
From: Artur Świgoń This patch relaxes the condition in of_icc_get_from_provider() so that it is no longer required to set #interconnect-cells = <1> in the DT. In case of the devfreq driver for exynos-bus, #interconnect-cells is always zero. Signed-off-by: Artur Świgoń [dig...@gmail.com: added c

[PATCH] drm/panfrost: Use kvfree() to free bo->sgts in panfrost_mmu_map_fault_addr()

2020-06-07 Thread Denis Efremov
Use kvfree() to free bo->sgts, because the memory is allocated with kvmalloc_array(). Fixes: 187d2929206e ("drm/panfrost: Add support for GPU heap allocations") Cc: sta...@vger.kernel.org Signed-off-by: Denis Efremov --- drivers/gpu/drm/panfrost/panfrost_mmu.c | 2 +- 1 file changed, 1 insertion

[PATCH v3 39/39] ARM: multi_v7_defconfig: Enable interconnect API

2020-06-07 Thread Dmitry Osipenko
NVIDIA Tegra now has interconnect providers that are used for memory bandwidth allocation. Signed-off-by: Dmitry Osipenko --- arch/arm/configs/multi_v7_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/arch/arm/configs/multi_v7_defconfig b/arch/arm/configs/multi_v7_defconfig index 9

[RFC PATCH 0/4] DSI/DBI and TinyDRM driver

2020-06-07 Thread Paul Cercueil
Hi, Here's a follow-up on the previous discussion about the current state of DSI/DBI panel drivers, TinyDRM, and the need of a cleanup. This patchset introduces the following: * It slightly tweaks the MIPI DSI code so that it supports MIPI DBI over various buses. This patch has been tested with

[PATCH v3 25/39] ARM: tegra: Add interconnect properties to Tegra20 device-tree

2020-06-07 Thread Dmitry Osipenko
Add interconnect properties to the memory controller, external memory controller and the display controller nodes in order to describe hardware interconnection. Signed-off-by: Dmitry Osipenko --- arch/arm/boot/dts/tegra20.dtsi | 22 +- 1 file changed, 21 insertions(+), 1 dele

[PATCH v3 10/39] PM / devfreq: tegra20: Silence deferred probe error

2020-06-07 Thread Dmitry Osipenko
Tegra EMC driver was turned into a regular kernel driver, it also could be compiled as a loadable kernel module now. Hence EMC clock isn't guaranteed to be available and clk_get("emc") may return -EPROBE_DEFER and there is no good reason to spam KMSG with a error about missing EMC clock in this cas

[PATCH 2/2] drm: rockchip: add NV15 and NV20 support

2020-06-07 Thread Jonas Karlman
Add support for displaying 10-bit 4:2:0 and 4:2:2 formats produced by the Rockchip Video Decoder on RK322X, RK3288, RK3328, RK3368 and RK3399. Signed-off-by: Jonas Karlman --- drivers/gpu/drm/rockchip/rockchip_drm_vop.c | 27 -- drivers/gpu/drm/rockchip/rockchip_drm_vop.h | 1 +

[PATCH 1/2] drm: drm_fourcc: add NV20 YUV format

2020-06-07 Thread Jonas Karlman
DRM_FORMAT_NV20 is a 2 plane format suitable for linear memory layout. The format is similar to P210 with 4:2:2 sub-sampling but has no padding between components. Instead, luminance and chrominance samples are grouped into 4s so that each group is packed into an integer number of bytes: = UV

[PATCH 0/2] drm: rockchip: add NV15 and NV20 support

2020-06-07 Thread Jonas Karlman
Hi, This series adds support for displaying 10-bit 4:2:0 and 4:2:2 formats produced by the Rockchip Video Decoder on RK322X, RK3288, RK3328, RK3368 and RK3399. First patch adds a new fourcc 10-bit YUV format with 4:2:2 sub-sampling. Second patch adds support for using the the two new fourcc forma

[PATCH 1/3] drm/dp_mst: Fix the DDC I2C device unregistration of an MST port

2020-06-07 Thread Imre Deak
The WARN below triggers during the removal of an MST port. The problem is that the parent device's (the connector's kdev) sysfs directory is removed recursively when the connector is unregistered (even though the I2C device holds a reference on the parent device). To fix this set first the Peer Dev

[PATCH 2/3] drm/dp_mst: Fix the DDC I2C device registration of an MST port

2020-06-07 Thread Imre Deak
During the initial MST probing an MST port's I2C device will be registered using the kdev of the DRM device as a parent. Later after MST Connection Status Notifications this I2C device will be re-registered with the kdev of the port's connector. This will also move inconsistently the I2C device's s

[PATCH 3/3] drm/dp_mst: Fix flushing the delayed port/mstb destroy work

2020-06-07 Thread Imre Deak
Atm, a pending delayed destroy work during module removal will be canceled, leaving behind MST ports, mstbs. Fix this by using a dedicated workqueue which will be drained of requeued items as well when destroying it. Signed-off-by: Imre Deak --- drivers/gpu/drm/drm_dp_mst_topology.c | 17 +++

Re: [PATCH v3 09/13] device core: Introduce multiple dma pfn offsets

2020-06-07 Thread Jim Quinlan
On Fri, Jun 5, 2020 at 1:27 PM Nicolas Saenz Julienne wrote: > > Hi Christoph, > a question arouse, is there a real value to dealing with PFNs (as opposed to > real addresses) in the core DMA code/structures? I see that in some cases it > eases interacting with mm, but the overwhelming usage of sa

[PATCH v4 08/12] device core: Introduce multiple dma pfn offsets

2020-06-07 Thread Jim Quinlan
The new field in struct device 'dma_pfn_offset_map' is used to facilitate the use of single or multiple pfn offsets between cpu addrs and dma addrs. It subsumes the role of dev->dma_pfn_offset -- a uniform offset. The function of_dma_get_range() has been modified to take two additional arguments:

[PATCH v4 00/12] PCI: brcmstb: enable PCIe for STB chips

2020-06-07 Thread Jim Quinlan
v4: Commit "device core: Introduce multiple dma pfn offsets" -- of_dma_get_range() does not take a dev param but instead takes two "out" params: map and map_size. We do this so that the code that parses dma-ranges is separate from the code that modifies 'dev'. (Nicolas) --

Re: [PATCH] drm/rcar-du: DRM_RCAR_WRITEBACK depends on DRM

2020-06-07 Thread Laurent Pinchart
Hi Qian, Thank you for the patch. On Sun, Jun 07, 2020 at 09:48:18PM -0400, Qian Cai wrote: > There is no need to select DRM_RCAR_WRITEBACK if DRM=n which just make > the generated .config a bit ugly. > > # ARM devices > # > # end of ARM devices > > CONFIG_DRM_RCAR_WRITEBACK=y > > # > #

Re: [PATCH v2] drm/rcar-du: DRM_RCAR_WRITEBACK depends on DRM

2020-06-07 Thread Laurent Pinchart
Hi Qian, Thank you for the patch. On Sun, Jun 07, 2020 at 10:53:40PM -0400, Qian Cai wrote: > There is no need to select DRM_RCAR_WRITEBACK if DRM=n which just make s/DRM=n/DRM_RCAR_DU=n/ here. > the generated .config a bit ugly. > > # ARM devices > # > # end of ARM devices > > CONFIG_DRM

[git pull] drm next fixes for 5.7-rc1

2020-06-07 Thread Dave Airlie
Hey Linus, This are the fixes from last week for the stuff merged in the merge window. It got a bunch of nouveau fixes for HDA audio on some new GPUs, some i915 and some amdpgu fixes. I've got another pull request with Rob's msm next stuff in it I'll send along after this, it was in -next all alo

Re: [PATCH v2] drm/rcar-du: DRM_RCAR_WRITEBACK depends on DRM

2020-06-07 Thread Laurent Pinchart
Hi Qian, I forgot to mention, I think the subject line should be drm/rcar-du: Make DRM_RCAR_WRITEBACK depend on DRM_RCAR_DU Could you please let me know if you're OK with these two small changes ? On Mon, Jun 08, 2020 at 06:14:43AM +0300, Laurent Pinchart wrote: > On Sun, Jun 07, 2020 at 10:53:

[git pull] drm msm next for 5.8-rc1

2020-06-07 Thread Dave Airlie
Hi Linus, This should be the final feature pull for drm for rc1. This tree has been in next for a couple of weeks, but Rob missed an arm32 build issue, so I was awaiting the tree with a patch reverted. The tree was also based on an 5.7-rc5 tree so I didn't want to futz around with backmerging just

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

2020-06-07 Thread Michael S. Tsirkin
On Mon, Jun 08, 2020 at 10:33:09AM +0900, David Stevens wrote: > On Sun, Jun 7, 2020 at 5:04 AM Michael S. Tsirkin wrote: > > > > On Fri, Jun 05, 2020 at 10:28:42AM +0900, David Stevens wrote: > > > On Fri, Jun 5, 2020 at 4:05 AM Michael S. Tsirkin wrote: > > > > > > > > On Tue, May 26, 2020 at 0