Received: by 2002:ac0:a5a6:0:0:0:0:0 with SMTP id m35-v6csp270528imm; Wed, 29 Aug 2018 21:00:25 -0700 (PDT) X-Google-Smtp-Source: ANB0VdZB5+4ZoUvX2DA5NjJaDMFmdsYbWOZ+osHX5VMm5WZwKxQCzQeIP61hZqvYCXChWZqycV69 X-Received: by 2002:a62:868b:: with SMTP id x133-v6mr5701513pfd.252.1535601625788; Wed, 29 Aug 2018 21:00:25 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1535601625; cv=none; d=google.com; s=arc-20160816; b=q3A9k4W1P82pMFO7k/0c7bIpYlxCf9Pv79jYyFidQvlRm+ow1E+lN4MsYYcydPdfYu wNVuCfx7LzwUNcJl+EqSiZ3kMlgrYumszhAdHntG5YCPPX2cOr2IYcAaEhu+m650/cgg TcvogcTbr4m1l6mssnscplP0kvD3tFse6tgoxm0+/Mfy/6UeKZJjMMIBfrzR3eIkZypM MJfvdw7+LuGtMxOy1lv8fZI5zrPzucM9iOdEFpHtLkrSjXgabCGrE3V1Q04bhg6ag9Fe Y689AGV5QMH43ZKJG6NM6yEgIlEQj+mJIP6nYIL1AN5YkE+9mhFxUcTfyTo6Z8pNdePR P4Ug== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:spamdiagnosticmetadata :spamdiagnosticoutput:content-transfer-encoding:mime-version :references:in-reply-to:message-id:subject:cc:to:from:date :dkim-signature:arc-authentication-results; bh=vdBjiBEDj+GMS4UwuI/enGq+G3G/huQ5tF0AX7QNTMk=; b=Nl5TuFOdMq3nijeDQMk/bMPgd4ErxsEqO0JXUJqAu4m9xGfMxbyyVFun1MoYQevrdo s/Bx/WJEtAYwyMx4VZBQF7apt9d4OUyPjNrz6HR7vZl5y9Cvlmheh+UZ3mppXU8SdVIb +ChjmLGZGzJ2fSCqxywvV4fwKanXxIh8LCQ5qk1QVqENY4n23S9U9ZbiimZ3PVbVTyYr Ye1gqbNmatfwYVaK3QRhg6iTspO1Hatuh9LBMW/wmwLhN0XNx0LwG8wleSwT3pSl/wmV vuaNNN5PAmtrQ+2yvK1DbR2MnvPh3o4UbawKP4zMWyhaucXbbbHKIzQf2gRkR6ioHGP5 QNaA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@Synaptics.onmicrosoft.com header.s=selector1-synaptics-com header.b=o43eLWtG; 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 d2-v6si5506716pla.307.2018.08.29.20.59.44; Wed, 29 Aug 2018 21:00:25 -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=@Synaptics.onmicrosoft.com header.s=selector1-synaptics-com header.b=o43eLWtG; 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 S1727588AbeH3H4q (ORCPT + 99 others); Thu, 30 Aug 2018 03:56:46 -0400 Received: from mail-eopbgr730071.outbound.protection.outlook.com ([40.107.73.71]:46400 "EHLO NAM05-DM3-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1727438AbeH3H4q (ORCPT ); Thu, 30 Aug 2018 03:56:46 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=Synaptics.onmicrosoft.com; s=selector1-synaptics-com; h=From:Date:Subject:Message-ID:Content-Type:MIME-Version:X-MS-Exchange-SenderADCheck; bh=vdBjiBEDj+GMS4UwuI/enGq+G3G/huQ5tF0AX7QNTMk=; b=o43eLWtGm71ms9im+G6mJDAfqvVMOALs7dg9tzrQt4+nnGbUTrI/Hj/8rAWSx6yfYs9pFnkQJnfUSI0gbuucjJxJ/Y1tmAaS0uQ1e9tUKY110wZSCpcul65k/SVcKPRjtzteEaOlIu9tjhhzNUQNycKo6qeGAqXzUO+MTL9sV2I= Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=Jisheng.Zhang@synaptics.com; Received: from xhacker.debian (124.74.246.114) by BLUPR0301MB1570.namprd03.prod.outlook.com (2a01:111:e400:52a9::16) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.20.1080.15; Thu, 30 Aug 2018 03:56:33 +0000 Date: Thu, 30 Aug 2018 11:53:29 +0800 From: Jisheng Zhang To: , "David S. Miller" Cc: netdev@vger.kernel.org, Gregory CLEMENT , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org Subject: Re: [PATCH 0/5] net: mvneta: some bug fix and trivial improvement Message-ID: <20180830115329.280943ef@xhacker.debian> In-Reply-To: <20180829165131.52798cd6@xhacker.debian> References: <20180829162456.2bd69796@xhacker.debian> <20180829162932.6015e89d@xhacker.debian> <20180829130836.GD1955@lunn.ch> <20180829165131.52798cd6@xhacker.debian> X-Mailer: Claws Mail 3.17.1 (GTK+ 2.24.32; x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-Originating-IP: [124.74.246.114] X-ClientProxiedBy: TYAPR01CA0161.jpnprd01.prod.outlook.com (2603:1096:404:7e::29) To BLUPR0301MB1570.namprd03.prod.outlook.com (2a01:111:e400:52a9::16) X-MS-PublicTrafficType: Email X-MS-Office365-Filtering-Correlation-Id: 3d9cf1c1-662d-4713-df1a-08d60e2c94c8 X-Microsoft-Antispam: BCL:0;PCL:0;RULEID:(7020095)(4652040)(8989137)(4534165)(4627221)(201703031133081)(201702281549075)(8990107)(5600074)(711020)(2017052603328)(7153060)(7193020);SRVR:BLUPR0301MB1570; X-Microsoft-Exchange-Diagnostics: 1;BLUPR0301MB1570;3:QMHrFrNw9FNp+ZAhg6a0oB13cL6hvndRXNW6oyNLfdL/NniQYt5Cfxy5kIWMwd+Cygj1m7eE75ZFTf9Qr7BGNuE6AG64HYJyZmSrC82jV3auI0clVveptm5xOgAiU4B55XUg4oRiBtHI++8sin+jvURpEp225wUywosxsABNptAiM3ZaXHhIVOclPdV3fq8u+WuwAuJSYRinYOiogSFdx7MGSC7/PU6jX+/UE1pFn268BEZFZ7nss5HASvja8Im0;25:Q+3f3vsuj6y7+aDzVzPTLyOAyend2DtABtwY69LuDE9powK/+S1vA96GI0Jb8wh2sF9M+0qAZxcT5XTBl1HKFcuB/0EYBmzbUSyaTLi1gasNtUejix9A1jBvxc11dllQjr+WL64K59+kFXBGeFJXIrrMr+dJsqGQchdazfFm8xOu/KwbHrDC03t3axxzy4NjlLINTOQk6G7z4YS+fm2+8rptrdA/MamrX67+T+xZdPxraeB5r/gC2RP7mqRrPbjNxULT1WYXD0PUuJK0fXnLpyslbMqQHNKFIo9Ei+8DTWWui1FyB48daiGZHnsNiEtWdNzO7UItIHvf+gQjiy7VaQ==;31:qD9jhD7gvC0ZTu4ABez9NLBxKzEaHzVTahKjw2kUrBHFTzlGntjlpmzHN44lg2e4+N5OLa8WkWzwIPGKwcaP4BOUa4gwX08bPyBys8hyZPK1zTaRZErrqESYNCeDS0ZdtVEOYDHPSyD4e7ME3vnwO7w1dqd08YnsGunTdj/GrjxIzlxhdSnPl1esOLgFqKj2taFkGfYMDCvDdXl2uxnBZPJ7Vn5JCCmUjJNWnH1s0pI= X-MS-TrafficTypeDiagnostic: BLUPR0301MB1570: X-Microsoft-Exchange-Diagnostics: 1;BLUPR0301MB1570;20:AbgBcDTP0cahxBt+wFHXOGv8IhABe27SzP7mHxvX3Qgxl9moYKWQY54t3ynHclYdmUmEsrFPbz9b3b5tgwFYGWz3i994uZ2ji72KMt34Jmb9EKUeOhpYCgm9A47RohGYytzhgSmANXBC8zRpOhdXZaed3CrNGoPSSaFfSgvx6GQm2jWIOytlTwBj+QVB7YJloNZNA5iAWWSdjPLsiY3ulDjvU9/kH70vQOxwdx7quIE1LgwNRWiGVinNrQMUK7iAY83MY6N7jaqNT4jWXjevDOOLvdDLh3bK8rca9WzDn3u8uq9CeHMztqsBe7iCQKdMQ6TxUylrfxVJMZbH0C/K0HbnkiDXCCcdBoUEgN2dpi3L6EEBySodqMss3UY0Vj8JslFi18S+69Wn02x0QnqdZHxHLctiMFDe/UW7hxoE8iNI54B1oUfWuc6i+bLSkzSIR8uFckwX922kMZHRVpHMERMKZIcsGZwmHRFX2CYanOBCbDKjbMp6wk1ek0dZ5weY;4:2OY/RgzqSNF2v03Oa9LWuzrSJff5VUJQXdN6r23LLLjB4J8OTOyz8u1TxmZi+JvdP45+204ZK9yZKbDlTZk8/T9dslgLXCBfEMcK6ucUWHoemXwek5xxRgNQC1nZt1voriBX67ZxSOXoI4CvziMO8drm+VRPG2Zbr0USCfsfufgSZ1P6ZFyy5bnRJ9t4Lw7Uln4M17u/HGWPigr7KzJrqcilvIefCvJcntA0KrbRqrTHKIYvTAEPkG2RLQsiKPDFS8ZfxE63m5jDaC/9eXu45Q== X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-MS-Exchange-SenderADCheck: 1 X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(6040522)(2401047)(8121501046)(5005006)(3231311)(944501410)(52105095)(3002001)(10201501046)(93006095)(93001095)(149027)(150027)(6041310)(20161123560045)(20161123564045)(20161123562045)(20161123558120)(201703131423095)(201702281528075)(20161123555045)(201703061421075)(201703061406153)(201708071742011)(7699016);SRVR:BLUPR0301MB1570;BCL:0;PCL:0;RULEID:;SRVR:BLUPR0301MB1570; X-Forefront-PRVS: 07807C55DC X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10009020)(366004)(396003)(39860400002)(346002)(376002)(136003)(52314003)(199004)(189003)(1076002)(3846002)(8936002)(6116002)(23726003)(76176011)(8676002)(72206003)(86362001)(81166006)(81156014)(4326008)(33896004)(105586002)(229853002)(50226002)(68736007)(55016002)(2906002)(106356001)(230700001)(53936002)(9686003)(6666003)(66066001)(47776003)(5660300001)(110136005)(478600001)(50466002)(486006)(386003)(6506007)(305945005)(14444005)(7736002)(97736004)(6246003)(7696005)(25786009)(93886005)(16526019)(26005)(186003)(956004)(316002)(476003)(11346002)(446003)(52116002)(39210200001);DIR:OUT;SFP:1101;SCL:1;SRVR:BLUPR0301MB1570;H:xhacker.debian;FPR:;SPF:None;LANG:en;PTR:InfoNoRecords;A:1;MX:1; Received-SPF: None (protection.outlook.com: synaptics.com does not designate permitted sender hosts) X-Microsoft-Exchange-Diagnostics: =?us-ascii?Q?1;BLUPR0301MB1570;23:SOJXOVdc38AUXhwDX8IxFe2oABFb+w2epZLHzz+?= =?us-ascii?Q?8eWIggVcvDtVgCN0Opni7bkYCPOoo296nRF01GjsDZ32flwwkg9T2D+e12Lx?= =?us-ascii?Q?D8UNwA93K4S4L1TlNMmmmWWD0+AvJilZw7UW4voXvvrXjOO9a7eZA1QszDkk?= =?us-ascii?Q?9SmkxS8GYrigdSdpemcuRJkt7bHiDiV5McRLNCMdH1CAH8tKIxFTjwYrrza+?= =?us-ascii?Q?EsO/HqMbG8TpUDaDcfScydY5f4Lg5jds8A1UhxWM8R/v7xsKoA6CFuiusLYX?= =?us-ascii?Q?bNE5xss+HXBBD2/DdL/9ji3GZZbN9J7wMZETn9Pge2OUriPaOzGyjKIxOdF8?= =?us-ascii?Q?Fyj7z+wP8XoZyeYLkFSGkvFnYIthml2eznueG4XJOTGfdB7Cpj7+3DJ8pLfu?= =?us-ascii?Q?GYtjed6dz9fcTNg6iN7Lo+lS0HrbLGCmuTYGjXOk2K3j1caJLSbiOJR/tqaq?= =?us-ascii?Q?+pzbMokNbZ/a//7gn6XJo0MCnM94Wv5mZbSIjCWNgYiUZSm2LeJjKvbiPGHh?= =?us-ascii?Q?pMwkKZt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KtroSGozOvYuSCWpqXToJEEtD2sFkvzNCnvg5N+brU9pCItH7bEdZh2hCC4KqCNJY1RjqmvuOyNWvixQI/oqBOobLhxZsGnWgERvI8dPLW51anuKbmuvZ8vlCfnt389OR4HBXbP3Q/9yaZRwvfhSVpG8W4bGeEawf2Fx5TknZ SpamDiagnosticOutput: 1:99 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: synaptics.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 30 Aug 2018 03:56:33.6997 (UTC) X-MS-Exchange-CrossTenant-Network-Message-Id: 3d9cf1c1-662d-4713-df1a-08d60e2c94c8 X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-CrossTenant-Id: 335d1fbc-2124-4173-9863-17e7051a2a0e X-MS-Exchange-Transport-CrossTenantHeadersStamped: BLUPR0301MB1570 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, 29 Aug 2018 16:51:31 +0800 Jisheng Zhang wrote: > On Wed, 29 Aug 2018 16:40:24 +0800 Jisheng Zhang wrote: > > > On Wed, 29 Aug 2018 16:25:57 +0800 > > Jisheng Zhang wrote: > > > > > patch1 fixes rx_offset_correction set and usage. Because the > > > rx_offset_correction is RX packet offset correction for platforms, > > > it's not related with SW BM, instead, it's only related with the > > > platform's NET_SKB_PAD. > > > > > > patch2 fixes the wrong function to unmap rx buf > > > > I have question about the following two commits: > > > > 7e47fd84b56b ("net: mvneta: Allocate page for the descriptor"), it cause > > a waste, for normal 1500 MTU, before this patch we allocate 1920Bytes for rx > > after this patch, we always allocate PAGE_SIZE bytes, if PAGE_SIZE=4096, we > > waste 53% memory for each rx buf. I'm not sure whether the performance > > improvement deserve the pay. > > > > 562e2f467e71 ("net: mvneta: Improve the buffer allocation method for SWBM") > > mentions that "With system having a small memory (around 256MB), the state > > "cannot allocate memory to refill with new buffer" is reach pretty quickly" > > is it due to the memory waste as said above? Anyway, by this commit, we > > want to improve the situation on a small memory system, so should we firstly > > revert commit 7e47fd84b56b ("net: mvneta: Allocate page for the descriptor")? Any comments? Now I believe the situation is due to the memory waste introduced by 7e47fd84b56b With linux 4.18, I tried to limit berlin platforms available memory to 256MB, I didn't see "cannot allocate memory to refill with new buffer". Thanks > > > > If maintainers decide to revert the two commits: 7e47fd84b56b and 562e2f467e71 > then, patch1,2,3 are useless, we can drop them. Only patch4 and patch5 are > still useful. > > Thanks > > > Any comments are welcome! > > > > Thanks > > > > > > > > > > patch3 removes the NETIF_F_GRO check ourself, because the net subsystem > > > will handle it for us. > > > > > > patch4 enables NETIF_F_RXCSUM by default, since the driver and HW > > > supports the feature. > > > > > > patch5 is a trivial optimization, to reduce smp_processor_id() calling > > > in mvneta_tx_done_gbe. > > > > > > Jisheng Zhang (5): > > > net: mvneta: fix rx_offset_correction set and usage > > > net: mvneta: fix the wrong function to unmap rx buf > > > net: mvneta: Don't check NETIF_F_GRO ourself > > > net: mvneta: enable NETIF_F_RXCSUM by default > > > net: mvneta: reduce smp_processor_id() calling in mvneta_tx_done_gbe > > > > > > drivers/net/ethernet/marvell/mvneta.c | 49 ++++++++++++--------------- > > > 1 file changed, 22 insertions(+), 27 deletions(-) > > > > > >