Do not try to turn on netmap if the driver doesn't support it
I'm having a separate issue with the IPS mode which stalls at some point because of a netmap + Realtek driver problem, so I started to look for solutions.
I've performed some packet generation tests with the official Realtek driver which don't support netmap and it works. The netmap pkt-gen app uses the generic OS netmap "driver" (I get that from dmesg) and relies on the CPU to reach the same rate.
Now if Suricata is started in netmap mode with the same driver, I get kernel panics, with all the problems it leads to.
Is my assessment correct that this could be avoided if Suricata could detect if the card supports the netmap mode and if not use the software mode?
If yes, could this be implemented?