Lines Matching +full:button +full:- +full:up
1 // SPDX-License-Identifier: GPL-2.0-only
3 * NetWinder Button Driver-
22 #include <asm/mach-types.h>
29 static int button_press_count; /* The count of button presses */
42 * to be called when a particular number of button presses occurs.
45 * to be performed by the kernel on different numbers of button presses ;).
48 * do so and return -ENOMEM. If an attempt is made to register a null pointer,
49 * it will fail to do so and return -EINVAL.
61 return -ENOMEM; in button_add_callback()
64 return -EINVAL; in button_add_callback()
76 * with -EINVAL. If there is more than one entry with the same address,
78 * last one to be registered first (FILO- First In Last Out).
89 return -EINVAL; in button_del_callback()
95 callback_count--; in button_del_callback()
98 lp--; in button_del_callback()
100 return -EINVAL; in button_del_callback()
106 * matches the current count of button presses. It starts at the beginning
107 * of the list and works up to the end. It will refuse to follow a null
125 * ie. When you don't press the button for bdelay jiffies, this is taken to
127 * called to wind things up (write the press_count out to /dev/button, call
138 button_press_count = 0; /* Reset the button press counter */ in button_sequence_finished()
143 * This handler is called when the orange button is pressed (GPIO 10 of the
176 ? -EFAULT : bcount; in button_read()
215 return -ENODEV; in nwbutton_init()
217 printk (KERN_INFO "NetWinder Button Driver Version %s (C) Alex Holden " in nwbutton_init()
223 return -EBUSY; in nwbutton_init()
231 return -EIO; in nwbutton_init()