From: Felix Homann <linuxaudio@showlabor.de>
To: patch@alsa-project.org
Cc: alsa-devel@alsa-project.org,
Felix Homann <linuxaudio@showlabor.de>,
mark@pogo.org.uk
Subject: [PATCH 2/5] Rename and export mixer_vol_tlv
Date: Mon, 23 Apr 2012 20:24:24 +0200 [thread overview]
Message-ID: <1335205467-12650-3-git-send-email-linuxaudio@showlabor.de> (raw)
In-Reply-To: <1335205467-12650-1-git-send-email-linuxaudio@showlabor.de>
Rename mixer_vol_tlv to snd_usb_mixer_vol_tlv and export it to make
it reuseable in mixer_quirks.c.
Signed-off-by: Felix Homann <linuxaudio@showlabor.de>
diff --git a/sound/usb/mixer.c b/sound/usb/mixer.c
index c374c72..bb56f53 100644
--- a/sound/usb/mixer.c
+++ b/sound/usb/mixer.c
@@ -486,7 +486,7 @@ static int set_cur_mix_value(struct usb_mixer_elem_info *cval, int channel,
/*
* TLV callback for mixer volume controls
*/
-static int mixer_vol_tlv(struct snd_kcontrol *kcontrol, int op_flag,
+int snd_usb_mixer_vol_tlv(struct snd_kcontrol *kcontrol, int op_flag,
unsigned int size, unsigned int __user *_tlv)
{
struct usb_mixer_elem_info *cval = kcontrol->private_data;
@@ -1158,7 +1158,7 @@ static void build_feature_ctl(struct mixer_build *state, void *raw_desc,
if (control == UAC_FU_VOLUME) {
check_mapped_dB(map, cval);
if (cval->dBmin < cval->dBmax || !cval->initialized) {
- kctl->tlv.c = mixer_vol_tlv;
+ kctl->tlv.c = snd_usb_mixer_vol_tlv;
kctl->vd[0].access |=
SNDRV_CTL_ELEM_ACCESS_TLV_READ |
SNDRV_CTL_ELEM_ACCESS_TLV_CALLBACK;
diff --git a/sound/usb/mixer.h b/sound/usb/mixer.h
index 81b2d8a..a7f3d45 100644
--- a/sound/usb/mixer.h
+++ b/sound/usb/mixer.h
@@ -68,4 +68,7 @@ int snd_usb_mixer_activate(struct usb_mixer_interface *mixer);
int snd_usb_mixer_add_control(struct usb_mixer_interface *mixer,
struct snd_kcontrol *kctl);
+int snd_usb_mixer_vol_tlv(struct snd_kcontrol *kcontrol, int op_flag,
+ unsigned int size, unsigned int __user *_tlv);
+
#endif /* __USBMIXER_H */
--
1.7.5.4
next prev parent reply other threads:[~2012-04-23 18:24 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-04-23 18:24 [PATCH 0/5] Alsa: snd-usb: Improve M-Audio Fast Track Ultra mixer - v3 Felix Homann
2012-04-23 18:24 ` [PATCH 1/5] Unify M-Audio Fast Track Ultra and Ebox-44 mixer quirks Felix Homann
2012-04-23 18:36 ` Mark Hills
2012-04-23 18:46 ` Felix Homann
2012-04-24 6:20 ` Takashi Iwai
2012-04-23 18:24 ` Felix Homann [this message]
2012-04-23 18:24 ` [PATCH 3/5] Add TLV to M-Audio Fast Track Ultra controls Felix Homann
2012-04-23 18:24 ` [PATCH 4/5] Rename Fast Track Ultra mixer quirk functions Felix Homann
2012-04-23 18:24 ` [PATCH 5/5] M-Audio Fast Track Ultra: Add effect controls Felix Homann
2012-04-23 18:47 ` [PATCH 0/5] Alsa: snd-usb: Improve M-Audio Fast Track Ultra mixer - v3 Mark Hills
2012-04-23 19:00 ` Felix Homann
2012-04-24 6:21 ` Takashi Iwai
2012-04-24 7:18 ` Felix Homann
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=1335205467-12650-3-git-send-email-linuxaudio@showlabor.de \
--to=linuxaudio@showlabor.de \
--cc=alsa-devel@alsa-project.org \
--cc=mark@pogo.org.uk \
--cc=patch@alsa-project.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 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).