From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from out0.migadu.com (out0.migadu.com [IPv6:2001:41d0:2:267::]) by mail.toke.dk (Postfix) with ESMTPS id DE1129BEA22 for ; Fri, 11 Nov 2022 02:39:06 +0100 (CET) Authentication-Results: mail.toke.dk; dkim=pass (1024-bit key; unprotected) header.d=linux.dev header.i=@linux.dev header.a=rsa-sha256 header.s=key1 header.b=KOIpzGnb Message-ID: DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linux.dev; s=key1; t=1668130746; 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=twDtSwj2Z37lCvXOgLdZKmh5FpMX714tcT+gZauocX4=; b=KOIpzGnbUf+6ykkdl3c9FO5xpydUPJ3oSwuzM6myq3dUhK/+2ddxSgHbU9kvQCY/0CxXvw kil1n3mvrlUGjXkDfmvRFkL2TxEsBRasxhG+Sc4RK9ZGk19KbiODfNiBKr93CiTDQQzHp+ VQi1/+b8rH84Qo9pF1nSINvoWS2Zqm0= Date: Thu, 10 Nov 2022 17:39:00 -0800 MIME-Version: 1.0 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Martin KaFai Lau To: =?UTF-8?Q?Toke_H=c3=b8iland-J=c3=b8rgensen?= References: <20221104032532.1615099-1-sdf@google.com> <20221104032532.1615099-7-sdf@google.com> <187e89c3-d7de-7bec-c72e-d9d6eb5bcca0@linux.dev> <9a8fefe4-2fcb-95b7-cda0-06509feee78e@linux.dev> <6f57370f-7ec3-07dd-54df-04423cab6d1f@linux.dev> <87leokz8lq.fsf@toke.dk> <5a23b856-88a3-a57a-2191-b673f4160796@linux.dev> <871qqazyc9.fsf@toke.dk> <7eb3e22a-c416-e898-dff0-1146d3cc82c0@linux.dev> <87mt8yxuag.fsf@toke.dk> Content-Language: en-US In-Reply-To: <87mt8yxuag.fsf@toke.dk> Content-Type: text/plain; charset="utf-8"; format="flowed" Content-Transfer-Encoding: base64 X-Migadu-Flow: FLOW_OUT Message-ID-Hash: FJVVXABYZDBPSXHYN2IO3SVOMKC4JNIH X-Message-ID-Hash: FJVVXABYZDBPSXHYN2IO3SVOMKC4JNIH X-MailFrom: martin.lau@linux.dev 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: Stanislav Fomichev , ast@kernel.org, daniel@iogearbox.net, andrii@kernel.org, song@kernel.org, yhs@fb.com, john.fastabend@gmail.com, kpsingh@kernel.org, haoluo@google.com, jolsa@kernel.org, David Ahern , Jakub Kicinski , Willem de Bruijn , Jesper Dangaard Brouer , Anatoly Burakov , Alexander Lobakin , Magnus Karlsson , Maryam Tahhan , xdp-hints@xdp-project.net, netdev@vger.kernel.org, bpf@vger.kernel.org X-Mailman-Version: 3.3.6 Precedence: list Subject: [xdp-hints] Re: [RFC bpf-next v2 06/14] xdp: Carry over xdp metadata into skb context List-Id: XDP hardware hints design discussion Archived-At: List-Archive: List-Help: List-Owner: List-Post: List-Subscribe: List-Unsubscribe: T24gMTEvMTAvMjIgMzoyOSBQTSwgVG9rZSBIw7hpbGFuZC1Kw7hyZ2Vuc2VuIHdyb3RlOg0KPj4+ IEZvciB0aGUgbWV0YWRhdGEgY29uc3VtZWQgYnkgdGhlIHN0YWNrIHJpZ2h0IG5vdyBpdCdzIGEg Yml0DQo+Pj4gaHlwb3RoZXRpY2FsLCB5ZWFoLiBIb3dldmVyLCB0aGVyZSdzIGEgYnVuY2ggb2Yg bWV0YWRhdGEgY29tbW9ubHkNCj4+PiBzdXBwb3J0ZWQgYnkgaGFyZHdhcmUgdGhhdCB0aGUgc3Rh Y2sgY3VycmVudGx5IGRvZXNuJ3QgY29uc3VtZSBhbmQgdGhhdA0KPj4+IGhvcGVmdWxseSB0aGlz IGZlYXR1cmUgd2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