Age | Commit message (Collapse) | Author | Files | Lines |
|
This patch is originally done by Carlos Eduardo Aguiar. Original fix is
commit 3305829b2816072b9c8ed01374b205ae4de74027 in
git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6.git
Author modified the fix for mainline version of menelaus.
Signed-off-by: Jarkko Nikula <[email protected]>
Cc: Carlos Eduardo Aguiar <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
We are modifying register value instead of return value.
This fix is originally done by Carlos Eduardo Aguiar. Original fix is
commit bb4e91722e29efe31587d2cc664b6def645aecd9 in
git.kernel.org/pub/scm/linux/kernel/git/tmlind/linux-omap-2.6.git
Author modified the fix for mainline version of menelaus.
Signed-off-by: Jarkko Nikula <[email protected]>
Cc: Carlos Eduardo Aguiar <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Signed-off-by: David S. Miller <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This patch includes below fixes:
1. fix wm8350_create_cache error path
make sure wm8350->reg_cache is freed in error path.
2. fix wm8350_device_init error path
no need to kfree(wm8350->reg_cache) in the case of goto out.
Signed-off-by: Axel Lin <[email protected]>
Acked-by: Mark Brown <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
wm8994_device_init() will return 0 in the case of kzalloc fail
in current implementation.
This patch fixes the return value.
Signed-off-by: Axel Lin <[email protected]>
Acked-by: Mark Brown <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
In the case of goto err2, what we want is to call
platform_device_del() instead of platform_device_unregister().
Otherwise, we call platform_device_put() twice.
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This patch includes below fixes:
1. add a missing iounmap in tc6387xb_probe() error path
2. fix resource reclaim in tc6387xb_remove()
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This patch corrects the error handling path.
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This adds all remaining definitions that are used by the core driver
to the .c file.
Signed-off-by: Uwe Kleine-König <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
There is a shiny new mc13783 API function that can be used instead.
While at it refactor the code a bit to reduce code duplication a bit.
This removes the last user of <linux/mfd/mc13783-private.h> and so this
include file can go away.
Signed-off-by: Uwe Kleine-König <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This is needed for the mc13783-adc driver to decide if a touch screen is
connected. If so some channels are not available as generic hwmon inputs.
Signed-off-by: Uwe Kleine-König <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
If kmalloc() fails exit with -ENOMEM.
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
If mfd_add_devices() fail, we need to relese allocated resources.
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
The WM8321 is a PMIC for low power, high performance applications. From a
software point of view the device is identical to the WM8320, all the
differences between the two devices are visible only in hardware.
Signed-off-by: Mark Brown <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Some STMPE devices support entering sleep mode automatically on a
specified timeout of inactivity on the I2C bus with the host system.
Acked-by: Linus Walleij <[email protected]>
Acked-by: Rabin Vincent <[email protected]>
Signed-off-by: Sundar R Iyer <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
platform_get_irq_byname() can return negative results, it is not seen to
unsigned ts_irq. Make it signed.
Signed-off-by: Kulikov Vasiliy <[email protected]>
Acked-By: Luotao Fu <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
TWL6030 supports PWM (Pulse Width Modulator) which is used
to control charging LED. PWM allows for controlling brightness.
This patch implements the APIs required by leds-pwm driver.
Signed-off-by: Hemanth V <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Later revisions of the WM8994 add some more GPIO functions, define them
in the header file.
Signed-off-by: Mark Brown <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This patch adds a MFD driver for the JZ4740 ADC unit. The driver is used to
demultiplex IRQs and synchronize access to shared registers between the
battery, hwmon and (future) touchscreen driver.
Signed-off-by: Lars-Peter Clausen <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
The debounce times are approximate, they can be selected using the two
input functions.
Signed-off-by: Mark Brown <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This one adds a driver for STMPE touchscreen controllers.
This driver depends on the stmpexxx mfd core driver.
Signed-off-by: Luotao Fu <[email protected]>
Acked-by: Dmitry Torokhov <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Add an input driver for the keypad on STMPE I/O expanders. This driver
uses the common support provided by the STMPE MFD driver.
Acked-by: Dmitry Torokhov <[email protected]>
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Rabin Vincent <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Add support for the GPIOs on STMPE I/O Expanders.
[[email protected]: fix set direction input]
[[email protected]: set GPIO alternate function while requesting]
Acked-by: Luotao Fu <[email protected]>
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Rabin Vincent <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Add support for the STMPE family of I/O Expanders from
STMicroelectronics. These devices include upto 24 gpios and a varying
selection of blocks, including PWM, keypad, and touchscreen controllers.
This patch adds the MFD core.
[[email protected]: fix stmpe811 enable hook]
[[email protected]: add touchscreen platform data]
Acked-by: Luotao Fu <[email protected]>
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Rabin Vincent <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
This patch includes below fixes to properly free clk32k clock source:
1. remove a redundant clk_put in t7l66xb_probe error path
2. add missing clk_disable(t7l66xb->clk32k) and clk_put(t7l66xb->clk32k)
to properly free the clock source.
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
For people to be able to intellingibly decide if they want to enable MFD
drivers or not, we have to give them a much better description of what they
are.
|
|
These are now exported via an ops table rather than referenced
directly and so should be staticised.
Signed-off-by: Mark Brown <[email protected]>
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Error handling code following a kmalloc should free the allocated data.
The semantic match that finds the problem is as follows:
(http://www.emn.fr/x-info/coccinelle/)
// <smpl>
@r exists@
local idexpression x;
statement S;
expression E;
identifier f,f1,l;
position p1,p2;
expression *ptr != NULL;
@@
x@p1 = \(kmalloc\|kzalloc\|kcalloc\)(...);
...
if (x == NULL) S
<... when != x
when != if (...) { <+...x...+> }
(
x->f1 = E
|
(x->f1 == NULL || ...)
|
f(...,x->f1,...)
)
...>
(
return \(0\|<+...x...+>\|ptr\);
|
return@p2 ...;
)
@script:python@
p1 << r.p1;
p2 << r.p2;
@@
print "* file: %s kmalloc %s return %s" % (p1[0].file,p1[0].line,p2[0].line)
// </smpl>
Signed-off-by: Julia Lawall <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
platform_device_add_resources may fail, thus add error checking for it.
Signed-off-by: Axel Lin <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Use !x rather than IS_ERR(x) to test the result of kzalloc.
The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)
// <smpl>
@@
expression x,E;
@@
x = \(kmalloc\|kzalloc\|kcalloc\)(...)
... when != x = E
- IS_ERR(x)
+ !x
// </smpl>
Signed-off-by: Julia Lawall <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
The registers on the AB8500 are only 8 bits wide, so the content
of the remaining bits is undefined. Let's mask off the undefined
stuff when returning a register in an SPI read.
Acked-by: Rabin Vincent <[email protected]>
Signed-off-by: Linus Walleij <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
The original code had a compile warning:
drivers/mfd/88pm860x-core.c:431: warning: ‘ret’ may be used
uninitialized in this function
It seems like the warning is valid if either pdata or pdata->touch is
NULL.
This patch checks pdata and pdata->touch at the beginning of the
function. That means everything can be pulled in one indent level.
Now all the statements fit within the 80 character limit.
Also at that point the "use_gpadc" variable isn't needed and removing
it simplifies the logic.
Signed-off-by: Dan Carpenter <[email protected]>
Acked-by: Haojian Zhuang <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
In current implementation, there is a memory leak if ab3100_otp_read fail.
And in the case of ab3100_otp_init_debugfs fail, it does not properly remove
sysfs entries.
This patch properly handle above failure cases.
Signed-off-by: Axel Lin <[email protected]>
Acked-by: Linus Walleij <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Fix typo error in LED resource of 88pm860x.
Signed-off-by: Haojian Zhuang <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
Enable onkey feature in max8925 driver.
Signed-off-by: Haojian Zhuang <[email protected]>
Signed-off-by: Samuel Ortiz <[email protected]>
|
|
If a minimal config did not specify the value
of all choice values, the resulting configuration
could have wrong values.
Consider following example:
config M
def_bool y
option modules
choice
prompt "choice list"
config A
tristate "a"
config B
tristate "b"
endchoice
With a defconfig like this:
CONFIG_M=y
CONFIG_A=y
The resulting configuration would have
CONFIG_A=m
which was unexpected.
The problem was not not all choice values were set and thus
kconfig calculated a wrong value.
The fix is to set all choice values when we
read a defconfig files.
conf_set_all_new_symbols() is refactored such that
random choice values are now handled by a dedicated function.
And new choice values are set by set_all_choice_values().
This was not the minimal fix, but the fix that resulted
in the most readable code.
Signed-off-by: Sam Ravnborg <[email protected]>
Reported-by: Arve Hjønnevåg <[email protected]>
Tested-by: Arve Hjønnevåg <[email protected]>
Signed-off-by: Michal Marek <[email protected]>
|
|
savedefconfig failed to save choice symbols equal to 'y'
for tristate choices.
This resulted in this value being lost.
In particular is fixes an issue where
make ARCH=avr32 atngw100_defconfig
make ARCH=avr32 savedefconfig
cp defconfig arch/avr32/configs/atngw100_defconfig
make ARCH=avr32 atngw100_defconfig
diff -u .config .config.old
failed to produce an identical .config.
Signed-off-by: Sam Ravnborg <[email protected]>
Signed-off-by: Michal Marek <[email protected]>
|
|
Signed-off-by: Andrea Gelmini <[email protected]>
Signed-off-by: Takashi Iwai <[email protected]>
|
|
Several gigabit network drivers (SB1250_MAC, TIGON3, FSL, GIANFAR,
UCC_GETH, MV643XX_ETH, XILINX_LL_TEMAC, S6GMAC, STMMAC_ETH, PASEMI_MAC,
and OCTEON_ETHERNET) select PHYLIB. These drivers are not under
NET_ETHERNET (10/100 mbit), so this warning is generated (long, irrelevant
parts are omitted):
warning: (NET_DSA && NET && EXPERIMENTAL && NET_ETHERNET && !S390 || ... || SB1250_MAC && NETDEVICES && NETDEV_1000 && SIBYTE_SB1xxx_SOC || TIGON3 && NETDEVICES && NETDEV_1000 && PCI || FSL_PQ_MDIO && NETDEVICES && NETDEV_1000 && FSL_SOC || GIANFAR && NETDEVICES && NETDEV_1000 && FSL_SOC || UCC_GETH && NETDEVICES && NETDEV_1000 && QUICC_ENGINE || MV643XX_ETH && NETDEVICES && NETDEV_1000 && (MV64X60 || PPC32 || PLAT_ORION) || XILINX_LL_TEMAC && NETDEVICES && NETDEV_1000 && (PPC || MICROBLAZE) || S6GMAC && NETDEVICES && NETDEV_1000 && XTENSA_VARIANT_S6000 || STMMAC_ETH && NETDEV_1000 && NETDEVICES && CPU_SUBTYPE_ST40 || PASEMI_MAC && NETDEVICES && NETDEV_10000 && PPC_PASEMI && PCI || OCTEON_ETHERNET && STAGING && !STAGING_EXCLUDE_BUILD && CPU_CAVIUM_OCTEON) selects PHYLIB which has unmet direct dependencies (!S390 && NET_ETHERNET)
PHYLIB is used by non-10/100 mbit ethernet drivers, so change the dependencies
to be NETDEVICES instead of NET_ETHERNET.
Signed-off-by: Randy Dunlap <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
|
|
The old code didn't work on binutils 2.12 because setting a symbol to
a register apparently requires a fairly recent version.
This commit refactors the code to use the C preprocessor instead, and
in the process makes the whole code a bit easier to understand.
The object code produced is unchanged as expected.
This fixes kernel bugzilla 16506.
Reported-by: Dieter Stussy <[email protected]>
Signed-off-by: Luca Barbieri <[email protected]>
Signed-off-by: H. Peter Anvin <[email protected]>
Cc: <[email protected]> 2.6.35
LKML-Reference: <tip-*@git.kernel.org>
|
|
Enable discard support in the DM multipath target.
This discard support depends on a few discard-specific fixes to the
block layer's request stacking driver methods.
Discard requests are optional so don't allow a failed discard to trigger
path failures. If there is a real problem with a given path the
barriers associated with the discard (either before or after the
discard) will cause path failure. That said, unconditionally passing
discard failures up the stack is not ideal. This must be fixed once DM
has more information about the nature of the underlying storage failure.
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
Cc: Kiyoshi Ueda <[email protected]>
|
|
The DM core will submit a discard bio to the stripe target for each
stripe in a striped DM device. The stripe target will determine
stripe-specific portions of the supplied bio to be remapped into
individual (at most 'num_discard_requests' extents). If a given
stripe-specific discard bio doesn't touch a particular stripe the bio
will be dropped.
Signed-off-by: Mikulas Patocka <[email protected]>
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
|
|
Update __clone_and_map_discard to loop across all targets in a DM
device's table when it processes a discard bio. If a discard crosses a
target boundary it must be split accordingly.
Update __issue_target_requests and __issue_target_request to allow a
cloned discard bio to have a custom start sector and size.
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
|
|
Optimize sector division: If the number of stripes is a power of two,
we can do shift and mask instead of division.
Signed-off-by: Mikulas Patocka <[email protected]>
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
|
|
Move sector to stripe translation into a function.
Signed-off-by: Mikulas Patocka <[email protected]>
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
|
|
Have the error target respond to a discard request with a hard -EIO
rather than fail the request with -EOPNOTSUPP.
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
|
|
Enable discard support for the delay target.
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
|
|
Have the zero target silently drop a discard rather than fail the
request with -EOPNOTSUPP.
Signed-off-by: Mike Snitzer <[email protected]>
Signed-off-by: Alasdair G Kergon <[email protected]>
|
|
Use new dm_target_offset() macro to avoid most references to ti->begin
in dm targets.
Signed-off-by: Alasdair G Kergon <[email protected]>
|