2007-01-27 05:14:34 +08:00
|
|
|
/*
|
2008-08-05 23:14:15 +08:00
|
|
|
* arch/arm/plat-omap/include/mach/onenand.h
|
2007-01-27 05:14:34 +08:00
|
|
|
*
|
|
|
|
* Copyright (C) 2006 Nokia Corporation
|
|
|
|
* Author: Juha Yrjola
|
|
|
|
*
|
|
|
|
* This program is free software; you can redistribute it and/or modify
|
|
|
|
* it under the terms of the GNU General Public License version 2 as
|
|
|
|
* published by the Free Software Foundation.
|
|
|
|
*/
|
|
|
|
|
2009-05-29 04:23:52 +08:00
|
|
|
#include <linux/mtd/mtd.h>
|
2007-01-27 05:14:34 +08:00
|
|
|
#include <linux/mtd/partitions.h>
|
|
|
|
|
2009-05-29 04:23:52 +08:00
|
|
|
#define ONENAND_SYNC_READ (1 << 0)
|
|
|
|
#define ONENAND_SYNC_READWRITE (1 << 1)
|
2012-10-05 14:09:54 +08:00
|
|
|
#define ONENAND_IN_OMAP34XX (1 << 2)
|
2009-05-29 04:23:52 +08:00
|
|
|
|
2007-01-27 05:14:34 +08:00
|
|
|
struct omap_onenand_platform_data {
|
|
|
|
int cs;
|
|
|
|
int gpio_irq;
|
|
|
|
struct mtd_partition *parts;
|
|
|
|
int nr_parts;
|
2011-02-07 16:46:59 +08:00
|
|
|
int (*onenand_setup)(void __iomem *, int *freq_ptr);
|
2007-01-27 05:14:34 +08:00
|
|
|
int dma_channel;
|
2009-05-29 04:23:52 +08:00
|
|
|
u8 flags;
|
2010-02-19 22:39:53 +08:00
|
|
|
u8 regulator_can_sleep;
|
2011-02-17 19:44:42 +08:00
|
|
|
u8 skip_initial_unlocking;
|
2007-01-27 05:14:34 +08:00
|
|
|
};
|
2008-08-06 15:08:46 +08:00
|
|
|
|
|
|
|
#define ONENAND_MAX_PARTITIONS 8
|
2009-05-29 04:23:52 +08:00
|
|
|
|
|
|
|
#if defined(CONFIG_MTD_ONENAND_OMAP2) || \
|
|
|
|
defined(CONFIG_MTD_ONENAND_OMAP2_MODULE)
|
|
|
|
|
|
|
|
extern void gpmc_onenand_init(struct omap_onenand_platform_data *d);
|
|
|
|
|
|
|
|
#else
|
|
|
|
|
|
|
|
#define board_onenand_data NULL
|
|
|
|
|
|
|
|
static inline void gpmc_onenand_init(struct omap_onenand_platform_data *d)
|
|
|
|
{
|
|
|
|
}
|
|
|
|
|
|
|
|
#endif
|