From a24d0d376558c32a5e8f316f7f532a13cab61aeb Mon Sep 17 00:00:00 2001 From: Misael Lopez Cruz Date: Fri, 10 Dec 2010 21:06:24 -0600 Subject: [PATCH] --- yaml --- r: 230415 b: refs/heads/master c: 4f44ee1f494edef1fea3db20565b2e209bef6280 h: refs/heads/master i: 230413: 5cfa1b0342c74637d17b7bec9cf87f89facdc0ee 230411: 84fd65f8e92de1388b0fca55548711a3f6b73ca3 230407: bb0f5e927a695bcb6b431d5c409b82805c99ea8a 230399: 650b1a5c5e1911740435aa05ed8d49538a3baac4 v: v3 --- [refs] | 2 +- trunk/sound/soc/codecs/twl6040.c | 10 +++------- trunk/sound/soc/codecs/twl6040.h | 1 + 3 files changed, 5 insertions(+), 8 deletions(-) diff --git a/[refs] b/[refs] index becf9e3b537e..08b8e209f2f4 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: f1f489a6aa89993892cd7b4d08f67e7e110492cb +refs/heads/master: 4f44ee1f494edef1fea3db20565b2e209bef6280 diff --git a/trunk/sound/soc/codecs/twl6040.c b/trunk/sound/soc/codecs/twl6040.c index f5d5f89a2216..a8ec9113cc33 100644 --- a/trunk/sound/soc/codecs/twl6040.c +++ b/trunk/sound/soc/codecs/twl6040.c @@ -1108,7 +1108,7 @@ static int twl6040_probe(struct snd_soc_codec *codec) struct twl6040_data *priv; int audpwron, naudint; int ret = 0; - u8 icrev; + u8 icrev, intmr = TWL6040_ALLINT_MSK; priv = kzalloc(sizeof(struct twl6040_data), GFP_KERNEL); if (priv == NULL) @@ -1154,16 +1154,12 @@ static int twl6040_probe(struct snd_soc_codec *codec) priv->codec_powered = 0; /* enable only codec ready interrupt */ - twl6040_write(codec, TWL6040_REG_INTMR, - ~TWL6040_READYMSK & TWL6040_ALLINT_MSK); + intmr &= ~(TWL6040_READYMSK | TWL6040_PLUGMSK); /* reset interrupt status to allow correct power up sequence */ twl6040_read_reg_volatile(codec, TWL6040_REG_INTID); - } else { - /* no interrupts at all */ - twl6040_write_reg_cache(codec, TWL6040_REG_INTMR, - TWL6040_ALLINT_MSK); } + twl6040_write(codec, TWL6040_REG_INTMR, intmr); if (naudint) { /* audio interrupt */ diff --git a/trunk/sound/soc/codecs/twl6040.h b/trunk/sound/soc/codecs/twl6040.h index 67396f63c1ec..23aeed0963e6 100644 --- a/trunk/sound/soc/codecs/twl6040.h +++ b/trunk/sound/soc/codecs/twl6040.h @@ -79,6 +79,7 @@ /* INTMR (0x04) fields */ +#define TWL6040_PLUGMSK 0x02 #define TWL6040_READYMSK 0x40 #define TWL6040_ALLINT_MSK 0x7B