aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap2/i2c.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2012-12-18 19:51:10 -0500
committerLinus Torvalds <torvalds@linux-foundation.org>2012-12-18 19:51:10 -0500
commit752451f01c4567b506bf4343082682dbb8fb30dd (patch)
treeec2ec2989c93e567952ddc1ec879013aa2704f0a /arch/arm/mach-omap2/i2c.c
parent673ab8783b596cda5b616b317b1a1b47480c66fd (diff)
parent972deb4f49b5b6703d9c6117ba0aeda2180d4447 (diff)
Merge branch 'i2c-embedded/for-next' of git://git.pengutronix.de/git/wsa/linux
Pull i2c-embedded changes from Wolfram Sang: - CBUS driver (an I2C variant) - continued rework of the omap driver - s3c2410 gets lots of fixes and gains pinctrl support - at91 gains DMA support - the GPIO muxer gains devicetree probing - typical fixes and additions all over * 'i2c-embedded/for-next' of git://git.pengutronix.de/git/wsa/linux: (45 commits) i2c: omap: Remove the OMAP_I2C_FLAG_RESET_REGS_POSTIDLE flag i2c: at91: add dma support i2c: at91: change struct members indentation i2c: at91: fix compilation warning i2c: mxs: Do not disable the I2C SMBus quick mode i2c: mxs: Handle i2c DMA failure properly i2c: s3c2410: Remove recently introduced performance overheads i2c: ocores: Move grlib set/get functions into #ifdef CONFIG_OF block i2c: s3c2410: Add fix for i2c suspend/resume i2c: s3c2410: Fix code to free gpios i2c: i2c-cbus-gpio: introduce driver i2c: ocores: Add support for the GRLIB port of the controller and use function pointers for getreg and setreg functions i2c: ocores: Add irq support for sparc i2c: omap: Move the remove constraint ARM: dts: cfa10049: Add the i2c muxer buses to the CFA-10049 i2c: s3c2410: do not special case HDMIPHY stuck bus detection i2c: s3c2410: use exponential back off while polling for bus idle i2c: s3c2410: do not generate STOP for QUIRK_HDMIPHY i2c: s3c2410: grab adapter lock while changing i2c clock i2c: s3c2410: Add support for pinctrl ...
Diffstat (limited to 'arch/arm/mach-omap2/i2c.c')
-rw-r--r--arch/arm/mach-omap2/i2c.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/arm/mach-omap2/i2c.c b/arch/arm/mach-omap2/i2c.c
index fbb9b152cd5e..df6d6acbc9ed 100644
--- a/arch/arm/mach-omap2/i2c.c
+++ b/arch/arm/mach-omap2/i2c.c
@@ -120,6 +120,16 @@ static int __init omap_i2c_nr_ports(void)
120 return ports; 120 return ports;
121} 121}
122 122
123/*
124 * XXX This function is a temporary compatibility wrapper - only
125 * needed until the I2C driver can be converted to call
126 * omap_pm_set_max_dev_wakeup_lat() and handle a return code.
127 */
128static void omap_pm_set_max_mpu_wakeup_lat_compat(struct device *dev, long t)
129{
130 omap_pm_set_max_mpu_wakeup_lat(dev, t);
131}
132
123static const char name[] = "omap_i2c"; 133static const char name[] = "omap_i2c";
124 134
125int __init omap_i2c_add_bus(struct omap_i2c_bus_platform_data *i2c_pdata, 135int __init omap_i2c_add_bus(struct omap_i2c_bus_platform_data *i2c_pdata,
@@ -157,6 +167,15 @@ int __init omap_i2c_add_bus(struct omap_i2c_bus_platform_data *i2c_pdata,
157 dev_attr = (struct omap_i2c_dev_attr *)oh->dev_attr; 167 dev_attr = (struct omap_i2c_dev_attr *)oh->dev_attr;
158 pdata->flags = dev_attr->flags; 168 pdata->flags = dev_attr->flags;
159 169
170 /*
171 * When waiting for completion of a i2c transfer, we need to
172 * set a wake up latency constraint for the MPU. This is to
173 * ensure quick enough wakeup from idle, when transfer
174 * completes.
175 * Only omap3 has support for constraints
176 */
177 if (cpu_is_omap34xx())
178 pdata->set_mpu_wkup_lat = omap_pm_set_max_mpu_wakeup_lat_compat;
160 pdev = omap_device_build(name, bus_id, oh, pdata, 179 pdev = omap_device_build(name, bus_id, oh, pdata,
161 sizeof(struct omap_i2c_bus_platform_data), 180 sizeof(struct omap_i2c_bus_platform_data),
162 NULL, 0, 0); 181 NULL, 0, 0);