aboutsummaryrefslogtreecommitdiffstats
path: root/drivers (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2009-12-06ARM: 5814/1: SA1100: h3100/h3600: convert all users of assign_h3600_egpio to gpiolibDmitry Artamonow2-18/+126
Use of gpio_request/gpio_free in some callbacks may look ugly, but corresponding drivers (sa1100_serial and sa1100_fb) don't provide (yet) init/exit hooks and registering these gpios in *_mach_init is also not possible, because htc-gpio driver starts a bit later... Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5813/1: SA1100: h3100/h3600: add htc-egpio driverDmitry Artamonow2-0/+69
It will be used for future conversion of assign_h3600_egpio calls to gpiolib. Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5812/1: SA1100: h3100/h3600: separate machine-specific LCD helpersDmitry Artamonow1-9/+20
h3100 and h3600 have different sets of LCD-controlling gpios, which mapped to the same "abstracted" EGPIO. As we plan to get rid of those abstracted egpios completely, we need to separate these helper functions. Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5811/2: pcmcia: convert sa1100_h3600 driver to gpiolibDmitry Artamonow1-11/+71
Convert all operations with GPLR/GPCR/GPSR to gpiolibs calls. Also change all IRQ_GPIO* to gpio_to_irq(*GPIO*) Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5799/1: SA1100: h3600: stop setting direction for LCD pinsDmitry Artamonow1-3/+1
sa1100_fb driver handles this Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5798/1: SA1100: h3600: remove unused cruft from h3600.hDmitry Artamonow1-8/+0
PM_SUSPEND, PM_RESUME and machine_is_h3xxx() are not used anywhere in kernel (checked with git grep), so it's safe to remove them. Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5796/1: SA1100: h3600: remove IRDA bits from serial PM callbackDmitry Artamonow1-4/+1
IRDA is handled by separate sa1100-ir driver and has nothing to do with sa1100_serial Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5797/1: SA1100: h3100/h3600: remove dead links from Kconfig help textDmitry Artamonow1-2/+0
Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: 5795/1: SA1100: h3100/h3600: mark *_mach_init functions as __initDmitry Artamonow1-3/+3
Signed-off-by: Dmitry Artamonow <mad_soft@inbox.ru> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: iPAQ: no need to set PWER_RTCRussell King1-1/+1
The rtc-sa1100 driver takes care of this. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: iPAQ: move serial port support functionsRussell King2-26/+52
No point calling sa1100_register_uart_fns early - these aren't used until late in the boot sequence. Also convert to gpiolib support. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: iPAQ: convert H3100 IrDA to use generic gpio supportRussell King2-3/+17
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: iPAQ: provide a way to setup platform-controlled GPIOsRussell King1-0/+42
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: iPAQ: separate IrDA machine specificsRussell King1-21/+41
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: h3600: provide each iPAQ machine type with own init functionRussell King1-2/+12
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06ARM: sa11x0: convert set_xxx_data() to register_xxx()Russell King13-40/+42
Only register devices if we have platform data for those which require platform data. Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-06i2c-stub: Documentation updateJean Delvare1-2/+2
There is nothing sensors-specific to i2c-stub. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c-stub: Allow user to disable some commandsJean Delvare2-2/+12
Add a module parameter to override the functionality bitfield. This lets the user disable some commands. This can be used to force a chip driver to take different code paths. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c-stub: Implement I2C block supportJean Delvare2-5/+29
This is required to test some drivers, for example at24. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c: Refactor for_each callbacksJean Delvare1-48/+22
Functions i2c_do_add_adapter() and __attach_adapter() do essentially the same thing, differing only in how the parameters are passed. Same for i2c_do_add_adapter() and __detach_adapter(). Introduce wrappers to normalize the parameters, so that we do not have to duplicate the code. Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: David Brownell <dbrownell@users.sourceforge.net>
2009-12-06i2c-i801: Retry on lost arbitrationJean Delvare1-0/+3
The Intel 82801 is sometimes used on systems with a BMC connected. The BMC can access the SMBus, resulting in lost arbitration for the 82801. We should let i2c-core retry transactions for us in this case. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c: Remove big kernel lock from i2cdev_openVincent Sanders1-16/+6
The BKL is held over a kmalloc so cannot protect anything beyond that. The two calls before the kmalloc have their own locking. Improve device open function by removing the now unnecessary ret variable Signed-off-by: Vincent Sanders <vince@simtec.co.uk> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06ics932s401: Clean up detect functionJean Delvare1-22/+15
As kind is now hard-coded to -1, there is room for code clean-ups. Signed-off-by: Jean Delvare <khali@linux-fr.org> Acked-by: "Darrick J. Wong" <djwong@us.ibm.com>
2009-12-06i2c: Simplify i2c_detect_addressJean Delvare1-13/+9
The kind parameter of i2c_detect_address() always has value -1, so we can get rid of it. Next step is to update all i2c detect callback functions to get rid of this now useless parameter. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c: Drop probe, ignore and force module parametersJean Delvare3-154/+46
The legacy probe and force module parameters are obsolete now, the same can be achieved using the new_device sysfs interface, which is both more flexible and cheaper (it is implemented by i2c-core rather than replicated in every driver module.) The legacy ignore module parameters can be dropped as well. Ignoring can be done by instantiating a "dummy" device at the problematic address. This is the first step of a huge cleanup to i2c-core's i2c_detect function, i2c.h's I2C_CLIENT_INSMOD* macros, and all drivers that made use of them. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c: Add missing __devinit markers to old i2c adapter driversJean Delvare4-4/+4
These _setup functions are called from _probe so they can be marked __devinit. Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c: Bus drivers don't have to support I2C_M_REV_DIR_ADDRJean Delvare3-11/+0
I2C bus drivers don't have to support I2C_M_REV_DIR_ADDR. It is a deviation from the I2C specification, which only makes sense to implement when really needed. Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: Ben Dooks <ben-linux@fluff.org>
2009-12-06i2c: Prevent priority inversion on top of bus lockMika Kuoppala3-10/+10
Low priority thread holding the i2c bus mutex could block higher priority threads to access the bus resulting in unacceptable latencies. Change the mutex type to rt_mutex preventing priority inversion. Tested-by: Peter Ujfalusi <peter.ujfalusi@nokia.com> Signed-off-by: Mika Kuoppala <mika.kuoppala@nokia.com> Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06i2c-voodoo3: DeleteJean Delvare5-338/+0
Superseded by tdfxfb. I2C/DDC support used to live in a separate driver but this caused driver conflicts. Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: Krzysztof Helt <krzysztof.h1@wp.pl>
2009-12-06i2c-powermac: Drop temporary name bufferJean Delvare1-6/+5
We no longer need to write the adapter name to a temporary buffer. We can write it directly to the i2c_adapter's name field. This is more efficient. Signed-off-by: Jean Delvare <khali@linux-fr.org> Tested-by: Michel Daenzer <michel@daenzer.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-12-06i2c-powermac: Include the i2c_adapter in struct pmac_i2c_busJean Delvare3-37/+9
Include the i2c_adapter in struct pmac_i2c_bus. This avoids memory fragmentation and allows for several code cleanups. Signed-off-by: Jean Delvare <khali@linux-fr.org> Tested-by: Michel Daenzer <michel@daenzer.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
2009-12-06i2c-powermac: Log errorsJean Delvare1-5/+23
Log errors when they happen, otherwise we have no idea what went wrong. Signed-off-by: Jean Delvare <khali@linux-fr.org> Tested-by: Michel Daenzer <michel@daenzer.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org>
2009-12-06i2c-powermac: Refactor i2c_powermac_smbus_xferJean Delvare1-44/+41
I wanted to add some error logging to the i2c-powermac driver, but found that it was very difficult due to the way the i2c_powermac_smbus_xfer function is organized. Refactor the code in this function so that each low-level function is only called once. Signed-off-by: Jean Delvare <khali@linux-fr.org> Tested-by: Michel Daenzer <michel@daenzer.net> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org>
2009-12-06i2c-powermac: Reject unsupported I2C transactionsJean Delvare1-0/+6
The i2c-powermac driver doesn't support arbitrary multi-message I2C transactions, only SMBus ones. Make it clear by returning an error if a multi-message I2C transaction is attempted. This is better than only processing the first message, because most callers won't recover from the short transaction. Anyone wishing to issue multi-message transactions should use the SMBus API instead of the raw I2C API. Signed-off-by: Jean Delvare <khali@linux-fr.org> Tested-by: Michel Daenzer <michel@daenzer.net> Acked-by: Benjamin Herrenschmidt <benh@kernel.crashing.org> Cc: Paul Mackerras <paulus@samba.org>
2009-12-06i2c/chips: Move ds1682 to drivers/miscWolfram Sang5-11/+11
As i2c/chips is deprecated, move ds1682 to a more apropriate location. Build tested. Signed-off-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Grant Likely <grant.likely@secretlab.ca> Signed-off-by: Jean Delvare <khali@linux-fr.org>
2009-12-06PM: Add flag for devices capable of generating run-time wake-up eventsRafael J. Wysocki3-5/+22
Apparently, there are devices that can wake up the system from sleep states and yet are incapable of generating wake-up events at run time. Thus, introduce a flag indicating if given device is capable of generating run-time wake-up events. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
2009-12-06PM / Runtime: Remove unnecessary braces in __pm_runtime_set_status()Rafael J. Wysocki1-5/+3
Some braces in __pm_runtime_set_status() are not necessary, so remove them. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
2009-12-06PM / Runtime: Make documentation of runtime_idle() agree with the codeRafael J. Wysocki1-2/+3
Currently the ->runtime_idle() callback is documented as having no return value, but in fact it returns int. Although its return value is ignored at the PM core level, it may be used by bus type routines executing the drivers' ->runtime_idle() callbacks. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Reported-by: Alan Stern <stern@rowland.harvard.edu>
2009-12-06PM / Runtime: Ensure timer_expires is nonzero in pm_schedule_suspend()Rafael J. Wysocki1-0/+2
The runtime PM core code assumes that dev->power.timer_expires is nonzero when the timer is scheduled, but it may become zero incidentally in pm_schedule_suspend(). Prevent this from happening by bumping dev->power.timer_expires up to 1 if it's 0 before calling mod_timer(). Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Reported-by: Alan Stern <stern@rowland.harvard.edu>
2009-12-06PM / Runtime: Use deferred_resume flag in pm_request_resumeAlan Stern1-4/+7
This patch (as1307) adds a small optimization to __pm_request_resume(). If the device is currently being suspended, there's no need to queue a work routine to resume it. Setting the deferred_resume flag will suffice. (There's also a minor improvement to the function's code layout: An unnecessary "else" is removed.) Also, the patch clarifies the usage of the deferred_resume flag. It is meaningful only while a suspend is in progress, so it should be cleared just before a suspend starts, not just after one ends. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
2009-12-06PM / Runtime: Export the PM runtime workqueueAlan Stern1-0/+1
This patch (as1306) exports the PM runtime workqueue for use by loadable modules. Signed-off-by: Alan Stern <stern@rowland.harvard.edu> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
2009-12-06PM / Runtime: Fix lockdep warning in __pm_runtime_set_status()Rafael J. Wysocki1-1/+1
Lockdep complains about taking the parent lock in __pm_runtime_set_status(), so mark it as nested. Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl> Reported-by: Alan Stern <stern@rowland.harvard.edu> Cc: stable@kernel.org
2009-12-06PM / Hibernate: Swap, use KERN_CONTJiri Slaby1-3/+3
Use KERN_CONT in save_image() for printks, so that anybody won't try to add a loglevel. Signed-off-by: Jiri Slaby <jirislaby@gmail.com> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
2009-12-06PM / Hibernate: Shift remaining code from swsusp.c to hibernate.cNigel Cunningham3-30/+31
Shift the remaining declaration of the variable in_suspend and the function swsusp_show_speed from swsusp.c to hibernate.c, and delete swsusp.c. Signed-off-by: Nigel Cunningham <nigel@tuxonice.net> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
2009-12-06PM / Hibernate: Move swap functions to kernel/power/swap.c.Nigel Cunningham2-101/+101
Move hibernation code's functions for allocating and freeing swap from swsusp.c to swap.c, which is where you'd expect to find them. Signed-off-by: Nigel Cunningham <nigel@tuxonice.net> Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
2009-12-06m68k: parport_mfc3 - Not makes it a bool before the comparison.Roel Kluin1-1/+1
Signed-off-by: Roel Kluin <roel.kluin@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
2009-12-06m68k: don't export static inline functionsStephen Rothwell2-2/+0
These now cause errors due to changes present in linux-next: (__ksymtab_sorted+0x1258): undefined reference to `dio_dev_driver' (__ksymtab_sorted+0x4d48): undefined reference to `zorro_dev_driver' Signed-off-by: Stephen Rothwell <sfr@canb.auug.org.au> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
2009-12-06fbdev: atafb - add palette register checkKrzysztof Helt1-0/+3
Add check if palette register number is in correct range for few drivers which miss it. The regno value comes indirectly from user space. Signed-off-by: Krzysztof Helt <krzysztof.h1@wp.pl> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
2009-12-06m68k: Remove the BKL from sys_execveJohn Kacur1-4/+1
This seems like a copy-and-paste from code that no-longer needs the BKL Just remove it. Signed-off-by: John Kacur <jkacur@redhat.com> Reviewed-by: Frederic Weisbecker <fweisbec@gmail.com> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>
2009-12-06m68k: Cleanup linker scripts using new linker script macros.Tim Abbott2-95/+20
Signed-off-by: Tim Abbott <tabbott@ksplice.com> Tested-by: Andreas Schwab <schwab@linux-m68k.org> Cc: Roman Zippel <zippel@linux-m68k.org> Cc: Sam Ravnborg <sam@ravnborg.org> Signed-off-by: Geert Uytterhoeven <geert@linux-m68k.org>