public inbox for linux-omap@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] ARM: OMAP: omap-alsa-aic23.c cleanup. No code change
@ 2006-12-03 17:49 Komal Shah
  2006-12-11 21:41 ` Tony Lindgren
  0 siblings, 1 reply; 2+ messages in thread
From: Komal Shah @ 2006-12-03 17:49 UTC (permalink / raw)
  To: linux-omap-open-source

[-- Attachment #1: Type: text/plain, Size: 48 bytes --]

-- 
---Komal Shah
http://komalshah.blogspot.com

[-- Attachment #2: 0002-ARM-OMAP-omap-alsa-aic23.c-cleanup.-No-code-change.patch --]
[-- Type: text/x-patch, Size: 5492 bytes --]

From e00b82a90c3086f596d5478e57249cf86e056b33 Mon Sep 17 00:00:00 2001
From: Komal Shah <komal_shah802003@yahoo.com>
Date: Sun, 3 Dec 2006 23:11:29 +0530
Subject: [PATCH] ARM: OMAP: omap-alsa-aic23.c cleanup. No code change.

- whitespace removal.
- Follow 80 line rule. Still few places left.

Signed-off-by: Komal Shah <komal_shah802003@yahoo.com>
---
 sound/arm/omap/omap-alsa-aic23.c |   46 +++++++++++++++++++-------------------
 1 files changed, 23 insertions(+), 23 deletions(-)

diff --git a/sound/arm/omap/omap-alsa-aic23.c b/sound/arm/omap/omap-alsa-aic23.c
index b483961..0e1528a 100644
--- a/sound/arm/omap/omap-alsa-aic23.c
+++ b/sound/arm/omap/omap-alsa-aic23.c
@@ -1,6 +1,4 @@
 /*
- * arch/arm/mach-omap1/omap-alsa-aic23.c
- * 
  * Alsa codec Driver for AIC23 chip on OSK5912 platform board
  *
  * Copyright (C) 2005 Instituto Nokia de Tecnologia - INdT - Manaus Brazil
@@ -8,7 +6,7 @@
  *            {daniel.petrini, david.cohen, anderson.briglia}@indt.org.br
  *
  * Copyright (C) 2006 Mika Laitio <lamikr@cc.jyu.fi>
- * 
+ *
  * Based in former alsa driver for osk and oss driver
  *
  * This program is free software; you can redistribute it and/or modify it
@@ -49,8 +47,8 @@ static const struct aic23_samplerate_reg
 /*
  * Hardware capabilities
  */
- 
- /*
+
+/*
  * DAC USB-mode sampling rates (MCLK = 12 MHz)
  * The rates and rate_reg_into MUST be in the same order
  */
@@ -68,7 +66,7 @@ static snd_pcm_hw_constraint_list_t aic2
 
 static snd_pcm_hardware_t aic23_snd_omap_alsa_playback = {
 	.info = (SNDRV_PCM_INFO_INTERLEAVED | SNDRV_PCM_INFO_BLOCK_TRANSFER |
-		 SNDRV_PCM_INFO_MMAP | SNDRV_PCM_INFO_MMAP_VALID),	
+		 SNDRV_PCM_INFO_MMAP | SNDRV_PCM_INFO_MMAP_VALID),
 	.formats = (SNDRV_PCM_FMTBIT_S16_LE),
 	.rates = (SNDRV_PCM_RATE_8000 | SNDRV_PCM_RATE_16000 |
 		  SNDRV_PCM_RATE_22050 | SNDRV_PCM_RATE_32000 |
@@ -174,7 +172,8 @@ inline void aic23_configure(void)
 	/* Initialize the AIC23 internal state */
 
 	/* Analog audio path control, DAC selected, delete INSEL_MIC for line in */
-	audio_aic23_write(ANALOG_AUDIO_CONTROL_ADDR, DEFAULT_ANALOG_AUDIO_CONTROL);
+	audio_aic23_write(ANALOG_AUDIO_CONTROL_ADDR,
+			  DEFAULT_ANALOG_AUDIO_CONTROL);
 
 	/* Digital audio path control, de-emphasis control 44.1kHz */
 	audio_aic23_write(DIGITAL_AUDIO_CONTROL_ADDR, DEEMP_44K);
@@ -193,10 +192,10 @@ inline void aic23_configure(void)
 
 /*
  *  Omap MCBSP clock configuration and Power Management
- *  
+ *
  *  Here we have some functions that allows clock to be enabled and
- *   disabled only when needed. Besides doing clock configuration 
- *   it allows turn on/turn off audio when necessary. 
+ *  disabled only when needed. Besides doing clock configuration
+ *  it allows turn on/turn off audio when necessary.
  */
 /*
  * Do clock framework mclk search
@@ -208,7 +207,7 @@ void aic23_clock_setup(void)
 
 /*
  * Do some sanity check, set clock rate, starts it and
- *  turn codec audio on 
+ * turn codec audio on
  */
 int aic23_clock_on(void)
 {
@@ -237,9 +236,9 @@ int aic23_clock_on(void)
 	       clk_get_usecount(aic23_mclk));
 
 	/* Now turn the audio on */
-	audio_aic23_write(POWER_DOWN_CONTROL_ADDR, 
+	audio_aic23_write(POWER_DOWN_CONTROL_ADDR,
 			  ~DEVICE_POWER_OFF & ~OUT_OFF & ~DAC_OFF &
-			  ~ADC_OFF & ~MIC_OFF & ~LINE_OFF);	
+			  ~ADC_OFF & ~MIC_OFF & ~LINE_OFF);
 	return 0;
 }
 
@@ -249,7 +248,7 @@ int aic23_clock_on(void)
  */
 int aic23_clock_off(void)
 {
-	if  (clk_get_usecount(aic23_mclk) > 0) { 
+	if  (clk_get_usecount(aic23_mclk) > 0) {
 		if (clk_get_rate(aic23_mclk) != CODEC_CLOCK) {
 			printk(KERN_WARNING
 			       "MCLK for audio should be %d Hz. But is %d Hz\n",
@@ -259,10 +258,10 @@ int aic23_clock_off(void)
 
 		clk_disable(aic23_mclk);
 	}
-	
+
 	audio_aic23_write(POWER_DOWN_CONTROL_ADDR,
 			  DEVICE_POWER_OFF | OUT_OFF | DAC_OFF |
-			  ADC_OFF | MIC_OFF | LINE_OFF);	
+			  ADC_OFF | MIC_OFF | LINE_OFF);
 	return 0;
 }
 
@@ -275,12 +274,12 @@ static int __devinit snd_omap_alsa_aic23
 {
 	int	ret;
 	struct	omap_alsa_codec_config *codec_cfg;
-	
+
 	codec_cfg = pdev->dev.platform_data;
 	if (codec_cfg != NULL) {
 		codec_cfg->hw_constraints_rates	= &aic23_hw_constraints_rates;
 		codec_cfg->snd_omap_alsa_playback  = &aic23_snd_omap_alsa_playback;
-		codec_cfg->snd_omap_alsa_capture  = &aic23_snd_omap_alsa_capture;		
+		codec_cfg->snd_omap_alsa_capture  = &aic23_snd_omap_alsa_capture;
 		codec_cfg->codec_configure_dev	= aic23_configure;
 		codec_cfg->codec_set_samplerate	= aic23_set_samplerate;
 		codec_cfg->codec_clock_setup	= aic23_clock_setup;
@@ -288,15 +287,16 @@ static int __devinit snd_omap_alsa_aic23
 		codec_cfg->codec_clock_off	= aic23_clock_off;
 		codec_cfg->get_default_samplerate = aic23_get_default_samplerate;
 		ret	= snd_omap_alsa_post_probe(pdev, codec_cfg);
-	}
-	else
+	} else {
 		ret = -ENODEV;
+	}
+
 	return ret;
 }
 
 static struct platform_driver omap_alsa_driver = {
 	.probe		= snd_omap_alsa_aic23_probe,
-	.remove 	= snd_omap_alsa_remove,
+	.remove		= snd_omap_alsa_remove,
 	.suspend	= snd_omap_alsa_suspend,
 	.resume		= snd_omap_alsa_resume,
 	.driver	= {
@@ -307,7 +307,7 @@ static struct platform_driver omap_alsa_
 static int __init omap_alsa_aic23_init(void)
 {
 	int err;
-	
+
 	ADEBUG();
 	err = platform_driver_register(&omap_alsa_driver);
 
@@ -317,7 +317,7 @@ static int __init omap_alsa_aic23_init(v
 static void __exit omap_alsa_aic23_exit(void)
 {
 	ADEBUG();
-	
+
 	platform_driver_unregister(&omap_alsa_driver);
 }
 
-- 
1.4.3.4.g82cc


[-- Attachment #3: Type: text/plain, Size: 0 bytes --]



^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] ARM: OMAP: omap-alsa-aic23.c cleanup. No code change
  2006-12-03 17:49 [PATCH] ARM: OMAP: omap-alsa-aic23.c cleanup. No code change Komal Shah
@ 2006-12-11 21:41 ` Tony Lindgren
  0 siblings, 0 replies; 2+ messages in thread
From: Tony Lindgren @ 2006-12-11 21:41 UTC (permalink / raw)
  To: Komal Shah; +Cc: linux-omap-open-source

* Komal Shah <komal.shah802003@gmail.com> [061203 09:50]:
> -- 
> ---Komal Shah
> http://komalshah.blogspot.com

> From e00b82a90c3086f596d5478e57249cf86e056b33 Mon Sep 17 00:00:00 2001
> From: Komal Shah <komal_shah802003@yahoo.com>
> Date: Sun, 3 Dec 2006 23:11:29 +0530
> Subject: [PATCH] ARM: OMAP: omap-alsa-aic23.c cleanup. No code change.
> 
> - whitespace removal.
> - Follow 80 line rule. Still few places left.

This one does not seem to apply, can you please refresh?

Regards,

Tony

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2006-12-11 21:41 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-12-03 17:49 [PATCH] ARM: OMAP: omap-alsa-aic23.c cleanup. No code change Komal Shah
2006-12-11 21:41 ` Tony Lindgren

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox