diff options
author | nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-03-14 15:52:42 +0000 |
---|---|---|
committer | nbd <nbd@3c298f89-4303-0410-b956-a3cf2f4a3e73> | 2009-03-14 15:52:42 +0000 |
commit | 26e3776a22bf894ced5af4c28968dc1dc99968eb (patch) | |
tree | 2d38a3789e27a423439c37a45a09cae31990a615 /target/linux/s3c24xx/patches-2.6.24/1131-fix-jack-interrupt-debounce-loss-window.patch.patch | |
parent | 4bd70fc26256cf485f19e0c8b881e078dc36134f (diff) |
nuke obsolete kernel stuff
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@14875 3c298f89-4303-0410-b956-a3cf2f4a3e73
Diffstat (limited to 'target/linux/s3c24xx/patches-2.6.24/1131-fix-jack-interrupt-debounce-loss-window.patch.patch')
-rw-r--r-- | target/linux/s3c24xx/patches-2.6.24/1131-fix-jack-interrupt-debounce-loss-window.patch.patch | 82 |
1 files changed, 0 insertions, 82 deletions
diff --git a/target/linux/s3c24xx/patches-2.6.24/1131-fix-jack-interrupt-debounce-loss-window.patch.patch b/target/linux/s3c24xx/patches-2.6.24/1131-fix-jack-interrupt-debounce-loss-window.patch.patch deleted file mode 100644 index b2a49ed21b..0000000000 --- a/target/linux/s3c24xx/patches-2.6.24/1131-fix-jack-interrupt-debounce-loss-window.patch.patch +++ /dev/null @@ -1,82 +0,0 @@ -From 4c445577b8f471612389007e5265c7dbfb2c487b Mon Sep 17 00:00:00 2001 -From: Andy Green <andy@openmoko.com> -Date: Sun, 13 Apr 2008 07:25:59 +0100 -Subject: [PATCH] fix-jack-interrupt-debounce-loss-window.patch - -Make sure we can't lose a jack interrupt in debounce, despite it is -a one-in-a-million thing that just needs replug to clear - -Signed-off-by: Andy Green <andy@openmoko.com> ---- - drivers/input/keyboard/neo1973kbd.c | 50 +++++++++++++++++++++++----------- - 1 files changed, 34 insertions(+), 16 deletions(-) - -diff --git a/drivers/input/keyboard/neo1973kbd.c b/drivers/input/keyboard/neo1973kbd.c -index a1fc7a3..8b9a420 100644 ---- a/drivers/input/keyboard/neo1973kbd.c -+++ b/drivers/input/keyboard/neo1973kbd.c -@@ -62,27 +62,45 @@ static irqreturn_t neo1973kbd_hold_irq(int irq, void *dev_id) - static void neo1973kbd_debounce_jack(struct work_struct *work) - { - struct neo1973kbd *kbd = container_of(work, struct neo1973kbd, work); -- -- /* we wait out any multiple interrupt stuttering in 100ms lumps */ -+ unsigned long flags; -+ int loop = 0; - - do { -- kbd->hp_irq_count_in_work = kbd->hp_irq_count; -- msleep(100); -- } while (kbd->hp_irq_count != kbd->hp_irq_count_in_work); -- -- /* no new interrupts on jack for 100ms... ok we will report it */ -- -- input_report_switch(kbd->input, -- SW_HEADPHONE_INSERT, -- gpio_get_value(irq_to_gpio(kbd->jack_irq))); -- input_sync(kbd->input); -- -- /* next time we get an interrupt on jack we need new work action */ -- kbd->work_in_progress = 0; -+ /* -+ * we wait out any multiple interrupt -+ * stuttering in 100ms lumps -+ */ -+ do { -+ kbd->hp_irq_count_in_work = kbd->hp_irq_count; -+ msleep(100); -+ } while (kbd->hp_irq_count != kbd->hp_irq_count_in_work); -+ /* -+ * no new interrupts on jack for 100ms... -+ * ok we will report it -+ */ -+ input_report_switch(kbd->input, SW_HEADPHONE_INSERT, -+ gpio_get_value(irq_to_gpio(kbd->jack_irq))); -+ input_sync(kbd->input); -+ /* -+ * we go around the outer loop again if we detect that more -+ * interrupts came while we are servicing here. But we have -+ * to sequence it carefully with interrupts off -+ */ -+ local_save_flags(flags); -+ /* no interrupts during this work means we can exit the work */ -+ loop = !!(kbd->hp_irq_count != kbd->hp_irq_count_in_work); -+ if (!loop) -+ kbd->work_in_progress = 0; -+ local_irq_restore(flags); -+ /* -+ * interrupt that comes here will either queue a new work action -+ * since work_in_progress is cleared now, or be dealt with -+ * when we loop. -+ */ -+ } while (loop); - } - - -- - static irqreturn_t neo1973kbd_headphone_irq(int irq, void *dev_id) - { - struct neo1973kbd *neo1973kbd_data = dev_id; --- -1.5.6.5 - |