All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] gpu/drm: ingenic: Remove bogus register write
@ 2021-10-30 10:00 Paul Cercueil
  2021-10-30 18:49 ` Sam Ravnborg
  0 siblings, 1 reply; 3+ messages in thread
From: Paul Cercueil @ 2021-10-30 10:00 UTC (permalink / raw)
  To: David Airlie, Daniel Vetter
  Cc: linux-mips, dri-devel, linux-kernel, Christophe Branchereau,
	list, Paul Cercueil, kernel test robot

Commit 1bdb542da736 ("drm/ingenic: Simplify code by using hwdescs
array") caused the dma_hwdesc_phys_f{0,1} variables to be used while
uninitialized in a mmio register write, which most certainly broke the
ingenic-drm driver.

However, the very same patchset also submitted commit 6055466203df
("drm/ingenic: Upload palette before frame"), which restored a correct
behaviour by doing the register writes in a different place in the code.

What's left of this, is just to remove the bogus register writes in the
probe function.

Signed-off-by: Paul Cercueil <paul@crapouillou.net>
Reported-by: kernel test robot <lkp@intel.com>
---
 drivers/gpu/drm/ingenic/ingenic-drm-drv.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c b/drivers/gpu/drm/ingenic/ingenic-drm-drv.c
index a05a9fa6e115..b4943a56be09 100644
--- a/drivers/gpu/drm/ingenic/ingenic-drm-drv.c
+++ b/drivers/gpu/drm/ingenic/ingenic-drm-drv.c
@@ -1013,7 +1013,6 @@ static int ingenic_drm_bind(struct device *dev, bool has_components)
 	void __iomem *base;
 	long parent_rate;
 	unsigned int i, clone_mask = 0;
-	dma_addr_t dma_hwdesc_phys_f0, dma_hwdesc_phys_f1;
 	int ret, irq;
 
 	soc_info = of_device_get_match_data(dev);
@@ -1268,10 +1267,6 @@ static int ingenic_drm_bind(struct device *dev, bool has_components)
 		}
 	}
 
-	/* Set address of our DMA descriptor chain */
-	regmap_write(priv->map, JZ_REG_LCD_DA0, dma_hwdesc_phys_f0);
-	regmap_write(priv->map, JZ_REG_LCD_DA1, dma_hwdesc_phys_f1);
-
 	/* Enable OSD if available */
 	if (soc_info->has_osd)
 		regmap_write(priv->map, JZ_REG_LCD_OSDC, JZ_LCD_OSDC_OSDEN);
-- 
2.33.0


^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] gpu/drm: ingenic: Remove bogus register write
  2021-10-30 10:00 [PATCH] gpu/drm: ingenic: Remove bogus register write Paul Cercueil
@ 2021-10-30 18:49 ` Sam Ravnborg
  2021-10-30 20:03   ` Paul Cercueil
  0 siblings, 1 reply; 3+ messages in thread
From: Sam Ravnborg @ 2021-10-30 18:49 UTC (permalink / raw)
  To: Paul Cercueil
  Cc: David Airlie, Daniel Vetter, linux-mips, dri-devel, linux-kernel,
	Christophe Branchereau, list, kernel test robot

Hi Paul,

On Sat, Oct 30, 2021 at 11:00:32AM +0100, Paul Cercueil wrote:
> Commit 1bdb542da736 ("drm/ingenic: Simplify code by using hwdescs
> array") caused the dma_hwdesc_phys_f{0,1} variables to be used while
> uninitialized in a mmio register write, which most certainly broke the
> ingenic-drm driver.
> 
> However, the very same patchset also submitted commit 6055466203df
> ("drm/ingenic: Upload palette before frame"), which restored a correct
> behaviour by doing the register writes in a different place in the code.
> 
> What's left of this, is just to remove the bogus register writes in the
> probe function.
> 
> Signed-off-by: Paul Cercueil <paul@crapouillou.net>
> Reported-by: kernel test robot <lkp@intel.com>

Thank you lkp...
Acked-by: Sam Ravnborg <sam@ravnborg.org>

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] gpu/drm: ingenic: Remove bogus register write
  2021-10-30 18:49 ` Sam Ravnborg
@ 2021-10-30 20:03   ` Paul Cercueil
  0 siblings, 0 replies; 3+ messages in thread
From: Paul Cercueil @ 2021-10-30 20:03 UTC (permalink / raw)
  To: Sam Ravnborg
  Cc: David Airlie, Daniel Vetter, linux-mips, dri-devel, linux-kernel,
	Christophe Branchereau, list, kernel test robot

Hi,

Le sam., oct. 30 2021 at 20:49:53 +0200, Sam Ravnborg 
<sam@ravnborg.org> a écrit :
> Hi Paul,
> 
> On Sat, Oct 30, 2021 at 11:00:32AM +0100, Paul Cercueil wrote:
>>  Commit 1bdb542da736 ("drm/ingenic: Simplify code by using hwdescs
>>  array") caused the dma_hwdesc_phys_f{0,1} variables to be used while
>>  uninitialized in a mmio register write, which most certainly broke 
>> the
>>  ingenic-drm driver.
>> 
>>  However, the very same patchset also submitted commit 6055466203df
>>  ("drm/ingenic: Upload palette before frame"), which restored a 
>> correct
>>  behaviour by doing the register writes in a different place in the 
>> code.
>> 
>>  What's left of this, is just to remove the bogus register writes in 
>> the
>>  probe function.
>> 
>>  Signed-off-by: Paul Cercueil <paul@crapouillou.net>
>>  Reported-by: kernel test robot <lkp@intel.com>
> 
> Thank you lkp...
> Acked-by: Sam Ravnborg <sam@ravnborg.org>

Pushed to drm-misc-next.

Thanks!
-Paul



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-10-30 20:03 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-10-30 10:00 [PATCH] gpu/drm: ingenic: Remove bogus register write Paul Cercueil
2021-10-30 18:49 ` Sam Ravnborg
2021-10-30 20:03   ` Paul Cercueil

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.