All of lore.kernel.org
 help / color / mirror / Atom feed
From: Tom Zanussi <tom.zanussi@intel.com>
To: kishore.k.bodke@intel.com
Cc: yocto@yoctoproject.org
Subject: Re: [PATCH 6/7] Cedartrail: Add a new recipe for Audio.
Date: Mon, 09 Apr 2012 13:04:09 -0500	[thread overview]
Message-ID: <1333994649.2335.72.camel@elmorro> (raw)
In-Reply-To: <7a988a33c1d49b6645b55076fe73cb9f2f4f2aaa.1333496206.git.kishore.k.bodke@intel.com>

On Tue, 2012-04-03 at 16:43 -0700, kishore.k.bodke@intel.com wrote:
> From: Kishore Bodke <kishore.k.bodke@intel.com>
> 
> Adding a new recipe for including a Audio
> feature for the cedartrail bsp.
> 

As mentioned, I think the new way to do this is using asound.state (see
meta-intel/meta-n450/recipes-bsp/alsa-state/alsa-state/n450/asound.state
as an example).

Tom

> Signed-off-by: Kishore Bodke <kishore.k.bodke@intel.com>
> ---
>  .../cedartrail-audio/cedartrail-audio.bb           |   30 ++++++++++++++
>  .../cedartrail-audio/cedartrail-audio              |   42 ++++++++++++++++++++
>  2 files changed, 72 insertions(+), 0 deletions(-)
>  create mode 100644 meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio.bb
>  create mode 100644 meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio/cedartrail-audio
> 
> diff --git a/meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio.bb b/meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio.bb
> new file mode 100644
> index 0000000..9a43f02
> --- /dev/null
> +++ b/meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio.bb
> @@ -0,0 +1,30 @@
> +SUMMARY = "Provide a basic init script to enable audio"
> +DESCRIPTION = "Set the volume and unmute the Front mixer setting during boot."
> +SECTION = "base"
> +LICENSE = "MIT"
> +LIC_FILES_CHKSUM = "file://${COREBASE}/LICENSE;md5=3f40d7994397109285ec7b81fdeb3b58"
> +
> +PR = "r0"
> +
> +inherit update-rc.d
> +
> +RDEPENDS = "alsa-utils-amixer"
> +
> +SRC_URI = "file://cedartrail-audio"
> +
> +INITSCRIPT_NAME = "cedartrail-audio"
> +INITSCRIPT_PARAMS = "defaults 90"
> +
> +do_install() {
> +	install -d ${D}${sysconfdir} \
> +	           ${D}${sysconfdir}/init.d
> +	install -m 0755 ${WORKDIR}/cedartrail-audio ${D}${sysconfdir}/init.d
> +        cat ${WORKDIR}/${INITSCRIPT_NAME} | \
> +            sed -e 's,/etc,${sysconfdir},g' \
> +                -e 's,/usr/sbin,${sbindir},g' \
> +                -e 's,/var,${localstatedir},g' \
> +                -e 's,/usr/bin,${bindir},g' \
> +                -e 's,/usr,${prefix},g' > ${D}${sysconfdir}/init.d/${INITSCRIPT_NAME}
> +        chmod 755 ${D}${sysconfdir}/init.d/${INITSCRIPT_NAME}
> +}
> +
> diff --git a/meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio/cedartrail-audio b/meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio/cedartrail-audio
> new file mode 100644
> index 0000000..efd08d3
> --- /dev/null
> +++ b/meta-cedartrail/recipes-bsp/cedartrail-audio/cedartrail-audio/cedartrail-audio
> @@ -0,0 +1,42 @@
> +#!/bin/sh
> +### BEGIN INIT INFO
> +# Provides:          cedartrail mixer setup
> +# Required-Start:    $syslog
> +# Required-Stop:     $syslog
> +# Default-Start:     2 3 4 5
> +# Default-Stop:      0 1 6
> +# Short-Description: Initialize the cedartrail audio mixer
> +# Description:       Unmute FRONT and set volume 
> +### END INIT INFO
> +
> +# Author: Darren Hart <dvhart@linux.intel.com>
> +# Based on /etc/init.d/skeleton
> +
> +PATH=/sbin:/usr/sbin:/bin:/usr/bin
> +DESC="Audio mixer settings"
> +NAME=cedartrail-audio
> +AMIXER=`which amixer`
> +SCRIPTNAME=/etc/init.d/$NAME
> +
> +# Exit if amixer is not installed
> +[ -x "$AMIXER" ] || exit 0
> +
> +do_start() {
> +	# Enable the "Front" simple controls (black phones jack)
> +	$AMIXER sset Front 90 on > /dev/null
> +}
> +
> +case "$1" in
> +start)
> +	echo "$NAME: setting default mixer settings."
> +	do_start
> +	;;
> +stop)
> +	;;
> +*)
> +	echo "Usage: $SCRIPTNAME {start|stop}" >&2
> +	exit 3
> +	;;
> +esac
> +
> +exit 0




  reply	other threads:[~2012-04-09 18:04 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-03 23:43 [PATCH 0/7] [meta-intel] Cedartrail BSP updates with pvr Graphics driver kishore.k.bodke
2012-04-03 23:43 ` [PATCH 1/7] Cedartrail: Add PVR graphics support kishore.k.bodke
2012-04-09 17:56   ` Tom Zanussi
2012-04-09 18:22     ` Bodke, Kishore K
2012-04-03 23:43 ` [PATCH 2/7] Cedartrail: Update SRCREVS and add EFI Support kishore.k.bodke
2012-04-03 23:43 ` [PATCH 3/7] Cedartrail: Add new recipes for audio and video samples kishore.k.bodke
2012-04-09 17:57   ` Tom Zanussi
2012-04-09 18:25     ` Bodke, Kishore K
2012-04-03 23:43 ` [PATCH 4/7] Cedartrail: Add bbappend files to install Audio and Video files kishore.k.bodke
2012-04-09 18:00   ` Tom Zanussi
2012-04-09 18:29     ` Bodke, Kishore K
2012-04-09 18:41       ` Tom Zanussi
2012-04-09 18:57         ` Bodke, Kishore K
2012-04-03 23:43 ` [PATCH 5/7] Cedartrail: Separte out machine.conf files kishore.k.bodke
2012-04-03 23:43 ` [PATCH 6/7] Cedartrail: Add a new recipe for Audio kishore.k.bodke
2012-04-09 18:04   ` Tom Zanussi [this message]
2012-04-09 18:31     ` Bodke, Kishore K
2012-04-03 23:43 ` [PATCH 7/7] Cedartrail: Update the README kishore.k.bodke
2012-04-09 18:06   ` Tom Zanussi
2012-04-09 18:35     ` Bodke, Kishore K
2012-04-09 17:46 ` [PATCH 0/7] [meta-intel] Cedartrail BSP updates with pvr Graphics driver Tom Zanussi
2012-04-09 18:17   ` Bodke, Kishore K

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=1333994649.2335.72.camel@elmorro \
    --to=tom.zanussi@intel.com \
    --cc=kishore.k.bodke@intel.com \
    --cc=yocto@yoctoproject.org \
    /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.