af-packet: output cleanups

pull/8297/head
Victor Julien 2 years ago
parent 393546af07
commit ef881c942b

@ -622,20 +622,20 @@ finalize:
/* for cluster_flow use core count */
if (cluster_type == PACKET_FANOUT_HASH) {
aconf->threads = (int)UtilCpuGetNumProcessorsOnline();
SCLogPerf("%u cores, so using %u threads", aconf->threads, aconf->threads);
SCLogPerf("cluster_flow: %u cores, using %u threads", aconf->threads, aconf->threads);
/* for cluster_qm use RSS queue count */
} else if (cluster_type == PACKET_FANOUT_QM) {
int rss_queues = GetIfaceRSSQueuesNum(iface);
if (rss_queues > 0) {
aconf->threads = rss_queues;
SCLogPerf("%d RSS queues, so using %u threads", rss_queues, aconf->threads);
SCLogPerf(
"cluster_qm: %d RSS queues, using %u threads", rss_queues, aconf->threads);
}
}
if (aconf->threads) {
SCLogPerf("Using %d AF_PACKET threads for interface %s",
aconf->threads, iface);
SCLogDebug("using %d threads for interface %s", aconf->threads, iface);
}
}
if (aconf->threads <= 0) {

@ -1570,9 +1570,9 @@ frame size: TPACKET_ALIGN(snaplen + TPACKET_ALIGN(TPACKET_ALIGN(tp_hdrlen) + siz
ptv->req.v2.tp_block_nr = ptv->req.v2.tp_frame_nr / frames_per_block + 1;
/* exact division */
ptv->req.v2.tp_frame_nr = ptv->req.v2.tp_block_nr * frames_per_block;
SCLogPerf("AF_PACKET RX Ring params: block_size=%d block_nr=%d frame_size=%d frame_nr=%d",
ptv->req.v2.tp_block_size, ptv->req.v2.tp_block_nr,
ptv->req.v2.tp_frame_size, ptv->req.v2.tp_frame_nr);
SCLogPerf("rx ring: block_size=%d block_nr=%d frame_size=%d frame_nr=%d",
ptv->req.v2.tp_block_size, ptv->req.v2.tp_block_nr, ptv->req.v2.tp_frame_size,
ptv->req.v2.tp_frame_nr);
return 1;
}

Loading…
Cancel
Save