From mboxrd@z Thu Jan 1 00:00:00 1970 Received: by passt.top (Postfix, from userid 1000) id 0F9F95A0624; Mon, 08 Dec 2025 22:28:22 +0100 (CET) From: Stefano Brivio To: passt-dev@passt.top Subject: [PATCH] flow: Set EPOLLFD_ID_DEFAULT on newly allocated flows, not EPOLLFD_ID_INVALID Date: Mon, 8 Dec 2025 22:28:22 +0100 Message-ID: <20251208212822.2721774-1-sbrivio@redhat.com> X-Mailer: git-send-email 2.43.0 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-ID-Hash: ZHI7TXOLN3KNU7574LU7BGJFPBBTGRZ4 X-Message-ID-Hash: ZHI7TXOLN3KNU7574LU7BGJFPBBTGRZ4 X-MailFrom: sbrivio@passt.top X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; digests; suspicious-header CC: David Gibson , Laurent Vivier X-Mailman-Version: 3.3.8 Precedence: list List-Id: Development discussion and patches for passt Archived-At: Archived-At: List-Archive: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: We're somehow hitting: ASSERTION FAILED in flow_epollfd (flow.c:362): f->epollid < ((1 << 8) - 1) on an inbound spliced connection, with a single forwarded port, an HTTP server in a Podman container, and a GET request. Reproducer at https://bodhi.fedoraproject.org/updates/FEDORA-2025-93b4eb64c3#comment-4473411 printf 'FROM registry.fedoraproject.org/fedora:latest\nRUN /usr/bin/dnf install -y httpd\nEXPOSE 80\nCMD ["-D", "FOREGROUND"]\nENTRYPOINT ["/usr/sbin/httpd"]\n' > Containerfile podman build -t fedora-httpd $(pwd) podman run -d -p 8080:80 localhost/fedora-httpd curl http://localhost:8080 I guess we don't set EPOLLFD_ID_DEFAULT early enough on inbound spliced sockets for some reason and we get a socket event while we still have EPOLLFD_ID_INVALID set. As we're not really using epoll identifiers yet, set EPOLLFD_ID_DEFAULT right away on newly allocated flows, while we figure this out. Link: https://bodhi.fedoraproject.org/updates/FEDORA-2025-93b4eb64c3#comment-4473411 Signed-off-by: Stefano Brivio --- I just merged this, posting for awareness / review. flow.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/flow.c b/flow.c index 8d72965..f1bde9a 100644 --- a/flow.c +++ b/flow.c @@ -382,7 +382,8 @@ void flow_epollid_set(struct flow_common *f, int epollid) */ void flow_epollid_clear(struct flow_common *f) { - f->epollid = EPOLLFD_ID_INVALID; + /* FIXME: Use EPOLLFD_ID_INVALID instead once it's safe to do so */ + f->epollid = EPOLLFD_ID_DEFAULT; } /** -- 2.43.0