Received: by 2002:ab2:3350:0:b0:1f4:6588:b3a7 with SMTP id o16csp1895791lqe; Tue, 9 Apr 2024 04:00:01 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCW0/z6EykyBBYGpJZR5/P14KlY0Omh19UNB3wsaGZ1PkTYtLccRO+lFLnSFwo/JKW+evt7SdS3qnVsuM1sgV5t/l7SjwKqxGWU65T8ceA== X-Google-Smtp-Source: AGHT+IETdy5NBQ+t2QBDUu1bzEU1GZCVVD5E8Ihts6tjjVYz3Rqa68qfAL8xpBVQHD8HI2sS+aRC X-Received: by 2002:a50:d794:0:b0:56b:f5ae:c6b2 with SMTP id w20-20020a50d794000000b0056bf5aec6b2mr7760209edi.13.1712660401739; Tue, 09 Apr 2024 04:00:01 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712660401; cv=pass; d=google.com; s=arc-20160816; b=whaVZROvHYOxUtxOHJoIbs8VKQMBq3/MWDYKb5gdjAfjgybnlQnB4Bl/2AuvcI/6Wk vu1khRJybsL+2THyOKXrG3xtl1TPOuMpe9zfyo+1uWur9emK3cU306FAvcBmNdp+FL5F 5fQQcfi/TwMf6LeVQ+DoMDXoNJsvnM+IadV7cCKj8kMbIA54dmLNqD1HWDn5Wr28SpuZ oBFi5M0sickBuzudfUdgi6ykbGDUHYwScztpuAd6YJhOAmrscdvzyxllFU19Y9deF8el /rO1cwNDDyWkqyQ1R57NLqFdyKLEB6x19bphm5GeUIFsQzHzSFU8ff64kCwlGlGyM33S oeNg== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=IIddpNRSXNpcxhhuTPbkM7tBZUu1mbRjQLrWMtsItNE=; fh=1vUu/d1GTjraph6G+ET+Z0z13QVrf6oL/IrrK9zaTF8=; b=qlJN1U4rCzR9duzqeGrbfkC5A+2zmDtRbfjZeAK3oYk5C8g5PVEOGwM3xDSXnvqTWi j6s2R5AD+ExskupPHjfwEVYCdo+tQGPvxFkiVD2obX3BQdsnHFQHmfj/Cai2utjkelYJ t2DN7c7klgCdAQtPXUPfNUtf8SKtVNYSE6jJ5xfa7AFF78MeHGQNKccGIpzmt7fHT5DZ 8ST3CPvcKexK9s+PHFdVtVNu5QsbjrYLkdphH46/X5K7P3vEanLfxle6U3r1t3Fr7gqh XCCUudVt2sAqTwbY9C6uSPTuLMd0Rczdn5qp2hC27UEdbOiot30Ag79n0CYKXLz4Q29f /z9A==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=lzoTfGJx; arc=pass (i=1 spf=pass spfdomain=bootlin.com dkim=pass dkdomain=bootlin.com dmarc=pass fromdomain=bootlin.com); spf=pass (google.com: domain of linux-kernel+bounces-136715-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-136715-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [147.75.80.249]) by mx.google.com with ESMTPS id r13-20020a05640251cd00b0056e5c6acedesi2134783edd.551.2024.04.09.04.00.01 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 09 Apr 2024 04:00:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-136715-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) client-ip=147.75.80.249; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=lzoTfGJx; arc=pass (i=1 spf=pass spfdomain=bootlin.com dkim=pass dkdomain=bootlin.com dmarc=pass fromdomain=bootlin.com); spf=pass (google.com: domain of linux-kernel+bounces-136715-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.80.249 as permitted sender) smtp.mailfrom="linux-kernel+bounces-136715-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=bootlin.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 6F3DC1F228F9 for ; Tue, 9 Apr 2024 11:00:01 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 98A238529C; Tue, 9 Apr 2024 10:59:01 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="lzoTfGJx" Received: from relay6-d.mail.gandi.net (relay6-d.mail.gandi.net [217.70.183.198]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C46AA127B4E; Tue, 9 Apr 2024 10:58:58 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.198 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712660340; cv=none; b=dSXJ2l3lg66naS4SEKly8bx+3Lnm/xtstmdF8yvK+kJW6138VHsT2c+mUtumR53ks/JS3Cn7d2tY+mxv37kLfpGRIbcvIudNrz8TKrQpSQPEUjqfatDXisfoOkdNZ/IkKXlgQqvFFX8doVp5AjrastWZV36c2cmpWmVRMEA2RxM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712660340; c=relaxed/simple; bh=EofGS1Qp4yAH6fOwtDK+5PKuoyiBpqNdDK2ROlQHoGM=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=GiqRVaCCohB45GvMYtqzW7A1U7PBqR/6Exn0xD0nANRbU9dTxStJ41CRUal+/ymI6iMav2Tbwnrdd2/2DHpyhpfa8vIS/iypjha4YoDgJZtHf4JtJsoEPfxKmRiEWYMmKtaAjtMP4pCEdEmCYwplyWCeVNnXGdsAf+AIFjGZRik= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com; spf=pass smtp.mailfrom=bootlin.com; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b=lzoTfGJx; arc=none smtp.client-ip=217.70.183.198 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=reject dis=none) header.from=bootlin.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=bootlin.com Received: by mail.gandi.net (Postfix) with ESMTPSA id D414DC000A; Tue, 9 Apr 2024 10:58:55 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1712660337; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=IIddpNRSXNpcxhhuTPbkM7tBZUu1mbRjQLrWMtsItNE=; b=lzoTfGJx2yyilbxtS5WkaVwDvdBtrYwJ52R5aTmAWdXQWd3oRhnqrZCv8lYPpfcLcgtXq1 Zzo5xTLq1brNoFErZgj2tUVa1xcCWnbibiSo/z0dO8XjcUxLb0WAz6HwcfXF2b287+LFDg wm/bAquHu2K57VkDkmscRgDs3ctxkv8K+PeZlf4C0Ef2O+P2DSWq9/Qi7UBueTLTedUhk7 +JodEHXUXdgHePurG6kLq1uPCmiDWf6zWKfZRn7Q8Kj4DIoXOEWPfvau59kjLpKnKJ/wwM gRqbbBC45FRzHWu/NIRUakFZVtbbnpB0ZyJ8S+L2vMR/hoyAR4R7BMxrS+Zbfg== From: Maxime Chevallier To: davem@davemloft.net Cc: Maxime Chevallier , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, thomas.petazzoni@bootlin.com, Andrew Lunn , Jakub Kicinski , Eric Dumazet , Paolo Abeni , Russell King , linux-arm-kernel@lists.infradead.org, Christophe Leroy , Herve Codina , Florian Fainelli , Heiner Kallweit , Vladimir Oltean , =?UTF-8?q?K=C3=B6ry=20Maincent?= , Jesse Brandeburg , Jonathan Corbet , =?UTF-8?q?Marek=20Beh=C3=BAn?= , Piergiorgio Beruto , Oleksij Rempel , =?UTF-8?q?Nicol=C3=B2=20Veronese?= , Simon Horman , mwojtas@chromium.org Subject: [PATCH net-next 3/8] netlink: specs: add ethnl PHY_GET command set Date: Tue, 9 Apr 2024 12:58:41 +0200 Message-ID: <20240409105847.465298-4-maxime.chevallier@bootlin.com> X-Mailer: git-send-email 2.44.0 In-Reply-To: <20240409105847.465298-1-maxime.chevallier@bootlin.com> References: <20240409105847.465298-1-maxime.chevallier@bootlin.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-GND-Sasl: maxime.chevallier@bootlin.com The PHY_GET command, supporting both DUMP and GET operations, is used to retrieve the list of PHYs connected to a netdevice, and get topology information to know where exactly it sits on the physical link. Add the netlink specs corresponding to that command. Signed-off-by: Maxime Chevallier --- Documentation/netlink/specs/ethtool.yaml | 59 ++++++++++++++++++++++++ 1 file changed, 59 insertions(+) diff --git a/Documentation/netlink/specs/ethtool.yaml b/Documentation/netlink/specs/ethtool.yaml index e8bdad790e3d..e33b74e9aea9 100644 --- a/Documentation/netlink/specs/ethtool.yaml +++ b/Documentation/netlink/specs/ethtool.yaml @@ -20,6 +20,11 @@ definitions: name: header-flags type: flags entries: [ compact-bitsets, omit-reply, stats ] + - + name: phy-upstream-type + enum-name: + type: enum + entries: [ mac, phy ] attribute-sets: - @@ -966,6 +971,38 @@ attribute-sets: - name: burst-tmr type: u32 + - + name: phy + attributes: + - + name: header + type: nest + nested-attributes: header + - + name: index + type: u32 + - + name: drvname + type: string + - + name: name + type: string + - + name: upstream-type + type: u32 + enum: phy-upstream-type + - + name: upstream-index + type: u32 + - + name: upstream-sfp-name + type: string + - + name: downstream-sfp-name + type: string + - + name: id + type: u32 operations: enum-model: directional @@ -1718,3 +1755,25 @@ operations: name: mm-ntf doc: Notification for change in MAC Merge configuration. notify: mm-get + - + name: phy-get + doc: Get PHY devices attached to an interface + + attribute-set: phy + + do: &phy-get-op + request: + attributes: + - header + reply: + attributes: + - header + - index + - drvname + - name + - upstream-type + - upstream-index + - upstream-sfp-name + - downstream-sfp-name + - id + dump: *phy-get-op -- 2.44.0