All of lore.kernel.org
 help / color / mirror / Atom feed
From: Sergei Shtylyov <sshtylyov@ru.mvista.com>
To: Stanislaw Gruszka <stf_xl@wp.pl>
Cc: linux-ide@vger.kernel.org, Andrew Victor <linux@maxim.org.za>,
	linux-arm-kernel@lists.arm.linux.org.uk
Subject: Re: [PATCH 3/3] AT91: initialize IDE driver on AT91SAM9263 cpu
Date: Wed, 04 Feb 2009 15:18:05 +0300	[thread overview]
Message-ID: <4989877D.6020401@ru.mvista.com> (raw)
In-Reply-To: <200902031147.41822.stf_xl@wp.pl>

Hello.

Stanislaw Gruszka wrote:
> Signed-off-by: Stanislaw Gruszka <stf_xl@wp.pl>
>   
[...]
> diff --git a/arch/arm/mach-at91/at91sam9263_devices.c b/arch/arm/mach-at91/at91sam9263_devices.c
> index b753cb8..503651a 100644
> --- a/arch/arm/mach-at91/at91sam9263_devices.c
> +++ b/arch/arm/mach-at91/at91sam9263_devices.c
> @@ -347,6 +347,103 @@ void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data)
>  void __init at91_add_device_mmc(short mmc_id, struct at91_mmc_data *data) {}
>  #endif
>  
> +/* --------------------------------------------------------------------
> + *  IDE
> + * -------------------------------------------------------------------- */
> +
> +#if defined(CONFIG_BLK_DEV_IDE_AT91) || defined(CONFIG_BLK_DEV_IDE_AT91_MODULE)
> +
> +/* Proper CS address space will be added */
> +#define AT91_IDE_TASK_FILE	0x00c00000
> +#define AT91_IDE_CTRL_REG	0x00e00000
>   

   Why are you assuming that these offsets are not board specifec I 
wonder? Theyu clearly depend on how the -CSx were wired on the board -- 
it's the same board specific data as your IRQ.

> +void __init at91_add_device_ide(struct at91_ide_data *data)
> +{
>   
[...]
> +	/* assign CS4/5 to SMC with Compact Flash logic support
> +	 * and fix resources addresses */
>   

   It again seems like board specific configuration...

> +	ebi0_csa = at91_sys_read(AT91_MATRIX_EBI0CSA);
> +	switch (chipselect) {
> +	case 4:
> +		at91_set_A_periph(AT91_PIN_PD6, 0);  /* EBI0_NCS4/CFCS0 */
> +		ebi0_csa |= AT91_MATRIX_EBI0_CS4A_SMC_CF1;
> +		addr_space = AT91_CHIPSELECT_4;
> +		break;
> +	case 5:
> +		at91_set_A_periph(AT91_PIN_PD7, 0);  /* EBI0_NCS5/CFCS1 */
> +		ebi0_csa |= AT91_MATRIX_EBI0_CS5A_SMC_CF2;
> +		addr_space = AT91_CHIPSELECT_5;
> +		break;
> +	default:
> +		printk(KERN_ERR "at91_ide: bad chip select %u\n", chipselect);
>   
> +		return;
>   

  Why do you consider it bad? Is there some SMC limitation or what?

MBR, Sergei



  parent reply	other threads:[~2009-02-04 12:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-02-03 10:47 [PATCH 3/3] AT91: initialize IDE driver on AT91SAM9263 cpu Stanislaw Gruszka
2009-02-03 20:27 ` Andrew Victor
2009-02-04  9:36   ` Stanislaw Gruszka
2009-02-05 12:03     ` Sergei Shtylyov
2009-02-05 19:43       ` Andrew Victor
2009-02-05 20:01         ` Sergei Shtylyov
2009-02-05 23:52           ` Sergei Shtylyov
2009-02-05 15:06   ` Stanislaw Gruszka
2009-02-04 12:18 ` Sergei Shtylyov [this message]
2009-02-04 14:15   ` Stanislaw Gruszka
2009-02-04 15:46     ` Sergei Shtylyov

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=4989877D.6020401@ru.mvista.com \
    --to=sshtylyov@ru.mvista.com \
    --cc=linux-arm-kernel@lists.arm.linux.org.uk \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux@maxim.org.za \
    --cc=stf_xl@wp.pl \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.