Merge remote-tracking branch 'asoc/fix/adsp' into asoc-adsp
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 28 Jan 2013 16:51:05 +0000 (00:51 +0800)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 28 Jan 2013 16:51:05 +0000 (00:51 +0800)
Conflicts:
sound/soc/codecs/wm_adsp.c

1  2 
sound/soc/codecs/wm_adsp.c

  #define ADSP1_START_SHIFT                      0  /* DSP1_START */
  #define ADSP1_START_WIDTH                      1  /* DSP1_START */
  
- #define ADSP2_CONTROL  0
- #define ADSP2_CLOCKING 1
- #define ADSP2_STATUS1  4
 +/*
 + * ADSP1 Control 31
 + */
 +#define ADSP1_CLK_SEL_MASK                0x0007  /* CLK_SEL_ENA */
 +#define ADSP1_CLK_SEL_SHIFT                    0  /* CLK_SEL_ENA */
 +#define ADSP1_CLK_SEL_WIDTH                    3  /* CLK_SEL_ENA */
 +
+ #define ADSP2_CONTROL        0x0
+ #define ADSP2_CLOCKING       0x1
+ #define ADSP2_STATUS1        0x4
+ #define ADSP2_WDMA_CONFIG_1 0x30
+ #define ADSP2_WDMA_CONFIG_2 0x31
+ #define ADSP2_RDMA_CONFIG_1 0x34
  
  /*
   * ADSP2 Control
@@@ -688,19 -399,9 +691,19 @@@ static int wm_adsp_load_coeff(struct wm
        hdr = (void*)&firmware->data[0];
        if (memcmp(hdr->magic, "WMDR", 4) != 0) {
                adsp_err(dsp, "%s: invalid magic\n", file);
-               return -EINVAL;
+               goto out_fw;
        }
  
 +      switch (be32_to_cpu(hdr->rev) & 0xff) {
 +      case 1:
 +              break;
 +      default:
 +              adsp_err(dsp, "%s: Unsupported coefficient file format %d\n",
 +                       file, be32_to_cpu(hdr->rev) & 0xff);
 +              ret = -EINVAL;
 +              goto out_fw;
 +      }
 +
        adsp_dbg(dsp, "%s: v%d.%d.%d\n", file,
                (le32_to_cpu(hdr->ver) >> 16) & 0xff,
                (le32_to_cpu(hdr->ver) >>  8) & 0xff,