From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 9C1DAA051B; Wed, 10 Jun 2020 13:57:02 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id 7DDBD4C7A; Wed, 10 Jun 2020 13:57:02 +0200 (CEST) Received: from mail-vk1-f195.google.com (mail-vk1-f195.google.com [209.85.221.195]) by dpdk.org (Postfix) with ESMTP id 05D9431FC for ; Wed, 10 Jun 2020 13:57:02 +0200 (CEST) Received: by mail-vk1-f195.google.com with SMTP id m23so498440vko.2 for ; Wed, 10 Jun 2020 04:57:01 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=WTx+MSsBZHTyLTv3xxBaQHdgiuMXtDOJLPqlA6y2YT4=; b=D4hpBqiXwgdRvRLoAqOlYeDPEsZgi4abl8AXTqc3onHjvp43kSMYn6dq9Dtlmh+jAP oGJMkifVZEInZ6POvvnqwdrEv7WnQ3RVlwIpFBjPuMPQlONbKpXh/uvzyg6ZJH0lhnW2 4gEiYTfSzIfGQ4w9q6rsznFS+T7XE690k3X5I= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=WTx+MSsBZHTyLTv3xxBaQHdgiuMXtDOJLPqlA6y2YT4=; b=P5D3smu0CK/Fxm4YdsVKW+CjIF5YxUY4dpQhN1n8PJRZRUJc8oKaEIMyg0Sb6jEOsX tVQYgji4TUfKbI+xKbXkxSDmg4f9j4qdg6/ObOVP4w6eLUJA7aoVRdTQgEQWAJKglIbc wFNxo48TYXR7aYrZTuQ8kfysDmNCeARAT+j9yfx5ikQE4IAgGluR/6m3XfiG1W1gSYPj 68vUJVu1YAvvQXilU3WYE6wl/KXC0IqAQ6ovsYgGr+LW8gaZHIWs/GApZGLwzAUNK245 iUJsdR6OOrZek6iRA6RPiFvyWd6ORiLD6Zkuodx0RnweKXc4wqtfwd5gPx70GiallcO6 af7A== X-Gm-Message-State: AOAM531GVrH/+yYJ9NBV+4FQMP+DJY2+k3fxM0Mza/UeFIxqYbUYXmll f+AJjqK75x9lDFkY/lOvMbZVj7A9LhlMQxygbIZaqQwV X-Google-Smtp-Source: ABdhPJzu9A2mB7V5VTfH9MLAE6v7TMExPPlDHsbSrQcsMQa93yiI09yCfJL7HtnH1UJZFWe3B3o9W87joz1bc+eLW2M= X-Received: by 2002:a1f:e8c4:: with SMTP id f187mr1900938vkh.24.1591790220943; Wed, 10 Jun 2020 04:57:00 -0700 (PDT) MIME-Version: 1.0 References: <20200610114344.22097-1-somnath.kotur@broadcom.com> In-Reply-To: <20200610114344.22097-1-somnath.kotur@broadcom.com> From: Somnath Kotur Date: Wed, 10 Jun 2020 17:26:49 +0530 Message-ID: To: dev Cc: Ferruh Yigit Content-Type: text/plain; charset="UTF-8" Subject: Re: [dpdk-dev] [PATCH] net/bnxt: fix max ring count calculation X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Wed, Jun 10, 2020 at 5:18 PM Somnath Kotur wrote: > > Max Rx Ring count could be < Max stat contexts. While accounting > for stat contexts, this should be also considered and > the max ring count adjusted accordingly. > > Fixes: f03e66cb64ce ("net/bnxt: limit queue count for NS3/Stingray devices") > Cc: stable@dpdk.org > > Signed-off-by: Somnath Kotur > --- > drivers/net/bnxt/bnxt.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/drivers/net/bnxt/bnxt.h b/drivers/net/bnxt/bnxt.h > index 586d3f5..12fed1e 100644 > --- a/drivers/net/bnxt/bnxt.h > +++ b/drivers/net/bnxt/bnxt.h > @@ -653,10 +653,10 @@ struct bnxt { > #define MAX_STINGRAY_RINGS 128U > /* For sake of symmetry, max Tx rings == max Rx rings, one stat ctx for each */ > #define BNXT_MAX_RX_RINGS(bp) \ > - (BNXT_STINGRAY(bp) ? RTE_MIN(RTE_MIN(bp->max_rx_rings, \ > + (BNXT_STINGRAY(bp) ? RTE_MIN(RTE_MIN(bp->max_rx_rings / 2U, \ > MAX_STINGRAY_RINGS), \ > bp->max_stat_ctx / 2U) : \ > - RTE_MIN(bp->max_rx_rings, \ > + RTE_MIN(bp->max_rx_rings / 2U, \ > bp->max_stat_ctx / 2U)) > #define BNXT_MAX_TX_RINGS(bp) \ > (RTE_MIN((bp)->max_tx_rings, BNXT_MAX_RX_RINGS(bp))) > -- > 1.8.3.1 > Sorry, kindly ignore this patch, got sent out by accident (prev history)