ANDROID: input: Add vendor hook for __pass_event in evdev.c
Add vendor hook for passing events to client drivers. We have some limitation to achieve the goal of input performance without modification of kernel. So I would like you to add vendor hook and please review the reason why I want to add it. As the users trigger input actions, we need to support the input operation and the what the users want to do so that there's no delay. So we've developed and used "input booster" controling some resources properly during input operations according to input type. Android already has the booster in framework to support input actions however this way has a long latency to control resources. To reduce latency, we've placed the booster in kernel side for high responsiveness and it guarantees faster than framework booster. In addtion, I applied Samsung's own concept to the booster. And it has been operated stably on all Galaxy models for about 10 years. So we need - add function to notify input events delivered to client in evdev. Bug: 228927595 Signed-off-by: HongCheol Shim <hongc.shim@samsung.corp-partner.google.com> Change-Id: Ibe199c148974b6788e02c192f950cb6802745f68
This commit is contained in:
parent
c555553a40
commit
9a7732c0b2
|
@ -64,6 +64,7 @@
|
|||
#include <trace/hooks/regmap.h>
|
||||
#include <trace/hooks/dmabuf.h>
|
||||
#include <trace/hooks/mmc.h>
|
||||
#include <trace/hooks/evdev.h>
|
||||
|
||||
/*
|
||||
* Export tracepoints that act as a bare tracehook (ie: have no trace event
|
||||
|
@ -311,6 +312,7 @@ EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_force_compatible_pre);
|
|||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_force_compatible_post);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_regmap_update);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_dma_buf_release);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_pass_input_event);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_mmc_check_status);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_blk_alloc_rqs);
|
||||
EXPORT_TRACEPOINT_SYMBOL_GPL(android_vh_blk_rq_ctx_init);
|
||||
|
|
|
@ -24,6 +24,7 @@
|
|||
#include <linux/device.h>
|
||||
#include <linux/cdev.h>
|
||||
#include "input-compat.h"
|
||||
#include <trace/hooks/evdev.h>
|
||||
|
||||
struct evdev {
|
||||
int open;
|
||||
|
@ -214,6 +215,9 @@ static int evdev_set_clk_type(struct evdev_client *client, unsigned int clkid)
|
|||
static void __pass_event(struct evdev_client *client,
|
||||
const struct input_event *event)
|
||||
{
|
||||
trace_android_vh_pass_input_event(client->head, client->tail, client->bufsize,
|
||||
event->type, event->code, event->value);
|
||||
|
||||
client->buffer[client->head++] = *event;
|
||||
client->head &= client->bufsize - 1;
|
||||
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0 */
|
||||
#undef TRACE_SYSTEM
|
||||
#define TRACE_SYSTEM evdev
|
||||
|
||||
#define TRACE_INCLUDE_PATH trace/hooks
|
||||
|
||||
#if !defined(_TRACE_HOOK_EVDEV_H) || defined(TRACE_HEADER_MULTI_READ)
|
||||
#define _TRACE_HOOK_EVDEV_H
|
||||
|
||||
#include <trace/hooks/vendor_hooks.h>
|
||||
|
||||
DECLARE_HOOK(android_vh_pass_input_event,
|
||||
TP_PROTO(int head, int tail, int bufsize, int type, int code, int value),
|
||||
TP_ARGS(head, tail, bufsize, type, code, value))
|
||||
|
||||
#endif /* _TRACE_HOOK_EVDEV_H */
|
||||
/* This part must be outside protection */
|
||||
#include <trace/define_trace.h>
|
||||
|
Loading…
Reference in New Issue