Lines Matching refs:dw
583 void dumpBpfMap(std::string mapName, DumpWriter& dw, const std::string& header) {
584 dw.blankline();
585 dw.println("%s:", mapName.c_str());
587 dw.println(header.c_str());
593 void TrafficController::dump(DumpWriter& dw, bool verbose) {
595 dw.incIndent();
596 dw.println("TrafficController");
598 dw.incIndent();
599 dw.println("BPF module status: %s", ebpfSupported? "ON" : "OFF");
604 dw.blankline();
605 dw.println("mCookieTagMap status: %s",
607 dw.println("mUidCounterSetMap status: %s",
609 dw.println("mAppUidStatsMap status: %s",
611 dw.println("mUidStatsMap status: %s",
613 dw.println("mTagStatsMap status: %s",
615 dw.println("mIfaceIndexNameMap status: %s",
617 dw.println("mIfaceStatsMap status: %s",
619 dw.println("mDozableUidMap status: %s",
621 dw.println("mStandbyUidMap status: %s",
623 dw.println("mPowerSaveUidMap status: %s",
626 dw.blankline();
627 dw.println("Cgroup ingress program status: %s",
629 dw.println("Cgroup egress program status: %s", getProgramStatus(BPF_EGRESS_PROG_PATH).c_str());
630 dw.println("xt_bpf ingress program status: %s",
632 dw.println("xt_bpf egress program status: %s",
637 dw.blankline();
638 dw.println("BPF map content:");
640 dw.incIndent();
643 dumpBpfMap("mCookieTagMap", dw, "");
644 const auto printCookieTagInfo = [&dw](const uint64_t& key, const UidTag& value,
646 dw.println("cookie=%" PRIu64 " tag=0x%x uid=%u", key, value.tag, value.uid);
651 dw.println("mCookieTagMap print end with error: %s", res.msg().c_str());
655 dumpBpfMap("mUidCounterSetMap", dw, "");
656 const auto printUidInfo = [&dw](const uint32_t& key, const uint8_t& value,
658 dw.println("%u %u", key, value);
663 dw.println("mUidCounterSetMap print end with error: %s", res.msg().c_str());
668 dumpBpfMap("mAppUidStatsMap:", dw, appUidStatsHeader);
669 auto printAppUidStatsInfo = [&dw](const uint32_t& key, const StatsValue& value,
671 dw.println("%u %" PRIu64 " %" PRIu64 " %" PRIu64 " %" PRIu64, key, value.rxBytes,
677 dw.println("mAppUidStatsMap print end with error: %s", res.msg().c_str());
683 dumpBpfMap("mUidStatsMap", dw, statsHeader);
684 const auto printStatsInfo = [&dw, this](const StatsKey& key, const StatsValue& value,
691 dw.println("%u %s 0x%x %u %u %" PRIu64 " %" PRIu64 " %" PRIu64 " %" PRIu64, ifIndex,
698 dw.println("mUidStatsMap print end with error: %s", res.msg().c_str());
702 dumpBpfMap("mTagStatsMap", dw, statsHeader);
705 dw.println("mTagStatsMap print end with error: %s", res.msg().c_str());
709 dumpBpfMap("mIfaceIndexNameMap", dw, "");
710 const auto printIfaceNameInfo = [&dw](const uint32_t& key, const IfaceValue& value,
713 dw.println("ifaceIndex=%u ifaceName=%s", key, ifname);
718 dw.println("mIfaceIndexNameMap print end with error: %s", res.msg().c_str());
724 dumpBpfMap("mIfaceStatsMap:", dw, ifaceStatsHeader);
725 const auto printIfaceStatsInfo = [&dw, this](const uint32_t& key, const StatsValue& value,
731 dw.println("%u %s %" PRIu64 " %" PRIu64 " %" PRIu64 " %" PRIu64, key, ifname.value().name,
737 dw.println("mIfaceStatsMap print end with error: %s", res.msg().c_str());
741 dumpBpfMap("mDozableUidMap", dw, "");
744 dw.println("mDozableUidMap print end with error: %s", res.msg().c_str());
747 dumpBpfMap("mStandbyUidMap", dw, "");
750 dw.println("mDozableUidMap print end with error: %s", res.msg().c_str());
753 dumpBpfMap("mPowerSaveUidMap", dw, "");
756 dw.println("mDozableUidMap print end with error: %s", res.msg().c_str());
759 dw.decIndent();
761 dw.decIndent();
763 dw.decIndent();