Merge branch 'for-2.6.37' into HEAD
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 2 Nov 2010 13:58:49 +0000 (09:58 -0400)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Tue, 2 Nov 2010 13:58:49 +0000 (09:58 -0400)
WARN() fix from Joe moved.

Conflicts:
sound/soc/codecs/wm_hubs.c

1  2 
sound/soc/codecs/wm_hubs.c

@@@ -113,29 -101,6 +113,29 @@@ static void calibrate_dc_servo(struct s
        wait_for_dc_servo(codec,
                          WM8993_DCS_TRIG_SERIES_0 | WM8993_DCS_TRIG_SERIES_1);
  
-               WARN(1, "Unknown DCS readback method");
 +      /* Different chips in the family support different readback
 +       * methods.
 +       */
 +      switch (hubs->dcs_readback_mode) {
 +      case 0:
 +              reg_l = snd_soc_read(codec, WM8993_DC_SERVO_READBACK_1)
 +                      & WM8993_DCS_INTEG_CHAN_0_MASK;;
 +              reg_r = snd_soc_read(codec, WM8993_DC_SERVO_READBACK_2)
 +                      & WM8993_DCS_INTEG_CHAN_1_MASK;
 +              break;
 +      case 1:
 +              reg = snd_soc_read(codec, WM8993_DC_SERVO_3);
 +              reg_l = (reg & WM8993_DCS_DAC_WR_VAL_1_MASK)
 +                      >> WM8993_DCS_DAC_WR_VAL_1_SHIFT;
 +              reg_r = reg & WM8993_DCS_DAC_WR_VAL_0_MASK;
 +              break;
 +      default:
++              WARN(1, "Unknown DCS readback method\n");
 +              break;
 +      }
 +
 +      dev_dbg(codec->dev, "DCS input: %x %x\n", reg_l, reg_r);
 +
        /* Apply correction to DC servo result */
        if (hubs->dcs_codes) {
                dev_dbg(codec->dev, "Applying %d code DC servo correction\n",