From: <mar...@us...> - 2007-06-22 01:35:01
|
Revision: 1042 http://svn.sourceforge.net/hackndev/?rev=1042&view=rev Author: marex_z71 Date: 2007-06-21 18:34:51 -0700 (Thu, 21 Jun 2007) Log Message: ----------- PalmT3: remove deprecated palmt3_ts driver Modified Paths: -------------- linux4palm/linux/trunk/drivers/input/touchscreen/Makefile Removed Paths: ------------- linux4palm/linux/trunk/drivers/input/touchscreen/palmt3_ts.c Modified: linux4palm/linux/trunk/drivers/input/touchscreen/Makefile =================================================================== --- linux4palm/linux/trunk/drivers/input/touchscreen/Makefile 2007-06-21 23:57:54 UTC (rev 1041) +++ linux4palm/linux/trunk/drivers/input/touchscreen/Makefile 2007-06-22 01:34:51 UTC (rev 1042) @@ -17,7 +17,6 @@ obj-$(CONFIG_TOUCHSCREEN_MTOUCH) += mtouch.o obj-$(CONFIG_TOUCHSCREEN_MK712) += mk712.o obj-$(CONFIG_TOUCHSCREEN_HP600) += hp680_ts_input.o -obj-$(CONFIG_PALM_T3_TSC2101) += palmt3_ts.o obj-$(CONFIG_TOUCHSCREEN_WM97XX) += wm97xx-ts.o wm97xx-ts-objs := wm97xx-core.o Deleted: linux4palm/linux/trunk/drivers/input/touchscreen/palmt3_ts.c =================================================================== --- linux4palm/linux/trunk/drivers/input/touchscreen/palmt3_ts.c 2007-06-21 23:57:54 UTC (rev 1041) +++ linux4palm/linux/trunk/drivers/input/touchscreen/palmt3_ts.c 2007-06-22 01:34:51 UTC (rev 1042) @@ -1,122 +0,0 @@ -/* - * Palm T|T3 touchscreen support - * - * Author: - * Vladimir "Farcaller" Pouzanov <far...@gm...> - * - * Based on tsc2101_ts.c by Richard Purdie - */ - -/* FIXME do I really need all those headers? */ -#include <linux/init.h> -#include <linux/kernel.h> -#include <asm/mach-types.h> -#include <asm/mach/arch.h> -#include <linux/interrupt.h> -#include <asm/arch/pxa-regs.h> -#include <asm/arch/pxa_keys.h> -#include <asm/arch/ssp.h> -#include <asm/arch/irqs.h> -#include <linux/sched.h> -#include <linux/workqueue.h> -#include <asm/hardware.h> -//#include "palmt3_ts.h" - -#define PALMT3_GPIO_TSC2101_SS 24 -#define PALMT3_GPIO_TOUCHSCREEN 37 - -/* FIXME Find more correct values? */ -#define X_AXIS_MAX 3800 -#define X_AXIS_MIN 300 -#define Y_AXIS_MAX 3900 -#define Y_AXIS_MIN 140 -#define PRESSURE_MIN 0 -#define PRESSURE_MAX 20000 - -void palmt3_tsc2101_readdata(void *ts_data); -struct tsc2101_ts_data { - int x,y,p; -}; -extern struct tsc2101_ts_data palmt3_ts_data; - -static struct input_dev inputdevice; - -/* static struct workqueue_struct *palmt3_ts_wq; */ -static struct timer_list palmt3_ts_timer; - -/*** IRQ handlers ***/ -static void palmt3_ts_handle(void* unused) -{ - palmt3_tsc2101_readdata(0); - - input_report_abs(&inputdevice, ABS_X, palmt3_ts_data.x); - input_report_abs(&inputdevice, ABS_Y, palmt3_ts_data.y); - input_report_abs(&inputdevice, ABS_PRESSURE, palmt3_ts_data.p); - input_report_key(&inputdevice, BTN_TOUCH, 1); - input_sync(&inputdevice); -} - -irqreturn_t palmt3_ts_irq(int irq, void *dev_id, struct pt_regs *regs) -{ - /* FIXME The first method seems to generate too much points - * But the second one is too slow... maybe try something other - * then HZ/4? - */ - - /* - static int initialised = 0; - static struct work_struct task; - - if (initialised == 0) { - INIT_WORK(&task, palmt3_ts_handle, NULL); - initialised = 1; - } else { - PREPARE_WORK(&task, palmt3_ts_handle, NULL); - } - - queue_work(palmt3_ts_wq, &task); - */ - mod_timer(&palmt3_ts_timer, jiffies + HZ/16); - return IRQ_HANDLED; -} - -static int __init palmt3_ts_init(void) -{ - init_input_dev(&inputdevice); - inputdevice.name = "tsc2101_ts"; - inputdevice.evbit[0] = BIT(EV_KEY) | BIT(EV_ABS); - inputdevice.keybit[LONG(BTN_TOUCH)] |= BIT(BTN_TOUCH); - input_set_abs_params(&inputdevice, ABS_X, X_AXIS_MIN, X_AXIS_MAX, 0, 0); - input_set_abs_params(&inputdevice, ABS_Y, Y_AXIS_MIN, Y_AXIS_MAX, 0, 0); - input_set_abs_params(&inputdevice, ABS_PRESSURE, PRESSURE_MIN, PRESSURE_MAX, 0, 0); - input_register_device(&inputdevice); - - printk("tsc2101 touchscreen driver registered\n"); - - /* palmt3_ts_wq = create_workqueue("T3 Touchscreen"); */ - init_timer(&palmt3_ts_timer); - palmt3_ts_timer.function = palmt3_ts_handle; - palmt3_ts_timer.data = 0; - - if(request_irq(IRQ_GPIO(PALMT3_GPIO_TOUCHSCREEN), palmt3_ts_irq, - SA_SAMPLE_RANDOM, "T3 Touchscreen GPIO", NULL)) { - printk(KERN_ERR "palmt3_ts: Unable to register GPIO handler for %d\n", PALMT3_GPIO_TSC2101_SS); - } else { - set_irq_type (IRQ_GPIO(PALMT3_GPIO_TOUCHSCREEN), IRQT_BOTHEDGE); - printk(KERN_INFO "palmt3_ts: Touchscreen GPIO registered\n"); - } - - printk("tsc2101 touchscreen driver initialized\n"); - return 0; -} - -static void __exit palmt3_ts_cleanup(void) -{ - /* FIXME Unreg stuff */ - printk(KERN_INFO "palmt3_ts: cleanup\n"); -} - -module_init(palmt3_ts_init); -module_exit(palmt3_ts_cleanup); - -MODULE_LICENCE("GPL"); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |