diff options
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/i2c/twl.h | 3 | ||||
| -rw-r--r-- | include/linux/mfd/twl6040.h | 1 | ||||
| -rw-r--r-- | include/linux/omapfb.h | 7 | ||||
| -rw-r--r-- | include/linux/platform_data/asoc-ti-mcbsp.h | 62 | ||||
| -rw-r--r-- | include/linux/platform_data/dsp-omap.h | 34 | ||||
| -rw-r--r-- | include/linux/platform_data/gpio-omap.h | 217 | ||||
| -rw-r--r-- | include/linux/platform_data/keypad-omap.h | 52 | ||||
| -rw-r--r-- | include/linux/platform_data/lcd-mipid.h | 29 | ||||
| -rw-r--r-- | include/linux/platform_data/mtd-nand-omap2.h | 43 | ||||
| -rw-r--r-- | include/linux/platform_data/mtd-onenand-omap2.h | 53 | ||||
| -rw-r--r-- | include/linux/platform_data/omap1_bl.h | 11 | ||||
| -rw-r--r-- | include/linux/platform_data/pinctrl-coh901.h | 26 | ||||
| -rw-r--r-- | include/linux/platform_data/remoteproc-omap.h | 57 | ||||
| -rw-r--r-- | include/linux/platform_data/spi-omap2-mcspi.h | 23 | ||||
| -rw-r--r-- | include/linux/platform_data/voltage-omap.h | 39 | ||||
| -rw-r--r-- | include/linux/power/smartreflex.h | 2 |
16 files changed, 653 insertions, 6 deletions
diff --git a/include/linux/i2c/twl.h b/include/linux/i2c/twl.h index 7ea898c55a60..a12a38107c1a 100644 --- a/include/linux/i2c/twl.h +++ b/include/linux/i2c/twl.h | |||
| @@ -561,9 +561,6 @@ struct twl4030_bci_platform_data { | |||
| 561 | 561 | ||
| 562 | /* TWL4030_GPIO_MAX (18) GPIOs, with interrupts */ | 562 | /* TWL4030_GPIO_MAX (18) GPIOs, with interrupts */ |
| 563 | struct twl4030_gpio_platform_data { | 563 | struct twl4030_gpio_platform_data { |
| 564 | int gpio_base; | ||
| 565 | unsigned irq_base, irq_end; | ||
| 566 | |||
| 567 | /* package the two LED signals as output-only GPIOs? */ | 564 | /* package the two LED signals as output-only GPIOs? */ |
| 568 | bool use_leds; | 565 | bool use_leds; |
| 569 | 566 | ||
diff --git a/include/linux/mfd/twl6040.h b/include/linux/mfd/twl6040.h index eaad49f7c130..ba43d4806b83 100644 --- a/include/linux/mfd/twl6040.h +++ b/include/linux/mfd/twl6040.h | |||
| @@ -194,7 +194,6 @@ struct twl6040_vibra_data { | |||
| 194 | 194 | ||
| 195 | struct twl6040_platform_data { | 195 | struct twl6040_platform_data { |
| 196 | int audpwron_gpio; /* audio power-on gpio */ | 196 | int audpwron_gpio; /* audio power-on gpio */ |
| 197 | unsigned int irq_base; | ||
| 198 | 197 | ||
| 199 | struct twl6040_codec_data *codec; | 198 | struct twl6040_codec_data *codec; |
| 200 | struct twl6040_vibra_data *vibra; | 199 | struct twl6040_vibra_data *vibra; |
diff --git a/include/linux/omapfb.h b/include/linux/omapfb.h index 4ff57e81051d..85af8184691a 100644 --- a/include/linux/omapfb.h +++ b/include/linux/omapfb.h | |||
| @@ -220,7 +220,12 @@ struct omapfb_display_info { | |||
| 220 | 220 | ||
| 221 | #ifdef __KERNEL__ | 221 | #ifdef __KERNEL__ |
| 222 | 222 | ||
| 223 | #include <plat/board.h> | 223 | struct omap_lcd_config { |
| 224 | char panel_name[16]; | ||
| 225 | char ctrl_name[16]; | ||
| 226 | s16 nreset_gpio; | ||
| 227 | u8 data_lines; | ||
| 228 | }; | ||
| 224 | 229 | ||
| 225 | struct omapfb_platform_data { | 230 | struct omapfb_platform_data { |
| 226 | struct omap_lcd_config lcd; | 231 | struct omap_lcd_config lcd; |
diff --git a/include/linux/platform_data/asoc-ti-mcbsp.h b/include/linux/platform_data/asoc-ti-mcbsp.h new file mode 100644 index 000000000000..18814127809a --- /dev/null +++ b/include/linux/platform_data/asoc-ti-mcbsp.h | |||
| @@ -0,0 +1,62 @@ | |||
| 1 | /* | ||
| 2 | * arch/arm/plat-omap/include/mach/mcbsp.h | ||
| 3 | * | ||
| 4 | * Defines for Multi-Channel Buffered Serial Port | ||
| 5 | * | ||
| 6 | * Copyright (C) 2002 RidgeRun, Inc. | ||
| 7 | * Author: Steve Johnson | ||
| 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 as published by | ||
| 11 | * the Free Software Foundation; either version 2 of the License, or | ||
| 12 | * (at your option) any later version. | ||
| 13 | * | ||
| 14 | * This program is distributed in the hope that it will be useful, | ||
| 15 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 16 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 17 | * GNU General Public License for more details. | ||
| 18 | * | ||
| 19 | * You should have received a copy of the GNU General Public License | ||
| 20 | * along with this program; if not, write to the Free Software | ||
| 21 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
| 22 | * | ||
| 23 | */ | ||
| 24 | #ifndef __ASM_ARCH_OMAP_MCBSP_H | ||
| 25 | #define __ASM_ARCH_OMAP_MCBSP_H | ||
| 26 | |||
| 27 | #include <linux/spinlock.h> | ||
| 28 | #include <linux/clk.h> | ||
| 29 | |||
| 30 | #define MCBSP_CONFIG_TYPE2 0x2 | ||
| 31 | #define MCBSP_CONFIG_TYPE3 0x3 | ||
| 32 | #define MCBSP_CONFIG_TYPE4 0x4 | ||
| 33 | |||
| 34 | /* Platform specific configuration */ | ||
| 35 | struct omap_mcbsp_ops { | ||
| 36 | void (*request)(unsigned int); | ||
| 37 | void (*free)(unsigned int); | ||
| 38 | }; | ||
| 39 | |||
| 40 | struct omap_mcbsp_platform_data { | ||
| 41 | struct omap_mcbsp_ops *ops; | ||
| 42 | u16 buffer_size; | ||
| 43 | u8 reg_size; | ||
| 44 | u8 reg_step; | ||
| 45 | |||
| 46 | /* McBSP platform and instance specific features */ | ||
| 47 | bool has_wakeup; /* Wakeup capability */ | ||
| 48 | bool has_ccr; /* Transceiver has configuration control registers */ | ||
| 49 | int (*enable_st_clock)(unsigned int, bool); | ||
| 50 | int (*set_clk_src)(struct device *dev, struct clk *clk, const char *src); | ||
| 51 | int (*mux_signal)(struct device *dev, const char *signal, const char *src); | ||
| 52 | }; | ||
| 53 | |||
| 54 | /** | ||
| 55 | * omap_mcbsp_dev_attr - OMAP McBSP device attributes for omap_hwmod | ||
| 56 | * @sidetone: name of the sidetone device | ||
| 57 | */ | ||
| 58 | struct omap_mcbsp_dev_attr { | ||
| 59 | const char *sidetone; | ||
| 60 | }; | ||
| 61 | |||
| 62 | #endif | ||
diff --git a/include/linux/platform_data/dsp-omap.h b/include/linux/platform_data/dsp-omap.h new file mode 100644 index 000000000000..5927709b1908 --- /dev/null +++ b/include/linux/platform_data/dsp-omap.h | |||
| @@ -0,0 +1,34 @@ | |||
| 1 | #ifndef __OMAP_DSP_H__ | ||
| 2 | #define __OMAP_DSP_H__ | ||
| 3 | |||
| 4 | #include <linux/types.h> | ||
| 5 | |||
| 6 | struct omap_dsp_platform_data { | ||
| 7 | void (*dsp_set_min_opp) (u8 opp_id); | ||
| 8 | u8 (*dsp_get_opp) (void); | ||
| 9 | void (*cpu_set_freq) (unsigned long f); | ||
| 10 | unsigned long (*cpu_get_freq) (void); | ||
| 11 | unsigned long mpu_speed[6]; | ||
| 12 | |||
| 13 | /* functions to write and read PRCM registers */ | ||
| 14 | void (*dsp_prm_write)(u32, s16 , u16); | ||
| 15 | u32 (*dsp_prm_read)(s16 , u16); | ||
| 16 | u32 (*dsp_prm_rmw_bits)(u32, u32, s16, s16); | ||
| 17 | void (*dsp_cm_write)(u32, s16 , u16); | ||
| 18 | u32 (*dsp_cm_read)(s16 , u16); | ||
| 19 | u32 (*dsp_cm_rmw_bits)(u32, u32, s16, s16); | ||
| 20 | |||
| 21 | void (*set_bootaddr)(u32); | ||
| 22 | void (*set_bootmode)(u8); | ||
| 23 | |||
| 24 | phys_addr_t phys_mempool_base; | ||
| 25 | phys_addr_t phys_mempool_size; | ||
| 26 | }; | ||
| 27 | |||
| 28 | #if defined(CONFIG_TIDSPBRIDGE) || defined(CONFIG_TIDSPBRIDGE_MODULE) | ||
| 29 | extern void omap_dsp_reserve_sdram_memblock(void); | ||
| 30 | #else | ||
| 31 | static inline void omap_dsp_reserve_sdram_memblock(void) { } | ||
| 32 | #endif | ||
| 33 | |||
| 34 | #endif | ||
diff --git a/include/linux/platform_data/gpio-omap.h b/include/linux/platform_data/gpio-omap.h new file mode 100644 index 000000000000..e8741c2678d5 --- /dev/null +++ b/include/linux/platform_data/gpio-omap.h | |||
| @@ -0,0 +1,217 @@ | |||
| 1 | /* | ||
| 2 | * OMAP GPIO handling defines and functions | ||
| 3 | * | ||
| 4 | * Copyright (C) 2003-2005 Nokia Corporation | ||
| 5 | * | ||
| 6 | * Written by Juha Yrjölä <juha.yrjola@nokia.com> | ||
| 7 | * | ||
| 8 | * This program is free software; you can redistribute it and/or modify | ||
| 9 | * it under the terms of the GNU General Public License as published by | ||
| 10 | * the Free Software Foundation; either version 2 of the License, or | ||
| 11 | * (at your option) any later version. | ||
| 12 | * | ||
| 13 | * This program is distributed in the hope that it will be useful, | ||
| 14 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 15 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 16 | * GNU General Public License for more details. | ||
| 17 | * | ||
| 18 | * You should have received a copy of the GNU General Public License | ||
| 19 | * along with this program; if not, write to the Free Software | ||
| 20 | * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA | ||
| 21 | * | ||
| 22 | */ | ||
| 23 | |||
| 24 | #ifndef __ASM_ARCH_OMAP_GPIO_H | ||
| 25 | #define __ASM_ARCH_OMAP_GPIO_H | ||
| 26 | |||
| 27 | #include <linux/io.h> | ||
| 28 | #include <linux/platform_device.h> | ||
| 29 | #include <mach/irqs.h> | ||
| 30 | |||
| 31 | #define OMAP1_MPUIO_BASE 0xfffb5000 | ||
| 32 | |||
| 33 | /* | ||
| 34 | * These are the omap15xx/16xx offsets. The omap7xx offset are | ||
| 35 | * OMAP_MPUIO_ / 2 offsets below. | ||
| 36 | */ | ||
| 37 | #define OMAP_MPUIO_INPUT_LATCH 0x00 | ||
| 38 | #define OMAP_MPUIO_OUTPUT 0x04 | ||
| 39 | #define OMAP_MPUIO_IO_CNTL 0x08 | ||
| 40 | #define OMAP_MPUIO_KBR_LATCH 0x10 | ||
| 41 | #define OMAP_MPUIO_KBC 0x14 | ||
| 42 | #define OMAP_MPUIO_GPIO_EVENT_MODE 0x18 | ||
| 43 | #define OMAP_MPUIO_GPIO_INT_EDGE 0x1c | ||
| 44 | #define OMAP_MPUIO_KBD_INT 0x20 | ||
| 45 | #define OMAP_MPUIO_GPIO_INT 0x24 | ||
| 46 | #define OMAP_MPUIO_KBD_MASKIT 0x28 | ||
| 47 | #define OMAP_MPUIO_GPIO_MASKIT 0x2c | ||
| 48 | #define OMAP_MPUIO_GPIO_DEBOUNCING 0x30 | ||
| 49 | #define OMAP_MPUIO_LATCH 0x34 | ||
| 50 | |||
| 51 | #define OMAP34XX_NR_GPIOS 6 | ||
| 52 | |||
| 53 | /* | ||
| 54 | * OMAP1510 GPIO registers | ||
| 55 | */ | ||
| 56 | #define OMAP1510_GPIO_DATA_INPUT 0x00 | ||
| 57 | #define OMAP1510_GPIO_DATA_OUTPUT 0x04 | ||
| 58 | #define OMAP1510_GPIO_DIR_CONTROL 0x08 | ||
| 59 | #define OMAP1510_GPIO_INT_CONTROL 0x0c | ||
| 60 | #define OMAP1510_GPIO_INT_MASK 0x10 | ||
| 61 | #define OMAP1510_GPIO_INT_STATUS 0x14 | ||
| 62 | #define OMAP1510_GPIO_PIN_CONTROL 0x18 | ||
| 63 | |||
| 64 | #define OMAP1510_IH_GPIO_BASE 64 | ||
| 65 | |||
| 66 | /* | ||
| 67 | * OMAP1610 specific GPIO registers | ||
| 68 | */ | ||
| 69 | #define OMAP1610_GPIO_REVISION 0x0000 | ||
| 70 | #define OMAP1610_GPIO_SYSCONFIG 0x0010 | ||
| 71 | #define OMAP1610_GPIO_SYSSTATUS 0x0014 | ||
| 72 | #define OMAP1610_GPIO_IRQSTATUS1 0x0018 | ||
| 73 | #define OMAP1610_GPIO_IRQENABLE1 0x001c | ||
| 74 | #define OMAP1610_GPIO_WAKEUPENABLE 0x0028 | ||
| 75 | #define OMAP1610_GPIO_DATAIN 0x002c | ||
| 76 | #define OMAP1610_GPIO_DATAOUT 0x0030 | ||
| 77 | #define OMAP1610_GPIO_DIRECTION 0x0034 | ||
| 78 | #define OMAP1610_GPIO_EDGE_CTRL1 0x0038 | ||
| 79 | #define OMAP1610_GPIO_EDGE_CTRL2 0x003c | ||
| 80 | #define OMAP1610_GPIO_CLEAR_IRQENABLE1 0x009c | ||
| 81 | #define OMAP1610_GPIO_CLEAR_WAKEUPENA 0x00a8 | ||
| 82 | #define OMAP1610_GPIO_CLEAR_DATAOUT 0x00b0 | ||
| 83 | #define OMAP1610_GPIO_SET_IRQENABLE1 0x00dc | ||
| 84 | #define OMAP1610_GPIO_SET_WAKEUPENA 0x00e8 | ||
| 85 | #define OMAP1610_GPIO_SET_DATAOUT 0x00f0 | ||
| 86 | |||
| 87 | /* | ||
| 88 | * OMAP7XX specific GPIO registers | ||
| 89 | */ | ||
| 90 | #define OMAP7XX_GPIO_DATA_INPUT 0x00 | ||
| 91 | #define OMAP7XX_GPIO_DATA_OUTPUT 0x04 | ||
| 92 | #define OMAP7XX_GPIO_DIR_CONTROL 0x08 | ||
| 93 | #define OMAP7XX_GPIO_INT_CONTROL 0x0c | ||
| 94 | #define OMAP7XX_GPIO_INT_MASK 0x10 | ||
| 95 | #define OMAP7XX_GPIO_INT_STATUS 0x14 | ||
| 96 | |||
| 97 | /* | ||
| 98 | * omap2+ specific GPIO registers | ||
| 99 | */ | ||
| 100 | #define OMAP24XX_GPIO_REVISION 0x0000 | ||
| 101 | #define OMAP24XX_GPIO_IRQSTATUS1 0x0018 | ||
| 102 | #define OMAP24XX_GPIO_IRQSTATUS2 0x0028 | ||
| 103 | #define OMAP24XX_GPIO_IRQENABLE2 0x002c | ||
| 104 | #define OMAP24XX_GPIO_IRQENABLE1 0x001c | ||
| 105 | #define OMAP24XX_GPIO_WAKE_EN 0x0020 | ||
| 106 | #define OMAP24XX_GPIO_CTRL 0x0030 | ||
| 107 | #define OMAP24XX_GPIO_OE 0x0034 | ||
| 108 | #define OMAP24XX_GPIO_DATAIN 0x0038 | ||
| 109 | #define OMAP24XX_GPIO_DATAOUT 0x003c | ||
| 110 | #define OMAP24XX_GPIO_LEVELDETECT0 0x0040 | ||
| 111 | #define OMAP24XX_GPIO_LEVELDETECT1 0x0044 | ||
| 112 | #define OMAP24XX_GPIO_RISINGDETECT 0x0048 | ||
| 113 | #define OMAP24XX_GPIO_FALLINGDETECT 0x004c | ||
| 114 | #define OMAP24XX_GPIO_DEBOUNCE_EN 0x0050 | ||
| 115 | #define OMAP24XX_GPIO_DEBOUNCE_VAL 0x0054 | ||
| 116 | #define OMAP24XX_GPIO_CLEARIRQENABLE1 0x0060 | ||
| 117 | #define OMAP24XX_GPIO_SETIRQENABLE1 0x0064 | ||
| 118 | #define OMAP24XX_GPIO_CLEARWKUENA 0x0080 | ||
| 119 | #define OMAP24XX_GPIO_SETWKUENA 0x0084 | ||
| 120 | #define OMAP24XX_GPIO_CLEARDATAOUT 0x0090 | ||
| 121 | #define OMAP24XX_GPIO_SETDATAOUT 0x0094 | ||
| 122 | |||
| 123 | #define OMAP4_GPIO_REVISION 0x0000 | ||
| 124 | #define OMAP4_GPIO_EOI 0x0020 | ||
| 125 | #define OMAP4_GPIO_IRQSTATUSRAW0 0x0024 | ||
| 126 | #define OMAP4_GPIO_IRQSTATUSRAW1 0x0028 | ||
| 127 | #define OMAP4_GPIO_IRQSTATUS0 0x002c | ||
| 128 | #define OMAP4_GPIO_IRQSTATUS1 0x0030 | ||
| 129 | #define OMAP4_GPIO_IRQSTATUSSET0 0x0034 | ||
| 130 | #define OMAP4_GPIO_IRQSTATUSSET1 0x0038 | ||
| 131 | #define OMAP4_GPIO_IRQSTATUSCLR0 0x003c | ||
| 132 | #define OMAP4_GPIO_IRQSTATUSCLR1 0x0040 | ||
| 133 | #define OMAP4_GPIO_IRQWAKEN0 0x0044 | ||
| 134 | #define OMAP4_GPIO_IRQWAKEN1 0x0048 | ||
| 135 | #define OMAP4_GPIO_IRQENABLE1 0x011c | ||
| 136 | #define OMAP4_GPIO_WAKE_EN 0x0120 | ||
| 137 | #define OMAP4_GPIO_IRQSTATUS2 0x0128 | ||
| 138 | #define OMAP4_GPIO_IRQENABLE2 0x012c | ||
| 139 | #define OMAP4_GPIO_CTRL 0x0130 | ||
| 140 | #define OMAP4_GPIO_OE 0x0134 | ||
| 141 | #define OMAP4_GPIO_DATAIN 0x0138 | ||
| 142 | #define OMAP4_GPIO_DATAOUT 0x013c | ||
| 143 | #define OMAP4_GPIO_LEVELDETECT0 0x0140 | ||
| 144 | #define OMAP4_GPIO_LEVELDETECT1 0x0144 | ||
| 145 | #define OMAP4_GPIO_RISINGDETECT 0x0148 | ||
| 146 | #define OMAP4_GPIO_FALLINGDETECT 0x014c | ||
| 147 | #define OMAP4_GPIO_DEBOUNCENABLE 0x0150 | ||
| 148 | #define OMAP4_GPIO_DEBOUNCINGTIME 0x0154 | ||
| 149 | #define OMAP4_GPIO_CLEARIRQENABLE1 0x0160 | ||
| 150 | #define OMAP4_GPIO_SETIRQENABLE1 0x0164 | ||
| 151 | #define OMAP4_GPIO_CLEARWKUENA 0x0180 | ||
| 152 | #define OMAP4_GPIO_SETWKUENA 0x0184 | ||
| 153 | #define OMAP4_GPIO_CLEARDATAOUT 0x0190 | ||
| 154 | #define OMAP4_GPIO_SETDATAOUT 0x0194 | ||
| 155 | |||
| 156 | #define OMAP_MAX_GPIO_LINES 192 | ||
| 157 | |||
| 158 | #define OMAP_MPUIO(nr) (OMAP_MAX_GPIO_LINES + (nr)) | ||
| 159 | #define OMAP_GPIO_IS_MPUIO(nr) ((nr) >= OMAP_MAX_GPIO_LINES) | ||
| 160 | |||
| 161 | struct omap_gpio_dev_attr { | ||
| 162 | int bank_width; /* GPIO bank width */ | ||
| 163 | bool dbck_flag; /* dbck required or not - True for OMAP3&4 */ | ||
| 164 | }; | ||
| 165 | |||
| 166 | struct omap_gpio_reg_offs { | ||
| 167 | u16 revision; | ||
| 168 | u16 direction; | ||
| 169 | u16 datain; | ||
| 170 | u16 dataout; | ||
| 171 | u16 set_dataout; | ||
| 172 | u16 clr_dataout; | ||
| 173 | u16 irqstatus; | ||
| 174 | u16 irqstatus2; | ||
| 175 | u16 irqstatus_raw0; | ||
| 176 | u16 irqstatus_raw1; | ||
| 177 | u16 irqenable; | ||
| 178 | u16 irqenable2; | ||
| 179 | u16 set_irqenable; | ||
| 180 | u16 clr_irqenable; | ||
| 181 | u16 debounce; | ||
| 182 | u16 debounce_en; | ||
| 183 | u16 ctrl; | ||
| 184 | u16 wkup_en; | ||
| 185 | u16 leveldetect0; | ||
| 186 | u16 leveldetect1; | ||
| 187 | u16 risingdetect; | ||
| 188 | u16 fallingdetect; | ||
| 189 | u16 irqctrl; | ||
| 190 | u16 edgectrl1; | ||
| 191 | u16 edgectrl2; | ||
| 192 | u16 pinctrl; | ||
| 193 | |||
| 194 | bool irqenable_inv; | ||
| 195 | }; | ||
| 196 | |||
| 197 | struct omap_gpio_platform_data { | ||
| 198 | int bank_type; | ||
| 199 | int bank_width; /* GPIO bank width */ | ||
| 200 | int bank_stride; /* Only needed for omap1 MPUIO */ | ||
| 201 | bool dbck_flag; /* dbck required or not - True for OMAP3&4 */ | ||
| 202 | bool loses_context; /* whether the bank would ever lose context */ | ||
| 203 | bool is_mpuio; /* whether the bank is of type MPUIO */ | ||
| 204 | u32 non_wakeup_gpios; | ||
| 205 | |||
| 206 | struct omap_gpio_reg_offs *regs; | ||
| 207 | |||
| 208 | /* Return context loss count due to PM states changing */ | ||
| 209 | int (*get_context_loss_count)(struct device *dev); | ||
| 210 | }; | ||
| 211 | |||
| 212 | extern void omap2_gpio_prepare_for_idle(int off_mode); | ||
| 213 | extern void omap2_gpio_resume_after_idle(void); | ||
| 214 | extern void omap_set_gpio_debounce(int gpio, int enable); | ||
| 215 | extern void omap_set_gpio_debounce_time(int gpio, int enable); | ||
| 216 | |||
| 217 | #endif | ||
diff --git a/include/linux/platform_data/keypad-omap.h b/include/linux/platform_data/keypad-omap.h new file mode 100644 index 000000000000..a6b21eddb212 --- /dev/null +++ b/include/linux/platform_data/keypad-omap.h | |||
| @@ -0,0 +1,52 @@ | |||
| 1 | /* | ||
| 2 | * arch/arm/plat-omap/include/mach/keypad.h | ||
| 3 | * | ||
| 4 | * Copyright (C) 2006 Komal Shah <komal_shah802003@yahoo.com> | ||
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License version 2 as | ||
| 8 | * published by the Free Software Foundation. | ||
| 9 | */ | ||
| 10 | #ifndef ASMARM_ARCH_KEYPAD_H | ||
| 11 | #define ASMARM_ARCH_KEYPAD_H | ||
| 12 | |||
| 13 | #ifndef CONFIG_ARCH_OMAP1 | ||
| 14 | #warning Please update the board to use matrix-keypad driver | ||
| 15 | #define omap_readw(reg) 0 | ||
| 16 | #define omap_writew(val, reg) do {} while (0) | ||
| 17 | #endif | ||
| 18 | #include <linux/input/matrix_keypad.h> | ||
| 19 | |||
| 20 | struct omap_kp_platform_data { | ||
| 21 | int rows; | ||
| 22 | int cols; | ||
| 23 | const struct matrix_keymap_data *keymap_data; | ||
| 24 | bool rep; | ||
| 25 | unsigned long delay; | ||
| 26 | bool dbounce; | ||
| 27 | /* specific to OMAP242x*/ | ||
| 28 | unsigned int *row_gpios; | ||
| 29 | unsigned int *col_gpios; | ||
| 30 | }; | ||
| 31 | |||
| 32 | /* Group (0..3) -- when multiple keys are pressed, only the | ||
| 33 | * keys pressed in the same group are considered as pressed. This is | ||
| 34 | * in order to workaround certain crappy HW designs that produce ghost | ||
| 35 | * keypresses. Two free bits, not used by neither row/col nor keynum, | ||
| 36 | * must be available for use as group bits. The below GROUP_SHIFT | ||
| 37 | * macro definition is based on some prior knowledge of the | ||
| 38 | * matrix_keypad defined KEY() macro internals. | ||
| 39 | */ | ||
| 40 | #define GROUP_SHIFT 14 | ||
| 41 | #define GROUP_0 (0 << GROUP_SHIFT) | ||
| 42 | #define GROUP_1 (1 << GROUP_SHIFT) | ||
| 43 | #define GROUP_2 (2 << GROUP_SHIFT) | ||
| 44 | #define GROUP_3 (3 << GROUP_SHIFT) | ||
| 45 | #define GROUP_MASK GROUP_3 | ||
| 46 | #if KEY_MAX & GROUP_MASK | ||
| 47 | #error Group bits in conflict with keynum bits | ||
| 48 | #endif | ||
| 49 | |||
| 50 | |||
| 51 | #endif | ||
| 52 | |||
diff --git a/include/linux/platform_data/lcd-mipid.h b/include/linux/platform_data/lcd-mipid.h new file mode 100644 index 000000000000..8e52c6572281 --- /dev/null +++ b/include/linux/platform_data/lcd-mipid.h | |||
| @@ -0,0 +1,29 @@ | |||
| 1 | #ifndef __LCD_MIPID_H | ||
| 2 | #define __LCD_MIPID_H | ||
| 3 | |||
| 4 | enum mipid_test_num { | ||
| 5 | MIPID_TEST_RGB_LINES, | ||
| 6 | }; | ||
| 7 | |||
| 8 | enum mipid_test_result { | ||
| 9 | MIPID_TEST_SUCCESS, | ||
| 10 | MIPID_TEST_INVALID, | ||
| 11 | MIPID_TEST_FAILED, | ||
| 12 | }; | ||
| 13 | |||
| 14 | #ifdef __KERNEL__ | ||
| 15 | |||
| 16 | struct mipid_platform_data { | ||
| 17 | int nreset_gpio; | ||
| 18 | int data_lines; | ||
| 19 | |||
| 20 | void (*shutdown)(struct mipid_platform_data *pdata); | ||
| 21 | void (*set_bklight_level)(struct mipid_platform_data *pdata, | ||
| 22 | int level); | ||
| 23 | int (*get_bklight_level)(struct mipid_platform_data *pdata); | ||
| 24 | int (*get_bklight_max)(struct mipid_platform_data *pdata); | ||
| 25 | }; | ||
| 26 | |||
| 27 | #endif | ||
| 28 | |||
| 29 | #endif | ||
diff --git a/include/linux/platform_data/mtd-nand-omap2.h b/include/linux/platform_data/mtd-nand-omap2.h new file mode 100644 index 000000000000..1a68c1e5fe53 --- /dev/null +++ b/include/linux/platform_data/mtd-nand-omap2.h | |||
| @@ -0,0 +1,43 @@ | |||
| 1 | /* | ||
| 2 | * arch/arm/plat-omap/include/mach/nand.h | ||
| 3 | * | ||
| 4 | * Copyright (C) 2006 Micron Technology Inc. | ||
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License version 2 as | ||
| 8 | * published by the Free Software Foundation. | ||
| 9 | */ | ||
| 10 | |||
| 11 | #include <plat/gpmc.h> | ||
| 12 | #include <linux/mtd/partitions.h> | ||
| 13 | |||
| 14 | enum nand_io { | ||
| 15 | NAND_OMAP_PREFETCH_POLLED = 0, /* prefetch polled mode, default */ | ||
| 16 | NAND_OMAP_POLLED, /* polled mode, without prefetch */ | ||
| 17 | NAND_OMAP_PREFETCH_DMA, /* prefetch enabled sDMA mode */ | ||
| 18 | NAND_OMAP_PREFETCH_IRQ /* prefetch enabled irq mode */ | ||
| 19 | }; | ||
| 20 | |||
| 21 | struct omap_nand_platform_data { | ||
| 22 | int cs; | ||
| 23 | struct mtd_partition *parts; | ||
| 24 | struct gpmc_timings *gpmc_t; | ||
| 25 | int nr_parts; | ||
| 26 | bool dev_ready; | ||
| 27 | enum nand_io xfer_type; | ||
| 28 | int devsize; | ||
| 29 | enum omap_ecc ecc_opt; | ||
| 30 | struct gpmc_nand_regs reg; | ||
| 31 | }; | ||
| 32 | |||
| 33 | /* minimum size for IO mapping */ | ||
| 34 | #define NAND_IO_SIZE 4 | ||
| 35 | |||
| 36 | #if defined(CONFIG_MTD_NAND_OMAP2) || defined(CONFIG_MTD_NAND_OMAP2_MODULE) | ||
| 37 | extern int gpmc_nand_init(struct omap_nand_platform_data *d); | ||
| 38 | #else | ||
| 39 | static inline int gpmc_nand_init(struct omap_nand_platform_data *d) | ||
| 40 | { | ||
| 41 | return 0; | ||
| 42 | } | ||
| 43 | #endif | ||
diff --git a/include/linux/platform_data/mtd-onenand-omap2.h b/include/linux/platform_data/mtd-onenand-omap2.h new file mode 100644 index 000000000000..2858667d2e4f --- /dev/null +++ b/include/linux/platform_data/mtd-onenand-omap2.h | |||
| @@ -0,0 +1,53 @@ | |||
| 1 | /* | ||
| 2 | * arch/arm/plat-omap/include/mach/onenand.h | ||
| 3 | * | ||
| 4 | * Copyright (C) 2006 Nokia Corporation | ||
| 5 | * Author: Juha Yrjola | ||
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or modify | ||
| 8 | * it under the terms of the GNU General Public License version 2 as | ||
| 9 | * published by the Free Software Foundation. | ||
| 10 | */ | ||
| 11 | |||
| 12 | #include <linux/mtd/mtd.h> | ||
| 13 | #include <linux/mtd/partitions.h> | ||
| 14 | |||
| 15 | #define ONENAND_SYNC_READ (1 << 0) | ||
| 16 | #define ONENAND_SYNC_READWRITE (1 << 1) | ||
| 17 | |||
| 18 | struct onenand_freq_info { | ||
| 19 | u16 maf_id; | ||
| 20 | u16 dev_id; | ||
| 21 | u16 ver_id; | ||
| 22 | }; | ||
| 23 | |||
| 24 | struct omap_onenand_platform_data { | ||
| 25 | int cs; | ||
| 26 | int gpio_irq; | ||
| 27 | struct mtd_partition *parts; | ||
| 28 | int nr_parts; | ||
| 29 | int (*onenand_setup)(void __iomem *, int *freq_ptr); | ||
| 30 | int (*get_freq)(const struct onenand_freq_info *freq_info, | ||
| 31 | bool *clk_dep); | ||
| 32 | int dma_channel; | ||
| 33 | u8 flags; | ||
| 34 | u8 regulator_can_sleep; | ||
| 35 | u8 skip_initial_unlocking; | ||
| 36 | }; | ||
| 37 | |||
| 38 | #define ONENAND_MAX_PARTITIONS 8 | ||
| 39 | |||
| 40 | #if defined(CONFIG_MTD_ONENAND_OMAP2) || \ | ||
| 41 | defined(CONFIG_MTD_ONENAND_OMAP2_MODULE) | ||
| 42 | |||
| 43 | extern void gpmc_onenand_init(struct omap_onenand_platform_data *d); | ||
| 44 | |||
| 45 | #else | ||
| 46 | |||
| 47 | #define board_onenand_data NULL | ||
| 48 | |||
| 49 | static inline void gpmc_onenand_init(struct omap_onenand_platform_data *d) | ||
| 50 | { | ||
| 51 | } | ||
| 52 | |||
| 53 | #endif | ||
diff --git a/include/linux/platform_data/omap1_bl.h b/include/linux/platform_data/omap1_bl.h new file mode 100644 index 000000000000..881a8e92d605 --- /dev/null +++ b/include/linux/platform_data/omap1_bl.h | |||
| @@ -0,0 +1,11 @@ | |||
| 1 | #ifndef __OMAP1_BL_H__ | ||
| 2 | #define __OMAP1_BL_H__ | ||
| 3 | |||
| 4 | #include <linux/device.h> | ||
| 5 | |||
| 6 | struct omap_backlight_config { | ||
| 7 | int default_intensity; | ||
| 8 | int (*set_power)(struct device *dev, int state); | ||
| 9 | }; | ||
| 10 | |||
| 11 | #endif | ||
diff --git a/include/linux/platform_data/pinctrl-coh901.h b/include/linux/platform_data/pinctrl-coh901.h new file mode 100644 index 000000000000..30dea251b835 --- /dev/null +++ b/include/linux/platform_data/pinctrl-coh901.h | |||
| @@ -0,0 +1,26 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2007-2012 ST-Ericsson AB | ||
| 3 | * License terms: GNU General Public License (GPL) version 2 | ||
| 4 | * GPIO block resgister definitions and inline macros for | ||
| 5 | * U300 GPIO COH 901 335 or COH 901 571/3 | ||
| 6 | * Author: Linus Walleij <linus.walleij@stericsson.com> | ||
| 7 | */ | ||
| 8 | |||
| 9 | #ifndef __MACH_U300_GPIO_U300_H | ||
| 10 | #define __MACH_U300_GPIO_U300_H | ||
| 11 | |||
| 12 | /** | ||
| 13 | * struct u300_gpio_platform - U300 GPIO platform data | ||
| 14 | * @ports: number of GPIO block ports | ||
| 15 | * @gpio_base: first GPIO number for this block (use a free range) | ||
| 16 | * @gpio_irq_base: first GPIO IRQ number for this block (use a free range) | ||
| 17 | * @pinctrl_device: pin control device to spawn as child | ||
| 18 | */ | ||
| 19 | struct u300_gpio_platform { | ||
| 20 | u8 ports; | ||
| 21 | int gpio_base; | ||
| 22 | int gpio_irq_base; | ||
| 23 | struct platform_device *pinctrl_device; | ||
| 24 | }; | ||
| 25 | |||
| 26 | #endif /* __MACH_U300_GPIO_U300_H */ | ||
diff --git a/include/linux/platform_data/remoteproc-omap.h b/include/linux/platform_data/remoteproc-omap.h new file mode 100644 index 000000000000..b10eac89e2e9 --- /dev/null +++ b/include/linux/platform_data/remoteproc-omap.h | |||
| @@ -0,0 +1,57 @@ | |||
| 1 | /* | ||
| 2 | * Remote Processor - omap-specific bits | ||
| 3 | * | ||
| 4 | * Copyright (C) 2011 Texas Instruments, Inc. | ||
| 5 | * Copyright (C) 2011 Google, Inc. | ||
| 6 | * | ||
| 7 | * This program is free software; you can redistribute it and/or | ||
| 8 | * modify it under the terms of the GNU General Public License | ||
| 9 | * version 2 as published by the Free Software Foundation. | ||
| 10 | * | ||
| 11 | * This program is distributed in the hope that it will be useful, | ||
| 12 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
| 13 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
| 14 | * GNU General Public License for more details. | ||
| 15 | */ | ||
| 16 | |||
| 17 | #ifndef _PLAT_REMOTEPROC_H | ||
| 18 | #define _PLAT_REMOTEPROC_H | ||
| 19 | |||
| 20 | struct rproc_ops; | ||
| 21 | struct platform_device; | ||
| 22 | |||
| 23 | /* | ||
| 24 | * struct omap_rproc_pdata - omap remoteproc's platform data | ||
| 25 | * @name: the remoteproc's name | ||
| 26 | * @oh_name: omap hwmod device | ||
| 27 | * @oh_name_opt: optional, secondary omap hwmod device | ||
| 28 | * @firmware: name of firmware file to load | ||
| 29 | * @mbox_name: name of omap mailbox device to use with this rproc | ||
| 30 | * @ops: start/stop rproc handlers | ||
| 31 | * @device_enable: omap-specific handler for enabling a device | ||
| 32 | * @device_shutdown: omap-specific handler for shutting down a device | ||
| 33 | */ | ||
| 34 | struct omap_rproc_pdata { | ||
| 35 | const char *name; | ||
| 36 | const char *oh_name; | ||
| 37 | const char *oh_name_opt; | ||
| 38 | const char *firmware; | ||
| 39 | const char *mbox_name; | ||
| 40 | const struct rproc_ops *ops; | ||
| 41 | int (*device_enable) (struct platform_device *pdev); | ||
| 42 | int (*device_shutdown) (struct platform_device *pdev); | ||
| 43 | }; | ||
| 44 | |||
| 45 | #if defined(CONFIG_OMAP_REMOTEPROC) || defined(CONFIG_OMAP_REMOTEPROC_MODULE) | ||
| 46 | |||
| 47 | void __init omap_rproc_reserve_cma(void); | ||
| 48 | |||
| 49 | #else | ||
| 50 | |||
| 51 | void __init omap_rproc_reserve_cma(void) | ||
| 52 | { | ||
| 53 | } | ||
| 54 | |||
| 55 | #endif | ||
| 56 | |||
| 57 | #endif /* _PLAT_REMOTEPROC_H */ | ||
diff --git a/include/linux/platform_data/spi-omap2-mcspi.h b/include/linux/platform_data/spi-omap2-mcspi.h new file mode 100644 index 000000000000..a357eb26bd25 --- /dev/null +++ b/include/linux/platform_data/spi-omap2-mcspi.h | |||
| @@ -0,0 +1,23 @@ | |||
| 1 | #ifndef _OMAP2_MCSPI_H | ||
| 2 | #define _OMAP2_MCSPI_H | ||
| 3 | |||
| 4 | #define OMAP2_MCSPI_REV 0 | ||
| 5 | #define OMAP3_MCSPI_REV 1 | ||
| 6 | #define OMAP4_MCSPI_REV 2 | ||
| 7 | |||
| 8 | #define OMAP4_MCSPI_REG_OFFSET 0x100 | ||
| 9 | |||
| 10 | struct omap2_mcspi_platform_config { | ||
| 11 | unsigned short num_cs; | ||
| 12 | unsigned int regs_offset; | ||
| 13 | }; | ||
| 14 | |||
| 15 | struct omap2_mcspi_dev_attr { | ||
| 16 | unsigned short num_chipselect; | ||
| 17 | }; | ||
| 18 | |||
| 19 | struct omap2_mcspi_device_config { | ||
| 20 | unsigned turbo_mode:1; | ||
| 21 | }; | ||
| 22 | |||
| 23 | #endif | ||
diff --git a/include/linux/platform_data/voltage-omap.h b/include/linux/platform_data/voltage-omap.h new file mode 100644 index 000000000000..5be4d5def427 --- /dev/null +++ b/include/linux/platform_data/voltage-omap.h | |||
| @@ -0,0 +1,39 @@ | |||
| 1 | /* | ||
| 2 | * OMAP Voltage Management Routines | ||
| 3 | * | ||
| 4 | * Copyright (C) 2011, Texas Instruments, Inc. | ||
| 5 | * | ||
| 6 | * This program is free software; you can redistribute it and/or modify | ||
| 7 | * it under the terms of the GNU General Public License version 2 as | ||
| 8 | * published by the Free Software Foundation. | ||
| 9 | */ | ||
| 10 | |||
| 11 | #ifndef __ARCH_ARM_OMAP_VOLTAGE_H | ||
| 12 | #define __ARCH_ARM_OMAP_VOLTAGE_H | ||
| 13 | |||
| 14 | /** | ||
| 15 | * struct omap_volt_data - Omap voltage specific data. | ||
| 16 | * @voltage_nominal: The possible voltage value in uV | ||
| 17 | * @sr_efuse_offs: The offset of the efuse register(from system | ||
| 18 | * control module base address) from where to read | ||
| 19 | * the n-target value for the smartreflex module. | ||
| 20 | * @sr_errminlimit: Error min limit value for smartreflex. This value | ||
| 21 | * differs at differnet opp and thus is linked | ||
| 22 | * with voltage. | ||
| 23 | * @vp_errorgain: Error gain value for the voltage processor. This | ||
| 24 | * field also differs according to the voltage/opp. | ||
| 25 | */ | ||
| 26 | struct omap_volt_data { | ||
| 27 | u32 volt_nominal; | ||
| 28 | u32 sr_efuse_offs; | ||
| 29 | u8 sr_errminlimit; | ||
| 30 | u8 vp_errgain; | ||
| 31 | }; | ||
| 32 | struct voltagedomain; | ||
| 33 | |||
| 34 | struct voltagedomain *voltdm_lookup(const char *name); | ||
| 35 | int voltdm_scale(struct voltagedomain *voltdm, unsigned long target_volt); | ||
| 36 | unsigned long voltdm_get_voltage(struct voltagedomain *voltdm); | ||
| 37 | struct omap_volt_data *omap_voltage_get_voltdata(struct voltagedomain *voltdm, | ||
| 38 | unsigned long volt); | ||
| 39 | #endif | ||
diff --git a/include/linux/power/smartreflex.h b/include/linux/power/smartreflex.h index 3101e62a1213..4a496ebc7d73 100644 --- a/include/linux/power/smartreflex.h +++ b/include/linux/power/smartreflex.h | |||
| @@ -23,7 +23,7 @@ | |||
| 23 | #include <linux/types.h> | 23 | #include <linux/types.h> |
| 24 | #include <linux/platform_device.h> | 24 | #include <linux/platform_device.h> |
| 25 | #include <linux/delay.h> | 25 | #include <linux/delay.h> |
| 26 | #include <plat/voltage.h> | 26 | #include <linux/platform_data/voltage-omap.h> |
| 27 | 27 | ||
| 28 | /* | 28 | /* |
| 29 | * Different Smartreflex IPs version. The v1 is the 65nm version used in | 29 | * Different Smartreflex IPs version. The v1 is the 65nm version used in |
