Received: by 2002:a05:7412:8d10:b0:f3:1519:9f41 with SMTP id bj16csp1806505rdb; Thu, 7 Dec 2023 09:12:11 -0800 (PST) X-Google-Smtp-Source: AGHT+IGdlZnalsicz5DTum8WB6TlY8awLpp4myln5zKrwiFW9j3mr7inzghDRYap8IaBZ9XgfJe/ X-Received: by 2002:a05:6a20:160b:b0:18f:97c:5b7c with SMTP id l11-20020a056a20160b00b0018f097c5b7cmr2196016pzj.74.1701969131014; Thu, 07 Dec 2023 09:12:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701969130; cv=none; d=google.com; s=arc-20160816; b=QyF21TkxUJk4+wqYkWunX7VAWU15+yQxVJy6ropJA/n/hl3M92hwWKS08xZUrDGNGl OG261KQnVisY6BuyGi0jIwt4AdKZGCGLsScIjun62RjmN49VWj94oqzi+xHqdOuhamdX qnhbqCM/QlFp3NJE3Jwl4Ln9+fHzxVDYGpO565kqhoaEYzkVThHYpUeG9OYkiuSAbDUs JMloL4dcxnCuJtINjX3E4Vd03oqqhV88tV5xdkepdzm6LjV5rPv4X6ZDCdJ1Ck+gTfgS AjXlSyQQzZLBew4peeBPxZnmETNdpuUbZwTR71fMp4f9cMkZ039GZ97v3K5GYOgLlVJf bUPw== 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-transfer-encoding :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature; bh=/UFjD58fhtoLAst150cniGCGsb0qSuthtkjBFrtzgWQ=; fh=ttZsY8jb7AwbD8F+uDO0j2ZVzMg7PhGR0kui8Ium2q8=; b=QSqdp/UsjdrpNTIp/TB/4W9D3uQwK5Myq5lAs+lbLI7Mlk+ZonJWM1bsUZK0XtXQvW HUq6hpiaZIfXarUPUK6h696McNNNobYKXa6UlpCCw2bpHHKScyqBulkFLuB5oX8jPw9S lg2JM86V7AshOptuCl7e02dU1pNJxLgD0RrTPOdg6IzYMWSlG6xKPPsZvJ2uFqRWIxzB 65BsMiflE88Thf5cFd6ae1qZRhzMLd45I/EgmFfFIDLhnDaIqoV6Kf7qnOiT/r+FC7WK ObLwXA63o7lKkjTJ0cNVFRvkUja3yNl1e79IoypPWlmcLMCeTlu1DUsjtBdBBg/auHmh uLbw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=To9TIVrz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 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 morse.vger.email (morse.vger.email. [23.128.96.31]) by mx.google.com with ESMTPS id f9-20020a056a00228900b006cde5241c15si17768pfe.306.2023.12.07.09.12.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Dec 2023 09:12:10 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) client-ip=23.128.96.31; Authentication-Results: mx.google.com; dkim=pass header.i=@lunn.ch header.s=20171124 header.b=To9TIVrz; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.31 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=lunn.ch Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by morse.vger.email (Postfix) with ESMTP id 9A1138078653; Thu, 7 Dec 2023 09:11:58 -0800 (PST) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.11 at morse.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232488AbjLGRLm (ORCPT + 99 others); Thu, 7 Dec 2023 12:11:42 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:35906 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229671AbjLGRLl (ORCPT ); Thu, 7 Dec 2023 12:11:41 -0500 Received: from vps0.lunn.ch (vps0.lunn.ch [156.67.10.101]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 80CB110EB; Thu, 7 Dec 2023 09:11:47 -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-Transfer-Encoding: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=/UFjD58fhtoLAst150cniGCGsb0qSuthtkjBFrtzgWQ=; b=To 9TIVrzpz8t2dkPVK0anb4qxU9D9czgjdViR0/5xmzbyUMZRjVvyo5P2lmhcNuJERkM8VokSq7XMJO qSd67bYlbk5ZKI8vAgFda7Et3yyidIceUOXxFK59lTr19DOWiJ+lATtOEru/23HUrjkkZ+WprR+dT AFMDiUn+EUptw/Y=; Received: from andrew by vps0.lunn.ch with local (Exim 4.94.2) (envelope-from ) id 1rBHuL-002Kqt-1h; Thu, 07 Dec 2023 18:11:29 +0100 Date: Thu, 7 Dec 2023 18:11:29 +0100 From: Andrew Lunn To: Marek =?iso-8859-1?Q?Beh=FAn?= Cc: Daniel Golle , Lee Jones , Pavel Machek , Jakub Kicinski , Christian Marangi , "David S. Miller" , Li Zetao , linux-kernel@vger.kernel.org, linux-leds@vger.kernel.org Subject: Re: [PATCH v3 1/2] leds: trigger: netdev: extend speeds up to 10G Message-ID: References: <99e7d3304c6bba7f4863a4a80764a869855f2085.1701143925.git.daniel@makrotopia.org> <20231207172923.62ce530e@dellmb> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <20231207172923.62ce530e@dellmb> X-Spam-Status: No, score=-0.9 required=5.0 tests=DKIM_SIGNED,DKIM_VALID, DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=unavailable autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on morse.vger.email Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (morse.vger.email [0.0.0.0]); Thu, 07 Dec 2023 09:11:58 -0800 (PST) On Thu, Dec 07, 2023 at 05:29:23PM +0100, Marek Beh?n wrote: > On Tue, 28 Nov 2023 04:00:10 +0000 > Daniel Golle wrote: > > > Add 2.5G, 5G and 10G as available speeds to the netdev LED trigger. > > > > Signed-off-by: Daniel Golle > > Reviewed-by: Andrew Lunn > > So what will happen when there are more speeds? Will we create a > separate file for each speed? > > Will we have a separate sysfs file for 10, 100, 1000, 2500, 5000, > 10000, 20000, 25000, 40000, 50000, 56000, 100000, 200000, 400000, > 800000 ? > > These are all speeds from include/uapi/linux/ethtool.h. > > Maybe we should have reused ethtool link mode bits, or something... That gets pretty ugly. The bits are not in any logical order, since they just get appended onto the end as needed. > Also, the files should only be present if the requested speed is > supported by the net device. So if 2500 mbps is not supported, there > should no be link_2500. Yes, this would be nice. We have the information in the phy_setting settings[] table in phy-core.c. Andrew