Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754620AbdGUP4o (ORCPT ); Fri, 21 Jul 2017 11:56:44 -0400 Received: from mx1.redhat.com ([209.132.183.28]:51066 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753502AbdGUP4m (ORCPT ); Fri, 21 Jul 2017 11:56:42 -0400 DMARC-Filter: OpenDMARC Filter v1.3.2 mx1.redhat.com 857D3D69AA Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; dmarc=none (p=none dis=none) header.from=redhat.com Authentication-Results: ext-mx03.extmail.prod.ext.phx2.redhat.com; spf=pass smtp.mailfrom=pabeni@redhat.com DKIM-Filter: OpenDKIM Filter v2.11.0 mx1.redhat.com 857D3D69AA Message-ID: <1500652599.3924.10.camel@redhat.com> Subject: Re: [RFC 1/2] net-next: add a dma_desc element to struct skb_shared_info From: Paolo Abeni To: John Crispin , "David S . Miller" , Eric Dumazet Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org Date: Fri, 21 Jul 2017 17:56:39 +0200 In-Reply-To: <20170721152035.6645-2-john@phrozen.org> References: <20170721152035.6645-1-john@phrozen.org> <20170721152035.6645-2-john@phrozen.org> Content-Type: text/plain; charset="UTF-8" Mime-Version: 1.0 Content-Transfer-Encoding: 7bit X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.27]); Fri, 21 Jul 2017 15:56:42 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1257 Lines: 38 Hi, On Fri, 2017-07-21 at 17:20 +0200, John Crispin wrote: > In order to make HW flow offloading work in latest MediaTek silicon we need > to propagate part of the RX DMS descriptor to the upper layers populating > the flow offload engines HW tables. This patch adds an extra element to > struct skb_shared_info allowing the ethernet drivers RX napi code to store > the required information and make it persistent for the lifecycle of the > skb and its clones. > > Signed-off-by: John Crispin > --- > include/linux/skbuff.h | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/include/linux/skbuff.h b/include/linux/skbuff.h > index 4093552be1de..db9576cd946b 100644 > --- a/include/linux/skbuff.h > +++ b/include/linux/skbuff.h > @@ -426,6 +426,7 @@ struct skb_shared_info { > unsigned int gso_type; > u32 tskey; > __be32 ip6_frag_id; > + u32 dma_desc; > > /* > * Warning : all fields before dataref are cleared in __alloc_skb() This will increase the skb_shared_info struct size, which is already quite large, and can have several kind of performance drawback. AFAIK this is discouraged. I don't understand the use case; the driver will set this field, but who is going to consume it? Thanks, Paolo