From patchwork Fri Jul 25 11:56:08 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kaushal Kumar X-Patchwork-Id: 4622651 Return-Path: X-Original-To: patchwork-linux-arm-msm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork2.web.kernel.org (Postfix) with ESMTP id BDAD0C0338 for ; Fri, 25 Jul 2014 11:56:55 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E16A4201F7 for ; Fri, 25 Jul 2014 11:56:54 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 14BB7201F2 for ; Fri, 25 Jul 2014 11:56:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752138AbaGYL4x (ORCPT ); Fri, 25 Jul 2014 07:56:53 -0400 Received: from smtp.codeaurora.org ([198.145.11.231]:42223 "EHLO smtp.codeaurora.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752133AbaGYL4w (ORCPT ); Fri, 25 Jul 2014 07:56:52 -0400 Received: from smtp.codeaurora.org (localhost [127.0.0.1]) by smtp.codeaurora.org (Postfix) with ESMTP id AEA04140E15; Fri, 25 Jul 2014 11:56:51 +0000 (UTC) Received: by smtp.codeaurora.org (Postfix, from userid 486) id A1898140E18; Fri, 25 Jul 2014 11:56:51 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham version=3.3.1 Received: from kaushalk-linux.qualcomm.com (unknown [202.46.23.54]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) (Authenticated sender: kaushalk@smtp.codeaurora.org) by smtp.codeaurora.org (Postfix) with ESMTPSA id E1D12140E15; Fri, 25 Jul 2014 11:56:48 +0000 (UTC) From: Kaushal Kumar To: Peter Zijlstra , Ingo Molnar , Michael Wang , Arun Bharadwaj Cc: linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Kaushal Kumar Subject: [PATCH] sched: Remove synchronize rcu/sched calls from _cpu_down Date: Fri, 25 Jul 2014 17:26:08 +0530 Message-Id: <1406289368-11332-1-git-send-email-kaushalk@codeaurora.org> X-Mailer: git-send-email 1.8.2.1 X-Virus-Scanned: ClamAV using ClamSMTP Sender: linux-arm-msm-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-arm-msm@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP synchronize_rcu calls fail hot-unplug latency tests since wait_rcu_gp can have very high latency, at times up to few hundred of millisecs. These calls were earlier removed for the same reason by the commit 9ee349ad6d326df3633d43f54202427295999c47, but got added back as part of commit c4575f83b9fe87bb57b737bc8a667f746a20320a. Moreover there should be no need for sync_sched() in _cpu_down as stop_machine() provides that barrier implicitly. Signed-off-by: Kaushal Kumar --- kernel/cpu.c | 20 -------------------- 1 file changed, 20 deletions(-) -- The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum, hosted by The Linux Foundation -- To unsubscribe from this list: send the line "unsubscribe linux-arm-msm" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/kernel/cpu.c b/kernel/cpu.c index 887eb32..93e526c 100644 --- a/kernel/cpu.c +++ b/kernel/cpu.c @@ -311,28 +311,8 @@ static int __ref _cpu_down(unsigned int cpu, int tasks_frozen) __func__, cpu); goto out_release; } - - /* - * By now we've cleared cpu_active_mask, wait for all preempt-disabled - * and RCU users of this state to go away such that all new such users - * will observe it. - * - * For CONFIG_PREEMPT we have preemptible RCU and its sync_rcu() might - * not imply sync_sched(), so explicitly call both. - * - * Do sync before park smpboot threads to take care the rcu boost case. - */ -#ifdef CONFIG_PREEMPT - synchronize_sched(); -#endif - synchronize_rcu(); - smpboot_park_threads(cpu); - /* - * So now all preempt/rcu users must observe !cpu_active(). - */ - err = __stop_machine(take_cpu_down, &tcd_param, cpumask_of(cpu)); if (err) { /* CPU didn't die: tell everyone. Can't complain. */