From mboxrd@z Thu Jan 1 00:00:00 1970 From: Jiri Pirko Subject: Re: [RFC net-next 0/6] devlink: add device (driver) information API Date: Tue, 15 Jan 2019 09:12:44 +0100 Message-ID: <20190115081244.GA2290@nanopsycho> References: <20190115005009.16025-1-jakub.kicinski@netronome.com> <20190115011859.GA8882@lunn.ch> <20190114173306.3d8037cd@cakuba.netronome.com> <20190115015755.GE8882@lunn.ch> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Jakub Kicinski , davem@davemloft.net, netdev@vger.kernel.org, oss-drivers@netronome.com To: Andrew Lunn Return-path: Received: from mail-wr1-f65.google.com ([209.85.221.65]:33894 "EHLO mail-wr1-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1727703AbfAOIVS (ORCPT ); Tue, 15 Jan 2019 03:21:18 -0500 Received: by mail-wr1-f65.google.com with SMTP id j2so1895845wrw.1 for ; Tue, 15 Jan 2019 00:21:18 -0800 (PST) Content-Disposition: inline In-Reply-To: <20190115015755.GE8882@lunn.ch> Sender: netdev-owner@vger.kernel.org List-ID: Tue, Jan 15, 2019 at 02:57:55AM CET, andrew@lunn.ch wrote: >> I think the plan was to use this opportunity to move the information >> which belongs in devlink to devlink. There is absolutely nothing >> netdev specific here, and ethtool uses a netdev as a handle. We can >> have the new ethtool command just issue a devlink request behind the >> scenes if we care. > >Hi Jakub > >Using that argument, you should probably make the devlink core call >the ethtool .get_drvinfo op if the device does not implement the >devlink op. I imagine it happening the other way around. Updated drivers would implement only the devlink interface. A compat layer would be introduced to redirect from ethtool calls into devlink to gather information (like fw version and other stuff which is currently in ethtool). This approach would provide a single and complete interface between driver and kernel and it would also maintain exinsting ethtool interface. > > Andrew