]> git.ipfire.org Git - people/ms/suricata.git/commit - src/source-af-packet.c
threading: change local packet queue logic
authorVictor Julien <victor@inliniac.net>
Tue, 12 Nov 2019 21:34:51 +0000 (22:34 +0100)
committerVictor Julien <victor@inliniac.net>
Fri, 7 Feb 2020 14:43:10 +0000 (15:43 +0100)
commitf8aed4ce2dd8ef141f5dd2ae64c9faccf8f0ca2e
tree4f4c810abc0ce8b8e9ecb4f68dec4d5ac195f0ce
parentb8c2b66d333c0816ec4f7e2bc1b38a44019fedbf
threading: change local packet queue logic

Previously each 'TmSlot' had it's own packet queue that was passed
to the registered SlotFunc as an argument. This was used mostly for
tunnel packets by the decoders and by defrag.

This patch removes that in favor of a single queue in the ThreadVars:
decode_pq. This is the non-locked version of the queue as this is
only a temporary store for handling packets within a thread.

This patch removes the PacketQueue pointer argument from the API.
The new queue can be accessed directly through the ThreadVars
pointer.
56 files changed:
src/alert-unified2-alert.c
src/decode-afl.c
src/decode-erspan.c
src/decode-ethernet.c
src/decode-gre.c
src/decode-icmpv4.c
src/decode-icmpv6.c
src/decode-ipv4.c
src/decode-ipv6.c
src/decode-mpls.c
src/decode-null.c
src/decode-ppp.c
src/decode-pppoe.c
src/decode-raw.c
src/decode-sctp.c
src/decode-sll.c
src/decode-tcp.c
src/decode-template.c
src/decode-teredo.c
src/decode-teredo.h
src/decode-udp.c
src/decode-vlan.c
src/decode-vxlan.c
src/decode.c
src/decode.h
src/defrag.c
src/defrag.h
src/detect-content.c
src/detect-csum.c
src/detect-dsize.c
src/detect-fragbits.c
src/detect-icmp-id.c
src/detect-ipproto.c
src/detect-parse.c
src/detect-replace.c
src/flow-worker.c
src/packet-queue.h
src/respond-reject.c
src/source-af-packet.c
src/source-erf-dag.c
src/source-erf-file.c
src/source-ipfw.c
src/source-napatech.c
src/source-netmap.c
src/source-nflog.c
src/source-nfq.c
src/source-pcap-file.c
src/source-pcap.c
src/source-pfring.c
src/source-windivert.c
src/tests/detect.c
src/threadvars.h
src/tm-modules.h
src/tm-threads.c
src/tm-threads.h
src/util-unittest-helper.c