Skip to content

Commit

Permalink
[MTD NAND] Fix s3c2410 NAND driver so it at least _looks_ like it com…
Browse files Browse the repository at this point in the history
…piles

Fix the control bit handling so it even looks like it might work, too.
Bad tglx. No biscuit.

Signed-off-by: David Woodhouse <dwmw2@infradead.org>
  • Loading branch information
David Woodhouse committed Jun 9, 2006
1 parent f24ff6b commit f906887
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions drivers/mtd/nand/s3c2410.c
Original file line number Diff line number Diff line change
Expand Up @@ -256,32 +256,32 @@ static void s3c2410_nand_select_chip(struct mtd_info *mtd, int chip)
*/

static void s3c2410_nand_hwcontrol(struct mtd_info *mtd, int cmd,
unsigend int ctrl)
unsigned int ctrl)
{
struct s3c2410_nand_info *info = s3c2410_nand_mtd_toinfo(mtd);
struct nand_chip *chip = mtd->priv;

if (cmd == NAND_CMD_NONE)
return;

if (cmd & NAND_CLE)
if (ctrl & NAND_CLE)
writeb(cmd, info->regs + S3C2410_NFCMD);
else
writeb(cmd, info->regs + S3C2410_NFADDR);
}

/* command and control functions */

static void s3c2410_nand_hwcontrol(struct mtd_info *mtd, int cmd,
unsigend int ctrl)
static void s3c2440_nand_hwcontrol(struct mtd_info *mtd, int cmd,
unsigned int ctrl)
{
struct s3c2410_nand_info *info = s3c2410_nand_mtd_toinfo(mtd);
struct nand_chip *chip = mtd->priv;

if (cmd == NAND_CMD_NONE)
return;

if (cmd & NAND_CLE)
if (ctrl & NAND_CLE)
writeb(cmd, info->regs + S3C2440_NFCMD);
else
writeb(cmd, info->regs + S3C2440_NFADDR);
Expand Down

0 comments on commit f906887

Please sign in to comment.