Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932143AbbHFFqj (ORCPT ); Thu, 6 Aug 2015 01:46:39 -0400 Received: from mail-by2on0126.outbound.protection.outlook.com ([207.46.100.126]:31599 "EHLO na01-by2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S932096AbbHFFqh (ORCPT ); Thu, 6 Aug 2015 01:46:37 -0400 Authentication-Results: spf=none (sender IP is ) smtp.mailfrom=scottwood@freescale.com; Message-ID: <1438839985.2097.151.camel@freescale.com> Subject: Re: [PATCH 1/3] Powerpc: mpc85xx: refactor the PM operations From: Scott Wood To: Chenhui Zhao CC: , , , Tang Yuantian , "linuxppc-dev@lists.ozlabs.org" Date: Thu, 6 Aug 2015 00:46:25 -0500 In-Reply-To: <1438834837.23384.0@remotesmtp.freescale.net> References: <1438334444-31919-1-git-send-email-b29983@freescale.com> <1438387178.19345.77.camel@freescale.com> <1438601578.7515.2@remotesmtp.freescale.net> <1438633568.2097.35.camel@freescale.com> <1438769477.21522.0@remotesmtp.freescale.net> <1438829848.2097.129.camel@freescale.com> <1438834837.23384.0@remotesmtp.freescale.net> Content-Type: text/plain; charset="UTF-8" X-Mailer: Evolution 3.16.0-fta1 MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Originating-IP: [2601:448:8100:f9f:12bf:48ff:fe84:c9a0] X-ClientProxiedBy: DM2PR22CA0040.namprd22.prod.outlook.com (25.162.205.50) To BY1PR03MB1484.namprd03.prod.outlook.com (25.162.210.142) X-Microsoft-Exchange-Diagnostics: 1;BY1PR03MB1484;2:OjyV9VY1tLk/OQjsPJE2caiKcri2hgKeh8kVOdSlP/BVvRg/VVb9vBJzGJlp00hR3uKVKIG1TajNBIp6D87vBOFyIU/tzn6vgnoDKuKcZvruaCfLlWamWe7WqzdipFIBi5bwB7A3qNHsMhYZe87O1sV9lCda6TQgpJqgI5otRpA=;3:xZ+dp1cDQzlodrrpXWuk962Z4UviPOLURrkXKvt4bPCKO96PFafAfimXtuqNoRygkuQsbzvekW9O2d4J5nc1FBCtRwRr5fMkz5Bgw5BWhyJbVJ2S43svwTY8nvoaGJfuiVTiDJsZrTo4yA5RnYTXNw==;25:3XIUYySUBWDwUUVX7BuxjCO0aFlWDZjscxn92zS2oBeei8REinBrW+SLbh6E1ktRzWHMBIUlrvyEp+AVW9VKYitaxnl2sD1/B+SnnW3JhFe/I7WnldKDD2B0wxRChzQAGDktPLtyDoEDA915xOaiCscPi/AbVDrjfBzhtmpds0ssmixkD74rEgkDh8A9i6M1CQmLc57gApUD4LHFVx5SbfrSk0dvlPgsE68/JZvHNQCncmJXWfHJfNimcdvD66iA X-Microsoft-Antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY1PR03MB1484; X-Microsoft-Exchange-Diagnostics: 1;BY1PR03MB1484;20:ehu/gB22HjIBG/r8azPR9iKxwi3a/s+LyX1MECZjVkian/gY9sgYQpJkz17IhisEWijfSroWJAGzIcDwL6O1K8YTmaRjS2j3QDSnIulgPR4w2gT4wWBBtyyqNO5S7t93NcC6BN9yGodN8mDyUhosnge7YVkMInjVItpk7uu4ou3Y3bJy2TtTGcxStO5cMHKkJPicCIn/CWjDCxu7K77mU7/Sxh4z1v2p6ReXCm5cy4g0Ct854U+eSEw7UL+PRUArj5Jdtkf/a6xvpfvt2HeCjkzg2pUz2z5MZNDoH2ze6FHvY49PRdeIAzkmLQOzWl5EpTk/5oPYTvI7qku2LfVJkPyYXb3whkNDwjeS17twvhpWoZfd8CntDDpomrTuS58L5gvw/qIm2MINK39iNX1hvjJAkkdB6TozjNxm3q0eNHGA2UoOFu6fv+RWqK4FxxboK77QedwJKKf0iROehqis1KOijNuo3OY0V2pBWqO2hnqYX1+Ubb4jEfyn/rymmHEH;4:Ogc9+T1vJMJ0D1Gp3PpuzMb0L7fsu65QFREy4pOjZbMpSc1DP4/peZ95GDSESIgcYK33JLNZBFD4R6NfuhP4HPDd7MGtWzPxffHV13tlD76SDuiNJADfTc1uppJ87OUtvNOmi4uup7h1KJUc7rG9n2M00VvXRy2xEvSEL/vVSwA5XfW7bZpS7kQOn6/Xe/i4IhRlIPM8e21W27RJ+eUB9kuhhYHOsngSIUfCeIGfzOkaucdfJk/XYQ1mH8EvjPwAn/UXaIaExDxBJ583RFROUXNVJ2lN4O+iFMrQWeAYIqo= X-Microsoft-Antispam-PRVS: X-Exchange-Antispam-Report-Test: UriScan:; X-Exchange-Antispam-Report-CFA-Test: BCL:0;PCL:0;RULEID:(601004)(5005006)(3002001);SRVR:BY1PR03MB1484;BCL:0;PCL:0;RULEID:;SRVR:BY1PR03MB1484; X-Forefront-PRVS: 06607E485E X-Forefront-Antispam-Report: SFV:NSPM;SFS:(10019020)(6009001)(199003)(189002)(377454003)(377424004)(24454002)(57704003)(19580405001)(50986999)(19580395003)(76176999)(50226001)(33646002)(122386002)(92566002)(93886004)(101416001)(4001450100002)(86362001)(46102003)(103116003)(23676002)(64706001)(106356001)(47776003)(50466002)(42186005)(87976001)(5001960100002)(5001920100001)(110136002)(5001860100001)(189998001)(5820100001)(5001830100001)(68736005)(77096005)(97736004)(81156007)(4001540100001)(77156002)(2950100001)(36756003)(62966003)(40100003)(105586002)(99106002)(3826002)(5001840100002);DIR:OUT;SFP:1102;SCL:1;SRVR:BY1PR03MB1484;H:[IPv6:2601:448:8100:f9f:12bf:48ff:fe84:c9a0];FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; X-Microsoft-Exchange-Diagnostics: =?utf-8?B?MTtCWTFQUjAzTUIxNDg0OzIzOjlaeUxnVXFTNDJaRC9oNDBSTnYyeVRaUWYv?= =?utf-8?B?dEpBTHI5bGE2Y2FIMlVYMmRDMEhXcFJpMjdsaVcraVcwN2wzZ3lTaWVlYUFW?= =?utf-8?B?VjR4SWJtRHdiSWFBUklYZ3djeVd5WGVsSE5Bb2s2K2ZkSHRwUzB5bTQ0SkhN?= =?utf-8?B?cFlkSUlkQ0Q3Q0E2WWVGcz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jyUErijPj+gaK7JFKobpw6x6PGPTP+7yQ67kqnGg=;20:1HBePz5Xt56L2utNZWKkG9Vu6QnS/tVUobHZq4qNDm1h8jYR7Q/5QngLwjkCX8Yk1NbL8k3KoYESbnYdlAGDWw== X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-OriginalArrivalTime: 06 Aug 2015 05:46:33.1916 (UTC) X-MS-Exchange-CrossTenant-FromEntityHeader: Hosted X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR03MB1484 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1769 Lines: 53 On Thu, 2015-08-06 at 12:20 +0800, Chenhui Zhao wrote: > On Thu, Aug 6, 2015 at 10:57 AM, Scott Wood > wrote: > > On Wed, 2015-08-05 at 18:11 +0800, Chenhui Zhao wrote: > > > On Tue, Aug 4, 2015 at 4:26 AM, Scott Wood > > > wrote: > > > > On Mon, 2015-08-03 at 19:32 +0800, Chenhui Zhao wrote: > > > > > > > > > > > > > > > On Sat, Aug 1, 2015 at 7:59 AM, Scott Wood > > > > > > > > wrote: > > > > > > > > > > > > > > > > Could you explain irq_mask()? Why would there still be IRQs > > > > > destined > > > > > > for > > > > > > this CPU at this point? > > > > > > > > > > This function just masks irq by setting the registers in RCPM > > > (for > > > > > example, RCPM_CPMIMR, RCPM_CPMCIMR). Actually, all irqs to > > > this CPU > > > > > have been migrated to other CPUs. > > > > > > > > So why do we need to set those bits in RCPM? Is it just caution? > > > > > > Setting these bits can mask interrupts signalled to RCPM from MPIC > > > as a > > > means of > > > waking up from a lower power state. So, cores will not be waked up > > > unexpectedly. > > > > Why would the MPIC be signalling those interrupts if they've been > > masked at > > the MPIC? > > > > -Scott > > > > The interrupts to RCPM from MPIC are IRQ, Machine Check, NMI and > Critical interrupts. Some of them didn't be masked in MPIC. What interrupt could actually happen to a sleeping cpu that this protects against? -Scott -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/