public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
From: Mark Brown <broonie@opensource.wolfsonmicro.com>
To: Gregoire Gentil <gregoire@gentil.com>
Cc: linux-omap@vger.kernel.org, Tony Lindgren <tony@atomide.com>,
	alsa-devel@alsa-project.org, Tim Yamin <plasmaroo@gmail.com>
Subject: Re: [alsa-devel] [PATCH 6/8] Audio driver of Always Innovating OMAP3-based Touch Book
Date: Mon, 23 Nov 2009 15:35:04 +0000	[thread overview]
Message-ID: <20091123153504.GD3987@sirena.org.uk> (raw)
In-Reply-To: <1258651091-31727-7-git-send-email-gregoire@gentil.com>

On Thu, Nov 19, 2009 at 09:18:09AM -0800, Gregoire Gentil wrote:

> Signed-off-by: Gregoire Gentil <gregoire@gentil.com>

Please remember to CC the maintainers for the subsystem you're
submitting to on patches.

> +static irqreturn_t touchbook_headphone_event(int irq, void *snd)
> +{
> +	int status = gpio_get_value(TB_HEADPHONE_GPIO);
> +	struct snd_soc_device *socdev = platform_get_drvdata(
> +						omap3touchbook_snd_device);
> +	struct snd_soc_codec *codec = socdev->card->codec;
> +
> +	if (status) {
> +		snd_soc_dapm_disable_pin(codec, "HFL");
> +		snd_soc_dapm_disable_pin(codec, "HFR");
> +	} else {
> +		snd_soc_dapm_enable_pin(codec, "HFL");
> +		snd_soc_dapm_enable_pin(codec, "HFR");
> +	}
> +
> +	schedule_work(&jack_work);
> +	return IRQ_HANDLED;
> +}

All this jack handling should be using the standard GPIO based jack
abstraction provided by sound/soc/soc-jack.c.  That will also give
userspace visiblity of the status of the jack, allowing better
application integration.  sdp3430 and ams-delta provide examples of
using the API.

  parent reply	other threads:[~2009-11-23 15:34 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-11-19 17:18 [PATCH 0/8] AI TB: Always Innovating OMAP3-based Touch Book Gregoire Gentil
2009-11-19 17:18 ` [PATCH 1/8] defconfig file of " Gregoire Gentil
2009-11-19 17:18   ` [PATCH 2/8] Board " Gregoire Gentil
2009-11-19 17:18     ` [PATCH 3/8] Freescale MMA7455 accelerometer driver Gregoire Gentil
2009-11-19 17:18       ` [PATCH 4/8] Driver for Always Innovating OMAP3-based Touch Book keyboard Gregoire Gentil
2009-11-19 17:18         ` [PATCH 5/8] HID file " Gregoire Gentil
2009-11-19 17:18           ` [PATCH 6/8] Audio driver of Always Innovating OMAP3-based Touch Book Gregoire Gentil
2009-11-19 17:18             ` [PATCH 7/8] Video " Gregoire Gentil
2009-11-19 17:18               ` [PATCH 8/8] Additional file for " Gregoire Gentil
2009-11-20  4:07               ` [PATCH 7/8] Video driver of " Hiremath, Vaibhav
2009-11-23 15:35             ` Mark Brown [this message]
2009-11-19 17:37           ` [PATCH 5/8] HID file for Always Innovating OMAP3-based Touch Book keyboard Koen Kooi
2009-11-19 19:24       ` [PATCH 3/8] Freescale MMA7455 accelerometer driver Jonathan Cameron
2009-11-20  4:20     ` [PATCH 2/8] Board file of Always Innovating OMAP3-based Touch Book Hiremath, Vaibhav
2009-12-07 21:49       ` Tony Lindgren
2009-12-07 22:11         ` Tim Yamin
2009-12-07 23:19           ` Tony Lindgren
2009-12-08 16:19             ` Hiremath, Vaibhav

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=20091123153504.GD3987@sirena.org.uk \
    --to=broonie@opensource.wolfsonmicro.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=gregoire@gentil.com \
    --cc=linux-omap@vger.kernel.org \
    --cc=plasmaroo@gmail.com \
    --cc=tony@atomide.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox