Haojian Zhuang [Mon, 7 Mar 2011 15:43:09 +0000 (23:43 +0800)]
mfd: Adopt mfd_data in 88pm860x backlight
Copy 88pm860x platform data into different mfd_data structure for
backlight driver. So move the identification of device node from
backlight driver to mfd driver.
Signed-off-by: Haojian Zhuang <haojian.zhuang@marvell.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Johan Palsson [Sat, 5 Mar 2011 10:46:37 +0000 (11:46 +0100)]
mfd: Calibrate ab8500 gpadc using OTP values
The GPADC found in the AB8500 needs to be calibrated to work
properly. This is done by writing a number of special OTP
(one-time-programmable) registers at production. This patch
makes sure that these values are used to calibrate the returned
value from the GPADC so that it is correct.
Signed-off-by: Johan Palsson <johan.palsson@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Daniel Willerud [Sat, 5 Mar 2011 10:46:13 +0000 (11:46 +0100)]
mfd: Reentrance and revamp ab8500 gpadc fetching interface
This revamps the interface so that AB8500 GPADCs are fetched by
name. Probed GPADCs are added to a list and this list is searched
for a matching GPADC. This makes it possible to have multiple
AB8500 GPADC instances instead of it being a singleton, and
rids the need to keep a GPADC pointer around in the core AB8500
MFD struct.
Currently the match is made to the device name which is by default
numbered from the device instance such as "ab8500-gpadc.0" but
by using the .init_name field of the device a more intiutive
naming for the GPADC blocks can be achieved if desired.
Signed-off-by: Daniel Willerud <daniel.willerud@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
MyungJoo Ham [Fri, 4 Mar 2011 06:50:26 +0000 (15:50 +0900)]
mfd: MAX8997/8966 support
MAX8997/MAX8966 chip is a multi-function device with I2C bussses. The
chip includes PMIC, RTC, Fuel Gauge, MUIC, Haptic, Flash control, and
Battery (charging) control.
This patch is an initial release of a MAX8997/8966 driver that supports
to enable the chip with its primary I2C bus that connects every device
mentioned above except for Fuel Gauge, which uses another I2C bus. The
fuel gauge is not supported by this mfd driver and is supported by a
seperated driver of MAX17042 Fuel Gauge (yes, the fuel gauge part is
compatible with MAX17042).
Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com> Signed-off-by: Kyungmin Park <kyungmin.park@samsung.com> Reviewed-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mattias Wallin [Wed, 2 Mar 2011 10:52:36 +0000 (11:52 +0100)]
mfd: ab8500-core switch off status added
This patch adds a sysfs file with the ab8500 switch off status.
The switch off status contains information of what caused the ab8500
chip to power off. A print during boot is also added.
Andres Salomon [Tue, 1 Mar 2011 21:35:48 +0000 (13:35 -0800)]
jz4740: silence warnings related to mfd_get_cell changes
mfd_get_cell returns a const, so change the jz4740 clients to store
a const mfd cell. This silences type mismatch warnings.
Signed-off-by: Andres Salomon <dilinger@queued.net> Acked-by: Anton Vorontsov <cbouatmailru@gmail.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Tue, 1 Mar 2011 20:12:46 +0000 (20:12 +0000)]
mfd: Add platform data to support multiple WM831x devices per board
If a system contains multiple WM831x devices we need to pass a device
number through to the MFD so that we use unique device IDs when we
instantiate child devices. In order to get support for this into 2.6.39
add some platform data to support the configuration, but no implementation
as yet.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Tue, 1 Mar 2011 20:12:45 +0000 (20:12 +0000)]
mfd: Convert WM8994/58 interrupt masking to enable/disable operations
The WM8994/58 interrupt masking support is a much better match for the genirq
enable and disable operations than for the mask and unmask operations. The
latter are intended to used during interrupt handling for temporary changes
which isn't really practical on a slow bus. Convert the operations over to
match this.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Tue, 1 Mar 2011 20:12:44 +0000 (20:12 +0000)]
mfd: Convert WM831x interrupt masking to enable/disable operations
The WM831x interrupt masking support is a much better match for the genirq
enable and disable operations than for the mask and unmask operations. The
latter are intended to used during interrupt handling for temporary changes
which isn't really practical on a slow bus. Convert the operations over to
match this.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Keerthy [Tue, 1 Mar 2011 13:42:36 +0000 (19:12 +0530)]
hwmon: twl4030: Hwmon Driver for TWL4030 MADC
This driver exposes the sysfs nodes of the TWL4030 MADC module.
All the voltage channel values are expressed in terms of mV. Channel 13
and channel 14 are reserved. There are channels which represent
temperature and current the output is represented by celcius
and mA respectively.
Keerthy [Tue, 1 Mar 2011 13:42:26 +0000 (19:12 +0530)]
mfd: Add twl4030 madc driver
Introducing a driver for MADC on TWL4030 powerIC. MADC stands for monitoring
ADC. This driver monitors the real time conversion of analog signals like
battery temperature, battery cuurent etc.
Signed-off-by: Keerthy <j-keerthy@ti.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Axel Lin [Mon, 28 Feb 2011 06:34:27 +0000 (14:34 +0800)]
mfd: Add MODULE_DEVICE_TABLE to vx855
The device table is required to load modules based on modaliases.
After adding the MODULE_DEVICE_TABLE, below entries will be added to
modules.pcimap:
vx855 0x00001106 0x00008409 0xffffffff 0xffffffff 0x00000000 0x00000000 0x0
Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Harald Welte <laforge@gnumonks.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Axel Lin [Mon, 28 Feb 2011 06:33:12 +0000 (14:33 +0800)]
mfd: Add MODULE_DEVICE_TABLE to pcf50633-core
The device table is required to load modules based on modaliases.
After adding the MODULE_DEVICE_TABLE, below entries will be added to
modules.alias:
alias i2c:pcf50633 pcf50633
Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Harald Welte <laforge@gnumonks.org> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Axel Lin [Mon, 28 Feb 2011 06:32:15 +0000 (14:32 +0800)]
mfd: Add MODULE_DEVICE_TABLE to mc13xxx-core
The device table is required to load modules based on modaliases.
After adding the MODULE_DEVICE_TABLE, below entries will be added to
modules.alias:
alias spi:mc13892 mc13xxx_core
alias spi:mc13783 mc13xxx_core
Signed-off-by: Axel Lin <axel.lin@gmail.com> Acked-by: Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:36 +0000 (19:07 -0800)]
mfd: Add sharing for cs5535 acpi/pms cells
This enables sharing of cs5535-mfd cells via the new mfd_shared_* API.
Hooks for enable/disble of resources are added, with refcounting of
resources being automatically handled so that cs5535_mfd_res_enable/disable
are only called when necessary.
Clients of cs5535-mfd (in this case, olpc-xo1.c) are also modified to
use the mfd_shared API. The platform drivers are also renamed to
olpc-xo1-{pms,acpi}, and resource enabling/disabling is replaced
with mfd_shared API calls.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:35 +0000 (19:07 -0800)]
mfd: add platform_device sharing support for mfd
This adds functions to enable platform_device sharing for mfd clients.
Each platform driver (mfd client) that wants to share an mfd_cell's
platform_device uses the mfd_shared_platform_driver_{un,}register()
functions instead of platform_driver_{un,}register(). Along with
registering the platform driver, these also register a new platform
device with the same characteristics as the original cell, but a different
name. Given an mfd_cell with the name "foo", drivers that want to
share access to its resources can call mfd_shared_platform_driver_register
with platform drivers named (for example) "bar" and "baz". This
will register two platform devices and drivers named "bar" and "baz"
that share the same cell as the platform device "foo". The drivers
can then call "foo" cell's enable hooks (or mfd_shared_cell_enable)
to enable resources, and obtain platform resources as they normally
would.
This deals with platform handling only; mfd driver-specific details,
hardware handling, refcounting, etc are all dealt with separately.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:34 +0000 (19:07 -0800)]
mfd: Add refcounting support to mfd_cells
This provides convenience functions for sharing of cells across
multiple mfd clients. Mfd drivers can provide enable/disable hooks
to actually tweak the hardware, and clients can call
mfd_shared_cell_{en,dis}able without having to worry about whether
or not another client happens to have enabled or disabled the
cell/hardware.
Note that this is purely optional; drivers can continue to use
the mfd_cell's enable/disable hooks for their own purposes, if
desired.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:30 +0000 (19:07 -0800)]
mtd: Use mfd_data instead of driver_data for tmio_nand
Use mfd_data for passing information from mfd drivers to mfd
clients. The mfd_cell's driver_data field is being phased out.
Clients that were using driver_data now access .mfd_data
via mfd_get_data(). This changes tmio-nand only; mfd drivers with
other cells are not modified.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:29 +0000 (19:07 -0800)]
mmc: Use mfd_data instead of driver_data for tmio-mmc
Use mfd_data for passing information from mfd drivers to mfd
clients. The mfd_cell's driver_data field is being phased out.
Clients that were using driver_data now access .mfd_data
via mfd_get_data(). This changes tmio-mmc only; mfd drivers with
other cells are not modified.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:28 +0000 (19:07 -0800)]
w1: Use mfd_data instead of driver_data for dsw1wm.c
Use mfd_data for passing information from mfd drivers to mfd
clients. The mfd_cell's driver_data field is being phased out.
Clients that were using driver_data now access .mfd_data
via mfd_get_data(). This changes ds1wm only; mfd drivers with
other cells are not modified, with the exception of led_cell.
The led_cell.driver_data line is dropped from htc-pasic3.c in this
patch as well. It's not used in mainline (there's no leds-pasic3
platform driver), so it should be safe to take care of that here.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:27 +0000 (19:07 -0800)]
asoc: wm8400-codec: Use mfd_data instead of driver_data
Use mfd_data for passing information from mfd drivers to soc
clients. The mfd_cell's driver_data field is being phased out.
Clients that were using driver_data now access .mfd_data
via mfd_get_data().
Signed-off-by: Andres Salomon <dilinger@queued.net> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Mon, 28 Feb 2011 16:24:03 +0000 (17:24 +0100)]
asoc: davinci_voicecodec: use mfd_data instead of driver_data
Use mfd_data for passing information from mfd drivers to soc
clients. The mfd_cell's driver_data field is being phased out.
Clients that were using driver_data now access .mfd_data
via mfd_get_data().
Signed-off-by: Andres Salomon <dilinger@queued.net> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:25 +0000 (19:07 -0800)]
mfd: Rename platform_data field of mfd_cell to mfd_data
Rename the platform_data variable to imply a distinction between
common platform_data driver usage (typically accessed via
pdev->dev.platform_data) and the way MFD passes data down to
clients (using a wrapper named mfd_get_data).
All clients have already been changed to use the wrapper function,
so this can be a quick single-commit change that only touches things
in drivers/mfd.
Signed-off-by: Andres Salomon <dilinger@queued.net> Acked-by: Linus Walleij <linus.walleij@stericsson.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:23 +0000 (19:07 -0800)]
mfd: mfd_cell is now implicitly available to mc13xxx drivers
The cell's platform_data is now accessed with a helper function;
change clients to use that, and remove the now-unused data_size.
Note that mfd-core no longer makes a copy of platform_data, but the
mc13xxx-core driver creates the pdata structures on the stack. In
order to get around that, the various ARM mach types that set the
pdata have been changed to hold the variable in static (global) memory.
Also note that __initdata references in aforementioned pdata structs
have been dropped.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:20 +0000 (19:07 -0800)]
mfd: mfd_cell is now implicitly available to twl4030 drivers
The cell's platform_data is now accessed with a helper function;
change clients to use that, and remove the now-unused data_size.
Signed-off-by: Andres Salomon <dilinger@queued.net> Acked-by: Peter Ujfalusi <peter.ujfalusi@nokia.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:15 +0000 (19:07 -0800)]
mfd: mfd_cell is now implicitly available to timberdale drivers
The cell's platform_data is now accessed with a helper function;
change clients to use that, and remove the now-unused data_size.
Note that the mfd's platform_data is marked __devinitdata. This
is still correct in all cases except for the timbgpio driver, whose
remove hook has been changed to no longer reference the pdata.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:11 +0000 (19:07 -0800)]
mfd: mfd_cell is now implicitly available to ab3550 driver
No clients (in mainline kernel, I'm told that drivers exist in external
trees that are planned for mainline inclusion) make use of this, nor
do they make use of platform_data, so nothing really had to change here.
The .data_size field is unused, so its usage gets removed.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Andres Salomon [Fri, 18 Feb 2011 03:07:09 +0000 (19:07 -0800)]
mfd-core: Unconditionally add mfd_cell to every platform_device
Previously, one would set the mfd_cell's platform_data/data_size to point
to the current mfd_cell in order to pass that information along to drivers.
This causes the current mfd_cell to always be available to drivers. It
also adds a wrapper function for fetching the mfd cell from a platform
device, similar to what originally existed for mfd devices.
Drivers who previously used platform_data for other purposes can still
use it; the difference is that mfd_get_data() must be used to
access it (and the pdata structure is no longer allocated in
mfd_add_devices).
Note that mfd_get_data is intentionally vague (in name) about where
the data is stored; variable name changes can come later without having
to touch brazillions of drivers.
Signed-off-by: Andres Salomon <dilinger@queued.net> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Keerthy [Wed, 23 Feb 2011 10:56:54 +0000 (16:26 +0530)]
mfd: Enabling twl4030_wdt and pwrbutton only for Triton
Enabling twl4030_wdt and twl4030_pwrbutton only for Triton i.e for
TWL4030 and TWL5030. This is to be excluded for Phoenix TWL6030.
Tested OMAP4 blaze, OMAP2430, OMAP3630 boot up.
Signed-off-by: Keerthy <j-keerthy@ti.com> Reviewed-by: Balaji T K <balajitk@ti.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Mon, 21 Feb 2011 18:30:31 +0000 (18:30 +0000)]
mfd: Put WM8994 into reset when suspending
Ensure that the chip is in the lowest power mode possible when suspended
by performing a soft reset on it. On early silicon revisions the lowest
power modes can't be entered without using reset so we can't achieve
equivalent results within the individual drivers.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Balaji T K [Thu, 10 Feb 2011 13:15:26 +0000 (18:45 +0530)]
OMAP4: add clk32kg data to omap4panda and blaze board file
In Blaze and Panda, 32KHz clock - CLK32KG to WLAN is supplied
from Phoenix TWL6030.
Add CLK32KG platform data to blaze and omap4panda board file.
Signed-off-by: Balaji T K <balajitk@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Tony Lindgren <tony@atomide.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Balaji T K [Thu, 10 Feb 2011 13:14:50 +0000 (18:44 +0530)]
regulator: twl: add clk32kg to twl-regulator
In OMAP4 Blaze and Panda, 32KHz clock to WLAN is supplied from Phoenix
TWL6030. The 32KHz clock state (ON/OFF) is configured in
CLK32KG_CFG_[GRP, TRANS, STATE] register. This follows the same register
programming model as other regulators in TWL6030. So add CLK32KG as pseudo
regulator.
Signed-off-by: Balaji T K <balajitk@ti.com> Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mattias Nilsson [Mon, 14 Feb 2011 10:17:12 +0000 (11:17 +0100)]
mfd: AB8500 system control driver
This adds a pretty straight-forward system control driver for the
AB8500. This driver will be used from the core platform, e.g the
clock tree implementation in the machine code, and is by nature
singleton.
There are a few simple functions to read, write, set and clear
registers so that the machine code can control its own foundation.
Mark Brown [Tue, 1 Feb 2011 11:46:13 +0000 (11:46 +0000)]
mfd: Add fast path for WM831x touchscreen interrupts
The WM831x interrupt controller provides reporting of the touchscreen
related interrupts in the primary interrupt status register as a
performance optimisation - use this to avoid reading the secondary
status registers for those interrupts.
For code simplicity and to avoid iterating over all interrupts we open
code for the two affected interrupt sources.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Tue, 1 Feb 2011 11:46:12 +0000 (11:46 +0000)]
mfd: Convert WM831x SPI to use dev_pm_ops
There is a move to deprecate bus-specific PM operations and move to
using dev_pm_ops instead in order to reduce the amount of boilerplate
code in buses and facilitiate updates to the PM core. Do this move for
the WM831x SPI driver.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Fri, 21 Jan 2011 13:26:46 +0000 (13:26 +0000)]
mfd: Support configuration of WM831x /IRQ output in CMOS mode
Provide platform data allowing the system to set the /IRQ pin into
CMOS mode rather than the default open drain. The default value of
this platform data reflects the default hardware configuration so
there should be no change to existing users.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Thu, 20 Jan 2011 21:52:42 +0000 (21:52 +0000)]
mfd: Convert pcf50633 to dev_pm_ops
There is a move to deprecate bus-specific PM operations and move to
using dev_pm_ops instead in order to reduce the amount of boilerplate
code in buses and facilitiate updates to the PM core. Do this move for
the pcf50633 driver.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Thu, 20 Jan 2011 21:47:31 +0000 (21:47 +0000)]
mfd: Staticise non-exported symbols in MAX8998 driver
No need to have them in the global namespace and sparse complains.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Acked-by: Kyungmin Park <kyungmin.park@samsung.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Thu, 20 Jan 2011 21:45:46 +0000 (21:45 +0000)]
mfd: Convert adp5520 to dev_pm_ops
There is a move to deprecate bus-specific PM operations and move to
using dev_pm_ops instead in order to reduce the amount of boilerplate
code in buses and facilitiate updates to the PM core. Do this move for
the adp5520 driver.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Mark Brown [Fri, 14 Jan 2011 13:38:16 +0000 (13:38 +0000)]
mfd: Leave acknowledgement of WM831x touchscreen IRQs to the driver
The WM831x touchscreen interrupts need acknowledgement even when using
direct signals to the CPU (which don't go through the core) so leave
the acknowledgement up to the touchscreen driver for simplicity.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
Linus Torvalds [Wed, 23 Mar 2011 00:53:13 +0000 (17:53 -0700)]
Merge branch 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/djbw/async_tx
* 'next' of git://git.kernel.org/pub/scm/linux/kernel/git/djbw/async_tx: (66 commits)
avr32: at32ap700x: fix typo in DMA master configuration
dmaengine/dmatest: Pass timeout via module params
dma: let IMX_DMA depend on IMX_HAVE_DMA_V1 instead of an explicit list of SoCs
fsldma: make halt behave nicely on all supported controllers
fsldma: reduce locking during descriptor cleanup
fsldma: support async_tx dependencies and automatic unmapping
fsldma: fix controller lockups
fsldma: minor codingstyle and consistency fixes
fsldma: improve link descriptor debugging
fsldma: use channel name in printk output
fsldma: move related helper functions near each other
dmatest: fix automatic buffer unmap type
drivers, pch_dma: Fix warning when CONFIG_PM=n.
dmaengine/dw_dmac fix: use readl & writel instead of __raw_readl & __raw_writel
avr32: at32ap700x: Specify DMA Flow Controller, Src and Dst msize
dw_dmac: Setting Default Burst length for transfers as 16.
dw_dmac: Allow src/dst msize & flow controller to be configured at runtime
dw_dmac: Changing type of src_master and dest_master to u8.
dw_dmac: Pass Channel Priority from platform_data
dw_dmac: Pass Channel Allocation Order from platform_data
...
Jean Delvare [Tue, 22 Mar 2011 23:35:13 +0000 (16:35 -0700)]
bloat-o-meter: include read-only data section in report
I'm not sure why the read-only data section is excluded from the report,
it seems as relevant as the other data sections (b and d).
I've stripped the symbols starting with __mod_ as they can have their
names dynamically generated and thus comparison between binaries is not
possible.
Signed-off-by: Jean Delvare <khali@linux-fr.org> Cc: Andi Kleen <andi@firstfloor.org> Acked-by: Nathan Lynch <ntl@pobox.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Jim Keniston [Tue, 22 Mar 2011 23:35:12 +0000 (16:35 -0700)]
zlib: slim down zlib_deflate() workspace when possible
Instead of always creating a huge (268K) deflate_workspace with the
maximum compression parameters (windowBits=15, memLevel=8), allow the
caller to obtain a smaller workspace by specifying smaller parameter
values.
For example, when capturing oops and panic reports to a medium with
limited capacity, such as NVRAM, compression may be the only way to
capture the whole report. In this case, a small workspace (24K works
fine) is a win, whether you allocate the workspace when you need it (i.e.,
during an oops or panic) or at boot time.
I've verified that this patch works with all accepted values of windowBits
(positive and negative), memLevel, and compression level.
Signed-off-by: Jim Keniston <jkenisto@us.ibm.com> Cc: Herbert Xu <herbert@gondor.apana.org.au> Cc: David Miller <davem@davemloft.net> Cc: Chris Mason <chris.mason@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Roland Dreier [Tue, 22 Mar 2011 23:35:10 +0000 (16:35 -0700)]
aio: wake all waiters when destroying ctx
The test program below will hang because io_getevents() uses
add_wait_queue_exclusive(), which means the wake_up() in io_destroy() only
wakes up one of the threads. Fix this by using wake_up_all() in the aio
code paths where we want to make sure no one gets stuck.
Stuart Swales [Tue, 22 Mar 2011 23:35:06 +0000 (16:35 -0700)]
adfs: add hexadecimal filetype suffix option
ADFS (FileCore) storage complies with the RISC OS filetype specification
(12 bits of file type information is stored in the file load address,
rather than using a file extension). The existing driver largely ignores
this information and does not present it to the end user.
It is desirable that stored filetypes be made visible to the end user to
facilitate a precise copy of data and metadata from a hard disc (or image
thereof) into a RISC OS emulator (such as RPCEmu) or to a network share
which can be accessed by real Acorn systems.
This patch implements a per-mount filetype suffix option (use -o
ftsuffix=1) to present any filetype as a ,xyz hexadecimal suffix on each
file. This type suffix is compatible with that used by RISC OS systems
that access network servers using NFS client software and by RPCemu's host
filing system.
Signed-off-by: Stuart Swales <stuart.swales.croftnuisk@gmail.com> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Stuart Swales [Tue, 22 Mar 2011 23:35:05 +0000 (16:35 -0700)]
adfs: improve timestamp precision
ADFS (FileCore) storage complies with the RISC OS timestamp specification
(40-bit centiseconds since 01 Jan 1900 00:00:00). It is desirable that
stored timestamp precision be maintained to facilitate a precise copy of
data and metadata from a hard disc (or image thereof) into a RISC OS
emulator (such as RPCEmu).
This patch implements a full-precision conversion from ADFS to Unix
timestamp as the existing driver, for ease of calculation with old 32-bit
compilers, uses the common trick of shifting the 40-bits representing
centiseconds around into 32-bits representing seconds thereby losing
precision.
Signed-off-by: Stuart Swales<stuart.swales.croftnuisk@gmail.com> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Stuart Swales [Tue, 22 Mar 2011 23:35:04 +0000 (16:35 -0700)]
adfs: fix E+/F+ dir size > 2048 crashing kernel
Kernel crashes in fs/adfs module when accessing directories with a large
number of objects on mounted Acorn ADFS E+/F+ format discs (or images) as
the existing code writes off the end of the fixed array of struct
buffer_head pointers.
Additionally, each directory access that didn't crash would leak a buffer
as nr_buffers was not adjusted correctly for E+/F+ discs (was always left
as one less than required).
The patch fixes this by allocating a dynamically-sized set of struct
buffer_head pointers if necessary for the E+/F+ case (many directories
still do in fact fit in 2048 bytes) and sets the correct nr_buffers so
that all buffers are released.
Tested by tar'ing the contents of my RISC PC's E+ format 20Gb HDD which
contains a number of large directories that previously crashed the kernel.
Signed-off-by: Stuart Swales <stuart.swales.croftnuisk@gmail.com> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Chen Gong [Tue, 22 Mar 2011 23:35:03 +0000 (16:35 -0700)]
Documentation/vm/page-types.c: auto debugfs mount for hwpoison operation
page-types.c doesn't supply a way to specify the debugfs path and the
original debugfs path is not usual on most machines. This patch supplies
a way to auto mount debugfs if needed.
This patch is heavily inspired by tools/perf/utils/debugfs.c
[akpm@linux-foundation.org: make functions static]
[akpm@linux-foundation.org: fix debugfs_mount() signature] Signed-off-by: Chen Gong <gong.chen@linux.intel.com> Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Reviewed-by: Wu Fengguang <fengguang.wu@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Christian Kujau [Tue, 22 Mar 2011 23:35:02 +0000 (16:35 -0700)]
Documentation/Changes: minor corrections
I noticed the 'mcelog' program had no comment and then ended up "fixing"
a few more things:
* reiserfsck -V does not print "reiserfsprogs" (any more?)
* is "udevinfo" still shipped? udevd certainly is
* grub2 doesn't have a 'grub' binary
* add a "# how to get the mcelog version" comment
Signed-off-by: Christian Kujau <lists@nerdbynature.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Harry Wei [Tue, 22 Mar 2011 23:35:01 +0000 (16:35 -0700)]
Documentation/CodingStyle: flesh out if-else examples
There is a missing case for "Chapter 3: Placing Braces and Spaces". We
often know we should not use braces where a single statement. The first
case is:
if (condition)
action();
Another case is:
if (condition)
do_this();
else
do_that();
However, I can not find a description of the second case.
Signed-off-by: Harry Wei <harryxiyou@gmail.com> Cc: Randy Dunlap <randy.dunlap@oracle.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
David Rientjes [Tue, 22 Mar 2011 23:34:59 +0000 (16:34 -0700)]
x86: allow CONFIG_ISA_DMA_API to be disabled
Not all 64-bit systems require ISA-style DMA, so allow it to be
configurable. x86 utilizes the generic ISA DMA allocator from
kernel/dma.c, so require it only when CONFIG_ISA_DMA_API is enabled.
Disabling CONFIG_ISA_DMA_API is dependent on x86_64 since those machines
do not have ISA slots and benefit the most from disabling the option (and
on CONFIG_EXPERT as required by H. Peter Anvin).
When disabled, this also avoids declaring claim_dma_lock(),
release_dma_lock(), request_dma(), and free_dma() since those interfaces
will no longer be provided.
Signed-off-by: David Rientjes <rientjes@google.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: "Luck, Tony" <tony.luck@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
David Rientjes [Tue, 22 Mar 2011 23:34:58 +0000 (16:34 -0700)]
x86: only compile floppy driver if CONFIG_ISA_DMA_API is enabled
The generic floppy disk driver utilizies the interface provided by
CONFIG_ISA_DMA_API, specifically claim_dma_lock(), release_dma_lock(),
request_dma(), and free_dma(). Thus, there's a strict dependency on the
config option and the driver should only be loaded if the kernel supports
ISA-style DMA.
Signed-off-by: David Rientjes <rientjes@google.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: "Luck, Tony" <tony.luck@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
David Rientjes [Tue, 22 Mar 2011 23:34:57 +0000 (16:34 -0700)]
x86: only compile 8237A if CONFIG_ISA_DMA_API is enabled
8237A utilizes the interface provided by CONFIG_ISA_DMA_API, specifically
claim_dma_lock() and release_dma_lock(). Thus, there's a strict
dependency on the config option and the module should only be loaded if
the kernel supports ISA-style DMA.
Signed-off-by: David Rientjes <rientjes@google.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: "Luck, Tony" <tony.luck@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
David Rientjes [Tue, 22 Mar 2011 23:34:56 +0000 (16:34 -0700)]
pnp: only assign IORESOURCE_DMA if CONFIG_ISA_DMA_API is enabled
IORESOURCE_DMA cannot be assigned without utilizing the interface
provided by CONFIG_ISA_DMA_API, specifically request_dma() and
free_dma(). Thus, there's a strict dependency on the config option and
limits IORESOURCE_DMA only to architectures that support ISA-style DMA.
ia64 is not one of those architectures, so pnp_check_dma() no longer
needs to be special-cased for that architecture.
pnp_assign_resources() will now return -EINVAL if IORESOURCE_DMA is
attempted on such a kernel.
Signed-off-by: David Rientjes <rientjes@google.com> Cc: Ingo Molnar <mingo@redhat.com> Cc: "H. Peter Anvin" <hpa@zytor.com> Cc: Thomas Gleixner <tglx@linutronix.de> Cc: Bjorn Helgaas <bjorn.helgaas@hp.com> Cc: Russell King <linux@arm.linux.org.uk> Cc: "Luck, Tony" <tony.luck@intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Andrew Chew [Tue, 22 Mar 2011 23:34:55 +0000 (16:34 -0700)]
rtc: add real-time clock driver for NVIDIA Tegra
This is a platform driver that supports the built-in real-time clock on
Tegra SOCs.
Signed-off-by: Andrew Chew <achew@nvidia.com> Acked-by: Alessandro Zummo <a.zummo@towertech.it> Acked-by: Wan ZongShun <mcuos.com@gmail.com> Acked-by: Jon Mayo <jmayo@nvidia.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Mark Brown [Tue, 22 Mar 2011 23:34:52 +0000 (16:34 -0700)]
rtc: convert DS1374 to dev_pm_ops
There is a general move to replace bus-specific PM ops with dev_pm_ops in
order to facilitate core improvements. Do this conversion for DS1374.
Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com> Cc: Alessandro Zummo <a.zummo@towertech.it> Cc: john stultz <johnstul@us.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Shawn Bohrer [Tue, 22 Mar 2011 23:34:47 +0000 (16:34 -0700)]
epoll: fix compiler warning and optimize the non-blocking path
Add a comment to ep_poll(), rename labels a bit clearly, fix a warning of
unused variable from gcc and optimize the non-blocking path a little.
Hinted-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Davide Libenzi <davidel@xmailserver.org>
hannes@cmpxchg.org:
: The non-blocking ep_poll path optimization introduced skipping over the
: return value setup.
:
: Initialize it properly, my userspace gets upset by epoll_wait() returning
: random things.
:
: In addition, remove the reinitialization at the fetch_events label, the
: return value is garuanteed to be zero when execution reaches there.
Davide Libenzi [Tue, 22 Mar 2011 23:34:46 +0000 (16:34 -0700)]
epoll: move ready event check into proper inline
Move the event readiness check into a proper inline, and use it uniformly
inside ep_poll() code. Events in the ->ovflist are no less ready than the
ones in ->rdllist.
Dave Jones [Tue, 22 Mar 2011 23:34:44 +0000 (16:34 -0700)]
checkpatch: warn about memset with swapped arguments
Because the second and third arguments of memset have the same type, it
turns out to be really easy to mix them up.
This bug comes up time after time, so checkpatch should really be checking
for it at patch submission time.
Signed-off-by: Dave Jones <davej@redhat.com> Cc: Steven Rostedt <rostedt@goodmis.org> Cc: Andy Whitcroft <apw@shadowen.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
If you run checkpatch against multiple patches, and one of them has a
whitespace issue which can be helped via a script (rpt_cleaners), you will
see the same NOTE over and over for all subsequent patches. It makes it
seem like those patches also have whitespace problems when in reality,
there's only one or two bad apples.
So reset rpt_cleaners back to 0 after we've issued the note so that it
only shows up near the patch with the actual problems.
Signed-off-by: Mike Frysinger <vapier@gentoo.org> Cc: Andy Whitcroft <apw@canonical.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>