af-packet: code cleaning and comments

pull/3221/head
Eric Leblond 9 years ago
parent cde438f670
commit 2598078ee6

@ -372,7 +372,7 @@ static void *ParseAFPConfig(const char *iface)
aconf->ebpf_lb_file = NULL;
} else {
#ifdef HAVE_PACKET_EBPF
SCLogInfo("af-packet will use '%s' as eBPF load balancing file",
SCLogConfig("af-packet will use '%s' as eBPF load balancing file",
ebpf_file);
#endif
aconf->ebpf_lb_file = ebpf_file;
@ -397,7 +397,7 @@ static void *ParseAFPConfig(const char *iface)
aconf->ebpf_filter_file = NULL;
} else {
#ifdef HAVE_PACKET_EBPF
SCLogInfo("af-packet will use '%s' as eBPF filter file",
SCLogConfig("af-packet will use '%s' as eBPF filter file",
ebpf_file);
#endif
aconf->ebpf_filter_file = ebpf_file;

@ -2259,6 +2259,7 @@ TmEcode AFPSetBPFFilter(AFPThreadVars *ptv)
* \param mapfd file descriptor of the protocol bypass table
* \param key data to use as key in the table
* \param inittime time of creation of the entry (in monotonic clock)
* \return 0 in case of error, 1 if success
*/
static int AFPInsertHalfFlow(int mapd, void *key, uint64_t inittime)
{
@ -2292,6 +2293,9 @@ static int AFPInsertHalfFlow(int mapd, void *key, uint64_t inittime)
}
#endif
/**
* Bypass function for AF_PACKET capture
*/
static int AFPBypassCallback(Packet *p)
{
#ifdef HAVE_PACKET_EBPF

Loading…
Cancel
Save