Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp7136743ybi; Thu, 13 Jun 2019 10:11:06 -0700 (PDT) X-Google-Smtp-Source: APXvYqwbs5sTkGspyoKCcb1qa9EhCltcaiHSbfJylnuZir/gYpqvX45k+P7vRhNeHzZFs/i9abdd X-Received: by 2002:a63:a1f:: with SMTP id 31mr23218810pgk.66.1560445865819; Thu, 13 Jun 2019 10:11:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560445865; cv=none; d=google.com; s=arc-20160816; b=u5i+QU3zMdVEUnZJ9lrhEEaCJ96iuOS14gqsj/HD3tLZq3yZxyTHjNPHay0ULPoioZ /IxNbLkho4y7uTJpM//gSNIcapQKL1iAWOdN4AIHFioqZJaiWDX+ED5FbTey1EyYk8KI IfNmc1+ihXL1DESjZTiTHT0GCfxy2/CukwEqe+nnIneEgO8jZrMb7FuAQ2seAkf/FML7 0/GYWlF/ndGe3aSl4cWBbd/NAlAlubBg68NxU8HPgJWUQjRWvjIhH4OJPMc48WEWZ+ib wV89RLsNLhPHRNCFqBySHewDzYXs+7HD5uuCWUPm/bMWYfJaT2NMLq8BlmPjIZwbTGAS IaNg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :organization:references:in-reply-to:message-id:subject:cc:to:from :date:dkim-signature; bh=AvEz80RndZML7i5e7xLWFJaU/oBcGksUZL3ZVAZz/vc=; b=we1HsjpkBp0coStDXdnH6QZBp02tDmz0JvkuZrwOR34kzmc1UbG7dyxVBFjNgr92hY TB2MshXaRyZfUgPot5/ndEntCNV4dLGfOaAbnWQkzR2lYTGdyfu3pMVZIFtGCcq2EMPM 7vn3NGuYFtqlAQ1Qr4/WmXzDFR/NQkzfF7f7S0xOpmyrloBHWv36Xw3WR09138X7UAZ5 f4G335rmqK+rUokoJQ7ZMUbqlaQtickrf1GEcRZmJ5+F8Q1ZpKCECAH8j+7VpLEiziCX 0v8oliPOBqNZRlQLxHqf9LhagnEa6mxxPv5vaZsSIC4ykO2KSchqlkjBlIPRtBTUTt4Z Wekw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@netronome-com.20150623.gappssmtp.com header.s=20150623 header.b=yeN126dH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w184si102569pfw.271.2019.06.13.10.10.51; Thu, 13 Jun 2019 10:11:05 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@netronome-com.20150623.gappssmtp.com header.s=20150623 header.b=yeN126dH; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2404622AbfFMRKc (ORCPT + 99 others); Thu, 13 Jun 2019 13:10:32 -0400 Received: from mail-qt1-f172.google.com ([209.85.160.172]:43842 "EHLO mail-qt1-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729421AbfFLWqm (ORCPT ); Wed, 12 Jun 2019 18:46:42 -0400 Received: by mail-qt1-f172.google.com with SMTP id z24so7153866qtj.10 for ; Wed, 12 Jun 2019 15:46:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=netronome-com.20150623.gappssmtp.com; s=20150623; h=date:from:to:cc:subject:message-id:in-reply-to:references :organization:mime-version:content-transfer-encoding; bh=AvEz80RndZML7i5e7xLWFJaU/oBcGksUZL3ZVAZz/vc=; b=yeN126dH080F5WJlpPkx/gVbgWfPMDnzZs19djMIpFWkQAaC6GGGjs3s9hsd6JKraY +QJ4pGRl91F1byjRjEOILr+u2loTuriMZty4iV0M0L7Q7Xav0PB3xkp+8EpcypvWWcMP zzJUwEPKDtJgWrWxR/R1ZDG5tzqLYY/cPoOn6XlPU1ROe48CiMkre6f09aEIh3/jOW44 yPgRQnWmNglH8zGM58ZL7Fq3YKJmE48oQCimuABrRuIIyufEav+Bjt8k+p7wzQrZBEVk cYzjSSpm3gM5RpipcK0Wzggy58E2yU21E4WcKWjdmDAg1R4VtJEEe6cyPxp6rxNWy4Sn IDjw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:in-reply-to :references:organization:mime-version:content-transfer-encoding; bh=AvEz80RndZML7i5e7xLWFJaU/oBcGksUZL3ZVAZz/vc=; b=knyUuso6PJRyXz5HKHXOlUOHB1PgcRViq0xlQPSkt7mJsEfpcSBoMrlPlg9AAiVPAd JUoh0+Wtd3j1tjwWBNAevhaIkybpfbjXcwadySHcsC9dmKV/yTys2OTHOjDzQXQfryXs bZOpvmuvGpIDVrMA5l85btOkVgsTvbT2REeAZ33Awc67VShnFSRU1qjU0yCmWFb/oBlD 2EJQx+LgmIbBr3Ei5LZKom9oKnyBTClrwIr6Aq9s6ix9DEclgJu0ktxV/x4Z9Wo7iCtk k7IZj4Sy7loxQZ0gwGeKqYkoCPHqhx5thwafodygGIdR5HlVC31LUxDqa5sVRV378avG uHMg== X-Gm-Message-State: APjAAAUDHcJbR9XCBjdV/qD5wbqNuE7eXnbvxIhETdfgEsu9FPA0tYiA 7TVdvLyCHR1/3H8AFZO7DgNmcg== X-Received: by 2002:a0c:8927:: with SMTP id 36mr823821qvp.131.1560379601808; Wed, 12 Jun 2019 15:46:41 -0700 (PDT) Received: from cakuba.netronome.com ([66.60.152.14]) by smtp.gmail.com with ESMTPSA id 34sm691604qtq.59.2019.06.12.15.46.40 (version=TLS1_3 cipher=AEAD-AES256-GCM-SHA384 bits=256/256); Wed, 12 Jun 2019 15:46:41 -0700 (PDT) Date: Wed, 12 Jun 2019 15:46:37 -0700 From: Jakub Kicinski To: Xue Chaojing Cc: , , , , , , Subject: Re: [PATCH net-next v2 1/2] hinic: add rss support Message-ID: <20190612154637.2ad4d882@cakuba.netronome.com> In-Reply-To: <20190611181234.4843-2-xuechaojing@huawei.com> References: <20190611181234.4843-1-xuechaojing@huawei.com> <20190611181234.4843-2-xuechaojing@huawei.com> Organization: Netronome Systems, Ltd. MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 11 Jun 2019 18:12:33 +0000, Xue Chaojing wrote: > + for (i = 0; i < HINIC_RSS_INDIR_SIZE; i++) > + indir_tbl[i] = (i / HINIC_RSS_INDIR_SIZE) * nic_dev->num_rss + > + i % nic_dev->num_rss; This looks suspicious: i is in range [0, HINIC_RSS_INDIR_SIZE) so i / HINIC_RSS_INDIR_SIZE is always 0 For the rest please use ethtool_rxfh_indir_default()