Received: by 2002:a05:7208:9594:b0:7e:5202:c8b4 with SMTP id gs20csp1216358rbb; Mon, 26 Feb 2024 02:27:32 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCXN+QEtn+012trXS4xm5crhoQoVCUn2oQnZF/YljjYElqFVWrY/j2xMbDFzPZ1S1s8OcMIdbKZQFJgB6bv2lhEsL626koFn+k4so9LWRQ== X-Google-Smtp-Source: AGHT+IGsCulbnR68TC1AloIkF3ahWEbOWcPiRetBo/BEmMSwqz8JTVlOAU0Ez7YCwXebTKDhWEDl X-Received: by 2002:a17:906:a256:b0:a43:199b:cc9c with SMTP id bi22-20020a170906a25600b00a43199bcc9cmr2742964ejb.75.1708943251955; Mon, 26 Feb 2024 02:27:31 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708943251; cv=pass; d=google.com; s=arc-20160816; b=FbRskbtTGKdCMflFAadkfObxSajmhlWbL4qeEFFn3vST20l2XfGKJhIPUYtIuGAJK3 oGmKPv3SjM8FHH8ZMIUxtcSHsJvymhvLnJqNMEfAccrr/jERpfWaB7wjf2XJI3C80Wtd OTbUA1RpybsoXJSqys5Ppc6aS7BN93dOgu1ZWNEoYpa2P7b9pbHTN5C9o4BazL17FhZI J99uG2YyL32ewDheGWpbzdbfEO1VUJttDVfNlIRKiGj+/w+ALgiLgJs0Fz3BT15jjKjf TcgPGXuy8zC0OutdJFaScdMDk72nt8dfPYiGkRfHrD6DcNyiDV3EXmbikm0UnaY9IUsJ Kmpw== 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:organization:references :in-reply-to:message-id:subject:cc:to:from:date:dkim-signature; bh=ZZjpenESpoom5pXFPq/3Rgc0cq0sAg4BJvGnYZALf+U=; fh=vLQ2QekPF58X9gXufavtU8TE+6hH60IMSGetL2aceqw=; b=mNedcQAko2v44pyZa4qDKrktQOFf8LRRqpyHBhMidrNfwpcpAGpZjRuF+rWWffBOxb dLSK+O0jJTrtEdvxoJw/d1d+7ZUaC4FYjUgNyOM6BE+gIe7UATwTqAwwuQm9RcVO2QLs qn2sQuohyCjNiRAFX8873dmGdx3cRb7aG8T5S2eT7knFdyQSt1BWayrA1qUZJVnBJCKE cQMAfp3hqP2YB2Y+xNwCaim/M0RLKTJuDjc9Q3p4YREx+BpWHab2xHjEv0+AP6z4pmSS hA/rq8lPP97Q6tItnQgXQtggAOZ3SWUeYaRm9EoxA1smaGuZ5pWMqHepPAansgWkENsS pcvw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=ETyCFEzv; 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-81134-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81134-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. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id g10-20020a1709067c4a00b00a3e66296cdfsi2044817ejp.753.2024.02.26.02.27.31 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Feb 2024 02:27:31 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-81134-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@bootlin.com header.s=gm1 header.b=ETyCFEzv; 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-81134-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-81134-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 8E3EF1F2A106 for ; Mon, 26 Feb 2024 10:25:53 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id C44FB5914B; Mon, 26 Feb 2024 10:09:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=bootlin.com header.i=@bootlin.com header.b="ETyCFEzv" Received: from relay4-d.mail.gandi.net (relay4-d.mail.gandi.net [217.70.183.196]) (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 C8F0D1CD32; Mon, 26 Feb 2024 10:09:52 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=217.70.183.196 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708942196; cv=none; b=L7tKumsUZD+PgjjtQr0woPbZiitqT6pqwvK8Hh/osJi8a7TXfaEJ0EL8GAAwHLQgrcsPLWCDKP234VAmeqr+X3sGBHKOGX4nXbR0VI3AlQhmh5RkbWHG8MUQyirmxXLCAXJowF19TRnUnn41kL278RomikmZ7Ln95T27C9JY3Yc= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708942196; c=relaxed/simple; bh=fD06I6761Bblu6LIz/0Vqc/s50lUzSjG3wEpIkRmx+Q=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=jic/BIh9qA9n2CbtOkZm19yJfDIpwfDXcBaZvRPUzXW9n1pPPpxMBb9F266Bq00/NklkEdMxKEpxegVOwuUryxjVoS5fYWSflIMV/i0ilSSr3nFcKiCnFHju37JRFTCzFfR8f5uVHdNWtrpFwoIHf0J5+Zk0n0A1aos4QVlHbpI= 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=ETyCFEzv; arc=none smtp.client-ip=217.70.183.196 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 A3794E0013; Mon, 26 Feb 2024 10:09:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1708942190; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ZZjpenESpoom5pXFPq/3Rgc0cq0sAg4BJvGnYZALf+U=; b=ETyCFEzvQnohjoo51KU0oyPDzRB5Zwv+KDf9I/3SAn+w2caCL7sdiLNDo5jV8nEkpR6OZy oIvi8m4Vg3MYIr9ECx7T1EERfMoiBCzbVUpw8KQvJVuK8tKWSPcUeMcVWhuvi7BPo9TEtU WsHcpis5x1mzSlvkquPS72cdWpjpR0pAuvBEn6D9FwFsXfrO7SD/WOF2kn/lYnCeegDR2i /mWsYJjPS8JgkTkT/Kc8TPsTqNBfmxIgnHdfkqENOhnz6srjUlF5o6A5thMb62WnZKOnHi +Iyh6QekmauaK6/ugbgW58kbcANNxVoUjrugGjhgFYj05G0RZCfxdyz9IzNv0A== Date: Mon, 26 Feb 2024 11:09:46 +0100 From: =?UTF-8?B?S8O2cnk=?= Maincent To: Rahul Rameshbabu Cc: Saeed Mahameed , Leon Romanovsky , "David S. Miller" , Eric Dumazet , Jakub Kicinski , Paolo Abeni , Jonathan Corbet , Richard Cochran , Tariq Toukan , Gal Pressman , Vadim Fedorenko , Andrew Lunn , Heiner Kallweit , Przemek Kitszel , Ahmed Zaki , Alexander Lobakin , Hangbin Liu , Paul Greenwalt , Justin Stitt , Randy Dunlap , Maxime Chevallier , Wojciech Drewek , Vladimir Oltean , Jiri Pirko , Jacob Keller , Alexandre Torgue , Jose Abreu , Dragos Tatulea , netdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-doc@vger.kernel.org Subject: Re: [PATCH RFC net-next v1 1/6] ethtool: add interface to read Tx hardware timestamping statistics Message-ID: <20240226110946.626a8474@kmaincent-XPS-13-7390> In-Reply-To: <20240223192658.45893-2-rrameshbabu@nvidia.com> References: <20240223192658.45893-1-rrameshbabu@nvidia.com> <20240223192658.45893-2-rrameshbabu@nvidia.com> Organization: bootlin X-Mailer: Claws Mail 3.17.5 (GTK+ 2.24.32; x86_64-pc-linux-gnu) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable X-GND-Sasl: kory.maincent@bootlin.com On Fri, 23 Feb 2024 11:24:45 -0800 Rahul Rameshbabu wrote: > Multiple network devices that support hardware timestamping appear to have > common behavior with regards to timestamp handling. Implement common Tx > hardware timestamping statistics in a tx_stats struct_group. Common Rx > hardware timestamping statistics can subsequently be implemented in a > rx_stats struct_group for ethtool_ts_stats. >=20 > Signed-off-by: Rahul Rameshbabu > Reviewed-by: Dragos Tatulea > + > +const struct nla_policy ethnl_stats_get_policy[__ETHTOOL_A_STATS_CNT] = =3D { > + [ETHTOOL_A_STATS_HEADER] =3D NLA_POLICY_NESTED(ethnl_header_policy), > + [ETHTOOL_A_STATS_GROUPS] =3D { .type =3D NLA_NESTED }, > + [ETHTOOL_A_STATS_SRC] =3D > NLA_POLICY_MAX(NLA_U32, ETHTOOL_MAC_STATS_SRC_PMAC), > + [ETHTOOL_A_STATS_LAYER] =3D > + NLA_POLICY_MAX(NLA_U32, ETHTOOL_TS_STATS_LAYER_PHY), > }; You should add this new netlink attributes to the specs in a new patch to be able to test it. diff --git a/Documentation/netlink/specs/ethtool.yaml b/Documentation/netlink/specs/ethtool.yaml index cfe48f8d6283..118508de2c88 100644 --- a/Documentation/netlink/specs/ethtool.yaml +++ b/Documentation/netlink/specs/ethtool.yaml @@ -859,6 +859,9 @@ attribute-sets: - name: src type: u32 + - + name: layer + type: u32 - name: phc-vclocks attributes: @@ -1526,6 +1529,7 @@ operations: attributes: - header - groups + - layer reply: attributes: - header Regards, --=20 K=C3=B6ry Maincent, Bootlin Embedded Linux and kernel engineering https://bootlin.com