Dmitry Torokhov [Thu, 25 Aug 2011 07:25:12 +0000 (00:25 -0700)]
Input: tsc2007 - convert to threaded IRQ
Instead of using hard IRQ and workqueue solution switch to using threaded
interrupt handler to simplify the code and locking rules.
Tested-by: Thierry Reding <thierry.reding@avionic-design.de>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Wanlong Gao [Wed, 24 Aug 2011 06:15:29 +0000 (23:15 -0700)]
Input: ad714x-i2c - change placement of __init/__exit annotations
Change the placement of __init and __exit annotations to be consistent
with the rest of the drivers.
Signed-off-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:02:56 +0000 (23:02 -0700)]
Input: synaptics - process finger (<=5) transitions
Synaptics image sensor touchpads track up to 5 fingers, but only report 2.
They use a special "TYPE=2" (AGM-CONTACT) packet type that reports
the number of tracked fingers and which finger is reported in the SGM
and AGM packets.
With this new packet type, it is possible to tell userspace when 4 or 5
fingers are touching.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:02:48 +0000 (23:02 -0700)]
Input: add BTN_TOOL_QUINTTAP for reporting 5 fingers on touchpad
"4-finger scroll" is a gesture supported by some applications and
operating systems.
"Resting thumb" is when a clickpad user rests a finger (e.g., a
thumb), in a "click zone" (typically the bottom of the touchpad) in
anticipation of click+move=select gestures.
Thus, "4-finger scroll + resting thumb" is a 5-finger gesture.
To allow userspace to detect this gesture, we send BTN_TOOL_QUINTTAP.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:02:40 +0000 (23:02 -0700)]
Input: synaptics - process finger (<=3) transitions
Synaptics image sensor touchpads track 5 fingers, but only report 2.
This patch attempts to deal with some idiosyncrasies of these touchpads:
* When there are 3 or more fingers, only two are reported.
* The touchpad tracks the 5 fingers in slot[0] through slot[4].
* It always reports the lowest and highest valid slots in SGM and AGM
packets, respectively.
* The number of fingers is only reported in the SGM packet. However,
the number of fingers can change either before or after an AGM
packet.
* Thus, if an SGM reports a different number of fingers than the last
SGM, it is impossible to tell whether the intervening AGM corresponds
to the old number of fingers or the new number of fingers.
* For example, when going from 2->3 fingers, it is not possible to tell
whether tell AGM contains slot[1] (old 2nd finger) or slot[2] (new
3rd finger).
* When fingers are added one at at time, from 1->2->3, it is possible to
track which slots are contained in the SGM and AGM packets:
1 finger: SGM = slot[0], no AGM
2 fingers: SGM = slot[0], AGM = slot[1]
3 fingers: SGM = slot[0], AGM = slot[2]
* It is also possible to track which slot is contained in the SGM when 1
of 2 fingers is removed. This is because the touchpad sends a special
(0,0,0) AGM packet whenever all fingers are removed except slot[0]:
Last AGM == (0,0,0): SGM contains slot[1]
Else: SGM contains slot[0]
* However, once there are 3 fingers, if exactly 1 finger is removed, it
is impossible to tell which 2 slots are contained in SGM and AGM.
The (SGM,AGM) could be (0,1), (0,2), or (1,2). There is no way to know.
* Similarly, if two fingers are simultaneously removed (3->1), then it
is only possible to know if SGM still contains slot[0].
* Since it is not possible to reliably track which slot is being
reported, we invalidate the tracking_id every time the number of
fingers changes until this ambiguity is resolved when:
a) All fingers are removed.
b) 4 or 5 fingers are touched, generates an AGM-CONTACT packet.
c) All fingers are removed except slot[0]. In this special case, the
ambiguity is resolved since by the (0,0,0) AGM packet.
Behavior of the driver:
When 2 or more fingers are present on the touchpad, the kernel reports
up to two MT-B slots containing the position data for two of the fingers
reported by the touchpad. If the identity of a finger cannot be tracked
when the number-of-fingers changes, the corresponding MT-B slot will be
invalidated (track_id set to -1), and a new track_id will be assigned in
a subsequent input event report.
The driver always reports the total number of fingers using one of the
EV_KEY/BTN_TOOL_*TAP events. This could differ from the number of valid
MT-B slots for two reasons:
a) There are more than 2 fingers on the pad.
b) During ambiguous number-of-fingers transitions, the correct track_id
for one or both of the slots cannot be determined, so the slots are
invalidated.
Thus, this is a hybrid singletouch/MT-B scheme. Userspace can detect
this behavior by noting that the driver supports more EV_KEY/BTN_TOOL_*TAP
events than its maximum EV_ABS/ABS_MT_SLOT.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:02:36 +0000 (23:02 -0700)]
Input: mt - document devices reporting more touches than slots
Some devices are capable of identifying and/or tracking more contacts than
they can report to the driver. Document how a driver should handle this,
and what userspace should expect.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:02:31 +0000 (23:02 -0700)]
Input: synaptics - decode AGM packet types
A Synaptics image sensor tracks 5 fingers, but can only report 2.
The algorithm for choosing which 2 fingers to report and in which packet:
Touchpad maintains 5 slots, numbered 0 to 4
Initially all slots are empty
As new fingers are detected, assign them to the lowest available slots
The touchpad always reports:
SGM: lowest numbered non-empty slot
AGM: highest numbered non-empty slot, if there is one
In addition, these touchpads have a special AGM packet type which reports
the number of fingers currently being tracked, and which finger is in
each of the two slots. Unfortunately, these "TYPE=2" packets are only used
when more than 3 fingers are being tracked. When less than 4 fingers
are present, the 'w' value must be used to track how many fingers are
present, and knowing which fingers are being reported is much more
difficult, if not impossible.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:02:25 +0000 (23:02 -0700)]
Input: synaptics - add image sensor support
Synaptics makes (at least) two kinds of touchpad sensors:
* Older pads use a profile sensor that could only infer the location
of individual fingers based on the projection of their profiles
onto row and column sensors.
* Newer pads use an image sensor that can track true finger position
using a two-dimensional sensor grid.
Both sensor types support an "Advanced Gesture Mode":
When multiple fingers are detected, the touchpad sends alternating
"Advanced Gesture Mode" (AGM) and "Simple Gesture Mode" (SGM)
packets.
The AGM packets have w=2, and contain reduced resolution finger data
The SGM packets have w={0,1} and contain full resolution finger data
Profile sensors try to report the "upper" (larger y value) finger in
the SGM packet, and the lower (smaller y value) in the AGM packet.
However, due to the nature of the profile sensor, they easily get
confused when fingers cross, and can start reporting the x-coordinate
of one with the y-coordinate of the other. Thus, for profile
sensors, "semi-mt" was created, which reports a "bounding box"
created by pairing min and max coordinates of the two pairs of
reported fingers.
Image sensors can report the actual coordinates of two of the fingers
present. This patch detects if the touchpad is an image sensor and
reports finger data using the MT-B protocol.
NOTE: This patch only adds partial support for 2-finger gestures.
The proper interpretation of the slot contents when more than
two fingers are present is left to later patches. Also,
handling of 'number of fingers' transitions is incomplete.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:00:41 +0000 (23:00 -0700)]
Input: synaptics - refactor initialization of abs position axes
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:00:33 +0000 (23:00 -0700)]
Input: synaptics - refactor agm packet parsing
When a Synaptics touchpad is in "AGM" mode, and multiple fingers are
detected, the touchpad sends alternating "Advanced Gesture Mode" (AGM) and
"Simple Gesture Mode" (SGM) packets.
The AGM packets have w=2, and contain reduced resolution finger data.
The SGM packets have w={0,1} and contain full resolution finger data.
Refactor the parsing of agm packets to its own function, and rename the
synaptics_data.mt field to .agm to indicate that it contains the contents of
the last agm packet.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Wed, 24 Aug 2011 06:00:24 +0000 (23:00 -0700)]
Input: synaptics - refactor y inversion
Synaptics touchpads report increasing y from bottom to top.
This is inverted from normal userspace "top of screen is 0" coordinates.
Thus, the kernel driver reports inverted y coordinates to userspace.
This patch refactors this inversion.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dmitry Torokhov [Wed, 24 Aug 2011 05:57:00 +0000 (22:57 -0700)]
Input: wacom_w8001 - simplify w8001_remove
Since touchscreen driver does not handle any events to be sent to the
device we can close serio port first and then unregister the input device.
Tested-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dmitry Torokhov [Wed, 24 Aug 2011 05:57:00 +0000 (22:57 -0700)]
Input: wacom_w8001 - implement open and close
Implement open() and close() methods for the input device so that we
do not start the device unless there are users listening to the events.
Acked-by: Chris Bagwell <chris@cnpbagwell.com>
Tested-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Eric Andersson [Tue, 9 Aug 2011 07:06:37 +0000 (00:06 -0700)]
Input: add driver for Bosch Sensortec's BMA150 accelerometer
Signed-off-by: Albert Zhang <xu.zhang@bosch-sensortec.com>
Signed-off-by: Eric Andersson <eric.andersson@unixphere.com>
Acked-by: Jonathan Cameron <jic23@cam.ac.uk>
Reviewed-by: Alan Cox <alan@linux.intel.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dmitry Torokhov [Wed, 3 Aug 2011 05:22:46 +0000 (22:22 -0700)]
Input: polldev - immediately poll device upon opening
To allow open/ioctl(EVIOCGABS)/close use pattern for polled devices read
the device in context of open() call instead of offloading the first read
to a workqueue. This will ensure that once call to open() returns device
would have cached reasonably recent axis values that can be retrieved via
appropriate ioctl.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Amy Maloche [Tue, 2 Aug 2011 06:41:44 +0000 (23:41 -0700)]
Input: add support for pm8xxx based vibrator driver
Add support for pm8xx based vibrator to facilitate haptics.
This module uses the ff-memless framework.
Signed-off-by: Amy Maloche <amaloche@codeaurora.org>
Signed-off-by: Anirudh Ghayal <aghayal@codeaurora.org>
Reviewed-by: Wanlong Gao <gaowanlong@cn.fujitsu.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dmitry Torokhov [Mon, 25 Jul 2011 08:36:46 +0000 (01:36 -0700)]
Input: synaptics - fix reporting of min coordinates
We were testing wrong bit in the extended capability query.
Reported-by: Daniel Kurtz <djkurtz@chromium.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Rakesh Iyer [Mon, 25 Jul 2011 07:49:55 +0000 (00:49 -0700)]
Input: tegra-kbc - enable key autorepeat
To support key repeats, keyboard needs to be setup as an autorepeating
device.
Signed-off-by: Rakesh Iyer <riyer@nvidia.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dan Carpenter [Wed, 20 Jul 2011 06:16:29 +0000 (23:16 -0700)]
Input: kxtj9 - fix locking typo in kxtj9_set_poll()
According to the comments we want to call mutex_lock() here instead
of mutex_unlock(). That makes more sense.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dan Carpenter [Wed, 20 Jul 2011 06:12:21 +0000 (23:12 -0700)]
Input: kxtj9 - fix bug in probe()
We are testing the wrong variable here. I believe tj9->input_dev
is always NULL at this point, so probe() will fail.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Tue, 19 Jul 2011 00:09:05 +0000 (17:09 -0700)]
Input: intel-mid-touch - remove pointless checking for variable 'found'
The implementation does break from the for loop after we assign 'i' to
variable 'found'.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Tue, 19 Jul 2011 00:09:46 +0000 (17:09 -0700)]
Input: hp_sdc - staticize hp_sdc_kicker()
It's not referenced outside this file so there's no need for it to be in
the global name space.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Tue, 19 Jul 2011 00:09:22 +0000 (17:09 -0700)]
Input: pmic8xxx-keypad - fix a leak of the IRQ during init failure
Make sure we are passing the same cookie in all calls to
request_any_context_irq() and free_irq().
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Tue, 19 Jul 2011 00:09:37 +0000 (17:09 -0700)]
Input: cy8ctmg110_ts - set reset_pin and irq_pin from platform data
The implementation in cy8ctmg110_probe() does not properly set reset_pin
and irq_pin from platform data. Let's fix it.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Wed, 13 Jul 2011 07:04:36 +0000 (00:04 -0700)]
Input: cy8ctmg110_ts - constify i2c_device_id table
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Wed, 13 Jul 2011 07:03:36 +0000 (00:03 -0700)]
Input: cy8ctmg110_ts - fix checking return value of i2c_master_send
i2c_master_send returns negative errno, or else the number of bytes written.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Wed, 13 Jul 2011 07:02:21 +0000 (00:02 -0700)]
Input: lifebook - make dmi callback functions return 1
We only care about if there is a successful match from the table (or
no match at all), so let's make dmi_check_system return immediately
instead of iterating thorough the whole table.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Wed, 13 Jul 2011 06:59:41 +0000 (23:59 -0700)]
Input: atkbd - make dmi callback functions return 1
We only care about if there is a successful match from the table (or
no match at all), so let's make dmi_check_system return immediately
instead of iterating thorough the whole table.
Make the dmi callback function return 1 then dmi_check_system
will return immediately if we have a successful match.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dmitry Torokhov [Sat, 9 Jul 2011 19:41:46 +0000 (12:41 -0700)]
Input: gpio_keys - switch to using SIMPLE_DEV_PM_OPS
This reduces amount #ifdeds in the code.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
David Jander [Sat, 9 Jul 2011 19:41:46 +0000 (12:41 -0700)]
Input: gpio_keys - add support for device-tree platform data
This patch enables fetching configuration data, which is normally provided
via platform_data, from the device-tree instead.
If the device is configured from device-tree data, the platform_data struct
is not used, and button data needs to be allocated dynamically. Big part of
this patch deals with confining pdata usage to the probe function, to make
this possible.
Signed-off-by: David Jander <david@protonic.nl>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Edwin van Vliet [Sun, 10 Jul 2011 23:07:28 +0000 (16:07 -0700)]
Input: aiptek - remove double define
Constant AIPTEK_TOOL_BUTTON_PEN_MODE was defined twice.
Signed-off-by: Edwin van Vliet <edwin@cheatah.nl>
Reviewed-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Dmitry Torokhov [Sat, 9 Jul 2011 19:32:56 +0000 (12:32 -0700)]
Input: synaptics - set minimum coordinates as reported by firmware
Newer Synaptics firmware allows to query minimum coordinates reported by
the device, let's use this data.
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Acked-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Thu, 7 Jul 2011 05:57:39 +0000 (22:57 -0700)]
Input: synaptics - process button bits in AGM packets
AGM packets contain valid button bits, too.
This patch refactors packet processing to parse button bits in AGM packets.
However, they aren't actually used or reported.
The point is to more completely process AGM packets,
and prepare for future patches that may actually use AGM packet button bits.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Thu, 7 Jul 2011 05:42:52 +0000 (22:42 -0700)]
Input: synaptics - rename set_slot to be more descriptive
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Thu, 7 Jul 2011 05:39:14 +0000 (22:39 -0700)]
Input: synaptics - fuzz position for touchpad with reduced filtering
Synaptics touchpads indicate via a capability bit when they perform reduced
filtering on position data. In such a case, use a non-zero fuzz value.
Fuzz = 8 was chosen empirically by observing the raw position data
reported by a clickpad indicating it had reduced filtering.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Daniel Kurtz [Thu, 7 Jul 2011 05:27:47 +0000 (22:27 -0700)]
Input: synaptics - set resolution for MT_POSITION_X/Y axes
Set resolution for MT_POSITION_X and MT_POSITION_Y to match ABS_X and
ABS_Y, respectively.
Signed-off-by: Daniel Kurtz <djkurtz@chromium.org>
Acked-by: Chase Douglas <chase.douglas@canonical.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Ping Cheng [Thu, 7 Jul 2011 01:05:43 +0000 (18:05 -0700)]
Input: wacom - cleanup a return value for the old Bamboo
The old code may call input_sync() without sending any other events.
While it will be suppressed by the input core not calling it at all
is still cheaper.
Signed-off-by: Ping Cheng <pingc@wacom.com>
Reviewed-by: Chris Bagwell <chris@cnpbagwell.com>
Reviewed-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Ping Cheng [Thu, 7 Jul 2011 01:05:42 +0000 (18:05 -0700)]
Input: wacom - update Graphire4 and old Bamboo tablet buttons
Bamboo touch sets BTN_BACK, BTN_FORWARD, BTN_LEFT, and BTN_RIGHT
as the default button events for tablet buttons. Change Graphire4
and old Bamboo to the same settings.
Signed-off-by: Ping Cheng <pingc@wacom.com>
Reviewed-by: Chris Bagwell <chris@cnpbagwell.com>
Reviewed-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Ping Cheng [Thu, 7 Jul 2011 01:05:41 +0000 (18:05 -0700)]
Input: wacom - add serial number for Graphire4 and old Bamboo
With the removal of BTN_TOOL_FINGER for tablet buttons and
expresskeys, serial number is needed to distingush if the
events were from a regular tool (stylus, eraser, or mouse)
or the attribures (buttons, strips, or wheels) on the tablet
since there are overlapped events between the tools and the
tablet attributes.
Signed-off-by: Ping Cheng <pingc@wacom.com>
Reviewed-by: Chris Bagwell <chris@cnpbagwell.com>
Reviewed-by: Henrik Rydberg <rydberg@euromail.se>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Ping Cheng [Thu, 7 Jul 2011 01:05:41 +0000 (18:05 -0700)]
Input: wacom - remove BTN_TOOL_FINGER for pad
BTN_TOOL_FINGER was designed to indicate a single finger touch.
Remove the lines that borrowed this type for expresskeys and
tablet buttons.
Signed-off-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Chris Hudson [Thu, 7 Jul 2011 01:36:51 +0000 (18:36 -0700)]
Input: add support for Kionix KXTJ9 accelerometer
Signed-off-by: Chris Hudson <chudson@kionix.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Simon Budig [Tue, 5 Jul 2011 02:56:01 +0000 (19:56 -0700)]
Input: add guarding parentheses to macros
Put parentheses around macro argument uses. This avoids pitfalls
for the programmer, where the argument expansion does not give the
expected result, for example:
ioctl (fd, EVIOCGABS (have_mt ? ABS_MT_POSITION_X : ABS_X), &abs);
Signed-off-by: Simon Budig <simon.budig@kernelconcepts.de>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Wolfram Sang [Tue, 5 Jul 2011 02:22:01 +0000 (19:22 -0700)]
Input: wm97xx - mark channels which need pen_down
Currently, battery drivers also use poll_sample() provided by the
wm97xx-core but this code always checks if the pen is down. Mark the
channels which really need this (i.e. for the touchscreen) with the
PEN_DOWN bit, and skip the checks otherwise. Now, the battery channels
can always be read.
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Wolfram Sang [Tue, 5 Jul 2011 02:22:00 +0000 (19:22 -0700)]
Input: wm97xx - refactor channel selection in poll_sample()
The current implementation of poll_sample() has the problem that one of
its arguments, the channel to be selected, differs from wm9713 to other
variants. This parameter gets passed to the (currently unused)
mach-specific functions pre_sample() and post_sample() which thus have
to deal with codec-specific differences. Refactor the routine so that
the argument to poll_sample() is generic for all codecs and do necessary
conversions only in the codec-specific driver. The outcome even uses
less code and removes the non-standard use of the PEN_DOWN bit to mark
the AUX-channels.
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Wolfram Sang [Tue, 5 Jul 2011 02:22:00 +0000 (19:22 -0700)]
Input: wm97xx - remove redundant define
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Stefano Stabellini [Tue, 5 Jul 2011 02:22:00 +0000 (19:22 -0700)]
Input: xen-kbdfront - enable driver for HVM guests
Signed-off-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Acked-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Chris Moeller [Tue, 5 Jul 2011 02:21:59 +0000 (19:21 -0700)]
Input: xpad - enable rumble support for XBox360 Wireless Controllers
This patch implements rumble support for XBox360 Wireless Controllers.
Signed-off-by: Chris Moeller <kode54@gmail.c>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Iiro Valkonen [Mon, 4 Jul 2011 10:16:25 +0000 (03:16 -0700)]
Input: atmel_mxt_ts - handle objects with multiple instances correctly
Handle the objects with multiple instances correctly when the configuration
data is loaded.
Signed-off-by: Iiro Valkonen <iiro.valkonen@atmel.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Iiro Valkonen [Mon, 4 Jul 2011 10:08:25 +0000 (03:08 -0700)]
Input: atmel_mxt_ts - update object list
Update the object list to include new objects, and add unique identifiers
so we can distinguish between old & new generation of the same object.
Signed-off-by: Iiro Valkonen <iiro.valkonen@atmel.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Jiejing Zhang [Wed, 29 Jun 2011 08:28:21 +0000 (01:28 -0700)]
Input: mpr121 - improve sensibility of touch key
The Quick Charge bit in Electrode conf register should be set in init
function. This bit was missed in chip's document, which may cause touch
controller charge too slow to generate an interrupt.
Also, adjust the default vlaue of touch and release threshold
to make touch key more sensitive, this fix touch may not sensitive
after setup with plastic case.
Signed-off-by: Jiejing Zhang <jiejing.zhang@freescale.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Joseph Lai [Mon, 27 Jun 2011 20:26:53 +0000 (13:26 -0700)]
Input: add a driver to support InvenSense mpu3050 gyroscope chip
This driver is registered as an input device. An IRQ is required in this
basic driver configuration.
Signed-off-by: Joseph Lai <joseph_lai@wistron.com>
[Cleaned up PM_RUNTIME defines]
Signed-off-by: Alan Cox <alan@linux.intel.com>
[dtor@mail.ru: consolidated PM methods, some code rearrangement]
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Hans-Christian Egtvedt [Wed, 29 Jun 2011 07:13:26 +0000 (00:13 -0700)]
Input: update author email for gpio_mouse, at32psif, and atmel-wm97xx
This patch updates the email address of the gpio_mouse, at32psif, and
atmel-wm97xx drivers supported by me to an email account I will use on a more
regular basis in the future.
Signed-off-by: Hans-Christian Egtvedt <hans-christian.egtvedt@atmel.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Tue, 28 Jun 2011 21:23:30 +0000 (14:23 -0700)]
Input: gpio_keys - fix a memory leak
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Igor Grinberg [Mon, 27 Jun 2011 20:06:27 +0000 (13:06 -0700)]
Input: ads7846 - cleanup GPIO initialization
Use gpio_request_one() instead of multiple gpiolib calls.
This also simplifies error handling a bit.
Signed-off-by: Igor Grinberg <grinberg@compulab.co.il>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Ping Cheng [Mon, 27 Jun 2011 19:57:58 +0000 (12:57 -0700)]
Input: wacom - add 3 new models - 6A, 6B, and 97
Tested-by: Alex Tervoort <alex.tervoort@gmail.com> for 6A
Signed-off-by: David Foley <favux.is@gmail.com>
Signed-off-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Ping Cheng [Mon, 27 Jun 2011 19:57:58 +0000 (12:57 -0700)]
Input: wacom - Wacom Bamboo Pen D4 has 1024 pressure levels
D4 has 1024, not 512, pressure levels.
Reported-by: David Foley <favux.is@gmail.com>
Signed-off-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
David Jander [Thu, 23 Jun 2011 08:30:09 +0000 (01:30 -0700)]
Input: gpio_keys - move to late_initcall
Initialize gpio_keys driver at late_initcall level, to give it a chance to
work with GPIO expanders that might not be ready yet if we initialize the
driver at module_init time.
This is strictly a band-aid until there is a better way to specify
inter-device dependencies.
Signed-off-by: David Jander <david@protonic.nl>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Mon, 27 Jun 2011 19:42:12 +0000 (12:42 -0700)]
Input: tnetv107x-ts - fix MODULE_ALIAS
Remove the space between "platform:" prefix and the driver name.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Axel Lin [Mon, 27 Jun 2011 19:38:43 +0000 (12:38 -0700)]
Input: tnetv107x-keypad - fix MODULE_ALIAS
Remove the space between "platform:" prefix and the driver name.
Signed-off-by: Axel Lin <axel.lin@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Jesper Juhl [Mon, 27 Jun 2011 18:59:43 +0000 (11:59 -0700)]
Input: remove unneeded version.h includes
It was pointed out by 'make versioncheck' that some includes of
linux/version.h are not needed in drivers/input/.
This patch removes them.
Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Acked-by: Mike Frysinger <vapier@gentoo.org>
Acked-by: Michael Hennerich <michael.hennerich@analog.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Eric Miao [Wed, 22 Jun 2011 08:02:50 +0000 (01:02 -0700)]
Input: add support for mma8450 accelerometer
Signed-off-by: Sammy He <r62914@freescale.com>
Signed-off-by: Eric Miao <eric.miao@linaro.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Aristeu Rozanski [Wed, 22 Jun 2011 08:17:17 +0000 (01:17 -0700)]
Input: wacom - use only one interface with DTU-2231
The Wacom DTU-2231 tablet has two interfaces on its default configuration
and both have HID class, leading to the creation of two input devices
instead of one. Only the first one is used, so filter out the second.
Signed-off-by: Aristeu Rozanski <aris@redhat.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Ping Cheng [Wed, 22 Jun 2011 08:02:51 +0000 (01:02 -0700)]
Input: wacom - Cintiq 21UX2 does not have menu strips
So don't set ABS_RX/ABS_RY for them.
Signed-off-by: Ping Cheng <pingc@wacom.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Magnus Hörlin [Tue, 21 Jun 2011 21:40:30 +0000 (14:40 -0700)]
Input: xpad - add support for two more dance pads and a guitar
Signed-off-by: Magnus Hörlin <magnus@alefors.se>
Reviewed-by: Christoph Fritz <chf.fritz@googlemail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
David Jander [Tue, 21 Jun 2011 21:26:18 +0000 (14:26 -0700)]
Input: gpio_keys - switch to using threaded IRQs
Use a threaded interrupt handler in order to permit the handler to use
a GPIO driver that causes things like I2C transactions being done inside
the handler context.
Signed-off-by: David Jander <david@protonic.nl>
Acked-by: Grant Likely <grant.likely@secretlab.ca>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Leigh Brown [Tue, 21 Jun 2011 11:25:21 +0000 (04:25 -0700)]
Input: lm8323 - use oneshot level triggered interrupts
According to the data sheet the interrupt should be level rather than
edge triggered. This fixes the issue of the Nokia N810 keypad stopping
responding if multiple key events occur in quick succession.
Signed-off-by: Leigh Brown <leigh@solinno.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Felipe Balbi [Tue, 21 Jun 2011 11:20:57 +0000 (04:20 -0700)]
Input: lm8323 - convert to threaded IRQ
There's no need for that workqueue anymore. Get rid of it and move to
threaded IRQs instead.
Signed-off-by: Felipe Balbi <balbi@ti.com>
Tested-by: Leigh Brown <leigh@solinno.co.uk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Wolfram Sang [Tue, 21 Jun 2011 11:20:57 +0000 (04:20 -0700)]
Input: qt1070 - remove obsolete cleanup for clientdata
A few new i2c-drivers came into the kernel which clear the clientdata
pointer on exit or error. This is not required anymore since the core
will do it for us.
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Acked-by: Jean Delvare <khali@linux-fr.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Linus Torvalds [Tue, 21 Jun 2011 03:25:46 +0000 (20:25 -0700)]
Linux 3.0-rc4
Linus Torvalds [Tue, 21 Jun 2011 03:13:49 +0000 (20:13 -0700)]
vfs: i_state needs to be 'unsigned long' for now
Commit
13e12d14e2dc ("vfs: reorganize 'struct inode' layout a bit")
moved things around a bit changed i_state to be unsigned int instead of
unsigned long. That was to help structure layout for the 64-bit case,
and shrink 'struct inode' a bit (admittedly that only happened when
spinlock debugging was on and i_flags didn't pack with i_lock).
However, Meelis Roos reports that this results in unaligned exceptions
on sprc, and it turns out that the bit-locking primitives that we use
for the I_NEW bit want to use the bitops. Which want 'unsigned long',
not 'unsigned int'.
We really should fix the bit locking code to not have that kind of
requirement, but that's a much bigger change. So for now, revert that
field back to 'unsigned long' (but keep the other re-ordering changes
from the commit that caused this).
Andi points out that we have played games with this in 'struct page', so
it's solvable with other hacks too, but since right now the struct inode
size advantage only happens with some rare config options, it's not
worth fighting.
It _would_ be worth fixing the bitlocking code, though. Especially
since there is no type safety in the bitlocking code (this never caused
any warnings, and worked fine on x86-64, because the bitlocks take a
'void *' and x86-64 doesn't care that deeply about alignment). So it's
currently a very easy problem to trigger by mistake and never notice.
Reported-by: Meelis Roos <mroos@linux.ee>
Cc: Andi Kleen <andi@firstfloor.org>
Cc: David Miller <davem@davemloft.net>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Linus Torvalds [Tue, 21 Jun 2011 03:12:48 +0000 (20:12 -0700)]
Merge branch 'drm-fixes' of git://git./linux/kernel/git/airlied/drm-2.6
* 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
drm/radeon/kms/r6xx+: voltage fixes
drm/nouveau: drop leftover debugging
drm/radeon: avoid warnings from r600/eg irq handlers on powered off card.
drm/radeon/kms: add missing param for dce3.2 DP transmitter setup
drm/radeon/kms/atom: fix duallink on some early DCE3.2 cards
drm/nouveau: fix assumption that semaphore dmaobj is valid in x-chan sync
drm/nv50/disp: fix gamma with page flipping overlay turned on
drm/nouveau/pm: Prevent overflow in nouveau_perf_init()
drm/nouveau: fix big-endian switch
Linus Torvalds [Tue, 21 Jun 2011 03:11:34 +0000 (20:11 -0700)]
Merge branch 'msm-fix' of git://codeaurora.org/quic/kernel/davidb/linux-msm
* 'msm-fix' of git://codeaurora.org/quic/kernel/davidb/linux-msm:
msm: timer: Fix DGT rate on 8960 and 8660
msm: timer: compensate for timer shift in msm_read_timer_count
msm: timer: Fix SMP build error
Linus Torvalds [Tue, 21 Jun 2011 03:10:52 +0000 (20:10 -0700)]
Merge branch 'for-2.6.40' of git://linux-nfs.org/~bfields/linux
* 'for-2.6.40' of git://linux-nfs.org/~bfields/linux:
nfsd4: fix break_lease flags on nfsd open
nfsd: link returns nfserr_delay when breaking lease
nfsd: v4 support requires CRYPTO
nfsd: fix dependency of nfsd on auth_rpcgss
Linus Torvalds [Tue, 21 Jun 2011 03:10:18 +0000 (20:10 -0700)]
Merge git://git./linux/kernel/git/davem/net-2.6
* git://git.kernel.org/pub/scm/linux/kernel/git/davem/net-2.6: (40 commits)
pxa168_eth: fix race in transmit path.
ipv4, ping: Remove duplicate icmp.h include
netxen: fix race in skb->len access
sgi-xp: fix a use after free
hp100: fix an skb->len race
netpoll: copy dev name of slaves to struct netpoll
ipv4: fix multicast losses
r8169: fix static initializers.
inet_diag: fix inet_diag_bc_audit()
gigaset: call module_put before restart of if_open()
farsync: add module_put to error path in fst_open()
net: rfs: enable RFS before first data packet is received
fs_enet: fix freescale FCC ethernet dp buffer alignment
netdev: bfin_mac: fix memory leak when freeing dma descriptors
vlan: don't call ndo_vlan_rx_register on hardware that doesn't have vlan support
caif: Bugfix - XOFF removed channel from caif-mux
tun: teach the tun/tap driver to support netpoll
dp83640: drop PHY status frames in the driver.
dp83640: fix phy status frame event parsing
phylib: Allow BCM63XX PHY to be selected only on BCM63XX.
...
Linus Torvalds [Tue, 21 Jun 2011 03:09:15 +0000 (20:09 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/viro/vfs-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/viro/vfs-2.6:
devcgroup_inode_permission: take "is it a device node" checks to inlined wrapper
fix comment in generic_permission()
kill obsolete comment for follow_down()
proc_sys_permission() is OK in RCU mode
reiserfs_permission() doesn't need to bail out in RCU mode
proc_fd_permission() is doesn't need to bail out in RCU mode
nilfs2_permission() doesn't need to bail out in RCU mode
logfs doesn't need ->permission() at all
coda_ioctl_permission() is safe in RCU mode
cifs_permission() doesn't need to bail out in RCU mode
bad_inode_permission() is safe from RCU mode
ubifs: dereferencing an ERR_PTR in ubifs_mount()
Alex Deucher [Mon, 20 Jun 2011 17:00:31 +0000 (13:00 -0400)]
drm/radeon/kms/r6xx+: voltage fixes
0xff01 is not an actual voltage value, but a flag
for the driver. If the power state as that value,
skip setting the voltage.
Signed-off-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
Stephen Boyd [Thu, 21 Apr 2011 23:09:11 +0000 (23:09 +0000)]
msm: timer: Fix DGT rate on 8960 and 8660
The DGT runs at 27 MHz divided by 4 on 8660 and 8960.
Signed-off-by: Stephen Boyd <sboyd@codeaurora.org>
Signed-off-by: David Brown <davidb@codeaurora.org>
Richard Cochran [Sun, 19 Jun 2011 21:48:06 +0000 (21:48 +0000)]
pxa168_eth: fix race in transmit path.
Because the socket buffer is freed in the completion interrupt, it is not
safe to access it after submitting it to the hardware.
Cc: stable@kernel.org
Cc: Sachin Sanap <ssanap@marvell.com>
Cc: Zhangfei Gao <zgao6@marvell.com>
Cc: Philip Rakity <prakity@marvell.com>
Signed-off-by: Richard Cochran <richard.cochran@omicron.at>
Acked-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Jesper Juhl [Sun, 19 Jun 2011 22:31:20 +0000 (22:31 +0000)]
ipv4, ping: Remove duplicate icmp.h include
Remove the duplicate inclusion of net/icmp.h from net/ipv4/ping.c
Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Eric Dumazet [Sun, 19 Jun 2011 20:26:15 +0000 (20:26 +0000)]
netxen: fix race in skb->len access
As soon as skb is given to hardware, TX completion can free skb under
us.
Therefore, we should update dev stats before kicking the device.
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
CC: Amit Kumar Salecha <amit.salecha@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Linus Torvalds [Mon, 20 Jun 2011 16:01:33 +0000 (09:01 -0700)]
Merge branch 'stable/bug.fixes' of git://git./linux/kernel/git/konrad/xen
* 'stable/bug.fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/konrad/xen:
xen/setup: Fix for incorrect xen_extra_mem_start.
xen: When calling power_off, don't call the halt function.
xen: Fix compile warning when CONFIG_SMP is not defined.
xen: support CONFIG_MAXSMP
xen: partially revert "xen: set max_pfn_mapped to the last pfn mapped"
Linus Torvalds [Mon, 20 Jun 2011 15:59:46 +0000 (08:59 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/dtor/input
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
Input: sh_keysc - 8x8 MODE_6 fix
Input: omap-keypad - add missing input_sync()
Input: evdev - try to wake up readers only if we have full packet
Input: properly assign return value of clamp() macro.
Linus Torvalds [Mon, 20 Jun 2011 15:58:53 +0000 (08:58 -0700)]
Merge branch 'for-linus' of git://git./linux/kernel/git/mason/btrfs-unstable
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/mason/btrfs-unstable:
Btrfs: avoid delayed metadata items during commits
btrfs: fix uninitialized return value
btrfs: fix wrong reservation when doing delayed inode operations
btrfs: Remove unused sysfs code
btrfs: fix dereference of ERR_PTR value
Btrfs: fix relocation races
Btrfs: set no_trans_join after trying to expand the transaction
Btrfs: protect the pending_snapshots list with trans_lock
Btrfs: fix path leakage on subvol deletion
Btrfs: drop the delalloc_bytes check in shrink_delalloc
Btrfs: check the return value from set_anon_super
Linus Torvalds [Mon, 20 Jun 2011 15:58:07 +0000 (08:58 -0700)]
Merge branch 'kvm-updates/3.0' of git://git./virt/kvm/kvm
* 'kvm-updates/3.0' of git://git.kernel.org/pub/scm/virt/kvm/kvm:
KVM: Fix register corruption in pvclock_scale_delta
KVM: MMU: fix opposite condition in mapping_level_dirty_bitmap
KVM: VMX: do not overwrite uptodate vcpu->arch.cr3 on KVM_SET_SREGS
KVM: MMU: Fix build warnings in walk_addr_generic()
Al Viro [Sun, 19 Jun 2011 17:01:04 +0000 (13:01 -0400)]
devcgroup_inode_permission: take "is it a device node" checks to inlined wrapper
inode_permission() calls devcgroup_inode_permission() and almost all such
calls are _not_ for device nodes; let's at least keep the common path
straight...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 05:56:53 +0000 (01:56 -0400)]
fix comment in generic_permission()
CAP_DAC_OVERRIDE is enough for MAY_EXEC on directory, even if
no exec bits are set.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Fri, 17 Jun 2011 23:20:48 +0000 (19:20 -0400)]
kill obsolete comment for follow_down()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 00:42:00 +0000 (20:42 -0400)]
proc_sys_permission() is OK in RCU mode
nothing blocking there, since all instances of sysctl
->permissions() method are non-blocking - both of them,
that is.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 00:37:33 +0000 (20:37 -0400)]
reiserfs_permission() doesn't need to bail out in RCU mode
nothing blocking other than generic_permission() (and
check_acl callback does bail out in RCU mode).
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 00:35:23 +0000 (20:35 -0400)]
proc_fd_permission() is doesn't need to bail out in RCU mode
nothing blocking except generic_permission()
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 00:21:44 +0000 (20:21 -0400)]
nilfs2_permission() doesn't need to bail out in RCU mode
Nothing blocking except for generic_permission(). Which will DTRT.
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 00:17:22 +0000 (20:17 -0400)]
logfs doesn't need ->permission() at all
... and never did, what with its ->permission() being what we do by default
when ->permission is NULL...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 00:11:43 +0000 (20:11 -0400)]
coda_ioctl_permission() is safe in RCU mode
return (mask & MAY_EXEC) ? -EACCES : 0; is non-blocking...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sun, 19 Jun 2011 00:03:36 +0000 (20:03 -0400)]
cifs_permission() doesn't need to bail out in RCU mode
nothing potentially blocking except generic_permission(), which
will DTRT
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Al Viro [Sat, 18 Jun 2011 23:59:04 +0000 (19:59 -0400)]
bad_inode_permission() is safe from RCU mode
return -EIO; is *not* a blocking operation, thank you very much.
Nick, what the hell have you been smoking?
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Dan Carpenter [Mon, 20 Jun 2011 07:10:24 +0000 (10:10 +0300)]
ubifs: dereferencing an ERR_PTR in ubifs_mount()
d251ed271d5 "ubifs: fix sget races" left out the goto from this
error path so the static checkers complain that we're dereferencing
"sb" when it's an ERR_PTR.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
J. Bruce Fields [Tue, 7 Jun 2011 15:50:23 +0000 (11:50 -0400)]
nfsd4: fix break_lease flags on nfsd open
Thanks to Casey Bodley for pointing out that on a read open we pass 0,
instead of O_RDONLY, to break_lease, with the result that a read open is
treated like a write open for the purposes of lease breaking!
Reported-by: Casey Bodley <cbodley@citi.umich.edu>
Cc: stable@kernel.org
Signed-off-by: J. Bruce Fields <bfields@redhat.com>
Dave Airlie [Mon, 20 Jun 2011 05:25:35 +0000 (15:25 +1000)]
drm/nouveau: drop leftover debugging
this printk isn't really useful, just drop it for now.
Signed-off-by: Dave Airlie <airlied@redhat.com>
Dave Airlie [Mon, 20 Jun 2011 02:02:38 +0000 (12:02 +1000)]
Merge branch 'drm-nouveau-fixes' of git://anongit.freedesktop.org/git/nouveau/linux-2.6 into drm-fixes
* 'drm-nouveau-fixes' of git://anongit.freedesktop.org/git/nouveau/linux-2.6:
drm/nouveau: fix assumption that semaphore dmaobj is valid in x-chan sync
drm/nv50/disp: fix gamma with page flipping overlay turned on
drm/nouveau/pm: Prevent overflow in nouveau_perf_init()
drm/nouveau: fix big-endian switch
Dave Airlie [Sat, 18 Jun 2011 03:59:51 +0000 (03:59 +0000)]
drm/radeon: avoid warnings from r600/eg irq handlers on powered off card.
Since we were calling the wptr function before checking if the IH was
even enabled, or the GPU wasn't shutdown, we'd get spam in the logs when
the GPU readback 0xffffffff. This reorders things so we return early
in the no IH and GPU shutdown cases.
Reported-and-tested-by: ManDay on #radeon
Reviewed-by: Alex Deucher <alexdeucher@gmail.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>