If unsure, say Y.
config MAC_EMUMOUSEBTN
- bool "Support for mouse button 2+3 emulation"
- depends on SYSCTL
- select INPUT
+ tristate "Support for mouse button 2+3 emulation"
+ depends on SYSCTL && INPUT
help
This provides generic support for emulating the 2nd and 3rd mouse
button with keypresses. If you say Y here, the emulation is still
If you have an Apple machine with a 1-button mouse, say Y here.
+ To compile this driver as a module, choose M here: the
+ module will be called mac_hid.
+
config THERM_WINDTUNNEL
tristate "Support for thermal management on Windtunnel G4s"
depends on I2C && I2C_POWERMAC && PPC_PMAC && !PPC_PMAC64
#include <linux/input.h>
#include <linux/module.h>
+MODULE_LICENSE("GPL");
+
static int mouse_emulate_buttons;
static int mouse_button2_keycode = KEY_RIGHTCTRL; /* right control key */
static int mouse_button3_keycode = KEY_RIGHTALT; /* right option key */
static struct ctl_table_header *mac_hid_sysctl_header;
-
static int __init mac_hid_init(void)
{
mac_hid_sysctl_header = register_sysctl_table(mac_hid_root_dir);
return 0;
}
+module_init(mac_hid_init);
-device_initcall(mac_hid_init);
+static void __exit mac_hid_exit(void)
+{
+ unregister_sysctl_table(mac_hid_sysctl_header);
+
+ if (mouse_emulate_buttons)
+ mac_hid_stop_emulation();
+}
+module_exit(mac_hid_exit);