Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: g.liakhovetski@gmx.de (Guennadi Liakhovetski)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v4 2/3] at91: add parameters for at91_add_device_isi function
Date: Mon, 17 Oct 2011 16:22:39 +0200 (CEST)	[thread overview]
Message-ID: <Pine.LNX.4.64.1110171616150.18438@axis700.grange> (raw)
In-Reply-To: <1318331020-22031-3-git-send-email-josh.wu@atmel.com>

On Tue, 11 Oct 2011, Josh Wu wrote:

> This patch add parameters for at91_add_device_isi function
> 
> Signed-off-by: Josh Wu <josh.wu@atmel.com>
> ---
>  arch/arm/mach-at91/at91sam9263_devices.c |   13 ++++++++++---
>  arch/arm/mach-at91/include/mach/board.h  |    4 +++-
>  2 files changed, 13 insertions(+), 4 deletions(-)
> 
> diff --git a/arch/arm/mach-at91/at91sam9263_devices.c b/arch/arm/mach-at91/at91sam9263_devices.c
> index a050f41..7990e8e 100644
> --- a/arch/arm/mach-at91/at91sam9263_devices.c
> +++ b/arch/arm/mach-at91/at91sam9263_devices.c
> @@ -885,7 +885,8 @@ static struct platform_device at91sam9263_isi_device = {
>  	.num_resources	= ARRAY_SIZE(isi_resources),
>  };
>  
> -void __init at91_add_device_isi(void)
> +void __init at91_add_device_isi(struct isi_platform_data * data,

Not sure if anything in CodingStyle prohibits this, but the rest of this 
file uses

static type fn(struct s *p)

i.e., without an extra space after the '*'. Would be better to keep that 
style.

> +		bool use_pck_as_mck)
>  {
>  	at91_set_A_periph(AT91_PIN_PE0, 0);	/* ISI_D0 */
>  	at91_set_A_periph(AT91_PIN_PE1, 0);	/* ISI_D1 */
> @@ -898,14 +899,20 @@ void __init at91_add_device_isi(void)
>  	at91_set_A_periph(AT91_PIN_PE8, 0);	/* ISI_PCK */
>  	at91_set_A_periph(AT91_PIN_PE9, 0);	/* ISI_HSYNC */
>  	at91_set_A_periph(AT91_PIN_PE10, 0);	/* ISI_VSYNC */
> -	at91_set_B_periph(AT91_PIN_PE11, 0);	/* ISI_MCK (PCK3) */
>  	at91_set_B_periph(AT91_PIN_PE12, 0);	/* ISI_PD8 */
>  	at91_set_B_periph(AT91_PIN_PE13, 0);	/* ISI_PD9 */
>  	at91_set_B_periph(AT91_PIN_PE14, 0);	/* ISI_PD10 */
>  	at91_set_B_periph(AT91_PIN_PE15, 0);	/* ISI_PD11 */
> +
> +	if (use_pck_as_mck) {
> +		at91_set_B_periph(AT91_PIN_PE11, 0);	/* ISI_MCK (PCK3) */
> +
> +		/* TODO: register the PCK for ISI_MCK and set its parent */



> +	}
>  }
>  #else
> -void __init at91_add_device_isi(void) {}
> +void __init at91_add_device_isi(struct isi_platform_data * data,

same - no extra space.

> +		int use_pck_as_mck) {}
>  #endif
>  
>  
> diff --git a/arch/arm/mach-at91/include/mach/board.h b/arch/arm/mach-at91/include/mach/board.h
> index ed544a0..731c449 100644
> --- a/arch/arm/mach-at91/include/mach/board.h
> +++ b/arch/arm/mach-at91/include/mach/board.h
> @@ -183,7 +183,9 @@ extern void __init at91_add_device_lcdc(struct atmel_lcdfb_info *data);
>  extern void __init at91_add_device_ac97(struct ac97c_platform_data *data);
>  
>   /* ISI */
> -extern void __init at91_add_device_isi(void);
> +struct isi_platform_data;
> +extern void __init at91_add_device_isi(struct isi_platform_data *data,
> +		bool use_pck_as_mck);
>  
>   /* Touchscreen Controller */
>  struct at91_tsadcc_data {
> -- 
> 1.6.3.3

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/

  reply	other threads:[~2011-10-17 14:22 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-10-11 11:03 [PATCH v4 0/3] add Atmel ISI, ov2640 support for sam9m10/sam9g45 Josh Wu
2011-10-11 11:03 ` [PATCH v4 1/3] [media] at91: add code to enable/disable ISI_MCK clock Josh Wu
2011-10-17 15:04   ` Guennadi Liakhovetski
2011-10-22  6:41     ` Wu, Josh
2011-10-11 11:03 ` [PATCH v4 2/3] at91: add parameters for at91_add_device_isi function Josh Wu
2011-10-17 14:22   ` Guennadi Liakhovetski [this message]
2011-10-11 11:03 ` [PATCH v4 3/3] at91: add Atmel ISI and ov2640 support on sam9m10/sam9g45 board Josh Wu
2011-10-17 15:01   ` Guennadi Liakhovetski

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.LNX.4.64.1110171616150.18438@axis700.grange \
    --to=g.liakhovetski@gmx.de \
    --cc=linux-arm-kernel@lists.infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox