From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S964914Ab3DHUsr (ORCPT ); Mon, 8 Apr 2013 16:48:47 -0400 Received: from terminus.zytor.com ([198.137.202.10]:41114 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S964850Ab3DHUsp (ORCPT ); Mon, 8 Apr 2013 16:48:45 -0400 Date: Mon, 8 Apr 2013 13:46:32 -0700 From: tip-bot for Thomas Gleixner Message-ID: Cc: linux-kernel@vger.kernel.org, hpa@zytor.com, mingo@kernel.org, rusty@rustcorp.com.au, torvalds@linux-foundation.org, peterz@infradead.org, srivatsa.bhat@linux.vnet.ibm.com, paulmck@linux.vnet.ibm.com, gxt@mprc.pku.edu.cn, tglx@linutronix.de, magnus.damm@gmail.com Reply-To: mingo@kernel.org, hpa@zytor.com, linux-kernel@vger.kernel.org, torvalds@linux-foundation.org, rusty@rustcorp.com.au, peterz@infradead.org, srivatsa.bhat@linux.vnet.ibm.com, paulmck@linux.vnet.ibm.com, tglx@linutronix.de, gxt@mprc.pku.edu.cn, magnus.damm@gmail.com In-Reply-To: <20130321215235.415426466@linutronix.de> References: <20130321215235.415426466@linutronix.de> To: linux-tip-commits@vger.kernel.org Subject: [tip:smp/hotplug] unicore: Use generic idle loop Git-Commit-ID: aba92c9e2cf3042bf6efc68fa2e4235ba01bf499 X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.2.7 (terminus.zytor.com [127.0.0.1]); Mon, 08 Apr 2013 13:46:38 -0700 (PDT) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: aba92c9e2cf3042bf6efc68fa2e4235ba01bf499 Gitweb: http://git.kernel.org/tip/aba92c9e2cf3042bf6efc68fa2e4235ba01bf499 Author: Thomas Gleixner AuthorDate: Thu, 21 Mar 2013 22:50:02 +0100 Committer: Thomas Gleixner CommitDate: Mon, 8 Apr 2013 17:39:29 +0200 unicore: Use generic idle loop Signed-off-by: Thomas Gleixner Cc: Linus Torvalds Cc: Rusty Russell Cc: Paul McKenney Cc: Peter Zijlstra Reviewed-by: Cc: Srivatsa S. Bhat Cc: Magnus Damm Cc: Guan Xuetao Link: http://lkml.kernel.org/r/20130321215235.415426466@linutronix.de Signed-off-by: Thomas Gleixner --- arch/unicore32/Kconfig | 1 + arch/unicore32/kernel/process.c | 21 +++------------------ 2 files changed, 4 insertions(+), 18 deletions(-) diff --git a/arch/unicore32/Kconfig b/arch/unicore32/Kconfig index 2943e3a..e12678d 100644 --- a/arch/unicore32/Kconfig +++ b/arch/unicore32/Kconfig @@ -17,6 +17,7 @@ config UNICORE32 select ARCH_WANT_FRAME_POINTERS select GENERIC_IOMAP select MODULES_USE_ELF_REL + select GENERIC_IDLE_LOOP help UniCore-32 is 32-bit Instruction Set Architecture, including a series of low-power-consumption RISC chip diff --git a/arch/unicore32/kernel/process.c b/arch/unicore32/kernel/process.c index 872d7e2..7fab86d 100644 --- a/arch/unicore32/kernel/process.c +++ b/arch/unicore32/kernel/process.c @@ -45,25 +45,10 @@ static const char * const processor_modes[] = { "UK18", "UK19", "UK1A", "EXTN", "UK1C", "UK1D", "UK1E", "SUSR" }; -void cpu_idle(void) +void arch_cpu_idle(void) { - /* endless idle loop with no priority at all */ - while (1) { - tick_nohz_idle_enter(); - rcu_idle_enter(); - while (!need_resched()) { - local_irq_disable(); - stop_critical_timings(); - cpu_do_idle(); - local_irq_enable(); - start_critical_timings(); - } - rcu_idle_exit(); - tick_nohz_idle_exit(); - preempt_enable_no_resched(); - schedule(); - preempt_disable(); - } + cpu_do_idle(); + local_irq_enable(); } static char reboot_mode = 'h';