Commit Graph

176235 Commits (9f5a5621e78cf48d86682a71ceb3fcdbde38b222)

Author SHA1 Message Date
Mark Brown 75b75722b4 mfd: Allow platforms to specify an IRQ base for WM8350
This is currently unused by the wm8350 drivers but getting it merged
now will reduce merge issues in the future when implementing wm8350
genirq support.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:31 +01:00
Amit Kucheria 53cf9a605d mfd: Fix more undefined twl4030-power resconfig value checks
Based on Aaro's previous fix, this needs to be fixed for the newly added
remap_off and remap_sleep resources as well.

The code tries to skip values initialized with -1, but since the values
are unsigned the comparison is always true.

The patch eliminates the following compiler warnings:

drivers/mfd/twl4030-power.c: In function 'twl4030_configure_resource':
drivers/mfd/twl4030-power.c:338: warning: comparison is always true due to
limited range of data type

Signed-off-by: Amit Kucheria <amit.kucheria@verdurent.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:30 +01:00
Amit Kucheria 3c684e84d1 mfd: Optimised twl4030-power power scripts for the rx51
The power scripts optimisation was mainly done by:
Tero Kristo <tero.kristo@nokia.com> and
Arnaud Mandy <ext-arnaud.2.mandy@nokia.com>

I'm only refactoring and testing it against the mainline kernel.

Signed-off-by: Amit Kucheria <amit.kucheria@verdurent.com>
Cc: Tero Kristo <tero.kristo@nokia.com>
Cc: linux-omap@vger.kernel.org
Acked-by: Tony Lindgren <tony@atomide.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:29 +01:00
Lars-Peter Clausen 24213ae19a mfd: Cleanup pcf50633_probe error handling
Currently the child devices were not freed if the irq could not be requested.
This patch restructures the function, that in case of an error all previously
allocated resources are freed.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:28 +01:00
Mark Brown 4e8b70265c mfd: Staticise __adp5520_ack_bits()
The function is not exported as the __ indicates. __

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:26 +01:00
Aaro Koskinen 56baa66797 mfd: fix undefined twl4030-power resconfig value checks
The code tries to skip values initialized with -1, but since the values
are unsigned the comparison is always true.

The patch eliminates the following compiler warnings:

drivers/mfd/twl4030-power.c: In function 'twl4030_configure_resource':
drivers/mfd/twl4030-power.c:338: warning: comparison is always true due to
limited range of data type
drivers/mfd/twl4030-power.c:358: warning: comparison is always true due to
limited range of data type
drivers/mfd/twl4030-power.c:363: warning: comparison is always true due to
limited range of data type

Signed-off-by: Aaro Koskinen <aaro.koskinen@nokia.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:25 +01:00
Amit Kucheria b4ead61e57 mfd: Add support for remapping twl4030-power power states
The <RESOURCE>_REMAP register allows configuration of the <RESOURCE> in case
of a sleep or off transition.

Allow this property of resources to be configured (through twl4030_resconfig)
and add code to parse these values to program the registers accordingly.

Signed-off-by: Amit Kucheria <amit.kucheria@verdurent.com>
Cc: linux-omap@vger.kernel.org
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:24 +01:00
Amit Kucheria 890463f0ff mfd: Add comments for the twl4030-power register and bit layout
Describe how the resource registers are laid out and the various bit-fields in
them.

Signed-off-by: Amit Kucheria <amit.kucheria@verdurent.com>
Cc: linux-omap@vger.kernel.org
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:22 +01:00
Amit Kucheria e97d15469f mfd: twl4030-power: Rename DEVGROUP to DEV_GRP
Stick to the names used in the reference manual

Signed-off-by: Amit Kucheria <amit.kucheria@verdurent.com>
Cc: linux-omap@vger.kernel.org
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:21 +01:00
Lars-Peter Clausen 98c2e49030 mfd: Fix pcf50633-regulator drvdata usage
Currently the pcf50633-regulator driver data is set to the pcf50633 core
structure, but the pcf50633-regulator remove handler assumes that it is set to
the regulator device. This patch fixes the issue by accessing the pcf506533
core structure through its parent device and setting the driver data to the
regulator device.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:20 +01:00
Lars-Peter Clausen bbb2e496f7 mfd: Use platform_device_add_data to set pcf50633 regulator platform data
Platform devices allocated with platform_device_alloc should use
platform_device_add_data to set the platform data, because kfree will be called
on the platform_data when the device is released.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:18 +01:00
Lars-Peter Clausen 68d641efd8 mfd: Fix memleak in pcf50633_client_dev_register
Since platform_device_add_data copies the passed data, the allocated
subdev_pdata is never freed. A simple fix would be to either free subdev_pdata
or put it onto the stack. But since the pcf50633 child devices can rely on
beeing children of the pcf50633 core device it's much more elegant to get access
to pcf50633 core structure through that link. This allows to get completly rid
of pcf5033_subdev_pdata.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:17 +01:00
Arnaud Patard b18fdc4b3e mfd: Move pcf50633 messages to appropriate log levels
IRQs masking/unmasking should be less verbose.

Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:15 +01:00
Lars-Peter Clausen 25993e4e42 mfd: Make pcf50633 suspend/resume belong to i2c_driver
When not using the i2c suspend/resume callbacks the i2c client resumed
before the i2c master.

Signed-off-by: Lars-Peter Clausen <lars@metafoo.de>
Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:12 +01:00
Paul Fertser 06b1cc9c05 mfd: Disable unnecessary pcf50633 shutdown on lowsys
On gta02 hardware revision A5 it can actually bring the system down
during normal operating conditions so we disable it.

Signed-off-by: Paul Fertser <fercerpav@gmail.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:07 +01:00
Mark Brown 0c7229f93a mfd: Convert WM835x IRQ handling to use a data table
Rather than open coding individual IRQs in each function which
manipulates them store data for IRQs in a table which is then
referenced in the users.

This is a substantial code shrink and should be a performance win in
cases where only a single IRQ goes off at once since instead of
reading four of the second level IRQ registers for each interrupt
we read only the sub-registers which have had an interrupt flagged.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:21:02 +01:00
Mark Brown e0a3389ab9 mfd: Split wm8350 IRQ code into a separate file
In preparation for refactoring - it's over 700 lines of well-isolated
code and having it in a file by itself makes things more managable.

While we're at it make sure that we clean up the IRQ if we fail after
acquiring it on init.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:55 +01:00
Michael Hennerich fba65fe0ed input/keyboard: new driver for ADP5520 MFD PMICs
Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Acked-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:53 +01:00
Michael Hennerich a5736e0b62 mfd: Add ADP5520/ADP5501 driver
Base driver for Analog Devices ADP5520/ADP5501 MFD PMICs

Subdevs:
LCD Backlight   : drivers/video/backlight/adp5520_bl.c
LEDs            : drivers/led/leds-adp5520.c
GPIO            : drivers/gpio/adp5520-gpio.c (ADP5520 only)
Keys            : drivers/input/keyboard/adp5520-keys.c (ADP5520 only)

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Bryan Wu <cooloney@kernel.org>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:53 +01:00
Michael Hennerich 7c29a47668 gpio: adp5520: rename common defines and typos
The common adp5520 mfd defines were namespaced to avoid collisions, so
update the define used in this driver accordingly.  The structs were also
renamed to fix a spelling typo.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:51 +01:00
Michael Hennerich c24b6b6a8e backlight: adp5520: rename common defines and typos
The common adp5520 mfd defines were namespaced to avoid collisions, so
update the define used in this driver accordingly.  The structs were also
renamed to fix a spelling typo.

Signed-off-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:50 +01:00
Haojian Zhuang 15e0ff7a0c mfd: Fix 88PM8607 I2C dependency
88PM8607 depends on I2C and MFD_CORE. Since 88PM8607 is built-in
kernel, it also requires that I2C and MFD_CORE are built-in
kernel also.

Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:48 +01:00
Uwe Kleine-König 1e3edaf6c0 mfd: Move asic3_remove to .devexit.text
The function asic3_remove is used only wrapped by __devexit_p so define
it using __devexit.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Acked-by: Sam Ravnborg <sam@ravnborg.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:46 +01:00
Mark Brown d4e0a89e3d mfd: Add support for WM8320 PMICs
The WM8320 is an integrated power management subsystem providing
voltage regulators, RTC, watchdog and other functionality. The
WM8320 is derived from the WM831x and therefore shares most of
the driver code with the WM831x.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:44 +01:00
Mark Brown 6f2ecaae72 gpiolib: Make WM831x GPIO count dynamic
This supports future devices with fewer GPIOs.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:43 +01:00
Mark Brown 894362f531 mfd: Refactor WM831x chip identification
Better support future device revisions by moving some of the output
around and making the chip ID enumeration be the value expected in
the ID register.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:42 +01:00
Jean Delvare 29f02646f0 mfd: Don't abuse i2c_client.name
The name field of struct i2c_client is for i2c-core's use, it should
never be changed by the drivers themselves.

Signed-off-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:40 +01:00
Samuel Ortiz 956266da70 mfd: Fix ab4500 compilation warnings
When building the driver as a module, module_exit was missing, and
subsys_initcall_sync() is not defined.

Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:39 +01:00
Srinidhi Kasagar 0c41839e98 mfd: add AB4500 driver
This adds core driver support for AB4500 mixed signal
multimedia & power management chip. This connects to U8500
on the SSP (pl022) and exports read/write functions for
the device to get access to this chip. This also registers
the client devices and sets the parent.

Signed-off-by: srinidhi kasagar <srinidhi.kasagar@stericsson.com>
Acked-by: Andrea Gallo <andrea.gallo@stericsson.com>
Reviewed-by: Mark Brown <broonie@sirena.org.uk>
Reviewed-by: Jean-Christophe <plagnioj@jcrosoft.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:38 +01:00
Haojian Zhuang 4107da2a28 mfd: Add 88PM8607 driver
This adds a core driver for 88PM8607 found in Marvell DKB development
platform. This driver is a proxy for all accesses to 88PM8607
sub-drivers which will be merged on top of this one, RTC, regulators,
battery and so on.

This chip is manufactured by Marvell.

Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com>
Reviewed-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
2009-12-13 19:20:37 +01:00
Russell King bc7ecbcbc2 Merge branch 'devel' of git://git.kernel.org/pub/scm/linux/kernel/git/ycmiao/pxa-linux-2.6 into devel 2009-12-13 16:35:09 +00:00
Russell King c7baab5d1e ARM: fix clps711x, footbridge, integrator, ixp2000, ixp2300 and s3c build bug
Anders Grafström reports that footbridge fails to build after 1c4a4f4.
Fix this by adding the necessary definitions for __pfn_to_bus and
__bus_to_pfn.

Reported-by: Anders Grafström <anders.grafstrom@netinsight.net>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-13 16:33:19 +00:00
Russell King 0d782dc430 ARM: VFP: fix vfp thread init bug and document vfp notifier entry conditions
When the VFP notifier is called for flush_thread(), we may be
preemptible, meaning we might migrate to another CPU, which means
referencing the current CPU number without some form of locking is
invalid, and can cause data corruption.

For the most cases, this isn't a problem since atomic notifiers are run
under rcu lock, which for most configurations results in preemption
being disabled - except when the preemptable tree-based rcu
implementation is selected.

Let's make it safe anyway.

Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-13 16:33:19 +00:00
Eric Miao 002939729c ARM: pxa: fix now incorrect reference of skt->irq by using skt->socket.pci_irq
commit 66024db removes all other references of skt->irq by using
skt->socket.pci_irq, while leaving these two missed. Get them fixed.

Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
2009-12-13 16:33:13 +00:00
Marc Zyngier 285eae0a4b [ARM] pxa/zeus: default configuration for Arcom Zeus SBC.
Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2009-12-13 21:42:58 +08:00
Marc Zyngier c2de1c3829 [ARM] pxa/zeus: make Viper pcmcia support more generic to support Zeus
The Arcom Zeus CF slot requires the same kind of support as the Viper.
To avoid code duplication, introduce a platform device that abstracts
the differences.

This also allows for the removal of the ugly export of viper_cf_rst().

Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2009-12-13 21:42:58 +08:00
Marc Zyngier e491a11c77 [ARM] pxa/zeus: basic support for Arcom Zeus SBC
Signed-off-by: Marc Zyngier <maz@misterjones.org>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2009-12-13 21:42:58 +08:00
Igor Grinberg 1b82e4c32f [ARM] pxa/em-x270: fix usb hub power up/reset sequence
Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
Signed-off-by: Mike Rapoport <mike@compulab.co.il>
Signed-off-by: Eric Miao <eric.y.miao@gmail.com>
2009-12-13 21:42:57 +08:00
Grant Likely 965346e3b9 spi: fix probe/remove section markings
Probe/remove functions need to be marked as __devinit and __devexit
(not __init an __exit) to prevent trying to run code that has been
discarded.  This patch fixes the spi_imx driver to mark probe and
remove correctly.

Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 01:03:12 -07:00
Cory Maccarrone 35c9049b27 Add OMAP spi100k driver
This change adds the OMAP SPI 100k driver created by
Fabrice Crohas <fcrohas@gmail.com>.  This SPI bus is found on
OMAP7xx-series smartphones, and for many, the touchscreen is
attached to this bus.

The lion's share of the work was done by Fabrice on this driver --
I am merely porting it from the Linwizard project on his behalf.

Signed-off-by: Cory Maccarrone <darkstar6262@gmail.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 01:02:11 -07:00
Uwe Kleine-König 980f3beeb6 spi-imx: don't access struct device directly but use dev_get_platdata
Also there is no casting needed to assign a void pointer.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 01:02:09 -07:00
Sascha Hauer 87f673e9ca spi-imx: Add mx25 support
Signed-off-by: Sascha Hauer <s.hauer@pengutronix.de>
Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 00:58:41 -07:00
Uwe Kleine-König f30d59c5d3 spi-imx: use positive logic to distinguish cpu variants
This is much safer when support for new variants is added.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 00:58:29 -07:00
Uwe Kleine-König 60f675a12c spi-imx: correct check for platform_get_irq failing
platform_get_irq returns -ENXIO if there is no entry.  So ensure
return value is greater than zero instead of non-zero.

Signed-off-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 00:58:13 -07:00
Wan ZongShun 30eaed053c ARM: NUC900: Add spi driver support for nuc900
Signed-off-by: Wan ZongShun <mcuos.com@gmail.com>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 00:58:00 -07:00
Magnus Damm 8051effcbc spi: SuperH MSIOF SPI Master driver V2
This patch is V2 of SPI Master support for the SuperH MSIOF.
Full duplex, spi mode 0-3, active high cs, 3-wire and lsb
first should all be supported, but the driver has so far
only been tested with "mmc_spi".

The MSIOF hardware comes with 32-bit FIFOs for receive and
transmit, and this driver simply breaks the SPI messages
into FIFO-sized chunks. The MSIOF hardware manages the pins
for clock, receive and transmit (sck/miso/mosi), but the chip
select pin is managed by software and must be configured as
a regular GPIO pin by the board code.

Performance wise there is still room for improvement, but
on a Ecovec board with the built-in sh7724 MSIOF0 this driver
gets Mini-sd read speeds of about half a megabyte per second.

Future work include better clock setup and merging of 8-bit
transfers into 32-bit words to reduce interrupt load and
improve throughput.

Signed-off-by: Magnus Damm <damm@opensource.se>
Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2009-12-13 00:48:27 -07:00
Cliff Wickman 1d865fb728 x86: Fix duplicated UV BAU interrupt vector
Interrupt vector 0xec has been doubly defined in irq_vectors.h

It seems arbitrary whether LOCAL_PENDING_VECTOR or
UV_BAU_MESSAGE is the higher number.  As long as they are
unique. If they are not unique we'll hit a BUG in
alloc_system_vector().

Signed-off-by: Cliff Wickman <cpw@sgi.com>
Cc: <stable@kernel.org>
LKML-Reference: <E1NJ9Pe-0004P7-0Q@eag09.americas.sgi.com>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
2009-12-13 08:17:40 +01:00
Linus Torvalds f40542532e Merge branch 'ixp4xx' of git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6
* 'ixp4xx' of git://git.kernel.org/pub/scm/linux/kernel/git/chris/linux-2.6:
  IXP4xx: GTWX5715 platform only has two PCI IRQ lines, not four.
  IXP4xx: Introduce IXP4XX_GPIO_IRQ(n) macro and convert IXP4xx platform files.
  IXP4xx: move Gemtek GTWX5715 platform macros to the platform code.
  IXP4xx: Remove unused Motorola PrPMC1100 platform macros.
  IXP4xx: move FSG platform macros to the platform code.
  IXP4xx: move DSM G600 platform macros to the platform code.
  IXP4xx: move NAS100D platform macros to the platform code.
  IXP4xx: move NSLU2 platform macros to the platform code.
  IXP4xx: move Coyote platform macros to the platform code.
  IXP4xx: move AVILA platform macros to the platform code.
  IXP4xx: move IXDP425 platform macros to the platform code.
  IXP4xx: Extend PCI MMIO indirect address space to 1 GB.
  IXP4xx: Fix compilation failure with CONFIG_IXP4XX_INDIRECT_PCI.
  IXP4xx: Drop "__ixp4xx_" prefix from in/out/ioread/iowrite functions for clarity.
  IXP4xx: Rename indirect MMIO primitives from __ixp4xx_* to __indirect_*.
  IXP4xx: Ensure index is positive in irq_to_gpio() and npe_request().
  ARM: fix insl() and outsl() endianness on IXP4xx architecture.
  IXP4xx: Fix normally-disabled debugging text in drivers/net/arm/ixp4xx_eth.c.
  IXP4xx: change the timer base frequency to 66.666000 MHz.
2009-12-12 15:22:22 -08:00
Linus Torvalds f01eb36403 [BKL] add 'might_sleep()' to the outermost lock taker
As shown by the previous patch (6698e3472: "tty: Fix BKL taken under a
spinlock bug introduced in the BKL split") the BKL removal is prone to
some subtle issues, where removing the BKL in one place may in fact make
a previously nested BKL call the new outer call, and then prone to nasty
deadlocks with other spinlocks.

In general, we should never take the BKL while we're holding a spinlock,
so let's just add a "might_sleep()" to it (even though the BKL doesn't
technically sleep - at least not yet), and we'll get nice warnings the
next time this kind of problem happens during BKL removal.

Acked-and-Tested-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-12-12 14:46:33 -08:00
Alan Cox 6698e34720 tty: Fix BKL taken under a spinlock bug introduced in the BKL split
The fasync path takes the BKL (it probably doesn't need to in fact)
while holding the file_list spinlock.  You can't do that with the kernel
lock: it causes lock inversions and deadlocks.

Leave the BKL over that bit for the moment.

Identified by AKPM.

Signed-off-by: Alan Cox <alan@linux.intel.com>
Acked-and-Tested-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-12-12 14:46:21 -08:00