]> git.openfabrics.org - ~emulex/infiniband.git/commitdiff
ASoC: Show device id in the debug message
authorAxel Lin <axel.lin@gmail.com>
Thu, 16 Feb 2012 02:33:45 +0000 (10:33 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Thu, 16 Feb 2012 06:19:55 +0000 (22:19 -0800)
Show the id we read when the id mismatch is detected.
This is useful for debugging.

Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
sound/soc/codecs/wm8962.c
sound/soc/codecs/wm8996.c
sound/soc/codecs/wm9090.c

index 172dcacb828e607c84bab09b8df26ac65b029d5d..5a6516ee06a8865ccb7ae7f1c2ec573653c8076c 100644 (file)
@@ -3718,7 +3718,7 @@ static __devinit int wm8962_i2c_probe(struct i2c_client *i2c,
        }
        if (reg != 0x6243) {
                dev_err(&i2c->dev,
-                       "Device is not a WM8962, ID %x != 0x6243\n", ret);
+                       "Device is not a WM8962, ID %x != 0x6243\n", reg);
                ret = -EINVAL;
                goto err_regmap;
        }
index 759ea69f0b44e326f720a9dfc3944a5811c36ee7..c3bde4a6b7fcf9d352b0c9b7a480421c85b985d6 100644 (file)
@@ -3185,7 +3185,7 @@ static __devinit int wm8996_i2c_probe(struct i2c_client *i2c,
                goto err_regmap;
        }
        if (reg != 0x8915) {
-               dev_err(&i2c->dev, "Device is not a WM8996, ID %x\n", ret);
+               dev_err(&i2c->dev, "Device is not a WM8996, ID %x\n", reg);
                ret = -EINVAL;
                goto err_regmap;
        }
index e8280eecd4c9691acb74bedf8ec16dde121cbe89..4b263b6edf13793908d3d1ab11c2630e5bee9054 100644 (file)
@@ -639,7 +639,7 @@ static int wm9090_i2c_probe(struct i2c_client *i2c,
        if (ret < 0)
                goto err;
        if (reg != 0x9093) {
-               dev_err(&i2c->dev, "Device is not a WM9090, ID=%x\n", ret);
+               dev_err(&i2c->dev, "Device is not a WM9090, ID=%x\n", reg);
                ret = -ENODEV;
                goto err;
        }