From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934290AbbGHKep (ORCPT ); Wed, 8 Jul 2015 06:34:45 -0400 Received: from pandora.arm.linux.org.uk ([78.32.30.218]:55919 "EHLO pandora.arm.linux.org.uk" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758279AbbGHKen (ORCPT ); Wed, 8 Jul 2015 06:34:43 -0400 Date: Wed, 8 Jul 2015 11:34:29 +0100 From: Russell King - ARM Linux To: Jisheng Zhang Cc: will.deacon@arm.com, mark.rutland@arm.com, daniel.lezcano@linaro.org, Catalin.Marinas@arm.com, Lorenzo.Pieralisi@arm.com, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 4/4] arm: psci: add cpuidle_ops support Message-ID: <20150708103429.GL7557@n2100.arm.linux.org.uk> References: <1436350417-6712-1-git-send-email-jszhang@marvell.com> <1436350417-6712-5-git-send-email-jszhang@marvell.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <1436350417-6712-5-git-send-email-jszhang@marvell.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 08, 2015 at 06:13:37PM +0800, Jisheng Zhang wrote: > This patch implements cpuidle_ops using psci. After this patch, we can use > cpuidle-arm.c with psci backend for both arm and arm64. I really don't see the point of most of the patches in this series. To summarise, what you're doing is: 1. Renaming arch/arm/kernel/psci_smp.c to arch/arm/kernel/psci.c 2. Adding a #ifdef CONFIG_SMP around _all_ the code in psci.c 3. Adding cpuidle code with an #ifdef CONFIG_CPU_IDLE around all the CPU idle code. So, we end up with a file which contains: /* header */ #include statements /* some commentry relevant to SMP code */ #ifdef CONFIG_CPU_IDLE ... cpu idle code ... #endif #ifdef CONFIG_SMP ... smp code ... #endif which (a) is a mess, and (b) is unnecessary. The only relevant bits which are shared are the #include statements. Please try this alternative approach: 1. Leave psci_smp.c alone. 2. Add arch/arm/kernel/psci_cpuidle.c containing the #include statements you need, and the CPU idle code. I think such an approach will reduce your patch series to two patches, one moving the ARM64 code, and one adding the cpuidle code. -- FTTC broadband for 0.8mile line: currently at 10.5Mbps down 400kbps up according to speedtest.net.