Received: by 2002:ac0:bc90:0:0:0:0:0 with SMTP id a16csp5119840img; Wed, 27 Mar 2019 02:26:57 -0700 (PDT) X-Google-Smtp-Source: APXvYqw47Pg4SaOnhORvDIAlO4ZZSZLklqIMGYIL93S99Apo7OUoPnlZzBkBckWx+2EGYrRNuuuE X-Received: by 2002:a65:5003:: with SMTP id f3mr20812930pgo.29.1553678817433; Wed, 27 Mar 2019 02:26:57 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1553678817; cv=none; d=google.com; s=arc-20160816; b=QKZVRQeJmi+fUZ3rKghoLUYEJQpJMaU2YmIGzXGM2vTUAQ70DLnaDUuD44jIMgrlS9 xhxlp1tNSL8RkuCjqQXfxetmxCV8S3w/FuWqWex7bfsHRYDAqZttc6CHrxFLz67sKYNv bYu4vvSJFfFLn+uXhaEfDfeOrBnnesZNbZZx6u88JFSxMDmJgkrNtRvcdhV09oD0Yzy0 zE9Bu9ueEly02FhaHM2P0jS+T34PvFa6yCaXaRQQXcc90mHGSF7r8TP0PXLEPKFP79Qq GTXw1Z5/7OPXiAIRlyztH+Vyn9DCnkBP1QkiIsCQLKqQw9ZibIyt2FCYvbHDOecep4vk Cu9Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=8LLwSdyPWGqlp4Bzp0+4r35rrwN84Sc823Flf31HzUU=; b=zYXYWpdT41zl1g+UIehK7E0HPJP1ut865ja3iEOqcTYkEdBvxwlRyRQRUtLobF48zZ n4C6JMuhUxGza/1nDdMkl7CzG8vrW+A2aVqkIMPEI2jnl63NGYCXmHsbTeXCzVOsUj2Y ld+8uaFPV7GiIAMoLHFE+TU8xI7J7Vd9+2NnDoiuRTUisKdlbRIDKWBLMDPuELTQ2QcW ESQSmng9t8M2nHfIsYSetTtS/Zaq1isZDBRVt93x6H38cnI3YDYn4gtzgm/XlF22p8Ln E4u76CVLl3Kvt5x3IGTDIEpQIZVkWWF3YcBT/nX+k8acgxbFrSGcPL2obRmWZ0xzAYsD 8cNw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@resnulli-us.20150623.gappssmtp.com header.s=20150623 header.b=zBR+Qy2n; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i37si9341092pgb.436.2019.03.27.02.26.41; Wed, 27 Mar 2019 02:26:57 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@resnulli-us.20150623.gappssmtp.com header.s=20150623 header.b=zBR+Qy2n; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1731920AbfC0J0F (ORCPT + 99 others); Wed, 27 Mar 2019 05:26:05 -0400 Received: from mail-wr1-f65.google.com ([209.85.221.65]:38651 "EHLO mail-wr1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726237AbfC0J0E (ORCPT ); Wed, 27 Mar 2019 05:26:04 -0400 Received: by mail-wr1-f65.google.com with SMTP id k11so10223295wro.5 for ; Wed, 27 Mar 2019 02:26:03 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=resnulli-us.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:references:mime-version :content-disposition:in-reply-to:user-agent; bh=8LLwSdyPWGqlp4Bzp0+4r35rrwN84Sc823Flf31HzUU=; b=zBR+Qy2ngxhlmx0bhOflb4EWbBzIQufoYWEwQINj49YmvS3Bbprw9iODeMCa0l3Fe4 DdNbtQqBFMI/+8/XrdXwZiay/wy78XrjX00M6rl1aPJMjFJFU5uUdjd6i7q/hha2Ujpb ubXYr4sMIZ9K0qI1H5C7M7hAEw46TFL1jPz7US5iQpft3UbE26M+JaAcuRhDLvNt0Ipg N6/7UYgt4hLglA6+0DulTF0zcKIT5PrTYIMNkodN5O6uBCBZox4RFXgD3BdOjIEoEN5k dPdeIzruXQrwnd2Ao8weoqcRXmI36LdCqFgqoLX9IZdt7B+kpuc+isZPl12B7Zbn3hiv pRwQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=8LLwSdyPWGqlp4Bzp0+4r35rrwN84Sc823Flf31HzUU=; b=GeqqsaivAfTBkNiCrfJtXsSuxQ8SVjW5N3TQ0ZpLe74qe5ubkREqg0cVWiviNM3e1h 8TU8KZpbWmgrpg0Y29MECiX2K0KLfHL1MIaRzJOL2vsEGF4aCVdXKikldWTJc27Xnk4y oE6yjDerKdhYNa6ZBM4PTOqnQLCF0p30TbcycJ7QqfVY0N4za1uNrGcfz1PdyDPIU9fv H8ICr69Zk5zr9mV5kS371vf6hmhjnk3jgafrTUmThO/H0vSn04XpZL6Lj8ndebUotpKY UU4wS4nCPWA0JQ4eTjMFLtR2/3UER8qv4mEgJVluHmqf+ZzyFOnHY5GjXOYFXuvWUVzs Rpew== X-Gm-Message-State: APjAAAVfxDk8CO0+fYZ2W5ZEAzRnn78TutWmvn837bAkZwj88rXd+ap4 IiDzAxElLO0/OkDtahM/rIEmpQ== X-Received: by 2002:a05:6000:5:: with SMTP id h5mr21844046wrx.271.1553678763176; Wed, 27 Mar 2019 02:26:03 -0700 (PDT) Received: from localhost (ip-94-113-223-73.net.upcbroadband.cz. [94.113.223.73]) by smtp.gmail.com with ESMTPSA id z7sm2500551wrt.10.2019.03.27.02.26.02 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 27 Mar 2019 02:26:02 -0700 (PDT) Date: Wed, 27 Mar 2019 10:26:02 +0100 From: Jiri Pirko To: Michal Kubecek Cc: David Miller , netdev@vger.kernel.org, Jakub Kicinski , Andrew Lunn , Florian Fainelli , John Linville , Stephen Hemminger , linux-kernel@vger.kernel.org Subject: Re: [PATCH net-next v5 05/22] ethtool: introduce ethtool netlink interface Message-ID: <20190327092602.GA6979@nanopsycho> References: <8795d07d3315b232b4e7ebc7d109c9aa3185e555.1553532199.git.mkubecek@suse.cz> <20190326163640.GD4958@nanopsycho.orion> <20190326173215.GM26076@unicorn.suse.cz> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20190326173215.GM26076@unicorn.suse.cz> User-Agent: Mutt/1.11.3 (2019-02-01) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Tue, Mar 26, 2019 at 06:32:15PM CET, mkubecek@suse.cz wrote: >On Tue, Mar 26, 2019 at 05:36:40PM +0100, Jiri Pirko wrote: >> Mon, Mar 25, 2019 at 06:08:09PM CET, mkubecek@suse.cz wrote: >> >+/* genetlink setup */ >> >+ >> >+static const struct genl_ops ethtool_genl_ops[] = { >> >> Please be consistent with prefixes. Either use "ethtool_" or "ethnl_" >> for all functions and variables in this code. > >OK > >> >+/* module setup */ >> >+ >> >+static int __init ethnl_init(void) >> >+{ >> >+ int ret; >> >+ >> >+ ret = genl_register_family(ðtool_genl_family); >> >+ if (WARN(ret < 0, "ethtool: genetlink family registration failed")) >> >> Why do you need this warning? Please avoid it. > >I'm confused now... few days ago you replied "+1" to the idea: > > http://lkml.kernel.org/r/20190321162105.GU2087@nanopsycho > >I agreed that panic() (which is what e.g. rtnetlink does) would be an >overkill but I would be definitely opposed to not having anything in the >log at all and just silently going on without the interface (which may >result in misconfigured network). I believe that if this fails, it is >a sign of something going very wrong inside the kernel so that the "W" >taint flag would be appropriate. Okay. Fair. It's just that I looked over the code and did not find any other genl_register_family() call with WARN. > >Michal