From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by passt.top (Postfix) with ESMTP id 3D2C75A004E for ; Fri, 07 Jun 2024 20:49:58 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1717786197; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=77DuXt58zjvpzv99oJ+P0bmnckfOPnTfxFzSa0hQO4A=; b=GlKbtMhu27XF6anCujXE56geSFG+7GzRzGVQgqbOe54gy1Na/9M09z1VVGBibDNo/GZvN0 fpaC8ktVzdFIC8L+dL5z5qIH8vFWB8DoXx7XDoStUEQvwB/QkV6tnmc6GD+7/kSB9fJt5R rZV3ea4W/ft50okkaiItCjNmCCP19Zw= Received: from mail-oi1-f199.google.com (mail-oi1-f199.google.com [209.85.167.199]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-407-HyjE-ONxNZ-RAIzwWR7RWQ-1; Fri, 07 Jun 2024 14:49:55 -0400 X-MC-Unique: HyjE-ONxNZ-RAIzwWR7RWQ-1 Received: by mail-oi1-f199.google.com with SMTP id 5614622812f47-3d1f22d79afso2602616b6e.2 for ; Fri, 07 Jun 2024 11:49:55 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1717786195; x=1718390995; h=content-transfer-encoding:mime-version:organization:references :in-reply-to:message-id:subject:cc:to:from:date:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=77DuXt58zjvpzv99oJ+P0bmnckfOPnTfxFzSa0hQO4A=; b=QlWIbcHBruyDzZOL/p7PRL8tpUTr/9B+wPuEDjBqCxxFeKFW7m7IkMibqkcy+ey4Fw 8uP6THA4tFNO7lH1n4PbrWtUxPRlDgLLDX/pHuk9Qh8vNkbQTpACZuh20VaRQgKXDowQ bQz+Vmiu/W3QcPiOVI2X8SWXILTGOTpaHdLX3wO+ovO7w8dlChXGjE3HrG/thJsuwtLv uJxAFlrktqysjAzbobLFGYQKUOqgSt0eqk020wKN59fXaYPGmZvPrzB3u9Iwig2uxbhG 792uYZQsvZXtTFzIL2ThWri9Vgf6BlDuIoVEznnDwPBJA+3Bgb14jbSma7uw48CTcr0r mlbA== X-Gm-Message-State: AOJu0YytmwP1AhntuUmB8au1uYXE25pdyEEVZfO/UqbqJ4ebinNzQiyN FCp5MzH2qk5xrXOTtPc0DoiJYXbFNJQNVxv3pFShKBqOQ13jt30wDgC59IyLlrzdNnc1GKo2/jw bePuJDIahVgUH3R6uPJi1N06EA91JMGzzIJ6P4P5wM+BhxVVF9A== X-Received: by 2002:a05:6808:1385:b0:3d2:160f:531c with SMTP id 5614622812f47-3d2160f9b72mr2217312b6e.58.1717786194723; Fri, 07 Jun 2024 11:49:54 -0700 (PDT) X-Google-Smtp-Source: AGHT+IH4tr51FeLdrpfLLlUThq4urmEW2lFg8JIXp/RPGHL2qU9/g8AOk/3xiHs6DIt54Q9Vk5OGxg== X-Received: by 2002:a05:6808:1385:b0:3d2:160f:531c with SMTP id 5614622812f47-3d2160f9b72mr2217277b6e.58.1717786193857; Fri, 07 Jun 2024 11:49:53 -0700 (PDT) Received: from maya.cloud.tilaa.com (maya.cloud.tilaa.com. [164.138.29.33]) by smtp.gmail.com with ESMTPSA id 6a1803df08f44-6b04f6213d4sm19806366d6.15.2024.06.07.11.49.53 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Fri, 07 Jun 2024 11:49:53 -0700 (PDT) Date: Fri, 7 Jun 2024 20:49:17 +0200 From: Stefano Brivio To: David Gibson Subject: Re: [PATCH] tcp, flow: Fix some error paths which didn't clean up flows properly Message-ID: <20240607204917.70dd6cf4@elisabeth> In-Reply-To: <20240607015524.1633407-1-david@gibson.dropbear.id.au> References: <20240607015524.1633407-1-david@gibson.dropbear.id.au> Organization: Red Hat X-Mailer: Claws Mail 4.2.0 (GTK 3.24.41; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-ID-Hash: HLSSMPG2XANQMD4IDPLW3J3OFRPIY7EH X-Message-ID-Hash: HLSSMPG2XANQMD4IDPLW3J3OFRPIY7EH X-MailFrom: sbrivio@redhat.com 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: passt-dev@passt.top 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: On Fri, 7 Jun 2024 11:55:24 +1000 David Gibson wrote: > Flow table entries need to be fully initialised before returning to the > main epoll loop. Commit 0060acd1 ("flow: Clarify and enforce flow state > transitions") now enforces that: once a flow is allocated we must either > cancel it, or activate it before returning to the main loop, or we will hit > an ASSERT(). > > Some error paths in tcp_conn_from_tap() weren't correctly updated for this > requirement - we can exit with a flow entry incompletely initialised. > Correct that by cancelling the flows in those situations. > > I don't have enough information to be certain if this is the cause for > podman bug 22925, but it plausibly could be. > > Fixes: 0060acd1 ("flow: Clarify and enforce flow state transitions") > Link: https://github.com/containers/podman/issues/22925 > > Signed-off-by: David Gibson Applied. -- Stefano