From: Jyri Sarha <jsarha@ti.com>
To: dri-devel@lists.freedesktop.org
Cc: Jyri Sarha <jsarha@ti.com>,
peter.ujfalusi@ti.com, tomi.valkeinen@ti.com,
laurent.pinchart@ideasonboard.com
Subject: [PATCH 0/3] drm/tilcdc: Fix cpufreq transition related race + cleanup
Date: Tue, 6 Sep 2016 11:19:38 +0300 [thread overview]
Message-ID: <cover.1473148345.git.jsarha@ti.com> (raw)
There was a race between mode_set_nofb() and cpufreq_transition()
calling tilcdc_crtc_update_clk() without locking.
The first patch fixes the race in with a minimal change by taking
drm_mode_config mutex for the duration of the clock update.
The second patch goes a step forward and cleans up the clock setting
code a bit.
The third patch should not really be needed, for now. However,
tilcdc_crtc_enable() and -disable() are called from all over the place
and relying on drm to only do one thing at the time may not work
forever. Adding one mutex does not cost too much after all.
BR,
Jyri
Jyri Sarha (3):
drm/tilcdc: Take mode config lock while updating the crtc clock rate
drm/tilcdc: Add tilcdc_crtc_set_clk() and cleanup cpufreq_transition()
drm/tilcdc: Add mutex to protect crtc enable and disable routines
drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 93 +++++++++++++++++++++++-------------
drivers/gpu/drm/tilcdc/tilcdc_drv.c | 11 ++---
drivers/gpu/drm/tilcdc/tilcdc_drv.h | 3 +-
3 files changed, 65 insertions(+), 42 deletions(-)
--
1.9.1
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next reply other threads:[~2016-09-06 8:19 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-09-06 8:19 Jyri Sarha [this message]
2016-09-06 8:19 ` [PATCH 1/3] drm/tilcdc: Take mode config lock while updating the crtc clock rate Jyri Sarha
2016-09-06 9:07 ` Tomi Valkeinen
2016-09-06 12:07 ` Jyri Sarha
2016-09-06 8:19 ` [PATCH 2/3] drm/tilcdc: Add tilcdc_crtc_set_clk() and cleanup cpufreq_transition() Jyri Sarha
2016-09-06 9:46 ` Tomi Valkeinen
2016-09-06 9:48 ` Tomi Valkeinen
2016-09-06 8:19 ` [PATCH 3/3] drm/tilcdc: Add mutex to protect crtc enable and disable routines Jyri Sarha
2016-09-06 9:30 ` Tomi Valkeinen
2016-09-06 12:09 ` Jyri Sarha
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=cover.1473148345.git.jsarha@ti.com \
--to=jsarha@ti.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=laurent.pinchart@ideasonboard.com \
--cc=peter.ujfalusi@ti.com \
--cc=tomi.valkeinen@ti.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.