Skip to contentSkip to conversation

small fixes during code reading

PATCH Applied Lu Guanqun 3 participants 7 messages Apr 20, 2011

Subsystems (2)
lore
Share & tools
lore

Lu Guanqun

author
#0 lore raw

cover small fixes during code reading

The following patches are fixed during my own code reading. These are quite trivial, most are style fixes.

These patches are based on Mark Brown's for-2.6.40 branch.

---

Lu Guanqun (4):
ASoC: fix a simple coding style issue
ASoC: remove unused comment
ASoC: simple style fix
ASoC: fix two ident style problems

 include/sound/soc-dapm.h |    2 +-
 sound/soc/soc-cache.c    |    1 -
 sound/soc/soc-core.c     |    4 ++--
 sound/soc/soc-dapm.c     |    2 +-
 4 files changed, 4 insertions(+), 5 deletions(-)
Signature · 1 line
guanqun
author
#1 lore raw

PATCH 1/4 ASoC: fix a simple coding style issue

---
 sound/soc/soc-dapm.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
sound/soc/soc-dapm.c +1 -1
index 2ee738c..2fa2442 100644
@@ -1597,7 +1597,7 @@ static int snd_soc_dapm_add_route(struct snd_soc_dapm_context *dapm,
 	}
 
 	/* connect dynamic paths */
-	switch(wsink->id) {
+	switch (wsink->id) {
 	case snd_soc_dapm_adc:
 	case snd_soc_dapm_dac:
 	case snd_soc_dapm_pga:
author
#3 lore raw

PATCH 2/4 ASoC: remove unused comment

In reply to Lu Guanqun

type parameter is not longer used in snd_soc_codec_set_cache_io, so remove this line.

---
 sound/soc/soc-cache.c |    1 -
 1 files changed, 0 insertions(+), 1 deletions(-)
sound/soc/soc-cache.c +0 -1
index f46a198..a217db2 100644
@@ -484,7 +484,6 @@ static struct {
  * snd_soc_codec_set_cache_io: Set up standard I/O functions.
  *
  * @codec: CODEC to configure.
- * @type: Type of cache.
  * @addr_bits: Number of bits of register address data.
  * @data_bits: Number of bits of data per register.
  * @control: Control bus used.
author
#4 lore raw

PATCH 3/4 ASoC: simple style fix

In reply to Lu Guanqun

replace the tab with spaces,
make it align with other paragraphs

---
 include/sound/soc-dapm.h |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
include/sound/soc-dapm.h +1 -1
index f72c103..d5f1b9a 100644
@@ -24,7 +24,7 @@
  * SoC dynamic audio power management
  *
  * We can have up to 4 power domains
- * 	1. Codec domain - VREF, VMID
+ *  1. Codec domain - VREF, VMID
  *     Usually controlled at codec probe/remove, although can be set
  *     at stream time if power is not needed for sidetone, etc.
  *  2. Platform/Machine domain - physically connected inputs and outputs
author
#5 lore raw

PATCH 4/4 ASoC: fix two ident style problems

In reply to Lu Guanqun
---
 sound/soc/soc-core.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
sound/soc/soc-core.c +2 -2
index 3b3a377d..a6f37d4 100644
@@ -3475,7 +3475,7 @@ int snd_soc_register_dai(struct device *dev,
 
 	dai = kzalloc(sizeof(struct snd_soc_dai), GFP_KERNEL);
 	if (dai == NULL)
-			return -ENOMEM;
+		return -ENOMEM;
 
 	/* create DAI component name */
 	dai->name = fmt_single_name(dev, &dai->id);
@@ -3614,7 +3614,7 @@ int snd_soc_register_platform(struct device *dev,
 
 	platform = kzalloc(sizeof(struct snd_soc_platform), GFP_KERNEL);
 	if (platform == NULL)
-			return -ENOMEM;
+		return -ENOMEM;
 
 	/* create platform component name */
 	platform->name = fmt_single_name(dev, &platform->id);
#6 lore raw

Re: [PATCH 4/4] ASoC: fix two ident style problems

Am Mittwoch, den 20.04.2011, 16:00 +0800 schrieb Lu Guanqun:

Mark, please fix s/ident/indent/ when applying the patches.

Quoted 1 line

[…]

Thanks,

Paul