[go: nahoru, domu]

History log of /drivers/input/mousedev.c
Revision Date Author Comments
e4dbedc7eac7da9db363a36f2bd4366962eeefcc 06-Mar-2014 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - fix race when creating mixed device

We should not be using static variable mousedev_mix in methods that can be
called before that singleton gets assigned. While at it let's add open and
close methods to mousedev structure so that we do not need to test if we
are dealing with multiplexor or normal device and simply call appropriate
method directly.

This fixes: https://bugzilla.kernel.org/show_bug.cgi?id=71551

Reported-by: GiulioDP <depasquale.giulio@gmail.com>
Tested-by: GiulioDP <depasquale.giulio@gmail.com>
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
c91cb7a75eaf65358aac5ea2b512ac60a9437ff4 16-Nov-2012 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - move /dev/input/mice to the correct minor

When doing conversion to dynamic input numbers I inadvertently moved
/dev/input/mice from c,13,63 to c,13,31. We need to fix this so that
setups with statically populated /dev continue working.

Tested-by: Krzysztof Mazur <krzysiek@podlesie.net>
Tested-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
4a215aade0baa0487d4644d7aef6f166c84c516e 22-Oct-2012 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: fix use-after-free introduced with dynamic minor changes

Commit 7f8d4cad1e4e ("Input: extend the number of event (and other)
devices") made evdev, joydev and mousedev to embed struct cdev into
their respective structures representing input devices.

Unfortunately character device structure may outlive the parent
structure unless we do not set it up as parent of character device so
that it will stay pinned until character device is freed.

Also, now that parent structure is pinned while character device exists
we do not need to pin and unpin it every time user opens or closes it.

Reported-by: Dave Jones <davej@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Acked-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
7f8d4cad1e4e11a45d02bd6e024cc2812963c38a 08-Oct-2012 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: extend the number of event (and other) devices

Extend the amount of character devices, such as eventX, mouseX and jsX,
from a hard limit of 32 per input handler to about 1024 shared across
all handlers.

To be compatible with legacy installations input handlers will start
creating char devices with minors in their legacy range, however once
legacy range is exhausted they will start allocating minors from the
dynamic range 256-1024.

Reviewed-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
0124be49770469cfb258d7df4693e70b4c5fb013 08-Oct-2012 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - mark mousedev interfaces as non-seekable

Seeking does not make sense for mousedev, so let's use nonseekable_open()
to mark its devices as non-seekable.

Reviewed-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
3376b8b753bcc300c4f1b170d01c2fb472889a3d 08-Oct-2012 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - rename mixdev_open to opened_by_mixdev

Do the rename to make the logic more clear and also change it to bool
while at it.

Reviewed-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
1c74585eccbef8fbdac494bfb2abb768aab886d3 08-Oct-2012 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - reformat structure initializers

Reformat structure initializers to match the rest of input handlers

Reviewed-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
a2cb1191f4733134b21918b6098512a2e2e48e61 08-Oct-2012 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - factor out psaux code to reduce #ifdefery

Reviewed-by: David Herrmann <dh.herrmann@googlemail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
41091ad0b8f843d36390058362c8f3c52a26a333 30-Jul-2012 Baodong Chen <chenbdchenbd@gmail.com> Input: random formatting fixes

Fixes for some coding style issues reported by scripts/checkpatch.pl
utility.

Signed-off-by: Baodong Chen <chenbdchenbd@gmail.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
8c127f0717b438e6abc3d92d4ae248c4224b9dcb 25-May-2011 Hans Petter Selasky <hselasky@c2i.net> Input: properly assign return value of clamp() macro.

[dtor@mail.ru: added mousedev changes]
Signed-off-by: Hans Petter Selasky <hselasky@c2i.net>
Cc: stable@kernel.org
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
7cbbb758d3c93b24b45b169af55440d2e7d5b7f6 12-May-2011 Eric Dumazet <eric.dumazet@gmail.com> Input: remove useless synchronize_rcu() calls

There is no need to call synchronize_rcu() after a list insertion,
or a NULL->ptr assignment.

However, the reverse operations do need this call.

Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
da0c490115de026618a7fdcd886602da44392a50 30-Nov-2010 Joe Perches <joe@perches.com> Input: use pr_fmt and pr_<level>

Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
f74eef95e33a07379aa2b950c7f313cbfd55ebbe 13-Oct-2010 Hitoshi Mitake <mitake@dcl.info.waseda.ac.jp> Input: mousedev - correct lockdep annotation

When annotating mutex to avoid false lockdep reports we should not
be using MOUSEDEV_MIX as lock subclass but rather SINGLE_DEPTH_NESTING.

Signed-off-by: Hitoshi Mitake <mitake@dcl.info.waseda.ac.jp>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
6038f373a3dc1f1c26496e60b6c40b164716f07e 15-Aug-2010 Arnd Bergmann <arnd@arndb.de> llseek: automatically add .llseek fop

All file_operations should get a .llseek operation so we can make
nonseekable_open the default for future file operations without a
.llseek pointer.

The three cases that we can automatically detect are no_llseek, seq_lseek
and default_llseek. For cases where we can we can automatically prove that
the file offset is always ignored, we use noop_llseek, which maintains
the current behavior of not returning an error from a seek.

New drivers should normally not use noop_llseek but instead use no_llseek
and call nonseekable_open at open time. Existing drivers can be converted
to do the same when the maintainer knows for certain that no user code
relies on calling seek on the device file.

The generated code is often incorrectly indented and right now contains
comments that clarify for each added line why a specific variant was
chosen. In the version that gets submitted upstream, the comments will
be gone and I will manually fix the indentation, because there does not
seem to be a way to do that using coccinelle.

Some amount of new code is currently sitting in linux-next that should get
the same modifications, which I will do at the end of the merge window.

Many thanks to Julia Lawall for helping me learn to write a semantic
patch that does all this.

===== begin semantic patch =====
// This adds an llseek= method to all file operations,
// as a preparation for making no_llseek the default.
//
// The rules are
// - use no_llseek explicitly if we do nonseekable_open
// - use seq_lseek for sequential files
// - use default_llseek if we know we access f_pos
// - use noop_llseek if we know we don't access f_pos,
// but we still want to allow users to call lseek
//
@ open1 exists @
identifier nested_open;
@@
nested_open(...)
{
<+...
nonseekable_open(...)
...+>
}

@ open exists@
identifier open_f;
identifier i, f;
identifier open1.nested_open;
@@
int open_f(struct inode *i, struct file *f)
{
<+...
(
nonseekable_open(...)
|
nested_open(...)
)
...+>
}

@ read disable optional_qualifier exists @
identifier read_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
expression E;
identifier func;
@@
ssize_t read_f(struct file *f, char *p, size_t s, loff_t *off)
{
<+...
(
*off = E
|
*off += E
|
func(..., off, ...)
|
E = *off
)
...+>
}

@ read_no_fpos disable optional_qualifier exists @
identifier read_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
@@
ssize_t read_f(struct file *f, char *p, size_t s, loff_t *off)
{
... when != off
}

@ write @
identifier write_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
expression E;
identifier func;
@@
ssize_t write_f(struct file *f, const char *p, size_t s, loff_t *off)
{
<+...
(
*off = E
|
*off += E
|
func(..., off, ...)
|
E = *off
)
...+>
}

@ write_no_fpos @
identifier write_f;
identifier f, p, s, off;
type ssize_t, size_t, loff_t;
@@
ssize_t write_f(struct file *f, const char *p, size_t s, loff_t *off)
{
... when != off
}

@ fops0 @
identifier fops;
@@
struct file_operations fops = {
...
};

@ has_llseek depends on fops0 @
identifier fops0.fops;
identifier llseek_f;
@@
struct file_operations fops = {
...
.llseek = llseek_f,
...
};

@ has_read depends on fops0 @
identifier fops0.fops;
identifier read_f;
@@
struct file_operations fops = {
...
.read = read_f,
...
};

@ has_write depends on fops0 @
identifier fops0.fops;
identifier write_f;
@@
struct file_operations fops = {
...
.write = write_f,
...
};

@ has_open depends on fops0 @
identifier fops0.fops;
identifier open_f;
@@
struct file_operations fops = {
...
.open = open_f,
...
};

// use no_llseek if we call nonseekable_open
////////////////////////////////////////////
@ nonseekable1 depends on !has_llseek && has_open @
identifier fops0.fops;
identifier nso ~= "nonseekable_open";
@@
struct file_operations fops = {
... .open = nso, ...
+.llseek = no_llseek, /* nonseekable */
};

@ nonseekable2 depends on !has_llseek @
identifier fops0.fops;
identifier open.open_f;
@@
struct file_operations fops = {
... .open = open_f, ...
+.llseek = no_llseek, /* open uses nonseekable */
};

// use seq_lseek for sequential files
/////////////////////////////////////
@ seq depends on !has_llseek @
identifier fops0.fops;
identifier sr ~= "seq_read";
@@
struct file_operations fops = {
... .read = sr, ...
+.llseek = seq_lseek, /* we have seq_read */
};

// use default_llseek if there is a readdir
///////////////////////////////////////////
@ fops1 depends on !has_llseek && !nonseekable1 && !nonseekable2 && !seq @
identifier fops0.fops;
identifier readdir_e;
@@
// any other fop is used that changes pos
struct file_operations fops = {
... .readdir = readdir_e, ...
+.llseek = default_llseek, /* readdir is present */
};

// use default_llseek if at least one of read/write touches f_pos
/////////////////////////////////////////////////////////////////
@ fops2 depends on !fops1 && !has_llseek && !nonseekable1 && !nonseekable2 && !seq @
identifier fops0.fops;
identifier read.read_f;
@@
// read fops use offset
struct file_operations fops = {
... .read = read_f, ...
+.llseek = default_llseek, /* read accesses f_pos */
};

@ fops3 depends on !fops1 && !fops2 && !has_llseek && !nonseekable1 && !nonseekable2 && !seq @
identifier fops0.fops;
identifier write.write_f;
@@
// write fops use offset
struct file_operations fops = {
... .write = write_f, ...
+ .llseek = default_llseek, /* write accesses f_pos */
};

// Use noop_llseek if neither read nor write accesses f_pos
///////////////////////////////////////////////////////////

@ fops4 depends on !fops1 && !fops2 && !fops3 && !has_llseek && !nonseekable1 && !nonseekable2 && !seq @
identifier fops0.fops;
identifier read_no_fpos.read_f;
identifier write_no_fpos.write_f;
@@
// write fops use offset
struct file_operations fops = {
...
.write = write_f,
.read = read_f,
...
+.llseek = noop_llseek, /* read and write both use no f_pos */
};

@ depends on has_write && !has_read && !fops1 && !fops2 && !has_llseek && !nonseekable1 && !nonseekable2 && !seq @
identifier fops0.fops;
identifier write_no_fpos.write_f;
@@
struct file_operations fops = {
... .write = write_f, ...
+.llseek = noop_llseek, /* write uses no f_pos */
};

@ depends on has_read && !has_write && !fops1 && !fops2 && !has_llseek && !nonseekable1 && !nonseekable2 && !seq @
identifier fops0.fops;
identifier read_no_fpos.read_f;
@@
struct file_operations fops = {
... .read = read_f, ...
+.llseek = noop_llseek, /* read uses no f_pos */
};

@ depends on !has_read && !has_write && !fops1 && !fops2 && !has_llseek && !nonseekable1 && !nonseekable2 && !seq @
identifier fops0.fops;
@@
struct file_operations fops = {
...
+.llseek = noop_llseek, /* no read or write fn */
};
===== End semantic patch =====

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Cc: Julia Lawall <julia@diku.dk>
Cc: Christoph Hellwig <hch@infradead.org>
268ba5c05b82af575819bd719a2facb2a3169260 24-Aug-2010 Christoph Fritz <chf.fritz@googlemail.com> Input: mousedev - fix regression of inverting axes

Introduced by 987a6c0298260b7aa40702b349282554d6180e4b a swap in max/min
calculation gets fixed by this patch.

Reported-by: Bruno Prémont <bonbons@linux-vserver.org>
Signed-off-by: Christoph Fritz <chf.fritz@googlemail.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
987a6c0298260b7aa40702b349282554d6180e4b 03-Aug-2010 Daniel Mack <daniel@caiaq.de> Input: switch to input_abs_*() access functions

Change all call sites in drivers/input to not access the ABS axis
information directly anymore. Make them use the access helpers instead.

Also use input_set_abs_params() when possible.
Did some code refactoring as I was on it.

Signed-off-by: Daniel Mack <daniel@caiaq.de>
Cc: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
4d4bf995ea873cc213c5abc5402af46ef490b8fd 16-Jul-2010 Julien Moutinho <julm+linux@savines.alpes.fr.eu.org> Input: mousedev - signal that device is writable in mousedev_poll()

The Microsoft ImPS/2 mouse protocol being bidirectionnal (sic)
one may have to write in /dev/input/mice; and that works better
if select() does not hang.

Signed-off-by: Julien Moutinho <julm+linux@savines.alpes.fr.eu.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
20da92de8ec3c1d4ba7e5aca322d38b6ce634932 16-Jul-2010 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: change input handlers to use bool when possible

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
c90c6a885ac9827921e8f94f3ce4360ae11148f1 10-Mar-2010 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com> Input: mousedev - remove BKL

There's no need for BKL in mousedev, relevan protection is provided by
a private mutex.

Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Acked-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
a99bbaf5ee6bad1aca0c88ea65ec6e5373e86184 04-Oct-2009 Alexey Dobriyan <adobriyan@gmail.com> headers: remove sched.h from poll.h

Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
3d5cb60ef3042ac479dab82e5a945966a0d54d53 10-May-2009 Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com> Input: simplify name handling for certain input handles

For evdev, joydev and mousedev, instead of having a separate character array
holding name of the handle, use struct devce's name which is the same.

Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@holoscopio.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
60aa49243d09afc873f082567d2e3c16634ced84 01-Feb-2009 Jonathan Corbet <corbet@lwn.net> Rationalize fasync return values

Most fasync implementations do something like:

return fasync_helper(...);

But fasync_helper() will return a positive value at times - a feature used
in at least one place. Thus, a number of other drivers do:

err = fasync_helper(...);
if (err < 0)
return err;
return 0;

In the interests of consistency and more concise code, it makes sense to
map positive return values onto zero where ->fasync() is called.

Cc: Al Viro <viro@ZenIV.linux.org.uk>
Signed-off-by: Jonathan Corbet <corbet@lwn.net>
233e70f4228e78eb2f80dc6650f65d3ae3dbf17c 01-Nov-2008 Al Viro <viro@ZenIV.linux.org.uk> saner FASYNC handling on file close

As it is, all instances of ->release() for files that have ->fasync()
need to remember to evict file from fasync lists; forgetting that
creates a hole and we actually have a bunch that *does* forget.

So let's keep our lives simple - let __fput() check FASYNC in
file->f_flags and call ->fasync() there if it's been set. And lose that
crap in ->release() instances - leaving it there is still valid, but we
don't have to bother anymore.

Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
a6c2490f010d9235b1424110c6f414460e41dfe1 30-Oct-2008 Kay Sievers <kay.sievers@vrfy.org> Input: struct device - replace bus_id with dev_name(), dev_set_name()

Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: Kay Sievers <kay.sievers@vrfy.org>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
f9c8154f367d471f1af56742fe8534f8458adb98 20-May-2008 Arnd Bergmann <arnd@arndb.de> mousedev: BKL pushdown

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
a7097ff89c3204737a07eecbc83f9ae6002cc534 01-Apr-2008 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: make sure input interfaces pin parent input devices

Recent driver core change causes references to parent devices being
dropped early, at device_del() time, as opposed to when all children
are freed. This causes oops in evdev with grabbed devices. Take the
reference to the parent input device ourselves to ensure that it
stays around long enough.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
d182c10c842007984e12b3b816df2b10d997cc8e 30-Jan-2008 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - use BIT_MASK instead of BIT

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
3b04a61107dfe46dbfc1796298b59ca3c0a09cd9 27-Nov-2007 Julia Lawall <julia@diku.dk> Input: drop redundant includes of moduleparam.h

Drop #include <linux/moduleparam.h> in files that also include
linux/module.h, since module.h includes moduleparam.h already.

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
6724f93463c332018e05f538a2ab3ce41eac0e8a 17-Jan-2008 Micah Parrish <micah.parrish@hp.com> Input: mousedev - handle mice that use absolute coordinates

Devices like the HP Integrated Remote Console Virtual Mouse, which are
standard equipment on all Proliant and Integrity servers, produce
absolute coordinates instead of relative coordinates. This is done to
synchronize the position of the mouse cursor on the client desktop
with the mouse cursor position on the server. Mousedev is not
designed to pass those absolute events directly to X, but it can
translate them into relative movements. It currently does this for
tablet like devices and touchpads. This patch merely tells it to also
include a device with ABS_X, ABS_Y, and mouse buttons in its list of
devices to process input for.

This patch enables the mouse pointer to move when using the remote
console.

Signed-off-by: Micah Parrish <micah.parrish@hp.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
7b19ada2ed3c1eccb9fe94d74b05e1428224663d 19-Oct-2007 Jiri Slaby <jirislaby@gmail.com> get rid of input BIT* duplicate defines

get rid of input BIT* duplicate defines

use newly global defined macros for input layer. Also remove includes of
input.h from non-input sources only for BIT macro definiton. Define the
macro temporarily in local manner, all those local definitons will be
removed further in this patchset (to not break bisecting).
BIT macro will be globally defined (1<<x)

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
Cc: <dtor@mail.ru>
Acked-by: Jiri Kosina <jkosina@suse.cz>
Cc: <lenb@kernel.org>
Acked-by: Marcel Holtmann <marcel@holtmann.org>
Cc: <perex@suse.cz>
Acked-by: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: <vernux@us.ibm.com>
Cc: <malattia@linux.it>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
82ba56c273911f7eda79849cfa0fc2d2e5a3b75b 13-Oct-2007 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: use full RCU API

RT guys alerted me to the fact that in their tree spinlocks
are preemptible and it is better to use full RCU API
(rcu_read_lock()/rcu_read_unlock()) to be safe.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
064450140f1eab959bd0eca0245f449993216074 12-Oct-2007 Oliver Neukum <oliver@neukum.org> Input: fix open count handling in input interfaces

If input_open_device() fails we should not leave interfaces marked
as opened.

Signed-off-by: Oliver Neukum <oneukum@suse.de>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
464b241575f3700e14492e34f26bcd1794280f55 30-Aug-2007 Dmitry Torokhov <dmitry.torokhov@gmail.com> Input: mousedev - implement proper locking

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
9657d75c5f0f7d0a9cb507521d3ad1436aea28c9 15-Jun-2007 Dmitry Torokhov <dtor@insightbb.com> Input: convert from class devices to standard devices

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
1dfa2812404c37d7571622195f907cea3331616c 04-Jun-2007 Dmitry Torokhov <dtor@insightbb.com> Input: reduce raciness when input handlers disconnect

There is a race between input handler's release() and disconnect()
methods: when input handler disconnects it wakes up all regular
users and then process to walk user list to wake up async. users.
While disconnect() walks the list release() removes elements of
the same list causing oopses.

While this is not a substibute for proper locking we can reduce
odds of getting an oops if we wake up normal readers after walking
the list.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
e63340ae6b6205fef26b40a75673d1c9c0c8bb90 08-May-2007 Randy Dunlap <randy.dunlap@oracle.com> header cleaning: don't include smp_lock.h when not used

Remove includes of <linux/smp_lock.h> where it is not used/needed.
Suggested by Al Viro.

Builds cleanly on x86_64, i386, alpha, ia64, powerpc, sparc,
sparc64, and arm (all 59 defconfigs).

Signed-off-by: Randy Dunlap <randy.dunlap@oracle.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
823bccfc4002296ba88c3ad0f049e1abd8108d30 13-Apr-2007 Greg Kroah-Hartman <gregkh@suse.de> remove "struct subsystem" as it is no longer needed

We need to work on cleaning up the relationship between kobjects, ksets and
ktypes. The removal of 'struct subsystem' is the first step of this,
especially as it is not really needed at all.

Thanks to Kay for fixing the bugs in this patch.

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
0d9d93c411c9351ba186f5ec910b10da7c1d9d14 12-Apr-2007 Dmitry Torokhov <dtor@insightbb.com> Input: mousedev - fix sudden warps with touchpads

Pete Zaitcev reports that with his touchpad, if he lifts the finger
and places it elsewhere, the pointer sometimes warps dramatically.
This happens because we don't store coordinates unless we detect a
touch so sometimes we have stale coordinates in queue (from where
the finger left the pad) and averaging makes cursor to jump across
the screen. The solution is to always store the latest coordinates.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
d542ed82fdc72cf63549deec19e86ee4addf2499 12-Apr-2007 Dmitry Torokhov <dtor@insightbb.com> Input: handlers - handle errors from input_open_device()

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
d0ffb9be866519775da19c0a6790f5431c1a8dc6 12-Apr-2007 Dmitry Torokhov <dtor@insightbb.com> Input: handlers - rename 'list' to 'client'

The naming convention in input handlers was very confusing -
client stuctures were called lists, regular lists were also
called lists making anyone looking at the code go mad.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
5b2a08262a8c952fef008154933953f083ca5766 12-Apr-2007 Dmitry Torokhov <dtor@insightbb.com> Input: rework handle creation code

- consolidate code for binding handlers to a device
- return error codes from handlers connect() methods back to input
core and log failures

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
6c595fb12fa6c1fe382cc086fdade4acd93c643f 17-Nov-2006 Marton Nemeth <nm127@freemail.hu> Input: mousedev - remap BTN_FORWARD from BTN_LEFT to BTN_MIDDLE

In mousedev the BTN_LEFT and BTN_FORWARD were mapped to mouse button 0,
causing that the user space program cannot distinguish between them through
/dev/input/mice. All mice have BTN_LEFT, but not all have BTN_MIDDLE (e.g.
Clevo D410J laptop). Mapping BTN_FORWARD to mouse button 2 makes the
BTN_FORWARD button useful on this laptop.

Signed-off-by: Marton Nemeth <nm127@freemail.hu>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
4263cf0fac28122c8381b6f4f9441a43cd93c81f 14-Sep-2006 Dmitry Torokhov <dtor@insightbb.com> Input: make input_register_handler() return error codes

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
66e66118837ed95a299328437c2d9fb4b5137352 14-Sep-2006 Dmitry Torokhov <dtor@insightbb.com> Input: constify input core

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
6ab3d5624e172c553004ecc862bfeac16d9d68b7 30-Jun-2006 Jörn Engel <joern@wohnheim.fh-wedel.de> Remove obsolete #include <linux/config.h>

Signed-off-by: Jörn Engel <joern@wohnheim.fh-wedel.de>
Signed-off-by: Adrian Bunk <bunk@stusta.de>
1e0afb288e56d469ca1c583342bb9782d49333c6 26-Jun-2006 Dmitry Torokhov <dtor_core@ameritech.net> Input: fix formatting to better follow CodingStyle

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
b39787a972042ded183343b177d9c595b5704575 14-Mar-2006 Eric Sesterhenn <snakebyte@gmx.de> Input: use kzalloc() throughout the code

Signed-off-by: Eric Sesterhenn <snakebyte@gmx.de>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
74570d413cbb5cede06a0183a91d3006f134bf6b 30-Jan-2006 Kimball Murray <kimball.murray@stratus.com> Input: mousedev - fix memory leak

Apparently, "while true; do cat </dev/null >/dev/input/mice; done" causes
an OOM in a short amount of time. Funny that nobody noticed, it actually
is very easy to trigger just by switching between VT1 and VT7...

Signed-off-by: Pete Zaitcev <zaitcev@redhat.com>
Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
84c12b2410ea3b88523270064222fbf505dbf15e 11-Dec-2005 Dmitry Torokhov <dtor_core@ameritech.net> Input: mousedev - make module parameters visible in sysfs

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
c9bcd582dfeec845b83bc948a430c9958bf839e6 28-Oct-2005 Greg Kroah-Hartman <gregkh@suse.de> [PATCH] INPUT: Create symlinks for backwards compatibility

This creates symlinks in /sys/class/input/ to the nested class devices
to help userspace cope with the nesting.

Unfortunatly udev still needs to be updated as it can't handle symlinks
properly here :(

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
ea9f240bd819f9299703283e5326da606bbb4b05 28-Oct-2005 Greg Kroah-Hartman <gregkh@suse.de> [PATCH] INPUT: rename input_dev_class to input_class to be correct.

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
967ca692161d8c4e894932599592af8d62c0a895 28-Oct-2005 Greg Kroah-Hartman <gregkh@suse.de> [PATCH] INPUT: move the input class devices under their new input_dev devices

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
4f00469c16b86a3dd6ed66b28c605c8430d58eeb 15-Sep-2005 Dmitry Torokhov <dtor_core@ameritech.net> [PATCH] Input: kill devfs references

Input: remove references to devfs from input subsystem

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
53f4654272df7c51064825024340554b39c9efba 28-Oct-2005 Greg Kroah-Hartman <gregkh@suse.de> [PATCH] Driver Core: fix up all callers of class_device_create()

The previous patch adding the ability to nest struct class_device
changed the paramaters to the call class_device_create(). This patch
fixes up all in-kernel users of the function.

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
1235686f6e67cf30c460eb77d90a6cb4be57b92f 15-Mar-2005 gregkh@suse.de <gregkh@suse.de> [PATCH] INPUT: move to use the new class code, instead of class_simple

Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
8121152c1770ef1cd029030d51802c65c489950d 01-Jun-2005 Dmitry Torokhov <dtor_core@ameritech.net> Input: mousedev - do not wake up readers when receiving 0-motion
event.

Signed-off-by: Dmitry Torokhov <dtor@mail.ru>
c1e4c8d3ee3300f363a52fd4cf3d90fdf5098f5a 27-May-2005 Pavel Machek <pavel@suse.cz> [PATCH] fix jumpy mouse cursor on console

Do not send empty events to gpm. (Keyboards are assumed to have scroll
wheel these days, that makes them part-mouse. That means typing on
keyboard generates empty mouse events).

From: Dmitry Torokhov <dtor_core@ameritech.net>
Signed-off-by: Pavel Machek <pavel@suse.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 17-Apr-2005 Linus Torvalds <torvalds@ppc970.osdl.org> Linux-2.6.12-rc2

Initial git repository build. I'm not bothering with the full history,
even though we have it. We can create a separate "historical" git
archive of that later if we want to, and in the meantime it's about
3.2GB when imported into git - space that would just make the early
git days unnecessarily complicated, when we don't have a lot of good
infrastructure for it.

Let it rip!