History

drop_monitor: Allow user to start monitoring hardware drops

Drop monitor has start and stop commands, but so far these were only used to start and stop monitoring of software drops. Now that drop monitor can also monitor hardware drops, we should allow the user to control these as well. Do that by adding SW and HW flags to these commands. If no flag is specified, then only start / stop monitoring software drops. This is done in order to maintain backward-compatibility with existing user space applications.

Ido Schimmel committed 7 years ago

Commit 8e94c3b1 parent d40e1de2 files · +123 −3Browse files

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

Unified · Split

include/uapi/linux/net_dropmon.h+2−0
@@ -90,6 +90,8 @@ enum net_dm_attr { · 89 unmodified lines
9090 NET_DM_ATTR_HW_ENTRIES, /* nested */
9191 NET_DM_ATTR_HW_ENTRY, /* nested */
9292 NET_DM_ATTR_HW_TRAP_COUNT, /* u32 */
93+ NET_DM_ATTR_SW_DROPS, /* flag */
94+ NET_DM_ATTR_HW_DROPS, /* flag */
9395
9496 __NET_DM_ATTR_MAX,
9597 NET_DM_ATTR_MAX = __NET_DM_ATTR_MAX - 1