- 01 Oct, 2008 25 commits
-
-
David Brownell authored
Better TWL init on Beagle: use the setup() callback to learn IRQ assignments; and configure pullups/pulldowns. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Finish moving initialization of pullups and pulldowns for twl4030 GPIOs into board specific init. Remove partial/incorrect init code for that from the hsmmc glue. Doing this right requires some attention from board init logic, based on how the TWL chip is wired. Letting digital inputs float will waste power. Everyone with board schematics should update their board init code so it matches their boards; meanwhile, this returns to "current" behavior (all pullups disabled) but finally offers a way to do it "right". Note that the ULPI pins won't need this attention (muxed against gpio{3-5,9-12,14} pins), and neither will ones with external pullups or pulldowns (conventional for MMC/SD card detect). Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
twl4030_bci_battery.c is now moved to new style registration of twl4030 children. During the process a few bugfixes came, the main one is that twl4030-bci was releasing the wrong irq if battery registration had failed. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
Brainless fixes, checkpatch.pl fixes, variable naming, etc. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Improve handling of the OMAP-specific setup in twl4030-core, and remove various warnings on non-OMAP builds. The main remaining portability problem for this core code (from a build perspective) is needing symbols like TWL4030_PWR_IRQ_BASE which are undesirable and platform-specific. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Remove some ARM and OMAP specific stuff from the twl4030 GPIO code, and some unused/undesirable CPP symbols. Add minor checkpatch fixes. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Make the hsmmc code use genirq interfaces to make sure the card detect IRQ triggers on both edges. Remove the older TWL-specific infrastructure for making that happen. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Make twl4030 GPIO support set_type() request. Plus a bit of cleanup for the simple functions. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
Trivial brainless fixes, a few unused headers removed, changed one printk to pr_err() and removed one comment. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
This avoids oopsing in statically linked systems when some subsystems register I2C drivers in subsys_initcall() code, but those subsystems are linked (and initialized) before I2C. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Jean Delvare <khali@linux-fr.org> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
use platform_get_irq() for getting irq number passed to twl4030-usb via twl4030-core.c:add_children() Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Minor IRQ-related cleanups: comment out the no-longer-used GPIO irq symbol (more to come, eventually); create RTC IRQ resource; and use that RTC IRQ resource. And incidentally, make the RTC code free the correct IRQ; it was pretty goofed up... Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
Previously we were failing platform_device_add_data() and returning from add_children but trying to keep going when platform_device_add() fails. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Move the twl4030 GPIO support from drivers/i2c/chips to drivers/gpio, which is a more appropriate home for this code. The Kconfig symbol name is changed to match the GPIO_* convention for such symbols, so config files must change in the obvious ways (Kconfig will prompt you). There's now some helptext. It can now be compiled as a module, should anyone really want to do that; that'll be mostly useful for test builds. Sanity check the IRQ range we're given. Initialization order needed a bit of work too: core add_children() called only after IRQs get set up, gpio uses subsys_initcall. This depends on a patch making i2c driver model init use postcore_initcall. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Provide detailed diagnostics in add_children() when DEBUG is defined ... and fix the non-DEBUG message to include minimal status, and not appear unless there was actually an error. Update the IRQ message; have it match what the GPIO subchip says, and as a precaution, make it only appear if the IRQs have been initialized. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Added a few more diagnostics when platform_device_add() fails. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Minor twl4030-core cleanups: alphabetize the creation of the new sub-function nodes; wrap an #if around the OMAP-only part (to get more general build testing when this goes upstream); remove reference to undocumented "twl3040" variant. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Moved gpio before keypad driver due to alphabetic order. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
Moving twl4030-madc to new style registration just like the other twl4030 children. Cc: Mikko Ylinen <mikko.k.ylinen@nokia.com> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Make the twl4030 core create a platform device to which its GPIO code will bind, with platform_data used to configure board-specific behaviors and configuration. Update the twl4030 GPIO code: - Morph its gpio function code into a platform driver. - Move away from IRQ (and GPIO) numbers hard-wired in headers. - Hook up the twl4030 GPIO code to gpiolib. - Start phasing out the older TWL-specific calls ... currently those are used only by arch/arm/mach-omap2/hsmmc.c setup code. - Use a mutex for locking, not a binary semaphore. NOTE: more patches pending: (a) this doesn't use pdata->pullups to initialize (currently hsmmc code always sets GPIO-0 pullup even if the board has an external pullup); (b) there's a new gpio request/free hook forthcoming in 2.6.28, which this should use; (c) likewise there's a new gpio_to_irq() hook; (d) the irq_chip set_type() mechanism needs to be supported; (e) needs to move over to drivers/gpio; (f) upcoming threaded IRQ infrastructure should be used, when that merges. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Define platform data for configuring TWL4030 GPIOs, and provide it for all boards using these chips. For now all boards use the same fixed assignments for GPIO and IRQ numbers. Eventually we should be able to shuffle them without changing platform headers. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
vbus sysfs file will report the state of vbus irq coming from twl4030-usb. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
use new style twl4030-core to register a platform_device for twl4030-usb. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
let twl4030-core.c take care of twl4030_keypad registration. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
Clean up add_children a bit before adding more children to twl4030-core.c Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Jagadeesh Bhaskar Pakaravoor authored
One twl4030_request_gpio() should not tamper with the pullup enabling/disabling of the rest of the GPIOs. So removing the default pullup values written to REG_GPIOPUPDCTR1. Acked-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Girish S G <girishsg@ti.com> Signed-off-by: Jagadeesh Bhaskar Pakaravoor <j-pakaravoor@ti.com> Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Felipe Balbi authored
The following patch fix a potential null pointer dereference in twl4030 keypad driver when parts of keypad platform_data aren't passed down to the driver. At that point kp->dbg_dev is not set yet. Signed-off-by: Felipe Balbi <felipe.balbi@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
- 30 Sep, 2008 1 commit
-
-
Tony Lindgren authored
Big MMC init clean up: - Remove enabled field from slots. It is really intended to mean enabled controller, not enabled slot. Some controllers can have multiple multiplexed slots connected to the first controller, such as H4 and N8X0. - Initialize MMC devices dynamically as suggested by Russell King - Fix omap1 and omap2 mmc clock instance numbers - Also attempt to fix massive omap1 MMC breakage caused by patch 138ab9f8. Remove obviously broken MMC configurations for now. MMC is still not working for any omap1 boards. Signed-off-by: Tony Lindgren <tony@atomide.com>
-
- 28 Sep, 2008 1 commit
-
-
Tony Lindgren authored
This reverts commit c434c15d. Will re-apply once the MMC breakage on 3430 has been sorted out. Signed-off-by: Tony Lindgren <tony@atomide.com>
-
- 25 Sep, 2008 8 commits
-
-
Tony Lindgren authored
This should not be needed with new style I2C drivers. Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
A bunch of little cleanups to twl4030-core. - Remove needless header inclusions, symbols, and forward declarations. - Make coding style more standard. And shrink the object size a bit. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
This updates most of the OMAP drivers which are in mainline to switch to using the cross-platform GPIO calls instead of the older OMAP-specific ones. This is all fairly brainless/obvious stuff. Probably the most interesting bit is to observe that the omap-keypad code seems to now have a portable core that could work with non-OMAP matrix keypads. (That would improve with hardware IRQ debouncing enabled, of course...) Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
David Brownell authored
Make the hsmmc driver irq requests say which controller they're associated with (e.g. "mmc0") so /proc/interrupts is more useful. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Tero Kristo authored
Hardware supervised control for clockdomain power state transitions now enabled in omap3_pm_init(). Also fixed set_pwrdm_state() to allow state changes between sleep states (i.e. RET<->OFF.) Signed-off-by: Tero Kristo <tero.kristo@nokia.com> Acked-by: Paul Walmsley <paul@pwsan.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Jouni Hogander authored
This patch changes gpio "driver" to enable debounce clock for gpio-bank only when debounce is enabled for some gpio in that bank. Gpio functional clocks are also renamed in clock tree, gpioX_fck -> gpioX_dbck. This patch triggers problem with gpio wake-up and Omap3. Gpios in PER domain aren't capable to generate wake-up if PER domain is in sleep state. For this iopad wake-up should be used and needed pad configuration should be done. Enabling iopad wake-up for gpio pads is left for bootloader or omap mux configuration in kernel. Signed-off-by: Jouni Hogander <jouni.hogander@nokia.com> Acked-by: Paul Walmsley <paul@pwsan.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Tony Lindgren authored
Fix it for ES3.0. Also use ES3.0 now as the default for unknown future revision, and make the code easier to follow. Also fixed omap detection for ES2.1 and ES3.0 with a patch from Tero Kristo. Signed-off-by: Tero Kristo <tero.kristo@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Tony Lindgren authored
Clean-up i2c-omap Signed-off-by: Tony Lindgren <tony@atomide.com>
-
- 24 Sep, 2008 5 commits
-
-
Tony Lindgren authored
Big MMC init clean up: - Remove enabled field from slots. It is really intended to mean enabled controller, not enabled slot. Some controllers can have multiple multiplexed slots connected to the first controller, such as H4 and N8X0. - Initialize MMC devices dynamically as suggested by Russell King - Fix omap1 mmc clock instance numbers - Also attempt to fix massive omap1 MMC breakage caused by patch 138ab9f8. Remove obviously broken MMC configurations for now. MMC is still not working for any omap1 boards. Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Tony Lindgren authored
This fixes booting, and is a step toward fixing things properly: - Make enable_reg u32 instead of u16 - Get rid of VIRTUAL_IO_ADDRESS for clocks - Use __raw_read/write instead of omap_read/write for clock registers This patch adds a bunch of compile warnings until omap1 clock also uses offsets. Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Uwe Kleine-König authored
Don't use __init but __devinit to define probe function. A pointer to omap_mcbsp_probe is passed to the core via platform_driver_register and so the function must not disappear when the init code is freed. Using __init and having HOTPLUG=y the following probably oopses: echo -n omap-mcbsp.1 > /sys/bus/platform/driver/omap-mcbsp/unbind echo -n omap-mcbsp.1 > /sys/bus/platform/driver/omap-mcbsp/bind While at it move the remove function to the .devexit.text section. Signed-off-by: Uwe Kleine-König <ukleinek@strlen.de> Cc: Russell King <rmk+kernel@arm.linux.org.uk> Cc: Tony Lindgren <tony@atomide.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Jarkko Nikula authored
Without RX and TX interrupt definitions, the omap_mcbsp_request will fail on OMAP2430 and OMAP34xx for ports 3-5 since default io_type is OMAP_MCBSP_IRQ_IO. Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-
Jarkko Nikula authored
Bootloader may let McBSP logic running so make sure that block is idle before requesting IRQs. Also make sure that TX and RX waitqueues are initialized before request_irq. Signed-off-by: Jarkko Nikula <jarkko.nikula@nokia.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
-