diff options
author | Takashi Iwai <tiwai@suse.de> | 2009-12-21 11:21:15 +0100 |
---|---|---|
committer | Takashi Iwai <tiwai@suse.de> | 2009-12-21 11:21:15 +0100 |
commit | de8853bc38ceab1fa7e7f723b21430d4aad60fea (patch) | |
tree | 5084ef51866fd1767324f8dc8eb36e97c55350f5 /sound/i2c | |
parent | f5de24b06aa46427500d0fdbe8616b73a71d8c28 (diff) | |
parent | 440b004cf953bec2bc8cd91c64ae707fd7e25327 (diff) | |
download | op-kernel-dev-de8853bc38ceab1fa7e7f723b21430d4aad60fea.zip op-kernel-dev-de8853bc38ceab1fa7e7f723b21430d4aad60fea.tar.gz |
Merge remote branch 'alsa/fixes' into fix/hda
Diffstat (limited to 'sound/i2c')
-rw-r--r-- | sound/i2c/cs8427.c | 15 | ||||
-rw-r--r-- | sound/i2c/other/tea575x-tuner.c | 2 |
2 files changed, 3 insertions, 14 deletions
diff --git a/sound/i2c/cs8427.c b/sound/i2c/cs8427.c index 020a5d5..04ae870 100644 --- a/sound/i2c/cs8427.c +++ b/sound/i2c/cs8427.c @@ -23,6 +23,7 @@ #include <linux/slab.h> #include <linux/delay.h> #include <linux/init.h> +#include <linux/bitrev.h> #include <asm/unaligned.h> #include <sound/core.h> #include <sound/control.h> @@ -55,18 +56,6 @@ struct cs8427 { struct cs8427_stream capture; }; -static unsigned char swapbits(unsigned char val) -{ - int bit; - unsigned char res = 0; - for (bit = 0; bit < 8; bit++) { - res <<= 1; - res |= val & 1; - val >>= 1; - } - return res; -} - int snd_cs8427_reg_write(struct snd_i2c_device *device, unsigned char reg, unsigned char val) { @@ -149,7 +138,7 @@ static int snd_cs8427_send_corudata(struct snd_i2c_device *device, } data[0] = CS8427_REG_AUTOINC | CS8427_REG_CORU_DATABUF; for (idx = 0; idx < count; idx++) - data[idx + 1] = swapbits(ndata[idx]); + data[idx + 1] = bitrev8(ndata[idx]); if (snd_i2c_sendbytes(device, data, count + 1) != count + 1) return -EIO; return 1; diff --git a/sound/i2c/other/tea575x-tuner.c b/sound/i2c/other/tea575x-tuner.c index d31c373..c4c6ef7 100644 --- a/sound/i2c/other/tea575x-tuner.c +++ b/sound/i2c/other/tea575x-tuner.c @@ -225,7 +225,7 @@ static int vidioc_s_ctrl(struct file *file, void *priv, case V4L2_CID_AUDIO_MUTE: if (tea->ops->mute) { tea->ops->mute(tea, ctrl->value); - tea->mute = 1; + tea->mute = ctrl->value; return 0; } } |