diff options
author | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-04-19 08:23:28 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2012-04-19 08:23:28 -0400 |
commit | d5aeee8cb28317ef608ecac421abc4d986d585d2 (patch) | |
tree | 70ec8ed8891f26e5c58152ffca9924ea1c58fe3a /include/linux/mtd/spear_smi.h | |
parent | 32898a145404acbebe3256709e012c2830a2043b (diff) | |
parent | e816b57a337ea3b755de72bec38c10c864f23015 (diff) |
Merge tag 'v3.4-rc3' into staging/for_v3.5
* tag 'v3.4-rc3': (3755 commits)
Linux 3.4-rc3
x86-32: fix up strncpy_from_user() sign error
ARM: 7386/1: jump_label: fixup for rename to static_key
ARM: 7384/1: ThumbEE: Disable userspace TEEHBR access for !CONFIG_ARM_THUMBEE
ARM: 7382/1: mm: truncate memory banks to fit in 4GB space for classic MMU
ARM: 7359/2: smp_twd: Only wait for reprogramming on active cpus
PCI: Fix regression in pci_restore_state(), v3
SCSI: Fix error handling when no ULD is attached
ARM: OMAP: clock: cleanup CPUfreq leftovers, fix build errors
ARM: dts: remove blank interrupt-parent properties
ARM: EXYNOS: Fix Kconfig dependencies for device tree enabled machine files
do not export kernel's NULL #define to userspace
ARM: EXYNOS: Remove broken config values for touchscren for NURI board
ARM: EXYNOS: set fix xusbxti clock for NURI and Universal210 boards
ARM: EXYNOS: fix regulator name for NURI board
ARM: SAMSUNG: make SAMSUNG_PM_DEBUG select DEBUG_LL
cpufreq: OMAP: fix build errors: depends on ARCH_OMAP2PLUS
sparc64: Eliminate obsolete __handle_softirq() function
sparc64: Fix bootup crash on sun4v.
ARM: msm: Fix section mismatches in proc_comm.c
...
Diffstat (limited to 'include/linux/mtd/spear_smi.h')
-rw-r--r-- | include/linux/mtd/spear_smi.h | 65 |
1 files changed, 65 insertions, 0 deletions
diff --git a/include/linux/mtd/spear_smi.h b/include/linux/mtd/spear_smi.h new file mode 100644 index 000000000000..8ae1726044c3 --- /dev/null +++ b/include/linux/mtd/spear_smi.h | |||
@@ -0,0 +1,65 @@ | |||
1 | /* | ||
2 | * Copyright © 2010 ST Microelectronics | ||
3 | * Shiraz Hashim <shiraz.hashim@st.com> | ||
4 | * | ||
5 | * This file is licensed under the terms of the GNU General Public | ||
6 | * License version 2. This program is licensed "as is" without any | ||
7 | * warranty of any kind, whether express or implied. | ||
8 | */ | ||
9 | |||
10 | #ifndef __MTD_SPEAR_SMI_H | ||
11 | #define __MTD_SPEAR_SMI_H | ||
12 | |||
13 | #include <linux/types.h> | ||
14 | #include <linux/mtd/mtd.h> | ||
15 | #include <linux/mtd/partitions.h> | ||
16 | #include <linux/platform_device.h> | ||
17 | #include <linux/of.h> | ||
18 | |||
19 | /* max possible slots for serial-nor flash chip in the SMI controller */ | ||
20 | #define MAX_NUM_FLASH_CHIP 4 | ||
21 | |||
22 | /* macro to define partitions for flash devices */ | ||
23 | #define DEFINE_PARTS(n, of, s) \ | ||
24 | { \ | ||
25 | .name = n, \ | ||
26 | .offset = of, \ | ||
27 | .size = s, \ | ||
28 | } | ||
29 | |||
30 | /** | ||
31 | * struct spear_smi_flash_info - platform structure for passing flash | ||
32 | * information | ||
33 | * | ||
34 | * name: name of the serial nor flash for identification | ||
35 | * mem_base: the memory base on which the flash is mapped | ||
36 | * size: size of the flash in bytes | ||
37 | * partitions: parition details | ||
38 | * nr_partitions: number of partitions | ||
39 | * fast_mode: whether flash supports fast mode | ||
40 | */ | ||
41 | |||
42 | struct spear_smi_flash_info { | ||
43 | char *name; | ||
44 | unsigned long mem_base; | ||
45 | unsigned long size; | ||
46 | struct mtd_partition *partitions; | ||
47 | int nr_partitions; | ||
48 | u8 fast_mode; | ||
49 | }; | ||
50 | |||
51 | /** | ||
52 | * struct spear_smi_plat_data - platform structure for configuring smi | ||
53 | * | ||
54 | * clk_rate: clk rate at which SMI must operate | ||
55 | * num_flashes: number of flashes present on board | ||
56 | * board_flash_info: specific details of each flash present on board | ||
57 | */ | ||
58 | struct spear_smi_plat_data { | ||
59 | unsigned long clk_rate; | ||
60 | int num_flashes; | ||
61 | struct spear_smi_flash_info *board_flash_info; | ||
62 | struct device_node *np[MAX_NUM_FLASH_CHIP]; | ||
63 | }; | ||
64 | |||
65 | #endif /* __MTD_SPEAR_SMI_H */ | ||