ANDROID: mm: add vendor hook to trace swap bio charge

Add a vendor hook `android_vh_swap_bio_charge` in swap read path
to allow vendors to monitor  behavior when a swap bio
is submitted.

Bug: 433890875

Change-Id: I742978c7cb5c7d678d585b49e3466920f99e4fba
Signed-off-by: Dongdong zhang <zhangdongdong5@xiaomi.com>
This commit is contained in:
Dongdong zhang
2025-07-24 20:07:06 +08:00
committed by Todd Kjos
parent 6aa695ed1b
commit ee117211e4
3 changed files with 5 additions and 0 deletions
+3
View File
@@ -540,6 +540,9 @@ DECLARE_HOOK(android_vh_filemap_add_folio,
DECLARE_HOOK(android_vh_gcma_cc_store_page_bypass,
TP_PROTO(bool *bypass),
TP_ARGS(bypass));
DECLARE_HOOK(android_vh_swap_bio_charge,
TP_PROTO(struct bio *bio),
TP_ARGS(bio));
#endif /* _TRACE_HOOK_MM_H */
/* This part must be outside protection */