aboutsummaryrefslogtreecommitdiff
path: root/drivers/input/evdev.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2006-06-26 11:01:58 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2006-06-26 11:01:58 -0700
commitcdf4f383a4b0ffbf458f65380ecffbeee1f79841 (patch)
tree8093cb3dbeda8827ca8b782f29474af523439c55 /drivers/input/evdev.c
parent954b36d48b495afed2880320750858a2eae312c9 (diff)
parente2e8115b54aa6f159ac3dfec8d3d23b0af5fbfa0 (diff)
Merge master.kernel.org:/pub/scm/linux/kernel/git/dtor/input
* master.kernel.org:/pub/scm/linux/kernel/git/dtor/input: Input: iforce - remove some pointless casts Input: psmouse - add support for Intellimouse 4.0 Input: atkbd - fix HANGEUL/HANJA keys Input: fix misspelling of Hangeul key Input: via-pmu - add input device support Input: rearrange exports Input: fix formatting to better follow CodingStyle Input: reset name, phys and uniq when unregistering Input: return correct size when reading modalias attribute Input: change my e-mail address in MAINTAINERS file Input: fix potential overflows in driver/input/keyboard Input: fix potential overflows in driver/input/touchscreen Input: fix potential overflows in driver/input/joystick Input: fix potential overflows in driver/input/mouse Input: fix accuracy of fixp-arith.h Input: iforce - use ENOSPC instead of ENOMEM Input: constify drivers/char/keyboard.c
Diffstat (limited to 'drivers/input/evdev.c')
-rw-r--r--drivers/input/evdev.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c
index 5f561fce32d..a29d5ceb00c 100644
--- a/drivers/input/evdev.c
+++ b/drivers/input/evdev.c
@@ -78,14 +78,19 @@ static int evdev_fasync(int fd, struct file *file, int on)
{
int retval;
struct evdev_list *list = file->private_data;
+
retval = fasync_helper(fd, file, on, &list->fasync);
+
return retval < 0 ? retval : 0;
}
-static int evdev_flush(struct file * file, fl_owner_t id)
+static int evdev_flush(struct file *file, fl_owner_t id)
{
struct evdev_list *list = file->private_data;
- if (!list->evdev->exist) return -ENODEV;
+
+ if (!list->evdev->exist)
+ return -ENODEV;
+
return input_flush_device(&list->evdev->handle, file);
}
@@ -300,6 +305,7 @@ static ssize_t evdev_read(struct file * file, char __user * buffer, size_t count
static unsigned int evdev_poll(struct file *file, poll_table *wait)
{
struct evdev_list *list = file->private_data;
+
poll_wait(file, &list->evdev->wait, wait);
return ((list->head == list->tail) ? 0 : (POLLIN | POLLRDNORM)) |
(list->evdev->exist ? 0 : (POLLHUP | POLLERR));