From nobody Thu May 2 23:32:23 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1501510254587470.8717493712966; Mon, 31 Jul 2017 07:10:54 -0700 (PDT) Received: from localhost ([::1]:59804 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dcBPJ-0002FH-99 for importer@patchew.org; Mon, 31 Jul 2017 10:10:53 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57395) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dcBM7-0008JK-Dx for qemu-devel@nongnu.org; Mon, 31 Jul 2017 10:07:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dcBM1-0006Jf-3a for qemu-devel@nongnu.org; Mon, 31 Jul 2017 10:07:35 -0400 Received: from mx1.redhat.com ([209.132.183.28]:47720) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dcBM0-0006J9-QU for qemu-devel@nongnu.org; Mon, 31 Jul 2017 10:07:29 -0400 Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.phx2.redhat.com [10.5.11.14]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id CF4B4112E8F; Mon, 31 Jul 2017 14:07:27 +0000 (UTC) Received: from localhost (ovpn-117-146.ams2.redhat.com [10.36.117.146]) by smtp.corp.redhat.com (Postfix) with ESMTP id B39365D9C1; Mon, 31 Jul 2017 14:07:24 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com CF4B4112E8F Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx09.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=stefanha@redhat.com From: Stefan Hajnoczi To: Date: Mon, 31 Jul 2017 15:07:17 +0100 Message-Id: <20170731140718.22010-2-stefanha@redhat.com> In-Reply-To: <20170731140718.22010-1-stefanha@redhat.com> References: <20170731140718.22010-1-stefanha@redhat.com> X-Scanned-By: MIMEDefang 2.79 on 10.5.11.14 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.38]); Mon, 31 Jul 2017 14:07:28 +0000 (UTC) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH v2 1/2] trace: add TRACE__BACKEND_DSTATE() X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Denis V. Lunev" , =?UTF-8?q?Llu=C3=ADs=20Vilanova?= , Stefan Hajnoczi Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" QEMU keeps track of trace event enabled/disabled state and provides monitor commands to inspect and modify the "dstate". SystemTap and LTTng UST maintain independent enabled/disabled states for each trace event, the other backends rely on QEMU dstate. Introduce a new per-event macro that combines backend-specific dstate like this: #define TRACE_MY_EVENT_BACKEND_DSTATE() ( \ QEMU_MY_EVENT_ENABLED() || /* SystemTap */ \ tracepoint_enabled(qemu, my_event) /* LTTng UST */ || \ false) This will be used to extend trace_event_get_state() in the next patch. Signed-off-by: Stefan Hajnoczi Reviewed-by: Daniel P. Berrange --- v2: * Don't special-case QEMU dstate [Daniel Berrange] --- scripts/tracetool/__init__.py | 1 + scripts/tracetool/backend/__init__.py | 3 +++ scripts/tracetool/backend/dtrace.py | 12 ++++++++++++ scripts/tracetool/backend/ftrace.py | 5 +++++ scripts/tracetool/backend/log.py | 5 +++++ scripts/tracetool/backend/simple.py | 5 +++++ scripts/tracetool/backend/syslog.py | 5 +++++ scripts/tracetool/backend/ust.py | 5 +++++ scripts/tracetool/format/h.py | 10 ++++++++++ 9 files changed, 51 insertions(+) diff --git a/scripts/tracetool/__init__.py b/scripts/tracetool/__init__.py index d4c204a472..0670ec17d5 100644 --- a/scripts/tracetool/__init__.py +++ b/scripts/tracetool/__init__.py @@ -271,6 +271,7 @@ class Event(object): QEMU_TRACE_NOCHECK =3D "_nocheck__" + QEMU_TRACE QEMU_TRACE_TCG =3D QEMU_TRACE + "_tcg" QEMU_DSTATE =3D "_TRACE_%(NAME)s_DSTATE" + QEMU_BACKEND_DSTATE =3D "TRACE_%(NAME)s_BACKEND_DSTATE" QEMU_EVENT =3D "_TRACE_%(NAME)s_EVENT" =20 def api(self, fmt=3DNone): diff --git a/scripts/tracetool/backend/__init__.py b/scripts/tracetool/back= end/__init__.py index f735a259c0..259c6a6531 100644 --- a/scripts/tracetool/backend/__init__.py +++ b/scripts/tracetool/backend/__init__.py @@ -119,5 +119,8 @@ class Wrapper: def generate(self, event, group): self._run_function("generate_%s", event, group) =20 + def generate_backend_dstate(self, event, group): + self._run_function("generate_%s_backend_dstate", event, group) + def generate_end(self, events, group): self._run_function("generate_%s_end", events, group) diff --git a/scripts/tracetool/backend/dtrace.py b/scripts/tracetool/backen= d/dtrace.py index c6812b70a2..17f902cc62 100644 --- a/scripts/tracetool/backend/dtrace.py +++ b/scripts/tracetool/backend/dtrace.py @@ -44,8 +44,20 @@ def generate_h_begin(events, group): out('#include "%s"' % header, '') =20 + # SystemTap defines __ENABLED() but other DTrace + # implementations might not. + for e in events: + out('#ifndef QEMU_%(uppername)s_ENABLED', + '#define QEMU_%(uppername)s_ENABLED() false', + '#endif', + uppername=3De.name.upper()) =20 def generate_h(event, group): out(' QEMU_%(uppername)s(%(argnames)s);', uppername=3Devent.name.upper(), argnames=3D", ".join(event.args.names())) + + +def generate_h_backend_dstate(event, group): + out(' QEMU_%(uppername)s_ENABLED() || \\', + uppername=3Devent.name.upper()) diff --git a/scripts/tracetool/backend/ftrace.py b/scripts/tracetool/backen= d/ftrace.py index dd0eda4441..92f71b28f9 100644 --- a/scripts/tracetool/backend/ftrace.py +++ b/scripts/tracetool/backend/ftrace.py @@ -45,3 +45,8 @@ def generate_h(event, group): event_id=3D"TRACE_" + event.name.upper(), fmt=3Devent.fmt.rstrip("\n"), argnames=3Dargnames) + + +def generate_h_backend_dstate(event, group): + out(' trace_event_get_state_dynamic_by_id(%(event_id)s) || \\', + event_id=3D"TRACE_" + event.name.upper()) diff --git a/scripts/tracetool/backend/log.py b/scripts/tracetool/backend/l= og.py index 54f0a69886..da86f6b882 100644 --- a/scripts/tracetool/backend/log.py +++ b/scripts/tracetool/backend/log.py @@ -48,3 +48,8 @@ def generate_h(event, group): name=3Devent.name, fmt=3Devent.fmt.rstrip("\n"), argnames=3Dargnames) + + +def generate_h_backend_dstate(event, group): + out(' trace_event_get_state_dynamic_by_id(%(event_id)s) || \\', + event_id=3D"TRACE_" + event.name.upper()) diff --git a/scripts/tracetool/backend/simple.py b/scripts/tracetool/backen= d/simple.py index f983670ee1..c2fd1c24c4 100644 --- a/scripts/tracetool/backend/simple.py +++ b/scripts/tracetool/backend/simple.py @@ -42,6 +42,11 @@ def generate_h(event, group): args=3D", ".join(event.args.names())) =20 =20 +def generate_h_backend_dstate(event, group): + out(' trace_event_get_state_dynamic_by_id(%(event_id)s) || \\', + event_id=3D"TRACE_" + event.name.upper()) + + def generate_c_begin(events, group): out('#include "qemu/osdep.h"', '#include "trace/control.h"', diff --git a/scripts/tracetool/backend/syslog.py b/scripts/tracetool/backen= d/syslog.py index 1ce627f0fc..668fb73fee 100644 --- a/scripts/tracetool/backend/syslog.py +++ b/scripts/tracetool/backend/syslog.py @@ -42,3 +42,8 @@ def generate_h(event, group): name=3Devent.name, fmt=3Devent.fmt.rstrip("\n"), argnames=3Dargnames) + + +def generate_h_backend_dstate(event, group): + out(' trace_event_get_state_dynamic_by_id(%(event_id)s) || \\', + event_id=3D"TRACE_" + event.name.upper()) diff --git a/scripts/tracetool/backend/ust.py b/scripts/tracetool/backend/u= st.py index 2adaf548d5..412592b8e0 100644 --- a/scripts/tracetool/backend/ust.py +++ b/scripts/tracetool/backend/ust.py @@ -38,3 +38,8 @@ def generate_h(event, group): out(' tracepoint(qemu, %(name)s%(tp_args)s);', name=3Devent.name, tp_args=3Dargnames) + + +def generate_h_backend_dstate(event, group): + out(' tracepoint_enabled(qemu, %(name)s) || \\', + name=3Devent.name) diff --git a/scripts/tracetool/format/h.py b/scripts/tracetool/format/h.py index aecf249d66..e06f0f27c5 100644 --- a/scripts/tracetool/format/h.py +++ b/scripts/tracetool/format/h.py @@ -49,6 +49,16 @@ def generate(events, backend, group): backend.generate_begin(events, group) =20 for e in events: + # tracer-specific dstate + out('', + '#define %(api)s() ( \\', + api=3De.api(e.QEMU_BACKEND_DSTATE)) + + if "disable" not in e.properties: + backend.generate_backend_dstate(e, group) + + out(' false)') + # tracer without checks out('', 'static inline void %(api)s(%(args)s)', --=20 2.13.3 From nobody Thu May 2 23:32:23 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) client-ip=208.118.235.17; envelope-from=qemu-devel-bounces+importer=patchew.org@nongnu.org; helo=lists.gnu.org; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of gnu.org designates 208.118.235.17 as permitted sender) smtp.mailfrom=qemu-devel-bounces+importer=patchew.org@nongnu.org Return-Path: Received: from lists.gnu.org (lists.gnu.org [208.118.235.17]) by mx.zohomail.com with SMTPS id 1501510150850684.1316483767554; Mon, 31 Jul 2017 07:09:10 -0700 (PDT) Received: from localhost ([::1]:59790 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dcBNc-0000ro-Br for importer@patchew.org; Mon, 31 Jul 2017 10:09:08 -0400 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57393) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dcBM6-0008Ik-Ib for qemu-devel@nongnu.org; Mon, 31 Jul 2017 10:07:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dcBM5-0006LT-4i for qemu-devel@nongnu.org; Mon, 31 Jul 2017 10:07:34 -0400 Received: from mx1.redhat.com ([209.132.183.28]:45238) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1dcBM4-0006L1-R7 for qemu-devel@nongnu.org; Mon, 31 Jul 2017 10:07:33 -0400 Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id D04A410602C; Mon, 31 Jul 2017 14:07:31 +0000 (UTC) Received: from localhost (ovpn-117-146.ams2.redhat.com [10.36.117.146]) by smtp.corp.redhat.com (Postfix) with ESMTP id 084BA6A74A; Mon, 31 Jul 2017 14:07:28 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com D04A410602C Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx02.extmail.prod.ext.phx2.redhat.com; spf=fail smtp.mailfrom=stefanha@redhat.com From: Stefan Hajnoczi To: Date: Mon, 31 Jul 2017 15:07:18 +0100 Message-Id: <20170731140718.22010-3-stefanha@redhat.com> In-Reply-To: <20170731140718.22010-1-stefanha@redhat.com> References: <20170731140718.22010-1-stefanha@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.26]); Mon, 31 Jul 2017 14:07:32 +0000 (UTC) Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 209.132.183.28 Subject: [Qemu-devel] [PATCH v2 2/2] trace: add trace_event_get_state_backends() X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: "Denis V. Lunev" , =?UTF-8?q?Llu=C3=ADs=20Vilanova?= , Stefan Hajnoczi Errors-To: qemu-devel-bounces+importer=patchew.org@nongnu.org Sender: "Qemu-devel" X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" Code that checks dstate is unaware of SystemTap and LTTng UST dstate, so the following trace event will not fire when solely enabled by SystemTap or LTTng UST: if (trace_event_get_state(TRACE_MY_EVENT)) { str =3D g_strdup_printf("Expensive string to generate ...", ...); trace_my_event(str); g_free(str); } Add trace_event_get_state_backends() to fetch backend dstate. Those backends that use QEMU dstate fetch it as part of generate_h_backend_dstate(). Update existing trace_event_get_state() callers to use trace_event_get_state_backends() instead. Signed-off-by: Stefan Hajnoczi Reviewed-by: Daniel P. Berrange --- v2: * Use _backends() postfix to clarify function purpose [Llu=C3=ADs] --- docs/devel/tracing.txt | 2 +- trace/control.h | 18 +++++++++++++++++- hw/usb/hcd-ohci.c | 13 +++++-------- net/colo-compare.c | 11 ++++++----- net/filter-rewriter.c | 4 ++-- 5 files changed, 31 insertions(+), 17 deletions(-) diff --git a/docs/devel/tracing.txt b/docs/devel/tracing.txt index 5768a0b7a2..07abbb345c 100644 --- a/docs/devel/tracing.txt +++ b/docs/devel/tracing.txt @@ -353,7 +353,7 @@ guard such computations and avoid its compilation when = the event is disabled: } =20 You can check both if the event has been disabled and is dynamically enabl= ed at -the same time using the 'trace_event_get_state' routine (see header +the same time using the 'trace_event_get_state_backends' routine (see head= er "trace/control.h" for more information). =20 =3D=3D=3D "tcg" =3D=3D=3D diff --git a/trace/control.h b/trace/control.h index b931824d60..1903e22975 100644 --- a/trace/control.h +++ b/trace/control.h @@ -96,7 +96,7 @@ static const char * trace_event_get_name(TraceEvent *ev); * trace_event_get_state: * @id: Event identifier name. * - * Get the tracing state of an event (both static and dynamic). + * Get the tracing state of an event, both static and the QEMU dynamic sta= te. * * If the event has the disabled property, the check will have no performa= nce * impact. @@ -105,6 +105,22 @@ static const char * trace_event_get_name(TraceEvent *e= v); ((id ##_ENABLED) && trace_event_get_state_dynamic_by_id(id)) =20 /** + * trace_event_get_state_backends: + * @id: Event identifier name. + * + * Get the tracing state of an event, both static and dynamic state from a= ll + * compiled-in backends. + * + * If the event has the disabled property, the check will have no performa= nce + * impact. + * + * Returns: true if at least one backend has the event enabled and the eve= nt + * does not have the disabled property. + */ +#define trace_event_get_state_backends(id) \ + ((id ##_ENABLED) && id ##_BACKEND_DSTATE()) + +/** * trace_event_get_vcpu_state: * @vcpu: Target vCPU. * @id: Event identifier name. diff --git a/hw/usb/hcd-ohci.c b/hw/usb/hcd-ohci.c index 3ada35e954..267982e160 100644 --- a/hw/usb/hcd-ohci.c +++ b/hw/usb/hcd-ohci.c @@ -936,16 +936,18 @@ static int ohci_service_iso_td(OHCIState *ohci, struc= t ohci_ed *ed, return 1; } =20 -#ifdef trace_event_get_state static void ohci_td_pkt(const char *msg, const uint8_t *buf, size_t len) { - bool print16 =3D !!trace_event_get_state(TRACE_USB_OHCI_TD_PKT_SHORT); - bool printall =3D !!trace_event_get_state(TRACE_USB_OHCI_TD_PKT_FULL); + bool print16; + bool printall; const int width =3D 16; int i; char tmp[3 * width + 1]; char *p =3D tmp; =20 + print16 =3D !!trace_event_get_state_backends(TRACE_USB_OHCI_TD_PKT_SHO= RT); + printall =3D !!trace_event_get_state_backends(TRACE_USB_OHCI_TD_PKT_FU= LL); + if (!printall && !print16) { return; } @@ -967,11 +969,6 @@ static void ohci_td_pkt(const char *msg, const uint8_t= *buf, size_t len) p +=3D sprintf(p, " %.2x", buf[i]); } } -#else -static void ohci_td_pkt(const char *msg, const uint8_t *buf, size_t len) -{ -} -#endif =20 /* Service a transport descriptor. Returns nonzero to terminate processing of this endpoint. */ diff --git a/net/colo-compare.c b/net/colo-compare.c index ca67c68615..5fe8e3fad9 100644 --- a/net/colo-compare.c +++ b/net/colo-compare.c @@ -188,7 +188,7 @@ static int packet_enqueue(CompareState *s, int mode) */ static int colo_packet_compare_common(Packet *ppkt, Packet *spkt, int offs= et) { - if (trace_event_get_state(TRACE_COLO_COMPARE_MISCOMPARE)) { + if (trace_event_get_state_backends(TRACE_COLO_COMPARE_MISCOMPARE)) { char pri_ip_src[20], pri_ip_dst[20], sec_ip_src[20], sec_ip_dst[20= ]; =20 strcpy(pri_ip_src, inet_ntoa(ppkt->ip->ip_src)); @@ -274,7 +274,8 @@ static int colo_packet_compare_tcp(Packet *spkt, Packet= *ppkt) res =3D -1; } =20 - if (res !=3D 0 && trace_event_get_state(TRACE_COLO_COMPARE_MISCOMPARE)= ) { + if (res !=3D 0 && + trace_event_get_state_backends(TRACE_COLO_COMPARE_MISCOMPARE)) { char pri_ip_src[20], pri_ip_dst[20], sec_ip_src[20], sec_ip_dst[20= ]; =20 strcpy(pri_ip_src, inet_ntoa(ppkt->ip->ip_src)); @@ -334,7 +335,7 @@ static int colo_packet_compare_udp(Packet *spkt, Packet= *ppkt) if (ret) { trace_colo_compare_udp_miscompare("primary pkt size", ppkt->size); trace_colo_compare_udp_miscompare("Secondary pkt size", spkt->size= ); - if (trace_event_get_state(TRACE_COLO_COMPARE_MISCOMPARE)) { + if (trace_event_get_state_backends(TRACE_COLO_COMPARE_MISCOMPARE))= { qemu_hexdump((char *)ppkt->data, stderr, "colo-compare pri pkt= ", ppkt->size); qemu_hexdump((char *)spkt->data, stderr, "colo-compare sec pkt= ", @@ -371,7 +372,7 @@ static int colo_packet_compare_icmp(Packet *spkt, Packe= t *ppkt) ppkt->size); trace_colo_compare_icmp_miscompare("Secondary pkt size", spkt->size); - if (trace_event_get_state(TRACE_COLO_COMPARE_MISCOMPARE)) { + if (trace_event_get_state_backends(TRACE_COLO_COMPARE_MISCOMPARE))= { qemu_hexdump((char *)ppkt->data, stderr, "colo-compare pri pkt= ", ppkt->size); qemu_hexdump((char *)spkt->data, stderr, "colo-compare sec pkt= ", @@ -390,7 +391,7 @@ static int colo_packet_compare_icmp(Packet *spkt, Packe= t *ppkt) static int colo_packet_compare_other(Packet *spkt, Packet *ppkt) { trace_colo_compare_main("compare other"); - if (trace_event_get_state(TRACE_COLO_COMPARE_MISCOMPARE)) { + if (trace_event_get_state_backends(TRACE_COLO_COMPARE_MISCOMPARE)) { char pri_ip_src[20], pri_ip_dst[20], sec_ip_src[20], sec_ip_dst[20= ]; =20 strcpy(pri_ip_src, inet_ntoa(ppkt->ip->ip_src)); diff --git a/net/filter-rewriter.c b/net/filter-rewriter.c index 55a6cf56fd..98120095de 100644 --- a/net/filter-rewriter.c +++ b/net/filter-rewriter.c @@ -69,7 +69,7 @@ static int handle_primary_tcp_pkt(NetFilterState *nf, struct tcphdr *tcp_pkt; =20 tcp_pkt =3D (struct tcphdr *)pkt->transport_header; - if (trace_event_get_state(TRACE_COLO_FILTER_REWRITER_DEBUG)) { + if (trace_event_get_state_backends(TRACE_COLO_FILTER_REWRITER_DEBUG)) { trace_colo_filter_rewriter_pkt_info(__func__, inet_ntoa(pkt->ip->ip_src), inet_ntoa(pkt->ip->ip_dst), ntohl(tcp_pkt->th_seq), ntohl(tcp_pkt->th_ack), @@ -115,7 +115,7 @@ static int handle_secondary_tcp_pkt(NetFilterState *nf, =20 tcp_pkt =3D (struct tcphdr *)pkt->transport_header; =20 - if (trace_event_get_state(TRACE_COLO_FILTER_REWRITER_DEBUG)) { + if (trace_event_get_state_backends(TRACE_COLO_FILTER_REWRITER_DEBUG)) { trace_colo_filter_rewriter_pkt_info(__func__, inet_ntoa(pkt->ip->ip_src), inet_ntoa(pkt->ip->ip_dst), ntohl(tcp_pkt->th_seq), ntohl(tcp_pkt->th_ack), --=20 2.13.3