History

net: core: Add offload stats to if_stats_msg

Add a nested attribute of offload stats to if_stats_msg named IFLA_STATS_LINK_OFFLOAD_XSTATS. Under it, add SW stats, meaning stats only per packets that went via slowpath to the cpu, named IFLA_OFFLOAD_XSTATS_CPU_HIT.

Nogah Frankel committed 10 years ago

Commit 69ae6ad1 parent 2c9d85d2 files · +116 −4Browse files

Showing the changes to include/uapi (1 of 2 files). Show all

Unified · Split

include/uapi/linux/if_link.h+9−0
@@ -826,6 +826,7 @@ enum { · 825 unmodified lines
826826 IFLA_STATS_LINK_64,
827827 IFLA_STATS_LINK_XSTATS,
828828 IFLA_STATS_LINK_XSTATS_SLAVE,
829+ IFLA_STATS_LINK_OFFLOAD_XSTATS,
829830 __IFLA_STATS_MAX,
830831 };
831832
@@ -845,6 +846,14 @@ enum { · 13 unmodified lines
845846 };
846847 #define LINK_XSTATS_TYPE_MAX (__LINK_XSTATS_TYPE_MAX - 1)
847848
849+/* These are stats embedded into IFLA_STATS_LINK_OFFLOAD_XSTATS */
850+enum {
851+ IFLA_OFFLOAD_XSTATS_UNSPEC,
852+ IFLA_OFFLOAD_XSTATS_CPU_HIT, /* struct rtnl_link_stats64 */
853+ __IFLA_OFFLOAD_XSTATS_MAX
854+};
855+#define IFLA_OFFLOAD_XSTATS_MAX (__IFLA_OFFLOAD_XSTATS_MAX - 1)
856+
848857 /* XDP section */
849858
850859 enum {

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t