Hello everyone.
I wish to add a rule on my mellanox device, so that the device drops the TX packet on some rules. I tried adding the rules through:
tc filter add dev enp66s0f3np1 egress protocol ip flower \
> dst_ip 1.1.1.1 \
> action drop
While listing the rules I was able to see that it was being performed in software, as it says “not_in_hw”.
[root@khi-15 src]# tc filter show dev enp66s0f3np1 egress
filter protocol ip pref 49152 flower chain 0
filter protocol ip pref 49152 flower chain 0 handle 0x1
eth_type ipv4
dst_ip 1.1.1.1
not_in_hw
action order 1: gact action drop
random type none pass val 0
index 1 ref 1 bind 1
Is there any way through which device can drop the TX packet on some specified rule? Also, given that the device drops the packet, how does the driver gets to know about this dropped packet then?