From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-1.1 required=3.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id E69D0C43387 for ; Wed, 16 Jan 2019 19:00:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id B4D7720873 for ; Wed, 16 Jan 2019 19:00:19 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="kbMRM67U" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729751AbfAPTAS (ORCPT ); Wed, 16 Jan 2019 14:00:18 -0500 Received: from mail-pf1-f194.google.com ([209.85.210.194]:35242 "EHLO mail-pf1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728926AbfAPTAS (ORCPT ); Wed, 16 Jan 2019 14:00:18 -0500 Received: by mail-pf1-f194.google.com with SMTP id z9so3510152pfi.2 for ; Wed, 16 Jan 2019 11:00:17 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version; bh=vLZ7H9geJKXbCeInq8oS3rinrYTQMvy51loYhKtqXrM=; b=kbMRM67UA4wTlU6FqNqTPt8ujiK03FNKN9HzpMmsH8VTG+YK5eBkifUeGVquuViVf4 xl66h3YlDQGNBRmsJyW3KNMMjRhjc81CAI3vWGBPf+aXlUAiWvGUS/opq5N/O1QXy5l4 PF9lUdB0it4XrlrTIUjuKU3wstGJK/KX4dBoKpHq/lLqiUZxIzDb1kZZWvTrZymYoYOP WQv8RSRYKOrQeHBgV/iCfPVVisjndAV7u16JrPE7ytM/re4f19s548KIYaKvWKA4d++s QdAvfVi7v8XYEPNJ+hNYVYjhmns3eCQlOHMTMYi2kt334D/irIZvX8+MjYgAebpDk2wd hgKQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version; bh=vLZ7H9geJKXbCeInq8oS3rinrYTQMvy51loYhKtqXrM=; b=tCYNbtu9BCwUvBC0q//0EDwhxdfaa+XxurMyAJXUQKWO7pgGZAXjfLJbVUrjIMaXOj JM4IuWlPV489aNRwb4AoepWAegdVfIm+q2jQI2GIFgMd2gqUwN/iAZlIl5WKF1TLJtXN GKfQ6JX8O+YStm7azRzCA6c4Cf0xec+VN1yKT+MprJc10YWZsGPd9AHUjIPxf7ETLKWO YBm8LsaowMHsvDPMi+71QunGUfGe8cdFIWkCI6XjsO3/vZb7sIuzSdYg4C8sJJAt4CKP jtWARpcevabPr4PS26fk+Gz3q+k2PMsBOnMZGDbjLwEe6qqhLE8w40CwgvJ74PHd8rYE IR+A== X-Gm-Message-State: AJcUuke7Rl4JKJ1ZjYQH0pJRY11fe4toBnT133xkXgD3+J/k+vUCtRNN ZxbfdcBT3/qZX4IY+NPMyNk= X-Google-Smtp-Source: ALg8bN7iK9SKlrAMQ1c3Uqdksa7NlqnVke2+OnSFsJ/c0ECxVAdn3qwKqVeHbwl0nAyqcLGU6NBNPg== X-Received: by 2002:a62:9719:: with SMTP id n25mr11643315pfe.240.1547665216893; Wed, 16 Jan 2019 11:00:16 -0800 (PST) Received: from [172.20.83.131] ([2620:10d:c090:180::1:af0a]) by smtp.gmail.com with ESMTPSA id q187sm10351333pfq.128.2019.01.16.11.00.15 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Wed, 16 Jan 2019 11:00:16 -0800 (PST) From: "Jonathan Lemon" To: "Jakub Kicinski" Cc: davem@davemloft.net, netdev@vger.kernel.org, oss-drivers@netronome.com, jiri@resnulli.us Subject: Re: [RFC net-next 0/6] devlink: add device (driver) information API Date: Wed, 16 Jan 2019 11:00:14 -0800 X-Mailer: MailMate Trial (1.12.3r5579) Message-ID: In-Reply-To: <20190115130642.0113288e@cakuba.netronome.com> References: <20190115005009.16025-1-jakub.kicinski@netronome.com> <7B7B83D2-5F56-4E7D-A313-4F8E48B23119@gmail.com> <20190115130642.0113288e@cakuba.netronome.com> MIME-Version: 1.0 Content-Type: text/plain; markup=markdown Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org On 15 Jan 2019, at 13:06, Jakub Kicinski wrote: > On Tue, 15 Jan 2019 11:30:10 -0800, Jonathan Lemon wrote: >> On 14 Jan 2019, at 16:50, Jakub Kicinski wrote: >> >>> Hi! >>> >>> For quite some time now the ethtool -i API has been showing its age. >>> The driver version field is generally considered obsolete these >>> days, and driver authors are encouraged to report the kernel version. >>> fw_version field 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 info show >>> pci/0000:05:00.0: >>> serial_number: 00:15:4d:12:20:7e >>> versions: >>> fixed: >>> board.model carbon >>> board.partno AMDA0099-0001 >>> board.revision 07 >>> board.vendor SMA >>> 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 >> >> How about adding the driver name and version as well? >> When connecting to an unknown system, "ethtool -i" is useful in >> discovering what is actually running. > > I'm happy to add the driver name, I'd, however, rather steer clear of > the driver version. In most scenarios kernel version is most reliable. > It's mostly out-of-tree drivers that need the driver version. The driver name + kernel version will work just fine as well. Thanks! -- Jonathan