From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-pg1-f194.google.com (mail-pg1-f194.google.com [209.85.215.194]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 15C67480356 for ; Tue, 18 Aug 2026 17:03:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.215.194 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787072637; cv=none; b=YsC3nZz0Tpn7KQ8TRbLYJEzjLoHs1/YRbz62GDmQArVFTXKEmybq4yYbZv3cDpvw3kKJCyrMc/kCmKPqy++/EanVwHEDbxE9D+ae5NtIMbA83wruxcuXDRPC6umcoETim4PtgKCDkaUED6dItuAEFj60D1rtp3g7ucesRmguyLk= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1787072637; c=relaxed/simple; bh=08GCpWBt+z4DejZQ9YX8rfyawTv3wwnrM8KFHn2j+YY=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=VQrwvf9qE6/5UkYmlCr1KgLkJe4B8qKIA2fRUt8Va9WyNHZehRocuvNVSxCIlZxAIU4QFl2QfTCntctJVycPgCXN5WAJEA8Apwyc1jgMsaUyB56QDYz7AoSfQauH1K2cDQHAi1SLScOY9Ug1Dr54TUS/1HOdV6rEsl6homM8hPE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=CIB6du8I; arc=none smtp.client-ip=209.85.215.194 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="CIB6du8I" Received: by mail-pg1-f194.google.com with SMTP id 41be03b00d2f7-cc147d86bebso817218a12.0 for ; Tue, 18 Aug 2026 10:03:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1787072635; x=1787677435; darn=vger.kernel.org; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:from:to:cc:subject :date:message-id:reply-to:content-type; bh=LARP5bmG64wd0GpLVR0nEMY/+zhPU+0Nmo0aQ8UdxmY=; b=CIB6du8ItoTnpe0+1vB0+nqdDaoSb6gIkX5fqUhNaWOomS+EF4RxaWPYEOOQCoDmfC SiQhCeiKeb2lPJIzuL4aJOCAaXUEc6oRZtHI6+h6rG9wjAd1ZFapQoyLl5y+k2g4R+KN t/dekYcEgK9A4QbX/dv1Q4kavkBUfDTcADjS8cAY/HY+aDIMHUQZI+ybx1fIeZMLjAIM gIBsZG47uWiRZL0d9dgl0bXE2loF0/MH1YePeV21Dkn6sMGvOb2xyitaEu0kVUskf5S2 zCJzakCQogldTbNW/SIbyI/L3LG3S8VE20LVKnUQrbYB6Vetx6MjchF/orqDpJW9jH44 mmLA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1787072635; x=1787677435; h=in-reply-to:content-disposition:content-type:mime-version :references:message-id:subject:cc:to:from:date:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to :content-type; bh=LARP5bmG64wd0GpLVR0nEMY/+zhPU+0Nmo0aQ8UdxmY=; b=JQT6oOhxa8U8ZSJXg0OAai/syyctdfVUUwkWSXnDICBzDz/mvrGolxeVmYfHOqy9KE 4dFxhKHImgbqOECSciS5z2vbVEdyCl+E8oiEtW3U0NU68rEAwYje57MBJ9gQ8LNND9Lu PCKOFMhPct/D4TwJ0rSLNK1MAmGWHheNudOqqWbbJCjnrn6p4UHnnHn55KTCy+7b+LnQ oz+sg1Y5TdEnQJQ8VqnyxpGKX2OUfCn3PFqyBush05SwoynrcwqtU6RHHx+2VYKDSy5T ZGnRv6gcfYbjryqYE6pA9peDLN3rjhTyxaFU100+uBT458qXHJj/KMNGNvaTgTInhF58 E+Iw== X-Forwarded-Encrypted: i=1; AHgh+RqiJKy3SG5yp1/MyIHD5r+oVWrbRm9g3goMoAyrkA4FdG5uO5bx4IvWUXWr3Aqs8FCRJnD7+sGHd2bXSaU=@vger.kernel.org X-Gm-Message-State: AOJu0Yy9Kiu67Ddy9n7kmRBUbQdvYAYeNR1qTJyUZuXDnY9xuuUxzz8x WUNm/Er3l1KRGpE0njSKh8PHF2JrG+Z2j0i3aamPEQFA1ba9ORruXdvh X-Gm-Gg: AR+sD11Bgl6xhd0uuIINyV4HljDsBUcOETumRycMFoIMhNq3RvFbWIm/EcJUGCEdVLG s+4leT+x0TAZX+/2wkvQBJOx0OR1RqnKPA9DBwCK4bNxK3Ck51qhLMAOyJR0X0EDSBs01fTXLLg 5gIDNiTPOnhpD4uxE5nO+Tex1laKMiPuKZFgvLtTufWzDaTJz7AmSLjRgY6awDrF8BKa4s/E/Q8 welIEZme3uoNS6pWUsy4eTVqG/vgTE6WrKs8qOxhACWVm0Cmssgq59f7dO/yRoHH7GnLl+7Zsm5 m6cOVg31f2a6RwjKUa93zvaqxB9DoX4bFZoAV7H0ymdgJO77aKxrLGNaq9Y+SdAft0R4gQmmnkr rVTc7FIeysRGBhZGOwrFS7T3Gluh0pq61L558lw26rOV3uCCNBhkHoXW+9vXWaUArp9RCUqQtYP ojK6I3faKD9SO/fDNABtblZDPCTPh/XRrfunKEDGv5F/PdbFBzHWJ5KvyNUsOtoiu+ X-Received: by 2002:a05:6a20:2446:b0:39b:bc11:9ec5 with SMTP id adf61e73a8af0-3ccded40c3emr7581611637.13.1787072635279; Tue, 18 Aug 2026 10:03:55 -0700 (PDT) Received: from localhost ([2a03:2880:2ff:56::]) by smtp.gmail.com with ESMTPSA id 41be03b00d2f7-cc13c0445c6sm2311742a12.32.2026.08.18.10.03.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 18 Aug 2026 10:03:54 -0700 (PDT) Date: Tue, 18 Aug 2026 10:03:38 -0700 From: Stanislav Fomichev To: Arnd Bergmann Cc: Netdev , "David S . Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Anthony L Nguyen , Przemek Kitszel , andrew+netdev@lunn.ch, Saeed Mahameed , Tariq Toukan , Mark Bloch , Maxime Chevallier , Maxime Coquelin , Alexandre Torgue , Alexander Lobakin , Simon Horman , magnus.karlsson@intel.com, Maciej Fijalkowski , Stanislav Fomichev , Alexei Starovoitov , Daniel Borkmann , Jesper Dangaard Brouer , John Fastabend , witu@nvidia.com, Martin KaFai Lau , yoong.siang.song@intel.com, rohan.g.thomas@intel.com, "intel-wired-lan@lists.osuosl.org" , linux-kernel@vger.kernel.org, linux-rdma@vger.kernel.org, linux-stm32@st-md-mailman.stormreply.com, linux-arm-kernel@lists.infradead.org, bpf@vger.kernel.org, Leon Romanovsky Subject: Re: [PATCH net v2 1/3] xsk: align TX metadata layout across ABIs Message-ID: References: <20260813190800.222527-1-sdf@fomichev.me> <20260813190800.222527-2-sdf@fomichev.me> <06f8153d-2156-4e7d-9d49-006db4b2cec4@app.fastmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: <06f8153d-2156-4e7d-9d49-006db4b2cec4@app.fastmail.com> On 08/17, Arnd Bergmann wrote: > On Thu, Aug 13, 2026, at 21:07, Stanislav Fomichev wrote: > > Add explicit padding before launch_time so xsk_tx_metadata has the same > > layout on 32-bit and 64-bit systems. > > > > On i386 and m68k, the old native 32-bit layout put launch_time at offset 12 > > and had a natural size of 20 bytes. Using sizeof(struct xsk_tx_metadata) as > > tx_metadata_len was already rejected because the length must be a multiple > > of eight, so the straightforward use of the interface was broken on those > > ABIs. Userspace could still register a padded length of 24 bytes, though; > > mixing the old and new layouts then silently reads launch_time from the > > wrong offset and misprograms packet launch times. This intentionally > > replaces that incompatible layout while the interface is still new. > > > > Fixes: ca4419f15abd ("xsk: Add launch time hardware offload support to > > XDP Tx metadata") > > Signed-off-by: Stanislav Fomichev > > This is probably the right approach, given lack of alternatives. > In the changelog text, it may be worth noting a few more points: > > - A few additional architectures have the same issue: csky, > nios2, openrisc and sh. > - the commit that introduced the mistake was part of linux-6.15, > so the 6.18-lts release also needs an ABI change. I don't > think the "while the interface is still new" wording > makes sense here. > - what actually saves us here is that none of the affected > architectures are likely to have notable use cases for > xdp that would care about the ABI break. > The one that is most likely to have affected users > is x86-compat, and that is also the only one that is > broken right now. Will try to add that to the commit description, thanks!