[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20190116052356.18086-1-jakub.kicinski@netronome.com>
Date: Tue, 15 Jan 2019 21:23:49 -0800
From: Jakub Kicinski <jakub.kicinski@...ronome.com>
To: davem@...emloft.net
Cc: netdev@...r.kernel.org, jiri@...nulli.us, f.fainelli@...il.com,
andrew@...n.ch, mkubecek@...e.cz, eugenem@...com,
jonathan.lemon@...il.com, oss-drivers@...ronome.com,
Jakub Kicinski <jakub.kicinski@...ronome.com>
Subject: [RFC net-next v2 0/6] devlink: add device (driver) information API
Hi!
fw_version field in ethtool -i does not suit modern needs with 31
characters being quite limiting on more complex systems. There is
also no distinction between the running and flashed versions of
the firmware.
Since the driver information pertains to the entire device, rather
than a particular netdev, it seems wise to move it do devlink, at
the same time fixing the aforementioned issues.
The new API allows exposing the device serial number and versions
of the components of the card - both hardware, firmware (running
and flashed). Driver authors can choose descriptive identifiers
for the version fields. There is a potential for defining common
fields here, but given the general direction of the stack I don't
think people would like that.
Example:
$ devlink dev info pci/0000:05:00.0
pci/0000:05:00.0:
driver nfp
serial_number 16240145
versions:
fixed:
board.id AMDA0099-0001
board.rev 07
board.vendor SMA
board.model carbon
running:
fw.mgmt: 010156.010156.010156
fw.cpld: 0x44
fw.app: sriov-2.1.16
stored:
fw.mgmt: 010158.010158.010158
fw.cpld: 0x44
fw.app: sriov-2.1.20
RFCv2:
- use one driver op;
- allow longer serial number;
- wrap the skb into an opaque request struct;
- add some common identifier into the devlink header.
Jakub Kicinski (6):
devlink: add device information API
devlink: add version reporting to devlink info API
nfp: devlink: report driver name and serial number
nfp: devlink: report fixed versions
nfp: nsp: add support for versions command
nfp: devlink: report the running and flashed versions
.../net/ethernet/netronome/nfp/nfp_devlink.c | 132 +++++++++++++++
.../ethernet/netronome/nfp/nfpcore/nfp_nsp.c | 53 ++++++
.../ethernet/netronome/nfp/nfpcore/nfp_nsp.h | 14 ++
include/net/devlink.h | 50 ++++++
include/uapi/linux/devlink.h | 10 ++
net/core/devlink.c | 154 ++++++++++++++++++
6 files changed, 413 insertions(+)
--
2.19.2
Powered by blists - more mailing lists