[patch] input: Fix minor errors in input-programming.txt [12/13]

Vojtech Pavlik (vojtech@suse.cz)
Sat, 14 Jun 2003 22:45:49 +0200


You can pull this changeset from:
bk://kernel.bkbits.net/vojtech/input

===================================================================

ChangeSet@1.1307.5.12, 2003-06-14 14:18:59+02:00, petero2@telia.com
input: fix some minor errors found in the input-programming.txt file

input-programming.txt | 16 ++++++++--------
1 files changed, 8 insertions(+), 8 deletions(-)

===================================================================

diff -Nru a/Documentation/input/input-programming.txt b/Documentation/input/input-programming.txt
--- a/Documentation/input/input-programming.txt Sat Jun 14 22:24:22 2003
+++ b/Documentation/input/input-programming.txt Sat Jun 14 22:24:22 2003
@@ -146,7 +146,7 @@
Note the button_used variable - we have to track how many times the open
function was called to know when exactly our device stops being used.

-The open() callback should return a 0 in case of succes or any nonzero value
+The open() callback should return a 0 in case of success or any nonzero value
in case of failure. The close() callback (which is void) must always succeed.

1.3 Basic event types
@@ -178,7 +178,7 @@
function. Events are generated only for nonzero value.

However EV_ABS requires a little special care. Before calling
-input_register_devices, you have to fill additional fields in the input_dev
+input_register_device, you have to fill additional fields in the input_dev
struct for each absolute axis your device has. If our button device had also
the ABS_X axis:

@@ -207,11 +207,11 @@
1.5 NBITS(), LONG(), BIT()
~~~~~~~~~~~~~~~~~~~~~~~~~~

-These three macros frin input.h help some bitfield computations:
+These three macros from input.h help some bitfield computations:

NBITS(x) - returns the length of a bitfield array in longs for x bits
LONG(x) - returns the index in the array in longs for bit x
- BIT(x) - returns the indes in a long for bit x
+ BIT(x) - returns the index in a long for bit x

1.6 The number, id* and name fields
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -221,7 +221,7 @@
in system messages.

The dev->name should be set before registering the input device by the input
-device driver. It's a string like 'Generic button device' containing an
+device driver. It's a string like 'Generic button device' containing a
user friendly name of the device.

The id* fields contain the bus ID (PCI, USB, ...), vendor ID and device ID
@@ -237,7 +237,7 @@
1.7 The keycode, keycodemax, keycodesize fields
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

-These two fields will be used for any inpur devices that report their data
+These two fields will be used for any input devices that report their data
as scancodes. If not all scancodes can be known by autodetection, they may
need to be set by userland utilities. The keycode array then is an array
used to map from scancodes to input system keycodes. The keycode max will
@@ -258,7 +258,7 @@

The other event types up to now are:

-EV_LED - used for the keyboad LEDs.
+EV_LED - used for the keyboard LEDs.
EV_SND - used for keyboard beeps.

They are very similar to for example key events, but they go in the other
@@ -270,7 +270,7 @@

int button_event(struct input_dev *dev, unsigned int type, unsigned int code, int value);
{
- if (type == EV_SND && code == EV_BELL) {
+ if (type == EV_SND && code == SND_BELL) {
outb(value, BUTTON_BELL);
return 0;
}
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/