Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit d6879837 authored by Linus Torvalds's avatar Linus Torvalds
Browse files
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input:
  Input: remove scan_keyb driver
  Input: i8042 - fix AUX IRQ delivery check
  Input: wistron - add support for Fujitsu-Siemens Amilo D88x0
  Input: inport - use correct config option for ATIXL
  Input: HIL - handle erros from input_register_device()
  Input: tsdev - schedule removal
  Input: add Atlas button driver
  Input: ads7846 - be more compatible with the hwmon framework
  Input: ads7846 - detect pen up from GPIO state
  Input: ads7846 - select correct SPI mode
  Input: ads7846 - switch to using hrtimer
  Input: ads7846 - optionally leave Vref on during differential measurements
  Input: ads7846 - pluggable filtering logic
  Input: gpio-keys - keyboard driver for GPIO buttons
  Input: hid-ff - add support for Logitech Momo racing wheel
  Input: i8042 - really suppress ACK/NAK during panic blink
  Input: pc110pad - return proper error
parents 412ecd77 2a598df5
Loading
Loading
Loading
Loading
+15 −0
Original line number Diff line number Diff line
@@ -319,3 +319,18 @@ Why: In kernel tree version of driver is unmaintained. Sk98lin driver
	replaced by the skge driver. 
Who:    Stephen Hemminger <shemminger@osdl.org>

---------------------------

What:	Compaq touchscreen device emulation
When:	Oct 2007
Files:	drivers/input/tsdev.c
Why:	The code says it was obsolete when it was written in 2001.
	tslib is a userspace library which does anything tsdev can do and
	much more besides in userspace where this code belongs. There is no
	longer any need for tsdev and applications should have converted to
	use tslib by now.
	The name "tsdev" is also extremely confusing and lots of people have
	it loaded when they don't need/use it.
Who:	Richard Purdie <rpurdie@rpsys.net>

---------------------------

drivers/char/scan_keyb.c

deleted100644 → 0
+0 −149
Original line number Diff line number Diff line
/*
 *	$Id: scan_keyb.c,v 1.2 2000/07/04 06:24:42 yaegashi Exp $ 
 *	Copyright (C) 2000 YAEGASHI Takeshi
 *	Generic scan keyboard driver
 */

#include <linux/spinlock.h>
#include <linux/sched.h>
#include <linux/interrupt.h>
#include <linux/tty.h>
#include <linux/mm.h>
#include <linux/signal.h>
#include <linux/init.h>
#include <linux/kbd_ll.h>
#include <linux/delay.h>
#include <linux/random.h>
#include <linux/poll.h>
#include <linux/miscdevice.h>
#include <linux/slab.h>
#include <linux/kbd_kern.h>
#include <linux/timer.h>

#define SCANHZ	(HZ/20)

struct scan_keyboard {
	struct scan_keyboard *next;
	int (*scan)(unsigned char *buffer);
	const unsigned char *table;
	unsigned char *s0, *s1;
	int length;
};

static int scan_jiffies=0;
static struct scan_keyboard *keyboards=NULL;
struct timer_list scan_timer;

static void check_kbd(const unsigned char *table,
		      unsigned char *new, unsigned char *old, int length)
{
	int need_tasklet_schedule=0;
	unsigned int xor, bit;
	
	while(length-->0) {
		if((xor=*new^*old)==0) {
			table+=8;
		}
		else {
			for(bit=0x01; bit<0x100; bit<<=1) {
				if(xor&bit) {
					handle_scancode(*table, !(*new&bit));
					need_tasklet_schedule=1;
#if 0
					printk("0x%x %s\n", *table, (*new&bit)?"released":"pressed");
#endif
				}
				table++;
			}
		}
		new++; old++;
	}

	if(need_tasklet_schedule)
		tasklet_schedule(&keyboard_tasklet);
}


static void scan_kbd(unsigned long dummy)
{
	struct scan_keyboard *kbd;

	scan_jiffies++;

	for(kbd=keyboards; kbd!=NULL; kbd=kbd->next) {
		if(scan_jiffies&1) {
			if(!kbd->scan(kbd->s0))
				check_kbd(kbd->table,
					  kbd->s0, kbd->s1, kbd->length);
			else
				memcpy(kbd->s0, kbd->s1, kbd->length);
		}
		else {
			if(!kbd->scan(kbd->s1))
				check_kbd(kbd->table,
					  kbd->s1, kbd->s0, kbd->length);
			else
				memcpy(kbd->s1, kbd->s0, kbd->length);
		}
		
	}

	init_timer(&scan_timer);
	scan_timer.expires = jiffies + SCANHZ;
	scan_timer.data = 0;
	scan_timer.function = scan_kbd;
	add_timer(&scan_timer);
}


int register_scan_keyboard(int (*scan)(unsigned char *buffer),
			   const unsigned char *table,
			   int length)
{
	struct scan_keyboard *kbd;

	kbd = kmalloc(sizeof(struct scan_keyboard), GFP_KERNEL);
	if (kbd == NULL)
		goto error_out;

	kbd->scan=scan;
	kbd->table=table;
	kbd->length=length;

	kbd->s0 = kmalloc(length, GFP_KERNEL);
	if (kbd->s0 == NULL)
		goto error_free_kbd;

	kbd->s1 = kmalloc(length, GFP_KERNEL);
	if (kbd->s1 == NULL)
		goto error_free_s0;

	memset(kbd->s0, -1, kbd->length);
	memset(kbd->s1, -1, kbd->length);
	
	kbd->next=keyboards;
	keyboards=kbd;

	return 0;

 error_free_s0:
	kfree(kbd->s0);

 error_free_kbd:
	kfree(kbd);

 error_out:
	return -ENOMEM;
}
			      
			      
void __init scan_kbd_init(void)
{
	init_timer(&scan_timer);
	scan_timer.expires = jiffies + SCANHZ;
	scan_timer.data = 0;
	scan_timer.function = scan_kbd;
	add_timer(&scan_timer);

	printk(KERN_INFO "Generic scan keyboard driver initialized\n");
}

drivers/char/scan_keyb.h

deleted100644 → 0
+0 −15
Original line number Diff line number Diff line
#ifndef	__DRIVER_CHAR_SCAN_KEYB_H
#define	__DRIVER_CHAR_SCAN_KEYB_H
/*
 *	$Id: scan_keyb.h,v 1.1 2000/06/10 21:45:30 yaegashi Exp $
 *	Copyright (C) 2000 YAEGASHI Takeshi
 *	Generic scan keyboard driver
 */

int register_scan_keyboard(int (*scan)(unsigned char *buffer),
			   const unsigned char *table,
			   int length);

void __init scan_kbd_init(void);

#endif
+16 −3
Original line number Diff line number Diff line
@@ -214,4 +214,17 @@ config KEYBOARD_AAED2000
	  To compile this driver as a module, choose M here: the
	  module will be called aaed2000_kbd.

config KEYBOARD_GPIO
        tristate "Buttons on CPU GPIOs (PXA)"
        depends on ARCH_PXA
	help
	  This driver implements support for buttons connected
	  directly to GPIO pins of PXA CPUs.

	  Say Y here if your device has buttons connected
	  directly to GPIO pins of the CPU.

	  To compile this driver as a module, choose M here: the
	  module will be called gpio-keys.

endif
+3 −2
Original line number Diff line number Diff line
@@ -18,4 +18,5 @@ obj-$(CONFIG_KEYBOARD_HIL) += hil_kbd.o
obj-$(CONFIG_KEYBOARD_HIL_OLD)		+= hilkbd.o
obj-$(CONFIG_KEYBOARD_OMAP)		+= omap-keypad.o
obj-$(CONFIG_KEYBOARD_AAED2000)		+= aaed2000_kbd.o
obj-$(CONFIG_KEYBOARD_GPIO)		+= gpio_keys.o
Loading