linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: jgarzik@pobox.com (Jeff Garzik)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v2 1/5] libata: pata_samsung: Add Samsung PATA controller driver
Date: Wed, 09 Jun 2010 13:31:23 -0400	[thread overview]
Message-ID: <4C0FCFEB.6030603@pobox.com> (raw)
In-Reply-To: <1275988020-29000-2-git-send-email-kgene.kim@samsung.com>

On 06/08/2010 05:06 AM, Kukjin Kim wrote:
> From: Abhilash Kesavan<a.kesavan@samsung.com>
>
> Adds support for the Samsung PATA controller. This driver is based on the
> Libata subsystem and references the earlier patches sent for IDE subsystem.
>
> Signed-off-by: Abhilash Kesavan<a.kesavan@samsung.com>
> Signed-off-by: Kukjin Kim<kgene.kim@samsung.com>
> ---
>   drivers/ata/Kconfig           |    9 +
>   drivers/ata/Makefile          |    1 +
>   drivers/ata/pata_samsung_cf.c |  608 +++++++++++++++++++++++++++++++++++++++++
>   3 files changed, 618 insertions(+), 0 deletions(-)
>   create mode 100644 drivers/ata/pata_samsung_cf.c

Looks OK to me, minor nits only...



> +#define DRV_NAME "pata_samsung"

this should be "pata_samsung_cf"


> +static void pata_s3c_hwinit(struct s3c_ide_info *info,
> +				struct s3c_ide_platdata *pdata)
> +{
> +	switch (info->cpu_type) {
> +	case TYPE_S3C64XX:
> +		/* Configure as big endian */
> +		pata_s3c_cfg_mode(info->sfr_addr);
> +		pata_s3c_set_endian(info->ide_addr, 1);
> +		pata_s3c_enable(info->ide_addr, 1);
> +		mdelay(100);
> +
> +		/* Remove IRQ Status */
> +		writel(0x1f, info->ide_addr + S3C_ATA_IRQ);
> +		writel(0x1b, info->ide_addr + S3C_ATA_IRQ_MSK);
> +	break;
> +
> +	case TYPE_S5PC100:
> +		pata_s3c_cfg_mode(info->sfr_addr);
> +
> +	case TYPE_S5PV210:
> +		/* Configure as little endian */
> +		pata_s3c_set_endian(info->ide_addr, 0);
> +		pata_s3c_enable(info->ide_addr, 1);
> +		mdelay(100);
> +
> +		/* Remove IRQ Status */
> +		writel(0x3f, info->ide_addr + S3C_ATA_IRQ);
> +		writel(0x3f, info->ide_addr + S3C_ATA_IRQ_MSK);
> +	break;
> +
> +	default:
> +		BUG();

Use of msleep() is preferred, in cases where you can sleep (such as this)

  reply	other threads:[~2010-06-09 17:31 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-06-08  9:06 [PATCH v2 0/5] Add support for Samsung CF controller Kukjin Kim
2010-06-08  9:06 ` [PATCH v2 1/5] libata: pata_samsung: Add Samsung PATA controller driver Kukjin Kim
2010-06-09 17:31   ` Jeff Garzik [this message]
2010-06-08  9:06 ` [PATCH v2 2/5] ARM: SAMSUNG: Add Compact Flash device support for Samsung SoCs Kukjin Kim
2010-06-08  9:06 ` [PATCH v2 3/5] ARM: S3C64XX: Add support for Compact Flash driver on SMDK6410 Kukjin Kim
2010-06-08  9:06 ` [PATCH v2 4/5] ARM: S5PC100: Add support for Compact Flash driver on SMDKC100 Kukjin Kim
2010-06-08  9:07 ` [PATCH v2 5/5] ARM: S5PV210: Add support for Compact Flash driver on SMDKV210/C110 Kukjin Kim

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=4C0FCFEB.6030603@pobox.com \
    --to=jgarzik@pobox.com \
    --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;
as well as URLs for NNTP newsgroup(s).