mirror of
https://github.com/rd-stuffs/msm-4.14.git
synced 2025-02-20 11:45:48 +08:00
input: Implement KernelSU SafeMode
Change-Id: Iad5d24e2d9ef248c98c565045dc47730c30fe481 Signed-off-by: Richard Raya <rdxzv.dev@gmail.com>
This commit is contained in:
parent
5c697687a6
commit
b84b54849f
@ -377,11 +377,21 @@ static int input_get_disposition(struct input_dev *dev,
|
||||
return disposition;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_KSU
|
||||
extern bool ksu_input_hook __read_mostly;
|
||||
extern int ksu_handle_input_handle_event(unsigned int *type, unsigned int *code, int *value);
|
||||
#endif
|
||||
|
||||
static void input_handle_event(struct input_dev *dev,
|
||||
unsigned int type, unsigned int code, int value)
|
||||
{
|
||||
int disposition = input_get_disposition(dev, type, code, &value);
|
||||
|
||||
#ifdef CONFIG_KSU
|
||||
if (unlikely(ksu_input_hook))
|
||||
ksu_handle_input_handle_event(&type, &code, &value);
|
||||
#endif
|
||||
|
||||
if (disposition != INPUT_IGNORE_EVENT && type != EV_SYN)
|
||||
add_input_randomness(type, code, value);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user