X-Git-Url: http://pilppa.org/gitweb/?a=blobdiff_plain;f=Documentation%2Finput%2Finput-programming.txt;h=81905e81585e2de04f9b80a658fb087013acd147;hb=c00f08d705e149fbfaf7a252b4d4fbb7affdcc96;hp=4d932dc660982d34fe488a2e9d8f10957a4d030b;hpb=804b908adfcffe3831621acb6c8a776585983d2a;p=linux-2.6-omap-h63xx.git diff --git a/Documentation/input/input-programming.txt b/Documentation/input/input-programming.txt index 4d932dc6609..81905e81585 100644 --- a/Documentation/input/input-programming.txt +++ b/Documentation/input/input-programming.txt @@ -22,7 +22,7 @@ static struct input_dev *button_dev; static void button_interrupt(int irq, void *dummy, struct pt_regs *fp) { - input_report_key(button_dev, BTN_1, inb(BUTTON_PORT) & 1); + input_report_key(button_dev, BTN_0, inb(BUTTON_PORT) & 1); input_sync(button_dev); } @@ -79,7 +79,7 @@ In the _init function, which is called either upon module load or when booting the kernel, it grabs the required resources (it should also check for the presence of the device). -Then it allocates a new input device structure with input_aloocate_device() +Then it allocates a new input device structure with input_allocate_device() and sets up input bitfields. This way the device driver tells the other parts of the input systems what it is - what events can be generated or accepted by this input device. Our example device can only generate EV_KEY