lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190321162105.GU2087@nanopsycho>
Date:   Thu, 21 Mar 2019 17:21:06 +0100
From:   Jiri Pirko <jiri@...nulli.us>
To:     Andrew Lunn <andrew@...n.ch>
Cc:     Michal Kubecek <mkubecek@...e.cz>,
        David Miller <davem@...emloft.net>, netdev@...r.kernel.org,
        Jakub Kicinski <jakub.kicinski@...ronome.com>,
        Florian Fainelli <f.fainelli@...il.com>,
        John Linville <linville@...driver.com>,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH net-next v4 05/22] ethtool: introduce ethtool netlink
 interface

Thu, Mar 21, 2019 at 04:25:09PM CET, andrew@...n.ch wrote:
>On Thu, Mar 21, 2019 at 03:13:43PM +0100, Michal Kubecek wrote:
>> On Thu, Mar 21, 2019 at 02:57:05PM +0100, Andrew Lunn wrote:
>> > On Thu, Mar 21, 2019 at 02:07:35PM +0100, Michal Kubecek wrote:
>> > > +static int __init ethnl_init(void)
>> > > +{
>> > > +	int ret;
>> > > +
>> > > +	ret = genl_register_family(&ethtool_genl_family);
>> > > +	if (ret < 0)
>> > > +		panic("ethtool: could not register genetlink family\n");
>> > 
>> > Panic seems a bit strong. Do we really want to kill the box because
>> > this fails?
>> 
>> When I switched CONFIG_ETHTOOL_NETLINK from tristate to bool, I checked
>> some other non-modular subsystems to see what they do on failed
>> initialization and each of them did handle it by panic() so I didn't
>> think about it too much and did the same.
>> 
>> Thinking about it now, if the family registration fails, the only entry
>> point to care about should be ethtool_notify() (I'll have to check more
>> carefully to be sure) so that adding a check there should be sufficient
>> to let everything work (except for the netlink interface, of course).
>
>Hi Michal
>
>So maybe do a WARN_ON() and return the error code.

+1

>
>Linus has been quite vocal about killing the box when there is no real
>need...
>
>	Andrew

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ