1#!/bin/bash
2# SPDX-License-Identifier: GPL-2.0
3
4CHECK_TC="yes"
5
6tc_check_packets()
7{
8	local id=$1
9	local handle=$2
10	local count=$3
11
12	cmd_jq "tc -j -s filter show $id" \
13	       ".[] | select(.options.handle == $handle) | \
14	              select(.options.actions[0].stats.packets == $count)" \
15	       &> /dev/null
16}
17