Based on the value of "dio->iocb->ki_ioprio" and "dio->iocb->ki_flags", we can update OEM-specific field of struct bio through this hook. then we can distinguish different IO's in lower level drivers and take different measures Bug: 262939423 Change-Id: Ie84d737ca72c29737542f3783d27d7231a272cc4 Signed-off-by: lijiaming <lijiaming3@xiaomi.com>
22 lines
558 B
C
22 lines
558 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
#undef TRACE_SYSTEM
|
|
#define TRACE_SYSTEM direct_io
|
|
#undef TRACE_INCLUDE_PATH
|
|
#define TRACE_INCLUDE_PATH trace/hooks
|
|
|
|
#if !defined(_TRACE_HOOK_DIRECT_IO_H) || defined(TRACE_HEADER_MULTI_READ)
|
|
#define _TRACE_HOOK_DIRECT_IO_H
|
|
|
|
#include <trace/hooks/vendor_hooks.h>
|
|
|
|
struct kiocb;
|
|
struct bio;
|
|
DECLARE_HOOK(android_vh_direct_io_update_bio,
|
|
TP_PROTO(struct kiocb *iocb, struct bio *bio),
|
|
TP_ARGS(iocb, bio));
|
|
|
|
#endif /* _TRACE_HOOK_DIRECT_IO_H */
|
|
|
|
/* This part must be outside protection */
|
|
#include <trace/define_trace.h>
|