From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752314AbdCWWFc (ORCPT ); Thu, 23 Mar 2017 18:05:32 -0400 Received: from shards.monkeyblade.net ([184.105.139.130]:57956 "EHLO shards.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751349AbdCWWFa (ORCPT ); Thu, 23 Mar 2017 18:05:30 -0400 Date: Thu, 23 Mar 2017 15:05:00 -0700 (PDT) Message-Id: <20170323.150500.1211908608737471263.davem@davemloft.net> To: parameswaran.r7@gmail.com Cc: netdev@vger.kernel.org, kleptog@svana.org, jchapman@katalix.com, nprachan@brocade.com, rshearma@brocade.com, stephen@networkplumber.org, sdietric@brocade.com, ciwillia@brocade.com, lboccass@brocade.com, dfawcus@brocade.com, bhong@brocade.com, jblunck@brocade.com, linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next v4 1/2] New kernel function to get IP overhead on a socket. From: David Miller In-Reply-To: References: X-Mailer: Mew version 6.7 on Emacs 24.5 / Mule 6.0 (HANACHIRUSATO) Mime-Version: 1.0 Content-Type: Text/Plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-Greylist: Sender succeeded SMTP AUTH, not delayed by milter-greylist-4.5.12 (shards.monkeyblade.net [149.20.54.216]); Thu, 23 Mar 2017 15:05:29 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: "R. Parameswaran" Date: Wed, 22 Mar 2017 15:59:13 -0700 (PDT) > A new function, kernel_sock_ip_overhead(), is provided > to calculate the cumulative overhead imposed by the IP > Header and IP options, if any, on a socket's payload. > The new function returns an overhead of zero for sockets > that do not belong to the IPv4 or IPv6 address families. > > Signed-off-by: R. Parameswaran Just use the IPv4/IPv6 header size for now, just like the VXLAN driver does. Thanks.