Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752872AbbH1TXZ (ORCPT ); Fri, 28 Aug 2015 15:23:25 -0400 Received: from mail-bl2on0105.outbound.protection.outlook.com ([65.55.169.105]:24976 "EHLO na01-bl2-obe.outbound.protection.outlook.com" rhost-flags-OK-OK-OK-FAIL) by vger.kernel.org with ESMTP id S1752606AbbH1TXX (ORCPT ); Fri, 28 Aug 2015 15:23:23 -0400 From: Shenwei Wang To: Thomas Gleixner CC: "shawn.guo@linaro.org" , "jason@lakedaemon.net" , "sudeep.holla@arm.com" , "linux-arm-kernel@lists.infradead.org" , "linux-kernel@vger.kernel.org" , Huang Anson Subject: RE: [PATCH v2 1/1] irqchip: imx-gpcv2: Simplify the implementation Thread-Topic: [PATCH v2 1/1] irqchip: imx-gpcv2: Simplify the implementation Thread-Index: AQHQ4cVtVRGXhbefBEOg3W7o0CfV3p4hx3Lw Date: Fri, 28 Aug 2015 19:23:18 +0000 Message-ID: References: <1440617755-2942-1-git-send-email-shenwei.wang@freescale.com> In-Reply-To: Accept-Language: zh-CN, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: authentication-results: spf=none (sender IP is ) smtp.mailfrom=Shenwei.Wang@freescale.com; x-originating-ip: [192.88.168.50] x-microsoft-exchange-diagnostics: 1;BY1PR03MB1369;5:sgEPGuRrWG0HNuWVyRQL8SSsPtlOMJeixZ+CAITH6uhU/2ZBi6OcgpyJcef0huGn+1rpYWozJo3dRiefrDwiZUZmex0j2r5OxFgJB4ljJ5B3kmqkuH0tnp+8WRKbDwyzCxIhKNlfiMXGJTy8Wsw7lQ==;24:gErI0bilsVK8qtuw6RXR/32E33ZOOrVUopBSIvAb2rgLyru9E9OqUOQ11Y51X30TF0ZYvF6sP3KpD7CAWY3gPs0p6SEUO1Mgc50bAs3Lpa8=;20:Yn27Dz8uXbgTJM7BVfzulYfYucJC0yVRvDFdvE4SbqCLxNg4lJ0HxT8vPrWy6c65DOZL0eEk2aKZZXtd+JkMsw== x-microsoft-antispam: UriScan:;BCL:0;PCL:0;RULEID:;SRVR:BY1PR03MB1369; x-microsoft-antispam-prvs: x-exchange-antispam-report-test: UriScan:; x-exchange-antispam-report-cfa-test: BCL:0;PCL:0;RULEID:(601004)(8121501046)(5005006)(3002001);SRVR:BY1PR03MB1369;BCL:0;PCL:0;RULEID:;SRVR:BY1PR03MB1369; x-forefront-prvs: 0682FC00E8 x-forefront-antispam-report: SFV:NSPM;SFS:(10019020)(6009001)(164054003)(24454002)(13464003)(199003)(189002)(74316001)(62966003)(81156007)(86362001)(50986999)(40100003)(5007970100001)(87936001)(99286002)(189998001)(105586002)(2656002)(110136002)(2950100001)(68736005)(54356999)(66066001)(102836002)(64706001)(5004730100002)(106116001)(76176999)(46102003)(10400500002)(5002640100001)(106356001)(92566002)(77096005)(101416001)(122556002)(76576001)(5001830100001)(5001960100002)(97736004)(2900100001)(19580405001)(5003600100002)(107886002)(5001920100001)(4001540100001)(19580395003)(77156002)(33656002)(5001860100001)(4001430100001);DIR:OUT;SFP:1102;SCL:1;SRVR:BY1PR03MB1369;H:CY1PR0301MB0843.namprd03.prod.outlook.com;FPR:;SPF:None;PTR:InfoNoRecords;A:1;MX:1;LANG:en; Content-Type: text/plain; charset="gb2312" MIME-Version: 1.0 X-OriginatorOrg: freescale.com X-MS-Exchange-CrossTenant-originalarrivaltime: 28 Aug 2015 19:23:18.5084 (UTC) X-MS-Exchange-CrossTenant-fromentityheader: Hosted X-MS-Exchange-CrossTenant-id: 710a03f5-10f6-4d38-9ff4-a80b81da590d X-MS-Exchange-Transport-CrossTenantHeadersStamped: BY1PR03MB1369 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Transfer-Encoding: 8bit X-MIME-Autoconverted: from base64 to 8bit by mail.home.local id t7SJNUmL008193 Content-Length: 1402 Lines: 47 > -----Original Message----- > From: Thomas Gleixner [mailto:tglx@linutronix.de] > Sent: 2015??8??28?? 14:11 > To: Wang Shenwei-B38339 > Cc: shawn.guo@linaro.org; jason@lakedaemon.net; sudeep.holla@arm.com; > linux-arm-kernel@lists.infradead.org; linux-kernel@vger.kernel.org; Huang > Yongcai-B20788 > Subject: Re: [PATCH v2 1/1] irqchip: imx-gpcv2: Simplify the implementation > > On Wed, 26 Aug 2015, Shenwei Wang wrote: > > u32 imx_gpcv2_get_wakeup_source(u32 **sources) { > > - if (!imx_gpcv2_instance) > > + struct gpcv2_irqchip_data *cd; > > + void __iomem *reg; > > + int i; > > + > > + cd = imx_gpcv2_instance; > > + if (!cd) > > return 0; > > > > + for (i = 0; i < IMR_NUM; i++) { > > + reg = cd->gpc_base + cd->cpu2wakeup + i * 4; > > + cd->wakeup_sources[i] = readl_relaxed(reg); > > + } > > + > > if (sources) > > - *sources = imx_gpcv2_instance->wakeup_sources; > > + *sources = cd->wakeup_sources; > > > > return IMR_NUM; > > } > > So once again. As you said before nothing is going to use the case where source > == NULL, can we please get rid of it? It will be used to allocate the memory for the predefined values of interrupts for each power Domain. Can we keep it? Thanks, Shenwei > Thanks, > > tglx ????{.n?+???????+%?????ݶ??w??{.n?+????{??G?????{ay?ʇڙ?,j??f???h?????????z_??(?階?ݢj"???m??????G????????????&???~???iO???z??v?^?m???? ????????I?