From patchwork Fri Aug 10 06:12:39 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Ilias Apalodimas X-Patchwork-Id: 143887 Delivered-To: patch@linaro.org Received: by 2002:a2e:9754:0:0:0:0:0 with SMTP id f20-v6csp2956567ljj; Thu, 9 Aug 2018 23:13:13 -0700 (PDT) X-Google-Smtp-Source: AA+uWPxUjKt6auoQz7NIDExDL0zyzSRjc1d4YHyc7khplwnEjMy+8IC/hVQHg24OspImVBr+6PXH X-Received: by 2002:a62:990f:: with SMTP id d15-v6mr5573170pfe.162.1533881593595; Thu, 09 Aug 2018 23:13:13 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1533881593; cv=none; d=google.com; s=arc-20160816; b=ja9ye+i42jKJYdN4AavGJaL8Djg28fMxIRCnc9dB5vCyKERFrxIHZOz/yMqyPmxCLD 9P+n3iRjEDFIU88O1qozzddBtU4WcGZ8I/MucDkM5G9gPWMNP6V0zCToWsJlc/66sJZ+ f2uBSAQsuUFIjZ+bZ022tEGDPHKoSU56JorFTmH/MN1u03r3oE+PF16IP8OW12Wdic6e DZYa8oiTJAbJI/P7rvEbpHTPkmXrR1DRlLVkWTs7pLGJcYlGRWBF9tNdBFE2j0KQ6ZCa 1ceOKixhtF6Q2rlFX6t/n5rFqVgzo7IlON6BUAa5TPi2uGolyeKGMHYsNGybBF/NAv3z lrlA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=J7J536chYQMuP2f8Ap1goSIjCZyTXPKdr51AcsLoKG0=; b=jDxIGOIVLLesPnRXKaBfNua62IcAD/EYS0Q7N4i7Ewyd/EK9FQ5hROm2JLJ8DqJJoB G/zj2WzStOnXkLAZfLBxDogYWsKp+/32PprysjQlbZMjpnRtVPRHjqvulPOMA8QyKKMr vgL6YoTtmA7z3ipJVnNbQuk/yjATIaCYyO2QqQld+EYcE4beIfrcyKdHmR+xtd030nFZ UG3nMTAO/MowhBMbdXUoaXoFeo6iOw4h6YzhbADrljTzs4wf8ppH/yUSaNEwKt4yMgjp CfSXyFGLV6VrAZYj/A2bcD7xnUrk6sM5ylFEIneSUiR1A0Acm7y/ITgpAhd933DpdnVU UP4w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=FsXOm+gO; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id e36-v6si8183970pge.507.2018.08.09.23.13.13; Thu, 09 Aug 2018 23:13:13 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of netdev-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=@linaro.org header.s=google header.b=FsXOm+gO; spf=pass (google.com: best guess record for domain of netdev-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=netdev-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727461AbeHJIle (ORCPT + 10 others); Fri, 10 Aug 2018 04:41:34 -0400 Received: from mail-wm0-f65.google.com ([74.125.82.65]:56272 "EHLO mail-wm0-f65.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725784AbeHJIld (ORCPT ); Fri, 10 Aug 2018 04:41:33 -0400 Received: by mail-wm0-f65.google.com with SMTP id f21-v6so619019wmc.5 for ; Thu, 09 Aug 2018 23:13:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=J7J536chYQMuP2f8Ap1goSIjCZyTXPKdr51AcsLoKG0=; b=FsXOm+gOt7iPq2F8A0pLbxEMXncmPn9D9vWZCns0N6Nrx3wtMASUcebxx0tB6GJ7hA lxcJhHq/DeHuFO/vewh7pVSw2uJjax2sSJTur0K1r/3RXU3gJeyP7QFPFWOUbfwkM0Cc rwjhBdYdpN89OlyVu8gxbMETl4zwQszDqkG6o= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=J7J536chYQMuP2f8Ap1goSIjCZyTXPKdr51AcsLoKG0=; b=cHRM9wvQ9qHWSRI0flohl6CQgOIZwEd37Aash+DyF3VQ1rppLCjystiL/9yfuRi+14 VKPzxkJM0QQf4XENiKGnfCt8F7fTdUhgvApv2ncwyTuUOva9qv5u1nCO6HwB4/lp0MOk DfpTj6tD2FyVpsSYJn4eWKIxyUCtsFZey/DvPIGskytdJi0/vAjlyNvJ0lffuwK+nZJ4 SAmg9oxP26NTuhhDVBx48q0wBgoaF9IxIqW//73xFMUItkkTU+emqf3hXj72BT/ysT7T iLbgBRb1QdjTEgQMhE4ywoIdXEu3MEtCii7GKG/kdfvJH4aoNES2k6iJAp/CZ/cbL4MT 3d6w== X-Gm-Message-State: AOUpUlFMye4W1EdJwq5IUTpBV+QUhVSNPth9ikmknNGL4H1F0/GpiTVd Z0Gy7DKoWqUfZJRVVN2gVMzwUBeLttA= X-Received: by 2002:a1c:790b:: with SMTP id l11-v6mr538061wme.66.1533881589662; Thu, 09 Aug 2018 23:13:09 -0700 (PDT) Received: from localhost.localdomain ([2a02:587:4605:8300:2e56:dcff:fe9a:8f06]) by smtp.gmail.com with ESMTPSA id i1-v6sm6182483wrq.69.2018.08.09.23.13.08 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 09 Aug 2018 23:13:09 -0700 (PDT) From: Ilias Apalodimas To: netdev@vger.kernel.org, jaswinder.singh@linaro.org Cc: ard.biesheuvel@linaro.org, masami.hiramatsu@linaro.org, arnd@arndb.de, Ilias Apalodimas Subject: [net-next, PATCH 2/2 v2] net: socionext: Increase descriptors to 256 Date: Fri, 10 Aug 2018 09:12:39 +0300 Message-Id: <1533881559-18589-3-git-send-email-ilias.apalodimas@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1533881559-18589-1-git-send-email-ilias.apalodimas@linaro.org> References: <1533881559-18589-1-git-send-email-ilias.apalodimas@linaro.org> Sender: netdev-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: netdev@vger.kernel.org Increasing descriptors to 256 from 128 and adjusting the NAPI weight to 64 increases performace on Rx by ~20% on 64byte packets Signed-off-by: Ilias Apalodimas --- drivers/net/ethernet/socionext/netsec.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) -- 2.7.4 diff --git a/drivers/net/ethernet/socionext/netsec.c b/drivers/net/ethernet/socionext/netsec.c index 334b618..7aa5ebb 100644 --- a/drivers/net/ethernet/socionext/netsec.c +++ b/drivers/net/ethernet/socionext/netsec.c @@ -232,8 +232,7 @@ #define NETSEC_EEPROM_PKT_ME_ADDRESS 0x20 #define NETSEC_EEPROM_PKT_ME_SIZE 0x24 -#define DESC_NUM 128 -#define NAPI_BUDGET (DESC_NUM / 2) +#define DESC_NUM 256 #define DESC_SZ sizeof(struct netsec_de) @@ -1659,7 +1658,7 @@ static int netsec_probe(struct platform_device *pdev) dev_info(&pdev->dev, "hardware revision %d.%d\n", hw_ver >> 16, hw_ver & 0xffff); - netif_napi_add(ndev, &priv->napi, netsec_napi_poll, NAPI_BUDGET); + netif_napi_add(ndev, &priv->napi, netsec_napi_poll, NAPI_POLL_WEIGHT); ndev->netdev_ops = &netsec_netdev_ops; ndev->ethtool_ops = &netsec_ethtool_ops;