-/* sound/soc/samsung/i2s.c
- *
+/*
* ALSA SoC Audio Layer - Samsung I2S Controller driver
*
* Copyright (c) 2010 Samsung Electronics Co. Ltd.
/* Platform device for this DAI */
struct platform_device *pdev;
- /* Frame Clock */
+ /* Frame clock */
unsigned frmclk;
/*
- * Specifically requested RCLK,BCLK by MACHINE Driver.
+ * Specifically requested RCLK, BCLK by machine driver.
* 0 indicates CPU driver is free to choose any value.
*/
unsigned rfs, bfs;
struct i2s_dai *pri_dai;
/* Pointer to the Secondary_Fifo if it has one, NULL otherwise */
struct i2s_dai *sec_dai;
-#define DAI_OPENED (1 << 0) /* Dai is opened */
-#define DAI_MANAGER (1 << 1) /* Dai is the manager */
+
+#define DAI_OPENED (1 << 0) /* DAI is opened */
+#define DAI_MANAGER (1 << 1) /* DAI is the manager */
unsigned mode;
/* Driver for this DAI */
/* Spinlock protecting access to the device's registers */
spinlock_t lock;
- /* Lock for cross i/f checks */
+ /* Lock for cross interface checks */
spinlock_t pcm_lock;
/* CPU DAIs and their corresponding drivers */
writel(mod, priv->addr + I2SMOD);
}
-/* Read Bit-Clock of I2S (in multiples of LRCLK) */
+/* Read bit-clock of I2S (in multiples of LRCLK) */
static inline unsigned get_bfs(struct i2s_dai *i2s)
{
struct samsung_i2s_priv *priv = i2s->priv;
}
}
-/* Write Bit-Clock of I2S (in multiples of LRCLK) */
+/* Write bit-clock of I2S (in multiples of LRCLK) */
static inline void set_bfs(struct i2s_dai *i2s, unsigned bfs)
{
struct samsung_i2s_priv *priv = i2s->priv;
writel(mod, priv->addr + I2SMOD);
}
-/* Sample-Size */
+/* Sample size */
static inline int get_blc(struct i2s_dai *i2s)
{
int blc = readl(i2s->priv->addr + I2SMOD);
}
}
-/* TX Channel Control */
+/* TX channel control */
static void i2s_txctrl(struct i2s_dai *i2s, int on)
{
struct samsung_i2s_priv *priv = i2s->priv;
switch (params_channels(params)) {
case 6:
val |= MOD_DC2_EN;
- /* fall through */
+ /* Fall through */
case 4:
val |= MOD_DC1_EN;
break;
return 0;
}
-/* We set constraints on the substream acc to the version of I2S */
+/* We set constraints on the substream according to the version of I2S */
static int i2s_startup(struct snd_pcm_substream *substream,
struct snd_soc_dai *dai)
{
pm_runtime_get_sync(dai->dev);
- if (is_secondary(i2s)) { /* If this is probe on the secondary DAI */
+ if (is_secondary(i2s)) {
+ /* If this is probe on the secondary DAI */
snd_soc_dai_init_dma_data(dai, &i2s->dma_playback, NULL);
} else {
snd_soc_dai_init_dma_data(dai, &i2s->dma_playback,