]> git.ipfire.org Git - people/ms/u-boot.git/blame - include/onenand_uboot.h
Sync with 2.6.27
[people/ms/u-boot.git] / include / onenand_uboot.h
CommitLineData
d7e8ce10
KP
1/*
2 * Header file for OneNAND support for U-Boot
3 *
4 * Adaptation from kernel to U-Boot
5 *
6 * Copyright (C) 2005-2007 Samsung Electronics
7 * Kyungmin Park <kyungmin.park@samsung.com>
8 *
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.
12 */
13
14#ifndef __UBOOT_ONENAND_H
15#define __UBOOT_ONENAND_H
16
229c56f0
SW
17#include <linux/types.h>
18
229c56f0
SW
19struct mtd_info;
20struct erase_info;
ef0921d6 21struct onenand_chip;
229c56f0 22
bfd7f386
KP
23extern struct mtd_info onenand_mtd;
24
ef0921d6
KP
25/* board */
26extern void onenand_board_init(struct mtd_info *);
27
d7e8ce10
KP
28/* Functions */
29extern void onenand_init(void);
30extern int onenand_read(struct mtd_info *mtd, loff_t from, size_t len,
31 size_t * retlen, u_char * buf);
ef0921d6 32extern int onenand_read_oob(struct mtd_info *mtd, loff_t from, struct mtd_oob_ops *ops);
d7e8ce10
KP
33extern int onenand_write(struct mtd_info *mtd, loff_t from, size_t len,
34 size_t * retlen, const u_char * buf);
35extern int onenand_erase(struct mtd_info *mtd, struct erase_info *instr);
36
ef0921d6 37extern char *onenand_print_device_info(int device, int version);
d7e8ce10 38
ef0921d6
KP
39/* S3C64xx */
40extern void s3c64xx_onenand_init(struct mtd_info *);
41extern void s3c64xx_set_width_regs(struct onenand_chip *);
d7e8ce10
KP
42
43#endif /* __UBOOT_ONENAND_H */