Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754634AbcCBVzW (ORCPT ); Wed, 2 Mar 2016 16:55:22 -0500 Received: from mail-by2on0119.outbound.protection.outlook.com ([207.46.100.119]:24128 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1751624AbcCBVzU (ORCPT ); Wed, 2 Mar 2016 16:55:20 -0500 Authentication-Results: kernel.org; dkim=none (message not signed) header.d=none;kernel.org; dmarc=none action=none header.from=hpe.com; Message-ID: <56D76138.1010606@hpe.com> Date: Wed, 2 Mar 2016 16:55:04 -0500 From: Waiman Long User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:10.0.12) Gecko/20130109 Thunderbird/10.0.12 MIME-Version: 1.0 To: Ingo Molnar CC: Alexander Viro , Jan Kara , Jeff Layton , "J. Bruce Fields" , Tejun Heo , Christoph Lameter , , , Ingo Molnar , Peter Zijlstra , Andi Kleen , Dave Chinner , Boqun Feng , Scott J Norton , Douglas Hatch , Linus Torvalds , Andrew Morton , Peter Zijlstra Subject: Re: [PATCH v5 5/5] lib/percpu-list: Add a config parameter for disabling per-cpu list References: <1456866003-32441-1-git-send-email-Waiman.Long@hpe.com> <1456866003-32441-6-git-send-email-Waiman.Long@hpe.com> <20160302084128.GA21779@gmail.com> In-Reply-To: <20160302084128.GA21779@gmail.com> Content-Type: text/plain; charset="ISO-8859-1"; format=flowed Content-Transfer-Encoding: 7bit X-Originating-IP: [72.71.243.88] X-ClientProxiedBy: BY2PR1001CA0016.namprd10.prod.outlook.com (25.164.163.154) To AT5PR84MB0307.NAMPRD84.PROD.OUTLOOK.COM (25.162.138.29) X-Microsoft-Exchange-Diagnostics: 1;AT5PR84MB0307;2:k54csqo5GgjSPIOCvhCwyX3/tzgiSUAPzcHQ22t+si/Khm20XQMalrj9IUaKnRhLTEot2myt1vYJ2tlTfrrzXSpZAdLmzMuDZAUdUYVPv2CBInbhZD4vTpeTTgG07KWrOyIREY69F2ID7gzlTVdGuA==;3:JzSF7k+ZnFs94qtgvuhJerfP5STUWcfCNxb4tvBja5u+/0+Hb7kSxMdXyhmeyEBDJZSj6e+qQ0Ykgv9pc7ipd05QNg/9TozZboRP05DqRhINZZrJYsgDajW1nTbg4R0S;25:wGN2PNyMuMRzWdrHclN5exknWEBJSu7k8GWOX9tLzXf6u3xiGll9zRoO1w+A4e0QABhdqlQMARCz9+8ZwWUH/1SDZ2fMWOf601JyhUemWJww8Om77JtJd6ffy0dDPQ9CavgvRdOvjbEj0gT7GXXeiSFKllBP+EczM+ZBt5iQ7vUBAk1FCCZy/YJQ2chb9QNX1JkMqMEgXVLizZiISi3U4Gakz1pLkLUaL7zBp/9hvLifqtLxCHeJ8/qPB07IjKTZW9xEvoNsyOlTLlo5KmiGb24ABpUYwU0dAhC4w368U6GERtr/CBx6nEBBUqZv0JmKbghGvwh0Vkaqex2ObuJwnw== X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:AT5PR84MB0307; X-MS-Office365-Filtering-Correlation-Id: c4856f7c-e468-4fe4-9f54-08d342e5576a X-Microsoft-Exchange-Diagnostics: 1;AT5PR84MB0307;20:4tpiOdhTTZkxUicdoqoHYy2/w9yahtCLXnj5OnRi/diazvR1iUaFv5O6DBdoeMkTGLVlc+hUQcmYIcJ2a6VhanHyatttr32m12Z4EQZlOoRjVR6FElw7xIgjb1kkX/cd1xirhM3cSbwp7FG6DmOXxDdsjMdPeer0LPLAm/xMUDeOscDzCnYNgUqeEursUGcbVoLlcVtTzEWkutgm1m+vt7371YiNp40A+3cIzt8JtIJt13ez7PqsMBc68NUDPOwwZPFc+wDm+Y+ptZ6vB7WwKgENDbdibGFt6+8GihBpb39WJzhR3qHwRNX+Elwf1UF7RBeByGUzFbRYBk7BFBGH4g==;4:h13VRTkTJ7XdF6adToOJFRmKkuVTtfypueSuYnWB7jtPoK15dSmcOTmkFLlcnw0PACuZyExG+m1w/ZQGo6cNvlHUvbM/kZZudhmbnNPl3D5mV9pNvYZsUlQeSKsBPauK6F/PCF8mu9baS6O6FRY5i6AFhaKkBlsIFnEf2vbJ48mDw06Tdht8SN1a4eK7ytusFnKIGAkS7JTH3aNauAtDkqjDtpmquDGVUVFrYQ9jDyJ/ZlfdlhkFh8cRz2o97Ha5Thp9Y7P5BgonEoKrO8gzJmk5+qsaqadPixkdFdrz1mrrMg1fLgt8Y4EaKdRgiWZ3S16SlliWJoxtm2qiwQg1NRlplK5mFWpXTllgbqZjr9hpZeNloQICi27WCbrtd00LTPozLsqEduk3EmMeuEQyiZ+BT7SLlQWWvjaC+JHxbww= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:(227479698468861); X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(2401047)(5005006)(8121501046)(3002001)(10201501046);SRVR:AT5PR84MB0307;BCL:0;PCL:0;RULEID:;SRVR:AT5PR84MB0307; X-Forefront-PRVS: 086943A159 X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(4630300001)(6009001)(6049001)(164054003)(24454002)(479174004)(377454003)(117156001)(40100003)(110136002)(189998001)(2950100001)(65956001)(59896002)(33656002)(86362001)(6116002)(5001960100004)(3846002)(76176999)(65816999)(586003)(87266999)(87976001)(230700001)(54356999)(77096005)(1096002)(50986999)(66066001)(23756003)(50466002)(5008740100001)(92566002)(36756003)(4001350100001)(2906002)(47776003)(19580405001)(19580395003)(80316001)(42186005)(4326007)(7059030);DIR:OUT;SFP:1102;SCL:1;SRVR:AT5PR84MB0307;H:[192.168.142.195];FPR:;SPF:None;MLV:sfv;LANG:en; X-Microsoft-Exchange-Diagnostics: =?iso-8859-1?Q?1;AT5PR84MB0307;23:DGg5pHPJpnEQhSqUZPoS9be64ZtaaDVvE4dfhKM?= =?iso-8859-1?Q?cbVdpgXSTpgNMfxGP+OjXJ8Hd+91ZX66kfkCWKWerX3JPIYIyCu03MuBW8?= =?iso-8859-1?Q?swTiBp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zrx12+N?= =?iso-8859-1?Q?PmytzH6FOxNKANltDHLeLqQII4glx1qCbAsLnsBRmZP2c3pazRGASjaGFk?= =?iso-8859-1?Q?gBWBudSk4WrG/D4YUq3K5UVU9lzcgfXH6t61sN2TYxX4FSMopDasoDUfZ8?= =?iso-8859-1?Q?10j7zX1yxMR//n8i66w/O80+lvShtIJl4SsCIGyM/ei0Y0i4+qdGfhkgkh?= =?iso-8859-1?Q?3pd5xv1iO7p?= X-Microsoft-Exchange-Diagnostics: 1;AT5PR84MB0307;5:rhFI99cjsQEQmXqvXYcrO70NcZIz6nkkxv0p57lqvKQLpZ2UaSqpakJ8yS47qG21/MeX+4eXKCc7kGFKQDnCiYVG+Zcl4DfWpbI3uc1ufyVl64hanLnahbntxdPfeMiJ/4X6S6cWdWVUMbKGaVSczQ==;24:/nJofQBAcJdww/FYS/757qE/2kJso5p2yCLdcgljFmrYOGqFEHO5/rPx07gKCvLzZoRZJybNzXQRFR/qNfi1T+JZ52wjtAWeE7HbC/Qg10o= SpamDiagnosticOutput: 1:23 SpamDiagnosticMetadata: NSPM X-OriginatorOrg: hpe.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 02 Mar 2016 21:55:13.8107 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: AT5PR84MB0307 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1581 Lines: 40 On 03/02/2016 03:41 AM, Ingo Molnar wrote: > * Waiman Long wrote: > >> As there is concern that the larger pcpu_list_node structure and the >> per-cpu overhead may be a waste of resource on small system. This patch >> adds a config parameter CONFIG_PERCPU_LIST to disable the per-cpu list >> if the kernel builder chooses to do so. With per-cpu list disabled, >> all the different groups of per-cpu lists will be degenerated into >> global lists for all the CPUs. >> >> The current default is to enable per-cpu list. A kernel builder needs >> to explicitly turn it off. >> >> Signed-off-by: Waiman Long >> --- >> fs/inode.c | 2 +- >> include/linux/percpu-list.h | 93 ++++++++++++++++++++++++++++++++++++++++++- >> lib/Kconfig | 14 ++++++ >> lib/percpu-list.c | 24 +++++++++++- >> 4 files changed, 130 insertions(+), 3 deletions(-) > I think this kind of #ifdef complexity and the doubling of our Kconfig and testing > space is counterproductive, and I think the per CPU locking is a win on as small > as dual core CPUs, and on UP CPUs the per CPU list becomes a single global list > automatically. > > I'm not against visible memory savings for overly clever scalability features, but > this does not appear to be such a case, so: > > NAKed-by: Ingo Molnar > > Thanks, > > Ingo The last patch was there to answer a feedback from Jan. I am fine if that is not merged as I prefer to have the per-cpu list capability as the default anyway. Cheers, Longman