From mboxrd@z Thu Jan 1 00:00:00 1970 Authentication-Results: passt.top; dmarc=pass (p=quarantine dis=none) header.from=redhat.com Authentication-Results: passt.top; dkim=pass (1024-bit key; unprotected) header.d=redhat.com header.i=@redhat.com header.a=rsa-sha256 header.s=mimecast20190719 header.b=CrJvEhQZ; dkim-atps=neutral Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by passt.top (Postfix) with ESMTPS id 1820E5A0272 for ; Tue, 30 Sep 2025 23:30:31 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1759267830; 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=KEgc+lkaV44NvJGHAyjVkToQdYUJp0r5GZDHi+4Wsq0=; b=CrJvEhQZDK6LXtGAtRRsyCLTGLWj6pLm31r21flWky8HkptWMKb0iYdVfRVoYYMaJ4bLpU LvybRKG9b8qaUtqLT86y4YQcKp0rRj38J/yUFaRFA0VGIFG7rAq7G3LI+4GcWBPPI7DnlR g8o75Z95MKk+wl9twyuVIZj7G17HrDI= Received: from mail-wm1-f69.google.com (mail-wm1-f69.google.com [209.85.128.69]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-578-Ww2LCAmNNiC8JOP-TMKlug-1; Tue, 30 Sep 2025 17:30:28 -0400 X-MC-Unique: Ww2LCAmNNiC8JOP-TMKlug-1 X-Mimecast-MFC-AGG-ID: Ww2LCAmNNiC8JOP-TMKlug_1759267827 Received: by mail-wm1-f69.google.com with SMTP id 5b1f17b1804b1-46e45899798so17359895e9.3 for ; Tue, 30 Sep 2025 14:30:28 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1759267826; x=1759872626; 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=KEgc+lkaV44NvJGHAyjVkToQdYUJp0r5GZDHi+4Wsq0=; b=s8qs3X6KPwtcSrz7sa9hnbK0vy7wFor1MmZQLByBc22wpQ8VEgIZA93t1fgWAZKWvt XoGjIkA0Q81CYQjVd8zpfhzuTCH9+NK1C956LnD2ms9AfHR282KJMQP+tp3FQtZ0hy+S 34YhklBecckkbTG0iUVVgCsi+FqqD2WDrUTEKPx8Ut5vqW/DJDcZBUMf51/OIpMFR+Um vokPurpchCyK+LhysjrAur7xoX3wrISoxd8YT5oJ44RfB8dNujwlMTZbOA64fOH6/Y9F ywa6iGIqUYcSj3eTs6yqdFf+4Jyv9JJ5ShG3ZHqzDIUjjUBBIKeIkZ2LRe/SCfCuwED7 h4Zw== X-Forwarded-Encrypted: i=1; AJvYcCU2LY+JwzRM0i48pw1QvbympbSPT5SrcQfLWSf3nGYFTYd8QiIG1ZKamh0seY8Rt3M5a3C5k08zH24=@passt.top X-Gm-Message-State: AOJu0YzRcQ8tbqty0TTmnT0720uPM3vBTsJwpcGrECULGpRaWdhx8nMf 4E3JbPE7c5AwMIUydo/2uxfGjOIuh5XuQym5N+ZkeixkMc3CqkdR8x8uzxrQGE/7PNKkyV48qM/ TSE1AQBMFGvwAFlKLZzCfAN/aNNuugTSNSDixBjKR2JnHQFo7m6dmIwlTkKFWPg== X-Gm-Gg: ASbGncvkVUvkaRHYeLHs6/weDLVRkAeR4Od7uiA+1T4vTuFHeY2O8PnRTFvlL5AuDdT TZ84HuTqHdQ9bOPfiIK3mV2zcTAjnAKtC7aIPKteAQnC5LRVyiZXybtxP9HH41L8rtR0kEwN6Hy fO0OGiPakcujoNr902YEXpI0tR902aDpZP/kdqHVAkpwaVIBRo3AuFodEtjpb7SQgLLwAgcPmPB TgNaHU5LXKgdIcREAf+kBUWikCY3tCpLb7hMKbNrQqFI8k6aSVjvO8GbdlyUStRDgSHF+jjxMip aqLK1Zh38hfbgfGi9dmfePRQHAOrix7/kPKYrWp9c9iW48oAfwvpLuPH X-Received: by 2002:a05:600c:8b83:b0:46e:49fb:4776 with SMTP id 5b1f17b1804b1-46e61216b48mr10789765e9.11.1759267826590; Tue, 30 Sep 2025 14:30:26 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFt9OCnOAOypx9Rpl+Rqyf3uny4zTEw9kimB3aepj5qBl1IRBrvtNDcRU+I293JCUs1aITUkA== X-Received: by 2002:a05:600c:8b83:b0:46e:49fb:4776 with SMTP id 5b1f17b1804b1-46e61216b48mr10789615e9.11.1759267826077; Tue, 30 Sep 2025 14:30:26 -0700 (PDT) Received: from maya.myfinge.rs (ifcgrfdd.trafficplex.cloud. [2a10:fc81:a806:d6a9::1]) by smtp.gmail.com with ESMTPSA id 5b1f17b1804b1-46e6111c1f4sm7727065e9.0.2025.09.30.14.30.25 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 30 Sep 2025 14:30:25 -0700 (PDT) Date: Tue, 30 Sep 2025 23:30:24 +0200 From: Stefano Brivio To: Jon Maloy Subject: Re: [PATCH v11 9/9] icmp: let icmp use mac address from flowside structure Message-ID: <20250930233024.56b9b57e@elisabeth> In-Reply-To: <20250927192522.3024554-10-jmaloy@redhat.com> References: <20250927192522.3024554-1-jmaloy@redhat.com> <20250927192522.3024554-10-jmaloy@redhat.com> Organization: Red Hat X-Mailer: Claws Mail 4.2.0 (GTK 3.24.49; x86_64-pc-linux-gnu) MIME-Version: 1.0 X-Mimecast-Spam-Score: 0 X-Mimecast-MFC-PROC-ID: myWIjIl71plbMtFmNgihW67atR7hgm9XHSHRggbrNDY_1759267827 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Message-ID-Hash: KVEXKYOJ6GFB7FYDVHFIEDO3PA4QLR3M X-Message-ID-Hash: KVEXKYOJ6GFB7FYDVHFIEDO3PA4QLR3M 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: dgibson@redhat.com, david@gibson.dropbear.id.au, 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 Sat, 27 Sep 2025 15:25:22 -0400 Jon Maloy wrote: > Even ICMP needs to be updated to use the external MAC address instead > of just the own tap address when applicable. We do that here. > > Signed-off-by: Jon Maloy > Reviewed-by: David Gibson > > --- > v3: - Adapted to the move of external MAC address from struct flowside > to struct flow_common > v4: - Adapted to name changes in previous commits in this series > v5: - Added conditional lookup in ARP/NDP if the flow's tap_omac is > undefined > v6: - Looking up MAC of ICMP generating node in udp_send_tap_icmp4/6() > when available, instead trusting the contents of flow->tap_omac. > --- > icmp.c | 8 ++++++-- > ndp.c | 2 +- > tap.c | 10 ++++++---- > tap.h | 4 ++-- > udp.c | 12 ++++++++++-- > 5 files changed, 25 insertions(+), 11 deletions(-) > > diff --git a/icmp.c b/icmp.c > index 6dffafb..1d99632 100644 > --- a/icmp.c > +++ b/icmp.c > @@ -125,17 +125,21 @@ void icmp_sock_handler(const struct ctx *c, union epoll_ref ref) > flow_dbg(pingf, "echo reply to tap, ID: %"PRIu16", seq: %"PRIu16, > ini->eport, seq); > > + /* Try to find true MAC address in ARP/NDP table if needed */ Same as for 4/9: consider using "recorded". Everything else looks good to me! But I haven't tried using my little hammer on it, yet. -- Stefano