Received: by 2002:a05:6500:2018:b0:1fb:9675:f89d with SMTP id t24csp144314lqh; Thu, 30 May 2024 17:39:15 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCUTRsLn+4mwys73BHMc7zf42tRbyxYUxTI0jBnRHGnO0BXqD4ricvaQuKSFpkhSNZDGwZY1kaiNJg0ylBkXQ0kXU8VWbY2ndeuvHbUBxQ== X-Google-Smtp-Source: AGHT+IH0VEZLPnR1zBkzKnuNnVP+yPJytLNT80uBFb77SPLSCbcwNcQ7nS14js0f8gYuIZXWSFVc X-Received: by 2002:a17:902:f94d:b0:1ec:e3c2:790e with SMTP id d9443c01a7336-1f63700392amr3728415ad.19.1717115955167; Thu, 30 May 2024 17:39:15 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1717115955; cv=pass; d=google.com; s=arc-20160816; b=NjHb0q62k1nt0vJrpCtV2mybs3ONuKkVtTlTnfR+ubpN+p60GOFrSQpniCsDID+Fjw /tQ0V5WiYOmT0Rr9xq43HNyJJ/AoNsoRGwOC+3R+V10ZjRVbHZDx4UsFpEIyeu4samCq 0kwA/aorudRb7fVj+npYpTXlyTk/tkhzfPpIYCd0GOHaT//YXI5Kv5J/dpiFDkVJqH3z 1Oi/8gw7qx6owtTBz8r/vedAHDip7SXT0gQ4qh6zby0pSdsAvlu0PM+8cK0DRIc9wVOa 41rJUQqjPKx1mOfAWtlBkMT0Kq5mAUT/5OavYExa//IVnl2fGxernpergsTwGwAfGxJU 26Mg== 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 :subject:cc:to:from:date:dkim-signature; bh=Hwo8IcY6sd+aWQEwjiizSstxeTNKnAjYOK4+Wny/mJs=; fh=fnU8w9dlicvVaszhCOxLHy0YICMxocstd277hxrlS84=; b=lB15BcXTwCLxoXvJs0bwAXphy7n9uw2KgSBCO6XfQ1oz687L8RaD8Sf20Ewfmc0ZZW zLnJSBoAvqIl6/X5UBBYgPsZOs/zvCqanFuk68P6ZIGIfhGODOFO2rvOSgrygztH8cMA 19j85Q7+cwTJwMwAHQt1LF8BXiA+tM4SMnjfMpBoTaZFpMlM/SXgPY8CmzhlV3txbMhr NrLqNe2wZrG1bnFP435BUdwNX7zChTDrMa657pRPMbQP0GuWHTYMoC2QvR8KCBxZCXrt 6zfiJHPKEgUMjkWbmajmkM8XFwgu5nSeyNbHvuz9rBXu3HsBkHqDXnSxOmifqr9Yjl06 8/pw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=giV28BoS; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-196087-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-196087-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id d9443c01a7336-1f6323eb9b3si5311615ad.421.2024.05.30.17.39.14 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 30 May 2024 17:39:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-196087-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=giV28BoS; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-196087-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-196087-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org 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 sv.mirrors.kernel.org (Postfix) with ESMTPS id BFFB82818BE for ; Fri, 31 May 2024 00:39:14 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 36FC9568A; Fri, 31 May 2024 00:39:05 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="giV28BoS" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 59B954C6D; Fri, 31 May 2024 00:39:04 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717115944; cv=none; b=oAUga5X/QgpdsTliYPURK7KZ2Pn5ZqIu2CqEmMdYQPJFqpvw4oqzrQeIVL9DQ3rDhfyHYIG3f7yTrORM5sMM9GaA8VTmWobcm30FrPz9R/SXYA/RdQXZap/i5e629K3oj9X2ZpEb+LSoIPSjYbLnvopyY1TmNYZ2Yd3ySfWUpr4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1717115944; c=relaxed/simple; bh=jz3uNt0ungI64vdcOBPvDDK2/oZ7fHMTLKoFD/qP59c=; h=Date:From:To:Cc:Subject:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=MrfF0yAhDQCixG5mFxOUcvVsLIFypjLTJyGCYXenANpK02COBTN88Efl4i6Ongm/ehPhgEEOnns/ykxpBUwEe5eYKOVNgUOCTStGw/6/VpXybnWQTisY/kVRvHmqh8Ni9JdbbcSSdAqmcCD76yCWHVjR10QwPFMWat7vKSiHbRc= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=giV28BoS; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 4AAF6C2BBFC; Fri, 31 May 2024 00:39:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1717115943; bh=jz3uNt0ungI64vdcOBPvDDK2/oZ7fHMTLKoFD/qP59c=; h=Date:From:To:Cc:Subject:In-Reply-To:References:From; b=giV28BoSnq+WkGdlsUZ2v7q3wbUwkzvm1r13itdZk5Hxcf+NUAhhCy4ALwgqAKLW2 UXE5axb8WsEyx3qjCsIBzuyQkk6EcskV94ijqaVejCn+8barpbcYOztB0KZoZCRX3f QniJYLQ3nCWj1hDHv4KDQRrdThNnOIfz1vcl48mS8e6r3aP9grmplZL518i8Ea1Vhh cYe2Gu1c3eaCOLPyw4NnvVkaRBPm+o+vKMDYBxp87KssjYBtLnyeMlHnn2cyXZy3Bg tzjQqmDJxaY+zuTer2OL5jFBXa7UXM7rrkWPO8ekhfx9PfRf9ywB7Q3PncwZlbvY6/ ab7scJI8aGDlw== Date: Thu, 30 May 2024 17:39:02 -0700 From: Jakub Kicinski To: Joe Damato , Saeed Mahameed Cc: linux-kernel@vger.kernel.org, netdev@vger.kernel.org, nalramli@fastly.com, "David S. Miller" , Eric Dumazet , Leon Romanovsky , "open list:MELLANOX MLX5 core VPI driver" , Paolo Abeni , Richard Cochran , Tariq Toukan Subject: Re: [RFC net-next v3 0/2] mlx5: Add netdev-genl queue stats Message-ID: <20240530173902.7f00a610@kernel.org> In-Reply-To: References: <20240529031628.324117-1-jdamato@fastly.com> <20240530171128.35bd0ee2@kernel.org> 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=US-ASCII Content-Transfer-Encoding: 7bit On Thu, 30 May 2024 17:15:25 -0700 Joe Damato wrote: > > Why to base, and not report them as queue stats? > > > > Judging by mlx5e_update_tx_netdev_queues() calls sprinkled in > > ../mlx5/core/en/htb.c it seems that the driver will update the > > real_num_tx_queues accordingly. And from mlx5e_qid_from_qos() > > it seems like the inverse calculation is: > > > > i - (chs->params.num_channels + is_ptp)*mlx5e_get_dcb_num_tc(&chs->params) > > > > But really, isn't it enough to use priv->txq2sq[i] for the active > > queues, and not active ones you've already covered? > > This is what I proposed in the thread for the v2, but Tariq > suggested a different approach he liked more, please see this > message for more details: > > https://lore.kernel.org/netdev/68225941-f3c3-4335-8f3d-edee43f59033@gmail.com/ > > I attempted to implement option 1 as he described in his message. I see, although it sounds like option 2 would also work. Saeed can you shine any light here? I'm worried Tariq is already AFK for the weekend and we'll make no progress until Monday...