Received: by 2002:a05:6358:d09b:b0:dc:cd0c:909e with SMTP id jc27csp4604367rwb; Sun, 13 Nov 2022 09:17:12 -0800 (PST) X-Google-Smtp-Source: AA0mqf6U//iTHnw/d+DohgEAFoTC4SBl9ZGRGTUpPleblfFy6AapfiMASOMcCqDXb+YwyqwrdllC X-Received: by 2002:a17:902:a408:b0:188:542a:68d8 with SMTP id p8-20020a170902a40800b00188542a68d8mr10530397plq.126.1668359832498; Sun, 13 Nov 2022 09:17:12 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1668359832; cv=none; d=google.com; s=arc-20160816; b=NFg+9gCUzFPvx1u4EjW1Rc9bCYyMyRupQVNQ4e406pn0CDxxYj+qyK32+psfca1cjy B4BSYH1D2kRlcR/Zk5DID5vud8lOsD/hYzi7zHcJHpFMI6tqy7St8DpLT7Mqej/vblS/ Tmmwvi2Z9CnkwT1tI3e87e1SqQXNuWUfE3QbkhN3tOZAiZOrGD0HT23ReY+gDwPuRzuF xyh5g5LXSHYft8sxfxC5X531JC75Z29EfLonUMHLSKhYKlVVeNnLhB8rkwn70uhsQ62N re+Njb9InkjDouNExnL0qLlcp3ZrLexvzRPTt5IoRUm+qapjVIeujiVTb/uAHlrMPHe4 exHA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=G3CZ56ybDleLJm2kN+uSFznFQhOcErtx2ALKqkrvU3M=; b=OuXCEbYQV7Ehsl3ua7sTZb8kGPEUxyHnq/QKcPcFvfNcxm+de8YClY0iDuYPRbq6vH 0I4UljTPMi1K9Jc0JaPp+25o9QrQ9eoE+/QRwg9zlwhfcZJUu7eDmou8S6nPMKGLsvXm fE9PgblgMctHHQ47PeX+3Dw796F7t1xIupytBTbsmbQptqHteMR9PW6fIjjtSyZNTqQl /P3rOEQfxJMT6rziVeuV/UDATWoCdgHHXJF7TzuD0BJcKK5Mt9QWS9yMDQHS6idgnXeh RPb1V1fdb23XqbP+Db+3hvJi6xG9EP3nAyjelSb3xNE91erOEmkXxUgtI2GUzUaa1fnH ZniQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=WSqKn1e5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id k16-20020a170902d59000b0018668baa655si7795387plh.280.2022.11.13.09.17.01; Sun, 13 Nov 2022 09:17:12 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=WSqKn1e5; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235397AbiKMQs5 (ORCPT + 89 others); Sun, 13 Nov 2022 11:48:57 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:38336 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232799AbiKMQsy (ORCPT ); Sun, 13 Nov 2022 11:48:54 -0500 Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 0AB04BC8D; Sun, 13 Nov 2022 08:48:53 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lunn.ch; s=20171124; h=In-Reply-To:Content-Disposition:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:From:Sender:Reply-To:Subject: Date:Message-ID:To:Cc:MIME-Version:Content-Type:Content-Transfer-Encoding: Content-ID:Content-Description:Content-Disposition:In-Reply-To:References; bh=G3CZ56ybDleLJm2kN+uSFznFQhOcErtx2ALKqkrvU3M=; b=WSqKn1e5Iv6xaMAv8Fn/ulw9uh jqF3AfQnjxhTMlGTnTFpJTu1w+kATpqd4ZoTRkBEgxo9NO5ux+ysvTz38tp1XNOOmC0RWdLPnlYgH kpoOmvWKSJMYZ2H6f5xBM9gh/Hx4hv5nfBJUBON5vtAsjiLVBa7p++jC4S9/ZAx15Xmg=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1ouG9o-002FbT-DJ; Sun, 13 Nov 2022 17:48:32 +0100 Date: Sun, 13 Nov 2022 17:48:32 +0100 From: Andrew Lunn To: Vincent Mailhol Cc: Marc Kleine-Budde , linux-can@vger.kernel.org, Greg Kroah-Hartman , linux-kernel@vger.kernel.org, netdev@vger.kernel.org, linux-usb@vger.kernel.org Subject: Re: [PATCH v3 0/3] can: etas_es58x: report firmware, bootloader and hardware version Message-ID: References: <20221104073659.414147-1-mailhol.vincent@wanadoo.fr> <20221113040108.68249-1-mailhol.vincent@wanadoo.fr> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20221113040108.68249-1-mailhol.vincent@wanadoo.fr> X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_PASS,SPF_PASS autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Sun, Nov 13, 2022 at 01:01:05PM +0900, Vincent Mailhol wrote: > The goal of this series is to report the firmware version, the > bootloader version and the hardware revision of ETAS ES58x > devices. > > These are already reported in the kernel log but this isn't best > practise. Remove the kernel log and instead export all these in > sysfs. In addition, the firmware version is also reported through > ethtool. Sorry to only comment on version 3, rather than version 1. I don't normally look at CAN patches. Have you considered using devlink? https://www.kernel.org/doc/html/latest/networking/devlink/devlink-info.html fw and asic.id would cover two of your properties. Maybe talk to Jiri about the bootloader. It might make sense to add it is a new common property, or to use a custom property. devlink has the advantage of being a well defined, standardised API, rather than just random, per device sys files. There might also be other interesting features in devlink, once you have basic support. Many Ethernet switch drivers use devlink regions to dump all the registers, for example. Since there is a bootloader, i assume the firmware is upgradeable? devlink supports that. Andrew