Received: by 2002:a19:651b:0:0:0:0:0 with SMTP id z27csp3759625lfb; Mon, 9 May 2022 03:28:17 -0700 (PDT) X-Google-Smtp-Source: ABdhPJzFY2PvILJcgS+7onOey7eJ44LXxk8BeoR9TYyCwaVpI4fr2g/vg5nIv0mBev3o7j/7Z/K6 X-Received: by 2002:a05:6a00:23c6:b0:50f:f570:7ea7 with SMTP id g6-20020a056a0023c600b0050ff5707ea7mr15240318pfc.76.1652092097090; Mon, 09 May 2022 03:28:17 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1652092097; cv=none; d=google.com; s=arc-20160816; b=J4Y/lCHaY61oEvhYVwHh89uLlmwJdDanLCKrTJeUpRQ7OWFrdwE82wz8z95o4vHlmk 8GIJ/oI6par+WRIdhgNw+V146gplOVy33GGos9fzVl4FKEUkIoBU6SgATXQsDxNgOGTf cBTQbJ2RV0jlP2RnZ0ClT8d1dhottnvx2vGfmSxN6FrzOuEeWaaMv9GQeB/TlhLdZSUy c7ibx8a5Qx4ZqnjNhNGgMsgU1m3Z/RpFI75W99kIvAn9L6ouv6h+KBXxwHQa88xDLyoJ XEyKrViOD41MBZeJjQzwXxsU3bAiZsbY2vloO9CFEuRzCFzmvdwZ4gg4JPWwy9dGM/QY qRJw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=QTHY//D2kCJcGfjjQQ29xj9+Qvuho9wSSnjlq8Fi0Ao=; b=mSkj5SK0RqRv66GMN0K3+tA7EO1kSO/chLe+zo0ufG3cWXZd+DZxupG4ATXnQkOdsG jGGGVDcAvIJBtKyM+WpUkxX/aSr8ukPMw39Z8e3/LWdexJvSN9WuNU73HLrGJ7ZygLGb oT3LSoxoqDsvjosfut+BAlW+SXK5z8KvBUksJjAX1BaW/8SJg19BYiIa+Xw71XKhIRzd IXcniEDKwxh39fZXtVXNV6NizuTLTuPb2jDpD/up+uvuJm0uXW10ivW4VaD0+FxB5OkH G+CnY/HRFBfuc5iCv93A7tsf4sruUVU0PjBDf6Aot6LCsmHNLgXfFKKv7phs9SOBbOS1 l5iA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.de header.s=amazon201209 header.b=colpFVTD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.de Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [2620:137:e000::1:18]) by mx.google.com with ESMTPS id i185-20020a6387c2000000b003c6a5d55413si5627978pge.114.2022.05.09.03.28.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 May 2022 03:28:17 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) client-ip=2620:137:e000::1:18; Authentication-Results: mx.google.com; dkim=pass header.i=@amazon.de header.s=amazon201209 header.b=colpFVTD; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.de Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id 272CC18A6BD; Mon, 9 May 2022 03:01:28 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236312AbiEIHv3 (ORCPT + 99 others); Mon, 9 May 2022 03:51:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:57896 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234021AbiEIHoh (ORCPT ); Mon, 9 May 2022 03:44:37 -0400 Received: from smtp-fw-6001.amazon.com (smtp-fw-6001.amazon.com [52.95.48.154]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 038F0D96; Mon, 9 May 2022 00:40:41 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.de; i=@amazon.de; q=dns/txt; s=amazon201209; t=1652082045; x=1683618045; h=from:to:cc:subject:date:message-id:in-reply-to: references:mime-version:content-transfer-encoding; bh=QTHY//D2kCJcGfjjQQ29xj9+Qvuho9wSSnjlq8Fi0Ao=; b=colpFVTDniE2xyXZmblIu/jF973j9XoRXJjUm2X5Vl+rO1JndnwTJTef KtVp40N/lrtvN9ldpBxs3y8uJYarA3R2m2kmA7pcal9DkB6RfwMYWkVnM 4LxA+c/LroBUvDCFkADsytkvghXJ0GjawkkKVz43V4MOV9cONBZTLd7Av Y=; X-IronPort-AV: E=Sophos;i="5.91,210,1647302400"; d="scan'208";a="201065087" Received: from iad12-co-svc-p1-lb1-vlan3.amazon.com (HELO email-inbound-relay-pdx-2b-c275e159.us-west-2.amazon.com) ([10.43.8.6]) by smtp-border-fw-6001.iad6.amazon.com with ESMTP; 09 May 2022 07:39:27 +0000 Received: from EX13D08EUC001.ant.amazon.com (pdx1-ws-svc-p6-lb9-vlan2.pdx.amazon.com [10.236.137.194]) by email-inbound-relay-pdx-2b-c275e159.us-west-2.amazon.com (Postfix) with ESMTPS id 23C40829A6; Mon, 9 May 2022 07:39:26 +0000 (UTC) Received: from EX13MTAUWA001.ant.amazon.com (10.43.160.58) by EX13D08EUC001.ant.amazon.com (10.43.164.184) with Microsoft SMTP Server (TLS) id 15.0.1497.32; Mon, 9 May 2022 07:39:24 +0000 Received: from dev-dsk-mheyne-1b-c1524648.eu-west-1.amazon.com (10.15.60.66) by mail-relay.amazon.com (10.43.160.118) with Microsoft SMTP Server id 15.0.1497.32 via Frontend Transport; Mon, 9 May 2022 07:39:23 +0000 Received: by dev-dsk-mheyne-1b-c1524648.eu-west-1.amazon.com (Postfix, from userid 5466572) id C2D8B41135; Mon, 9 May 2022 07:39:21 +0000 (UTC) From: Maximilian Heyne To: Tony Nguyen CC: Jakub Kicinski , Maximilian Heyne , Jesse Brandeburg , "David S. Miller" , Paolo Abeni , , , Subject: Re: [PATCH net-next v2] drivers, ixgbe: show VF statistics Date: Mon, 9 May 2022 07:39:15 +0000 Message-ID: <20220509073915.28476-1-mheyne@amazon.de> X-Mailer: git-send-email 2.32.0 In-Reply-To: <7775a23b-199e-b0f2-fe6b-06a667ac9dee@intel.com> References: MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable X-Spam-Status: No, score=-2.6 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,RDNS_NONE,SPF_HELO_NONE,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 lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2022-05-06T09:20:14-07:00 Tony Nguyen wro= te: > On 5/6/2022 9:13 AM, Jakub Kicinski wrote: > > On Fri, 6 May 2022 06:44:40 +0000 Maximilian Heyne wrote: > >> On 2022-05-04T20:16:32-07:00 Jakub Kicinski wrote: > >> > >>> On Tue, 3 May 2022 15:00:17 +0000 Maximilian Heyne wrote: > >>>> + for (i =3D 0; i < adapter->num_vfs; i++) { > >>>> + ethtool_sprintf(&p, "VF %u Rx Packets", i); > >>>> + ethtool_sprintf(&p, "VF %u Rx Bytes", i); > >>>> + ethtool_sprintf(&p, "VF %u Tx Packets", i); > >>>> + ethtool_sprintf(&p, "VF %u Tx Bytes", i); > >>>> + ethtool_sprintf(&p, "VF %u MC Packets", i); > >>>> + } > >>> > >>> Please drop the ethtool stats. We've been trying to avoid duplicating > >>> the same stats in ethtool and iproute2 for a while now. > >> > >> I can see the point that standard metrics should only be reported via = the > >> iproute2 interface. However, in this special case this patch was > >> intended to converge the out-of-tree driver with the in-tree version. > >> These missing stats were breaking our userspace. If we now switch > >> solely to iproute2 based statistics both driver versions would > >> diverge even more. So depending on where a user gets the ixgbe driver > >> from, they have to work-around. > >> > >> I can change the patch as requested, but it will contradict the inital > >> intention. At least Intel should then port this change to the > >> external driver as well. Let's get a statement from them. > = > We discussed this patch internally and concluded the correct approach = > would be to not have the ethtool stats and use the VF info. Jakub beat = > us to the comment. We would plan to port the iproute implementation to = > OOT as well. Ok, then I'll send a follow-up patch without the ethtool changes. I'm happy= to get some kind of convergence between the out-of-tree driver and upstream. = While at it, I wonder whether other drivers need similar changes as well and what other features are missing in the upstream driver. There should be no surprises when switching between these drivers. > = > > Ack, but we really want people to move towards using standard stats. > > = > > Can you change the user space to first try reading the stats via > > iproute2/rtnetlink? And fallback to random ethtool strings if not > > available? That way it will work with any driver implementing the > > standard API. Long term that'll make everyone's life easier. Yes, in this case we are in control of user space and can work around. > > = > > Out-of-tree code cannot be an argument upstream, otherwise we'd > > completely lose control over our APIs. Vendors could ship whatever > > in their out of tree repo and then force us to accept it upstream. > > = > > It's disappointing to see the vendor letting the uAPI of the out of > > tree driver diverge from upstream, especially a driver this mature. > = Amazon Development Center Germany GmbH Krausenstr. 38 10117 Berlin Geschaeftsfuehrung: Christian Schlaeger, Jonathan Weiss Eingetragen am Amtsgericht Charlottenburg unter HRB 149173 B Sitz: Berlin Ust-ID: DE 289 237 879