device/generic/common
修订版 | 7ce62c66d43d5ca5c338b546b2750fe586d30c81 (tree) |
---|---|
时间 | 2018-12-19 13:05:28 |
作者 | Chih-Wei Huang <cwhuang@linu...> |
Commiter | Chih-Wei Huang |
Update tp_smapi to 0.43
Copied from https://github.com/evgeni/tp_smapi
commit a63729a.
@@ -62,7 +62,7 @@ static const struct thinkpad_ec_row ec_accel_args = | ||
62 | 62 | |
63 | 63 | #define HDAPS_INPUT_FUZZ 4 /* input event threshold */ |
64 | 64 | #define HDAPS_INPUT_FLAT 4 |
65 | -#define KMACT_REMEMBER_PERIOD (HZ/10) /* keyboard/mouse persistance */ | |
65 | +#define KMACT_REMEMBER_PERIOD (HZ/10) /* keyboard/mouse persistence */ | |
66 | 66 | |
67 | 67 | /* Input IDs */ |
68 | 68 | #define HDAPS_INPUT_VENDOR PCI_VENDOR_ID_IBM |
@@ -469,7 +469,11 @@ static void hdaps_calibrate(void) | ||
469 | 469 | /* Timer handler for updating the input device. Runs in softirq context, |
470 | 470 | * so avoid lenghty or blocking operations. |
471 | 471 | */ |
472 | +#if LINUX_VERSION_CODE < KERNEL_VERSION(4,15,0) | |
472 | 473 | static void hdaps_mousedev_poll(unsigned long unused) |
474 | +#else | |
475 | +static void hdaps_mousedev_poll(struct timer_list *unused) | |
476 | +#endif | |
473 | 477 | { |
474 | 478 | int ret; |
475 | 479 |
@@ -779,11 +783,11 @@ static int __init hdaps_init(void) | ||
779 | 783 | hdaps_invert = 0; /* default */ |
780 | 784 | |
781 | 785 | /* Init timer before platform_driver_register, in case of suspend */ |
782 | -#if LINUX_VERSION_CODE >= KERNEL_VERSION(4, 15, 0) | |
783 | - timer_setup(&hdaps_timer, hdaps_mousedev_poll, 0); | |
784 | -#else | |
786 | +#if LINUX_VERSION_CODE < KERNEL_VERSION(4,15,0) | |
785 | 787 | init_timer(&hdaps_timer); |
786 | 788 | hdaps_timer.function = hdaps_mousedev_poll; |
789 | +#else | |
790 | + timer_setup(&hdaps_timer, hdaps_mousedev_poll, 0); | |
787 | 791 | #endif |
788 | 792 | ret = platform_driver_register(&hdaps_driver); |
789 | 793 | if (ret) |
@@ -45,7 +45,7 @@ | ||
45 | 45 | #include <linux/semaphore.h> |
46 | 46 | #endif |
47 | 47 | |
48 | -#define TP_VERSION "0.42" | |
48 | +#define TP_VERSION "0.43" | |
49 | 49 | |
50 | 50 | MODULE_AUTHOR("Shem Multinymous"); |
51 | 51 | MODULE_DESCRIPTION("ThinkPad embedded controller hardware access"); |
@@ -47,7 +47,7 @@ | ||
47 | 47 | #include <asm/uaccess.h> |
48 | 48 | #include <asm/io.h> |
49 | 49 | |
50 | -#define TP_VERSION "0.42" | |
50 | +#define TP_VERSION "0.43" | |
51 | 51 | #define TP_DESC "ThinkPad SMAPI Support" |
52 | 52 | #define TP_DIR "smapi" |
53 | 53 |