ppc4xx: AMCC Taihu board config file cleanup
[u-boot-openmoko.git] / include / onenand_uboot.h
blobbd1831ea6d651a3a2c58f9314b84fa1e44cddeec
1 /*
2 * Header file for OneNAND support for U-Boot
4 * Adaptation from kernel to U-Boot
6 * Copyright (C) 2005-2007 Samsung Electronics
7 * Kyungmin Park <kyungmin.park@samsung.com>
9 * This program is free software; you can redistribute it and/or modify
10 * it under the terms of the GNU General Public License version 2 as
11 * published by the Free Software Foundation.
14 #ifndef __UBOOT_ONENAND_H
15 #define __UBOOT_ONENAND_H
17 struct kvec {
18 void *iov_base;
19 size_t iov_len;
22 typedef int spinlock_t;
23 typedef int wait_queue_head_t;
25 /* Functions */
26 extern void onenand_init(void);
27 extern int onenand_read(struct mtd_info *mtd, loff_t from, size_t len,
28 size_t * retlen, u_char * buf);
29 extern int onenand_read_oob(struct mtd_info *mtd, loff_t from, size_t len,
30 size_t * retlen, u_char * buf);
31 extern int onenand_write(struct mtd_info *mtd, loff_t from, size_t len,
32 size_t * retlen, const u_char * buf);
33 extern int onenand_erase(struct mtd_info *mtd, struct erase_info *instr);
35 extern int onenand_unlock(struct mtd_info *mtd, loff_t ofs, size_t len);
37 extern void onenand_print_device_info(int device, int verbose);
39 #endif /* __UBOOT_ONENAND_H */