From patchwork Sat Jun 15 02:32:47 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Olof Johansson X-Patchwork-Id: 2725811 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id A02C49F96B for ; Sat, 15 Jun 2013 02:33:50 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id D1BD72011B for ; Sat, 15 Jun 2013 02:33:49 +0000 (UTC) Received: from casper.infradead.org (casper.infradead.org [85.118.1.10]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D96372014B for ; Sat, 15 Jun 2013 02:33:48 +0000 (UTC) Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UngJ3-0007DM-CE; Sat, 15 Jun 2013 02:33:33 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UngIo-00084P-NM; Sat, 15 Jun 2013 02:33:18 +0000 Received: from mail-pb0-x233.google.com ([2607:f8b0:400e:c01::233]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UngIl-00083O-Rf for linux-arm-kernel@lists.infradead.org; Sat, 15 Jun 2013 02:33:16 +0000 Received: by mail-pb0-f51.google.com with SMTP id um15so1084611pbc.24 for ; Fri, 14 Jun 2013 19:32:53 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:x-gm-message-state; bh=cT5vxO3Z5qEtKj2BEjLQoRqFuudpgwHxRTGMzs1RLVE=; b=Rtj3ea4RzEKGo1x09e/nDAfYTnakCpE8zihvRC+KdwrRDIeOC6YmorVuz1zUxwOolM U5A1/2oag3bx3YsnFU4WxVrYAD9/G060v4CIQy06Av9DPybWpRDuBWV5m0ZL9Raapqfw ZMcvCW2pwoEDj6AofnlTXi1JcLLhUZ6/CGTBUDrFA55c9LYmr8gATZt4ARLGQuL+ZlXj wtclollJOPsVatyJ/C0iOdVB4Av/HJYpl05wY6ip7mqjJRftl1Of9kIUFSbaVf+ZSBeO FNNFX5RmuV/3dfxg9qb1gecaZiaKYoVeDKL++LLdMNq8hWL49u3g2LucRZ4l9wVHOHh0 lsnQ== X-Received: by 10.66.155.199 with SMTP id vy7mr4984271pab.69.1371263573091; Fri, 14 Jun 2013 19:32:53 -0700 (PDT) Received: from quad.lixom.net (173-13-129-225-sfba.hfc.comcastbusiness.net. [173.13.129.225]) by mx.google.com with ESMTPSA id qe10sm4276631pbb.2.2013.06.14.19.32.51 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 14 Jun 2013 19:32:52 -0700 (PDT) From: Olof Johansson To: Linus Walleij Subject: [PATCH] ARM: ux500: minor code cleanup Date: Fri, 14 Jun 2013 19:32:47 -0700 Message-Id: <1371263567-8520-1-git-send-email-olof@lixom.net> X-Mailer: git-send-email 1.8.1.192.gc4361b8 X-Gm-Message-State: ALoCoQnU7wyPqxIpe2baaHgOeRCMDZhynUwdNMwCKtJ3PIV/l+EC3OWUUcj2KHKl/MdKXQDEot9o X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130614_223315_993559_BCB8F08F X-CRM114-Status: GOOD ( 16.12 ) X-Spam-Score: -1.9 (-) Cc: Olof Johansson , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Spam-Status: No, score=-4.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_MED, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Clean up coding style a bit in cpu-db8500. Signed-off-by: Olof Johansson --- Linus, Noticed the last chunk of this patch when I resolved one of the recent conflicts, so I did a once-over of the file. Feel free to drop the first chunk when applying if you'd prefer to do a sweeping DEFINE_RES() cleanup instead. arch/arm/mach-ux500/cpu-db8500.c | 19 ++++++++----------- 1 file changed, 8 insertions(+), 11 deletions(-) diff --git a/arch/arm/mach-ux500/cpu-db8500.c b/arch/arm/mach-ux500/cpu-db8500.c index 27e5566..d25db87 100644 --- a/arch/arm/mach-ux500/cpu-db8500.c +++ b/arch/arm/mach-ux500/cpu-db8500.c @@ -95,11 +95,7 @@ void __init u8500_map_io(void) } static struct resource db8500_pmu_resources[] = { - [0] = { - .start = IRQ_DB8500_PMU, - .end = IRQ_DB8500_PMU, - .flags = IORESOURCE_IRQ, - }, + [0] = DEFINE_RES_IRQ(IRQ_DB8500_PMU), }; /* @@ -281,8 +277,8 @@ static const struct of_device_id u8500_local_bus_nodes[] = { /* only create devices below soc node */ { .compatible = "stericsson,db8500", }, { .compatible = "stericsson,db8500-prcmu", }, - { .compatible = "simple-bus"}, - { }, + { .compatible = "simple-bus" }, + {}, }; static void __init u8500_init_machine(void) @@ -290,15 +286,16 @@ static void __init u8500_init_machine(void) struct device *parent = db8500_soc_device_init(); /* Pinmaps must be in place before devices register */ - if (of_machine_is_compatible("st-ericsson,mop500")) + if (of_machine_is_compatible("st-ericsson,mop500")) { mop500_pinmaps_init(); - else if (of_machine_is_compatible("calaosystems,snowball-a9500")) { + } else if (of_machine_is_compatible("calaosystems,snowball-a9500")) { snowball_pinmaps_init(); mop500_snowball_ethernet_clock_enable(); - } else if (of_machine_is_compatible("st-ericsson,hrefv60+")) + } else if (of_machine_is_compatible("st-ericsson,hrefv60+")) { hrefv60_pinmaps_init(); - else if (of_machine_is_compatible("st-ericsson,ccu9540")) {} + } else if (of_machine_is_compatible("st-ericsson,ccu9540")) { /* TODO: Add pinmaps for ccu9540 board. */ + } /* automatically probe child nodes of dbx5x0 devices */ if (of_machine_is_compatible("st-ericsson,u8540"))