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.133.124]) by passt.top (Postfix) with ESMTP id E8BD75A004F for ; Wed, 10 Jul 2024 23:37:37 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1720647457; 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=zSaqITHG3WhABDVe6lP4Ksse98r7W/lx+1hTewJ6Rrg=; b=W9IraipbGkyj1CQn2WG65MJ4kzp5MGHddLalt0EMrC0xVfMIzncyvzGZ5mZzi2HwZeGt4N /+ioFwH99vOASFl1poyLLBoyGVKttlJs8llxMLZmgBZyeeGtWWyujyJ0ASikRnr9azKoA3 m3LAeDwfnsnn0nXw0dSjjDCSBJwO9t4= Received: from mail-qt1-f197.google.com (mail-qt1-f197.google.com [209.85.160.197]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-512-iNlq9m6fMKCjHhS2F3ui7w-1; Wed, 10 Jul 2024 17:37:36 -0400 X-MC-Unique: iNlq9m6fMKCjHhS2F3ui7w-1 Received: by mail-qt1-f197.google.com with SMTP id d75a77b69052e-447f7dfa343so2116511cf.2 for ; Wed, 10 Jul 2024 14:37:35 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1720647455; x=1721252255; 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=zSaqITHG3WhABDVe6lP4Ksse98r7W/lx+1hTewJ6Rrg=; b=whyWgbKsjZmOxxbqi9LFNQPPHOlct7pPskBW8JZdYIdZZJqprg8JwazO+yxZXGiUHS +LhY/TMdbn2qKIa41LLxTft/BycohOZzU5brXktCKyh6K4eG4Ozo5Ejxrl89Sb4oHYhE nEhljZxVUZEfIrbbYoDxsdpichc8nOA3/+DUCoQXd6u13lR/fGxXvECm8gtjNhLy3nmt JsvYyjQQr7jVP8YJn6mZD+4f5st0BptfzIZ5fiYZKP32R6Tv6MMulbrWAGdc8WrFCJYa iWejBV+efZjS3KrN6hXHzTr9MWpxGg4akJ2SBkdUg6imJW/HAkXZWw0QdwIidTkEj8sa Xd1g== X-Gm-Message-State: AOJu0Yz6+ZOyNsUbnkHI/cFBuOYov+DY4jM1J2Y4Dmrx22xkZwdqodCq CP03G1hkbk2WrYaOsh6cVdDalrgOxAR96ySeUyzIwmV97AErivBbXCGrvOXhTnEdU6qUudaKDfU xbDSOLzVOoUKmYhHkC/oRmOUFEHZbL2BON+AIWn2bt/gJexnJm7S6jwMISfCt X-Received: by 2002:ac8:7f4e:0:b0:447:f41a:aac5 with SMTP id d75a77b69052e-447fa8a39c8mr86504151cf.25.1720647455046; Wed, 10 Jul 2024 14:37:35 -0700 (PDT) X-Google-Smtp-Source: AGHT+IE3T3LCvndcK+c9XiEfAdem4M0Cxm1zkhiQzQDuQ93JXeODJ+pUAfP5HioBMIsXt7nHRsIfaQ== X-Received: by 2002:ac8:7f4e:0:b0:447:f41a:aac5 with SMTP id d75a77b69052e-447fa8a39c8mr86504011cf.25.1720647454785; Wed, 10 Jul 2024 14:37:34 -0700 (PDT) Received: from maya.cloud.tilaa.com (maya.cloud.tilaa.com. [164.138.29.33]) by smtp.gmail.com with ESMTPSA id d75a77b69052e-447f9bf6c53sm23587501cf.95.2024.07.10.14.37.34 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Wed, 10 Jul 2024 14:37:34 -0700 (PDT) Date: Wed, 10 Jul 2024 23:36:56 +0200 From: Stefano Brivio To: David Gibson Subject: Re: [PATCH v7 23/27] udp: Find or create flows for datagrams from tap interface Message-ID: <20240710233656.303b399d@elisabeth> In-Reply-To: <20240705020724.3447719-24-david@gibson.dropbear.id.au> References: <20240705020724.3447719-1-david@gibson.dropbear.id.au> <20240705020724.3447719-24-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: M2XSDBCOXDAC246BYXUQ2VAAENTU2U63 X-Message-ID-Hash: M2XSDBCOXDAC246BYXUQ2VAAENTU2U63 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, jmaloy@redhat.com 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: Some nits in the commit message only: On Fri, 5 Jul 2024 12:07:20 +1000 David Gibson wrote: > Currently we create flows for datagrams from socket interfaces, and use > them to direct "spliced" (socket to socket) datagrams. We don't yet > match datagrams from the tap interface to existing flows, nor create new > flows for them. Add that functionality, matching datagrams from tap to > existing flows when they exist, or creating new ones. > > As with spliced flows, when creating a new flow from tap to socket, we > create a new connected socket to receive reply datagrams attached to that > flow specifically. We extend udp_flow_sock_handler() to handle reply > packets bound for tap rather than another socket. > > For non-obvious reasons, this caused a failure for me when running under > valgrind, because valgrind invoked rt_sigreturn which is not in our > seccomp filter. That might be because the stack area needed by udp_reply_sock_handler() is now a bit bigger... or something like that, I suppose. > Since we already allow rt_signaction and others in the rt_sigaction > valgrind, it seems reasonable to add rt_sigreturn as well. valgrind target -- Stefano