Merge tag 'for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mst/vhost
[cris-mirror.git] / include / linux / spi / flash.h
blob2401a0887209bf15e0b8f5f5a88dab45823548cd
1 /* SPDX-License-Identifier: GPL-2.0 */
2 #ifndef LINUX_SPI_FLASH_H
3 #define LINUX_SPI_FLASH_H
5 struct mtd_partition;
7 /**
8 * struct flash_platform_data: board-specific flash data
9 * @name: optional flash device name (eg, as used with mtdparts=)
10 * @parts: optional array of mtd_partitions for static partitioning
11 * @nr_parts: number of mtd_partitions for static partitioning
12 * @type: optional flash device type (e.g. m25p80 vs m25p64), for use
13 * with chips that can't be queried for JEDEC or other IDs
15 * Board init code (in arch/.../mach-xxx/board-yyy.c files) can
16 * provide information about SPI flash parts (such as DataFlash) to
17 * help set up the device and its appropriate default partitioning.
19 * Note that for DataFlash, sizes for pages, blocks, and sectors are
20 * rarely powers of two; and partitions should be sector-aligned.
22 struct flash_platform_data {
23 char *name;
24 struct mtd_partition *parts;
25 unsigned int nr_parts;
27 char *type;
29 /* we'll likely add more ... use JEDEC IDs, etc */
32 #endif