diff options
author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2010-02-04 03:30:42 -0500 |
---|---|---|
committer | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2010-02-04 03:31:44 -0500 |
commit | 3d7bbd4575cfb23e6ef7368fff1f7d7e198b7930 (patch) | |
tree | acfffe2afc69e59d97c454c5b1429fd980e05b55 /drivers | |
parent | daf8a96b2d4a5d4d1d288831be43457c84c55a2f (diff) |
Input: mark input interfaces as non-seekable
Seeking does not make sense for input interfaces such as evdev and joydev
so let's use nonseekable_open to mark them non-seekable.
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/input/evdev.c | 2 | ||||
-rw-r--r-- | drivers/input/joydev.c | 2 |
2 files changed, 4 insertions, 0 deletions
diff --git a/drivers/input/evdev.c b/drivers/input/evdev.c index 258c639571b5..9f9816baeb97 100644 --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c | |||
@@ -278,6 +278,8 @@ static int evdev_open(struct inode *inode, struct file *file) | |||
278 | goto err_free_client; | 278 | goto err_free_client; |
279 | 279 | ||
280 | file->private_data = client; | 280 | file->private_data = client; |
281 | nonseekable_open(inode, file); | ||
282 | |||
281 | return 0; | 283 | return 0; |
282 | 284 | ||
283 | err_free_client: | 285 | err_free_client: |
diff --git a/drivers/input/joydev.c b/drivers/input/joydev.c index 63e71f2a7acc..c52bec4d0530 100644 --- a/drivers/input/joydev.c +++ b/drivers/input/joydev.c | |||
@@ -286,6 +286,8 @@ static int joydev_open(struct inode *inode, struct file *file) | |||
286 | goto err_free_client; | 286 | goto err_free_client; |
287 | 287 | ||
288 | file->private_data = client; | 288 | file->private_data = client; |
289 | nonseekable_open(inode, file); | ||
290 | |||
289 | return 0; | 291 | return 0; |
290 | 292 | ||
291 | err_free_client: | 293 | err_free_client: |