From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S935738AbcA1NAK (ORCPT ); Thu, 28 Jan 2016 08:00:10 -0500 Received: from mail-pf0-f193.google.com ([209.85.192.193]:33766 "EHLO mail-pf0-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964930AbcA1NAE (ORCPT ); Thu, 28 Jan 2016 08:00:04 -0500 Message-ID: <1453986002.7627.20.camel@edumazet-glaptop2.roam.corp.google.com> Subject: Re: [PATCH net 0/4] net: add rx_unhandled stat counter From: Eric Dumazet To: Jarod Wilson Cc: linux-kernel@vger.kernel.org, "David S. Miller" , Eric Dumazet , Jiri Pirko , Daniel Borkmann , Tom Herbert , Jay Vosburgh , Veaceslav Falico , Andy Gospodarek , netdev@vger.kernel.org Date: Thu, 28 Jan 2016 05:00:02 -0800 In-Reply-To: <20160128061808.GD59058@redhat.com> References: <1453489882-57948-1-git-send-email-jarod@redhat.com> <1453926098-40181-1-git-send-email-jarod@redhat.com> <1453928987.20722.29.camel@edumazet-glaptop2.roam.corp.google.com> <20160128060215.GB59058@redhat.com> <20160128061808.GD59058@redhat.com> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.10.4-0ubuntu2 Mime-Version: 1.0 Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, 2016-01-28 at 01:18 -0500, Jarod Wilson wrote: > Or not. Now I remember why I added that in the first place: > > In file included from ./arch/x86/include/asm/uaccess.h:7:0, > from net/core/dev.c:75: > net/core/dev.c: In function 'netdev_stats_to_stats64': > include/linux/compiler.h:484:20: error: call to '__compiletime_assert_7263' declared with attribute error: BUILD_BUG_ON failed: sizeof(*stats64) != sizeof(*netdev_stats) > prefix ## suffix(); \ > ^ > > Things are actually hard-wired to require that addition at the moment, or > you get the above build failure. Not sure if it's safe to remove that > BUILD_BUG_ON() yet, haven't looked closely, it's past my bed time. :) > This was done for the transition from "unsigned long" to "u64", which is a nop on 64bit arches. But as we do not need to be compatible, since no linux kernel in the past had this new field in struct net_device_stats, and we do not need to add this new field as it is only accessed from core networking stack [1], you need to adapt this helper. [1] And maybe some virtual devices like bonding/team