SSC_RCMR, ssc_p->ssc_state.ssc_rcmr);
	at91_ssc_write(ssc_p->ssc.base + AT91_SSC_CMR,  ssc_p->ssc_state.ssc_cmr);

	at91_ssc_write(ssc_p->ssc.base + AT91_SSC_IER,  ssc_p->ssc_state.ssc_imr);

	at91_ssc_write(ssc_p->ssc.base + AT91_SSC_CR,
		((ssc_p->ssc_state.ssc_sr & AT91_SSC_RXENA) ? AT91_SSC_RXEN : 0) |
		((ssc_p->ssc_state.ssc_sr & AT91_SSC_TXENA) ? AT91_SSC_TXEN : 0));

	return 0;
}

#else
#define at91_ssc_suspend	NULL
#define at91_ssc_resume		NULL
#endif

#define AT91_SSC_RATES (SNDRV_PCM_RATE_8000  | SNDRV_PCM_RATE_11025 |\
			SNDRV_PCM_RATE_16000 | SNDRV_PCM_RATE_22050 |\
			SNDRV_PCM_RATE_32000 | SNDRV_PCM_RATE_44100 |\
			SNDRV_PCM_RATE_48000 | SNDRV_PCM_RATE_88200 |\
			SNDRV_PCM_RATE_96000)

#define AT91_SSC_FORMATS (SNDRV_PCM_FMTBIT_S8     | SNDRV_PCM_FMTBIT_S16_LE |\
			  SNDRV_PCM_FMTBIT_S24_LE | SNDRV_PCM_FMTBIT_S32_LE)

struct snd_soc_cpu_dai at91_ssc_dai[NUM_SSC_DEVICES] = {
	{	.name = "at91-ssc0",
		.id = 0,
		.type = SND_SOC_DAI_PCM,
		.suspend = at91_ssc_suspend,
		.resume = at91_ssc_resume,
		.playback = {
			.channels_min = 1,
			.channels_max = 2,
			.rates = AT91_SSC_RATES,
			.formats = AT91_SSC_FORMATS,},
		.capture = {
			.channels_min = 1,
			.channels_max = 2,
			.rates = AT91_SSC_RATES,
			.formats = AT91_SSC_FORMATS,},
		.ops = {
			.startup = at91_ssc_startup,
			.shutdown = at91_ssc_shutdown,
			.prepare = at91_ssc_prepare,
			.hw_params = at91_ssc_hw_params,},
		.dai_ops = {
			.set_sysclk = at91_ssc_set_dai_sysclk,
			.set_fmt = at91_ssc_set_dai_fmt,
			.set_clkdiv = at91_ssc_set_dai_clkdiv,},
		.private_data = &ssc_info[0].ssc,
	},
#if NUM_SSC_DEVICES == 3
	{	.name = "at91-ssc1",
		.id = 1,
		.type = SND_SOC_DAI_PCM,
		.suspend = at91_ssc_suspend,
		.resume = at91_ssc_resume,
		.playback = {
			.channels_min = 1,
			.channels_max = 2,
			.rates = AT91_SSC_RATES,
			.formats = AT91_SSC_FORMATS,},
		.capture = {
			.channels_min = 1,
			.channels_max = 2,
			.rates = AT91_SSC_RATES,
			.formats = AT91_SSC_FORMATS,},
		.ops = {
			.startup = at91_ssc_startup,
			.shutdown = at91_