From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: Ricardo Neri <ricardo.neri@ti.com>
Cc: mythripk@ti.com, s-chereau@ti.com, x0055901@ti.com,
vaibhav.bedia@ti.com, s-guiriec@ti.com, lrg@ti.com,
peter.ujfalusi@ti.com, agraf@suse.de, research@ottomaneng.com,
linux-omap@vger.kernel.org, alsa-devel@alsa-project.org
Subject: Re: [PATCH v2 14/14] OMAPDSS: HDMI: Implement DSS driver interface for audio
Date: Mon, 07 May 2012 14:43:06 +0300 [thread overview]
Message-ID: <1336390986.2667.8.camel@deskari> (raw)
In-Reply-To: <1336095848-6923-15-git-send-email-ricardo.neri@ti.com>
[-- Attachment #1: Type: text/plain, Size: 1289 bytes --]
Hi,
On Thu, 2012-05-03 at 20:44 -0500, Ricardo Neri wrote:
> Implement the DSS device driver audio support interface in the HDMI
> panel driver and generic driver. The implementation relies on the
> IP-specific functions that are defined at DSS probe time.
>
> At the moment, a hardirq-safe spinlock is used to protect the audio
> functions. This is because such functions might be called while
> holding a lock (this especially true for audio_start/stop). For the
> rest of the audio functions, a mutex could be used in the future as
> the enablement of resources might take too much time.
The series looks good, except locking. Granted, the locking in omapdss
is a bit bad generally also, but here I think it's a bit more broken.
For example, hdmi_panel.c:hdmi_panel_audio_supported() takes the audio
lock, and then uses variables like dssdev->state, and the hdmi video
mode. However, the video functions do not use audio lock, so effectively
the lock doesn't protect at all.
I'm not sure how to fix it, though. I think this shows the shortcomings
of the current locking strategy (or lack of =). What if the audio
functions that can sleep would take the hdmi panel's mutex, and also the
audio spinlock? That would at least fix some of the cases.
Tomi
[-- Attachment #2: This is a digitally signed message part --]
[-- Type: application/pgp-signature, Size: 836 bytes --]
next prev parent reply other threads:[~2012-05-07 11:43 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-04 1:43 [PATCH v2 00/14] OMAPDSS: HDMI: Prepare for DSS dev driver audio support and OMAP5 Ricardo Neri
2012-05-04 1:43 ` [PATCH v2 01/14] OMAPDSS: HDMI: Split audio_enable into audio_enable/disable Ricardo Neri
2012-05-04 1:43 ` [PATCH v2 02/14] OMAPDSS: HDMI: Split video_enable into video_enable/disable Ricardo Neri
2012-05-04 1:43 ` [PATCH v2 03/14] OMAPDSS: HDMI: Remove ASoC codec Ricardo Neri
2012-05-04 1:43 ` [PATCH v2 04/14] OMAPDSS: HDMI: OMAP4: Remove CEA-861 audio infoframe and IEC-60958 enums Ricardo Neri
2012-05-04 1:43 ` [PATCH v2 05/14] OMAPDSS: HDMI: OMAP4: Remove invalid I2S settings Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 06/14] OMAPDSS: HDMI: Decouple wrapper enable/disable and audio start/stop Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 07/14] OMAPDSS: HDMI: Decouple HDMI audio from ASoC Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 08/14] OMAPDSS: HDMI: OMAP4: Expand configuration for IEC-60958 audio Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 09/14] OMAPDSS: HDMI: Relocate N/CTS calculation Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 10/14] OMAPDSS: HDMI: Add support for more audio sample rates in " Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 11/14] OMAPDSS: HDMI: Add an audio configuration function Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 12/14] OMAPDSS: HDMI: OMAP4: Remap speaker order to match ALSA order Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 13/14] OMAPDSS: HDMI: Panel: Simplify the name of the HDMI mutex Ricardo Neri
2012-05-04 1:44 ` [PATCH v2 14/14] OMAPDSS: HDMI: Implement DSS driver interface for audio Ricardo Neri
2012-05-07 11:43 ` Tomi Valkeinen [this message]
2012-05-08 23:55 ` Ricardo Neri
2012-05-09 8:28 ` Tomi Valkeinen
2012-05-10 4:12 ` Ricardo Neri
2012-05-10 7:54 ` Tomi Valkeinen
2012-05-11 1:56 ` Ricardo Neri
2012-05-11 12:51 ` Tomi Valkeinen
2012-05-12 0:18 ` Ricardo Neri
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=1336390986.2667.8.camel@deskari \
--to=tomi.valkeinen@ti.com \
--cc=agraf@suse.de \
--cc=alsa-devel@alsa-project.org \
--cc=linux-omap@vger.kernel.org \
--cc=lrg@ti.com \
--cc=mythripk@ti.com \
--cc=peter.ujfalusi@ti.com \
--cc=research@ottomaneng.com \
--cc=ricardo.neri@ti.com \
--cc=s-chereau@ti.com \
--cc=s-guiriec@ti.com \
--cc=vaibhav.bedia@ti.com \
--cc=x0055901@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.