From mboxrd@z Thu Jan 1 00:00:00 1970 From: Simon Horman Subject: Re: [RFC v4] Add TCP encap_rcv hook (repost) Date: Mon, 23 Apr 2012 08:27:09 +0900 Message-ID: <20120422232706.GA22375@verge.net.au> References: <20120419045333.GA21311@verge.net.au> <64d4ef6b-f082-4c25-97c2-528773fb4566@tahiti.vyatta.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Cc: dev-yBygre7rU0TnMu66kgdUjQ@public.gmane.org, netdev-u79uwXL29TY76Z2rM5mHXA@public.gmane.org, Eric Dumazet To: Stephen Hemminger Return-path: Content-Disposition: inline In-Reply-To: <64d4ef6b-f082-4c25-97c2-528773fb4566-bX68f012229Xuxj3zoTs5AC/G2K4zDHf@public.gmane.org> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: dev-bounces-yBygre7rU0TnMu66kgdUjQ@public.gmane.org Errors-To: dev-bounces-yBygre7rU0TnMu66kgdUjQ@public.gmane.org List-Id: netdev.vger.kernel.org On Sun, Apr 22, 2012 at 08:24:35AM -0700, Stephen Hemminger wrote: > > > > This hook is based on a hook of the same name provided by UDP. It > > provides > > a way for to receive packets that have a TCP header and treat them in > > some > > alternate way. > > > > It is intended to be used by an implementation of the STT tunneling > > protocol within Open vSwtich's datapath. A prototype of such an > > implementation has been made. > > > > The STT draft is available at > > http://tools.ietf.org/html/draft-davie-stt-01 > > > > My prototype STT implementation has been posted to the > > dev-UOEtcQmXneFl884UGnbwIQ@public.gmane.org > > The second version can be found at: > > http://www.mail-archive.com/dev-yBygre7rU0TnMu66kgdUjQ@public.gmane.org/msg09001.html > > It needs to be updated to call tcp_encap_enable() > > > > Cc: Eric Dumazet > > Signed-off-by: Simon Horman > > > > > > +static struct static_key tcp_encap_needed __read_mostly; > > +void tcp_encap_enable(void) > > +{ > > + if (!static_key_enabled(&tcp_encap_needed)) > > + static_key_slow_inc(&tcp_encap_needed); > > +} > > +EXPORT_SYMBOL(tcp_encap_enable); > > I have reservations about adding such a hook. but if we > must, then the hook must be GPL only. Sure, I have no objections there.