* [patch] drm/tegra: bad irqsave/restore in tegra_dc_finish_page_flip()
@ 2015-01-07 11:01 Dan Carpenter
2015-01-07 13:46 ` Thierry Reding
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2015-01-07 11:01 UTC (permalink / raw)
To: Thierry Reding
Cc: Alexandre Courbot, Terje Bergström, Stephen Warren,
kernel-janitors, dri-devel, linux-tegra, Rob Herring,
Grant Likely
We can't save two values to the IRQ flags at the same time so the IRQs
are not enabled at the end. This kind of bug is easy to miss in testing
if the function is normally called with IRQs disabled so we wouldn't
enable IRQs anyway.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/drivers/gpu/drm/tegra/dc.c b/drivers/gpu/drm/tegra/dc.c
index ae26cc0..c746161 100644
--- a/drivers/gpu/drm/tegra/dc.c
+++ b/drivers/gpu/drm/tegra/dc.c
@@ -838,7 +838,7 @@ static void tegra_dc_finish_page_flip(struct tegra_dc *dc)
bo = tegra_fb_get_plane(crtc->primary->fb, 0);
- spin_lock_irqsave(&dc->lock, flags);
+ spin_lock(&dc->lock);
/* check if new start address has been latched */
tegra_dc_writel(dc, WINDOW_A_SELECT, DC_CMD_DISPLAY_WINDOW_HEADER);
@@ -846,7 +846,7 @@ static void tegra_dc_finish_page_flip(struct tegra_dc *dc)
base = tegra_dc_readl(dc, DC_WINBUF_START_ADDR);
tegra_dc_writel(dc, 0, DC_CMD_STATE_ACCESS);
- spin_unlock_irqrestore(&dc->lock, flags);
+ spin_unlock(&dc->lock);
if (base == bo->paddr + crtc->primary->fb->offsets[0]) {
drm_crtc_send_vblank_event(crtc, dc->event);
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [patch] drm/tegra: bad irqsave/restore in tegra_dc_finish_page_flip()
2015-01-07 11:01 [patch] drm/tegra: bad irqsave/restore in tegra_dc_finish_page_flip() Dan Carpenter
@ 2015-01-07 13:46 ` Thierry Reding
0 siblings, 0 replies; 2+ messages in thread
From: Thierry Reding @ 2015-01-07 13:46 UTC (permalink / raw)
To: Dan Carpenter
Cc: Terje Bergström, David Airlie, Stephen Warren,
Alexandre Courbot, Grant Likely, Rob Herring, dri-devel,
linux-tegra, kernel-janitors
[-- Attachment #1: Type: text/plain, Size: 416 bytes --]
On Wed, Jan 07, 2015 at 02:01:26PM +0300, Dan Carpenter wrote:
> We can't save two values to the IRQ flags at the same time so the IRQs
> are not enabled at the end. This kind of bug is easy to miss in testing
> if the function is normally called with IRQs disabled so we wouldn't
> enable IRQs anyway.
>
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Good catch, applied.
Thanks,
Thierry
[-- Attachment #2: Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-01-07 13:46 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-01-07 11:01 [patch] drm/tegra: bad irqsave/restore in tegra_dc_finish_page_flip() Dan Carpenter
2015-01-07 13:46 ` Thierry Reding
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).