18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-only */
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci *  arch/arm/include/asm/mach/flash.h
48c2ecf20Sopenharmony_ci *
58c2ecf20Sopenharmony_ci *  Copyright (C) 2003 Russell King, All Rights Reserved.
68c2ecf20Sopenharmony_ci */
78c2ecf20Sopenharmony_ci#ifndef ASMARM_MACH_FLASH_H
88c2ecf20Sopenharmony_ci#define ASMARM_MACH_FLASH_H
98c2ecf20Sopenharmony_ci
108c2ecf20Sopenharmony_cistruct mtd_partition;
118c2ecf20Sopenharmony_cistruct mtd_info;
128c2ecf20Sopenharmony_ci
138c2ecf20Sopenharmony_ci/*
148c2ecf20Sopenharmony_ci * map_name:	the map probe function name
158c2ecf20Sopenharmony_ci * name:	flash device name (eg, as used with mtdparts=)
168c2ecf20Sopenharmony_ci * width:	width of mapped device
178c2ecf20Sopenharmony_ci * init:	method called at driver/device initialisation
188c2ecf20Sopenharmony_ci * exit:	method called at driver/device removal
198c2ecf20Sopenharmony_ci * set_vpp:	method called to enable or disable VPP
208c2ecf20Sopenharmony_ci * mmcontrol:	method called to enable or disable Sync. Burst Read in OneNAND
218c2ecf20Sopenharmony_ci * parts:	optional array of mtd_partitions for static partitioning
228c2ecf20Sopenharmony_ci * nr_parts:	number of mtd_partitions for static partitioning
238c2ecf20Sopenharmony_ci */
248c2ecf20Sopenharmony_cistruct flash_platform_data {
258c2ecf20Sopenharmony_ci	const char	*map_name;
268c2ecf20Sopenharmony_ci	const char	*name;
278c2ecf20Sopenharmony_ci	unsigned int	width;
288c2ecf20Sopenharmony_ci	int		(*init)(void);
298c2ecf20Sopenharmony_ci	void		(*exit)(void);
308c2ecf20Sopenharmony_ci	void		(*set_vpp)(int on);
318c2ecf20Sopenharmony_ci	void		(*mmcontrol)(struct mtd_info *mtd, int sync_read);
328c2ecf20Sopenharmony_ci	struct mtd_partition *parts;
338c2ecf20Sopenharmony_ci	unsigned int	nr_parts;
348c2ecf20Sopenharmony_ci};
358c2ecf20Sopenharmony_ci
368c2ecf20Sopenharmony_ci#endif
37