Lines Matching refs:mi
1154 static bool meminfo_parse_line(char *line, union meminfo *mi) { in meminfo_parse_line() argument
1175 mi->arr[field_idx] = val / page_k; in meminfo_parse_line()
1180 static int meminfo_parse(union meminfo *mi) { in meminfo_parse() argument
1189 memset(mi, 0, sizeof(union meminfo)); in meminfo_parse()
1197 if (!meminfo_parse_line(line, mi)) { in meminfo_parse()
1202 mi->field.nr_file_pages = mi->field.cached + mi->field.swap_cached + in meminfo_parse()
1203 mi->field.buffers; in meminfo_parse()
1208 static void meminfo_log(union meminfo *mi) { in meminfo_log() argument
1210 android_log_write_int32(ctx, (int32_t)min(mi->arr[field_idx] * page_k, INT32_MAX)); in meminfo_log()
1479 void record_low_pressure_levels(union meminfo *mi) { in record_low_pressure_levels() argument
1481 low_pressure_mem.min_nr_free_pages > mi->field.nr_free_pages) { in record_low_pressure_levels()
1484 low_pressure_mem.min_nr_free_pages, mi->field.nr_free_pages); in record_low_pressure_levels()
1486 low_pressure_mem.min_nr_free_pages = mi->field.nr_free_pages; in record_low_pressure_levels()
1495 (low_pressure_mem.max_nr_free_pages < mi->field.nr_free_pages && in record_low_pressure_levels()
1496 mi->field.nr_free_pages - low_pressure_mem.max_nr_free_pages < in record_low_pressure_levels()
1500 low_pressure_mem.max_nr_free_pages, mi->field.nr_free_pages); in record_low_pressure_levels()
1502 low_pressure_mem.max_nr_free_pages = mi->field.nr_free_pages; in record_low_pressure_levels()
1539 union meminfo mi; in mp_event_common() local
1599 if (meminfo_parse(&mi) < 0 || zoneinfo_parse(&zi) < 0) { in mp_event_common()
1607 other_free = mi.field.nr_free_pages - zi.field.totalreserve_pages; in mp_event_common()
1608 … if (mi.field.nr_file_pages > (mi.field.shmem + mi.field.unevictable + mi.field.swap_cached)) { in mp_event_common()
1609 other_file = (mi.field.nr_file_pages - mi.field.shmem - in mp_event_common()
1610 mi.field.unevictable - mi.field.swap_cached); in mp_event_common()
1638 record_low_pressure_levels(&mi); in mp_event_common()
1668 if (mi.field.free_swap >= in mp_event_common()
1669 mi.field.total_swap * swap_free_low_percentage / 100) { in mp_event_common()
1694 meminfo_log(&mi); in mp_event_common()
1703 if (mi.field.nr_free_pages >= low_pressure_mem.max_nr_free_pages) { in mp_event_common()
1707 mi.field.nr_free_pages, low_pressure_mem.max_nr_free_pages); in mp_event_common()
1728 meminfo_log(&mi); in mp_event_common()
1734 other_file * page_k, mi.field.nr_free_pages * page_k, in mp_event_common()