summaryrefslogtreecommitdiffstats
path: root/include/trace
diff options
context:
space:
mode:
Diffstat (limited to 'include/trace')
-rw-r--r--include/trace/events/vmscan.h40
1 files changed, 40 insertions, 0 deletions
diff --git a/include/trace/events/vmscan.h b/include/trace/events/vmscan.h
index 08c1cd5af0d6..27e8a5c77579 100644
--- a/include/trace/events/vmscan.h
+++ b/include/trace/events/vmscan.h
@@ -15,6 +15,7 @@
15#define RECLAIM_WB_MIXED 0x0010u 15#define RECLAIM_WB_MIXED 0x0010u
16#define RECLAIM_WB_SYNC 0x0004u /* Unused, all reclaim async */ 16#define RECLAIM_WB_SYNC 0x0004u /* Unused, all reclaim async */
17#define RECLAIM_WB_ASYNC 0x0008u 17#define RECLAIM_WB_ASYNC 0x0008u
18#define RECLAIM_WB_LRU (RECLAIM_WB_ANON|RECLAIM_WB_FILE)
18 19
19#define show_reclaim_flags(flags) \ 20#define show_reclaim_flags(flags) \
20 (flags) ? __print_flags(flags, "|", \ 21 (flags) ? __print_flags(flags, "|", \
@@ -426,6 +427,45 @@ TRACE_EVENT(mm_vmscan_lru_shrink_active,
426 show_reclaim_flags(__entry->reclaim_flags)) 427 show_reclaim_flags(__entry->reclaim_flags))
427); 428);
428 429
430TRACE_EVENT(mm_vmscan_inactive_list_is_low,
431
432 TP_PROTO(int nid, int reclaim_idx,
433 unsigned long total_inactive, unsigned long inactive,
434 unsigned long total_active, unsigned long active,
435 unsigned long ratio, int file),
436
437 TP_ARGS(nid, reclaim_idx, total_inactive, inactive, total_active, active, ratio, file),
438
439 TP_STRUCT__entry(
440 __field(int, nid)
441 __field(int, reclaim_idx)
442 __field(unsigned long, total_inactive)
443 __field(unsigned long, inactive)
444 __field(unsigned long, total_active)
445 __field(unsigned long, active)
446 __field(unsigned long, ratio)
447 __field(int, reclaim_flags)
448 ),
449
450 TP_fast_assign(
451 __entry->nid = nid;
452 __entry->reclaim_idx = reclaim_idx;
453 __entry->total_inactive = total_inactive;
454 __entry->inactive = inactive;
455 __entry->total_active = total_active;
456 __entry->active = active;
457 __entry->ratio = ratio;
458 __entry->reclaim_flags = trace_shrink_flags(file) & RECLAIM_WB_LRU;
459 ),
460
461 TP_printk("nid=%d reclaim_idx=%d total_inactive=%ld inactive=%ld total_active=%ld active=%ld ratio=%ld flags=%s",
462 __entry->nid,
463 __entry->reclaim_idx,
464 __entry->total_inactive, __entry->inactive,
465 __entry->total_active, __entry->active,
466 __entry->ratio,
467 show_reclaim_flags(__entry->reclaim_flags))
468);
429#endif /* _TRACE_VMSCAN_H */ 469#endif /* _TRACE_VMSCAN_H */
430 470
431/* This part must be outside protection */ 471/* This part must be outside protection */