From patchwork Fri Jul 27 12:45:53 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 10322 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 8375823E23 for ; Fri, 27 Jul 2012 12:46:24 +0000 (UTC) Received: from mail-gh0-f180.google.com (mail-gh0-f180.google.com [209.85.160.180]) by fiordland.canonical.com (Postfix) with ESMTP id 525E1A1853E for ; Fri, 27 Jul 2012 12:46:24 +0000 (UTC) Received: by mail-gh0-f180.google.com with SMTP id z12so3105409ghb.11 for ; Fri, 27 Jul 2012 05:46:24 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=Z6lhVw8vN+sZ7e7AvVMyqY9W5+VuepujFCeoqw8VaBs=; b=LI5tCNSISEHA3UktToVsm4Qn3xGY8UnmrQ7bhW9c7rdeVwGNiYctN7jjYqatwQzGc7 cY8QbHPA9Cuk1ejXbO+QdHpwq8OrVdzMApF5ZbGKuA/VcWQYzf+s8qA3sEhowFjYMNFG jbrGs1xovI8C7TYiOLgc/JJ/T2aW3mRmydck+9QoQjLpGcGEvwExWIw2vqZKbujru4wc 9TGystXlG7SV3pgZqr8ac1KnRpAm1ZPqD8Z0ulSG8snv9rQpd+8z4N9JGs+ZWG50ztml txAHQfmdl09sLwgz7OJ8/9KUe6Un1/IeUILWM2VSVy03zw2K7flfpjDT497V1y2pyG/r vuLQ== Received: by 10.50.160.130 with SMTP id xk2mr1723094igb.66.1343393183911; Fri, 27 Jul 2012 05:46:23 -0700 (PDT) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.43.93.3 with SMTP id bs3csp29853icc; Fri, 27 Jul 2012 05:46:23 -0700 (PDT) Received: by 10.216.134.11 with SMTP id r11mr1113903wei.177.1343393182396; Fri, 27 Jul 2012 05:46:22 -0700 (PDT) Received: from mail-wi0-f172.google.com (mail-wi0-f172.google.com [209.85.212.172]) by mx.google.com with ESMTPS id n21si2630731wee.115.2012.07.27.05.46.22 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 27 Jul 2012 05:46:22 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.212.172 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=209.85.212.172; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.212.172 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) smtp.mail=lee.jones@linaro.org Received: by mail-wi0-f172.google.com with SMTP id hm11so5802099wib.13 for ; Fri, 27 Jul 2012 05:46:22 -0700 (PDT) Received: by 10.180.14.8 with SMTP id l8mr5980187wic.6.1343393182283; Fri, 27 Jul 2012 05:46:22 -0700 (PDT) Received: from localhost.localdomain (cpc1-aztw13-0-0-cust473.18-1.cable.virginmedia.com. [77.102.241.218]) by mx.google.com with ESMTPS id dc3sm12342025wib.7.2012.07.27.05.46.20 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 27 Jul 2012 05:46:21 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: STEricsson_nomadik_linux@list.st.com, linus.walleij@stericsson.com, arnd@arndb.de, olalilja@yahoo.se, ola.o.lilja@stericsson.com, alsa-devel@alsa-project.org, lrg@ti.com, broonie@opensource.wolfsonmicro.com, Lee Jones Subject: [PATCH 09/18] ARM: ux500: Fork MSP platform registration for step-by-step DT enablement Date: Fri, 27 Jul 2012 13:45:53 +0100 Message-Id: <1343393162-11938-10-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1343393162-11938-1-git-send-email-lee.jones@linaro.org> References: <1343393162-11938-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQnaKiN3I0cwlvVBOgoNo0s9rA8TrV4HApt0VfiU308B2amN1pWCEXTdOzbH5OrrQ9UVHKJJ We've done this before and it worked well last time. Here we're duplicating a complex registration function to ease the process of enabling it for Device Tree. As there are quite a few steps taken during the registration process, it makes sense to break them up into more manageable chunks. This patch will aid us. Signed-off-by: Lee Jones --- arch/arm/mach-ux500/board-mop500-msp.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/arch/arm/mach-ux500/board-mop500-msp.c b/arch/arm/mach-ux500/board-mop500-msp.c index 719db15..ec5857b 100644 --- a/arch/arm/mach-ux500/board-mop500-msp.c +++ b/arch/arm/mach-ux500/board-mop500-msp.c @@ -174,6 +174,26 @@ static struct msp_i2s_platform_data msp3_platform_data = { .use_pinctrl = true, }; +/* Due for removal once the MSP driver has been fully DT:ed. */ +void mop500_of_msp_init(struct device *parent) +{ + pr_info("%s: Register platform-device 'snd-soc-u8500'.\n", __func__); + platform_device_register(&snd_soc_mop500); + + pr_info("Initialize MSP I2S-devices.\n"); + db8500_add_msp_i2s(parent, 0, U8500_MSP0_BASE, IRQ_DB8500_MSP0, + &msp0_platform_data); + db8500_add_msp_i2s(parent, 1, U8500_MSP1_BASE, IRQ_DB8500_MSP1, + &msp1_platform_data); + db8500_add_msp_i2s(parent, 2, U8500_MSP2_BASE, IRQ_DB8500_MSP2, + &msp2_platform_data); + db8500_add_msp_i2s(parent, 3, U8500_MSP3_BASE, IRQ_DB8500_MSP1, + &msp3_platform_data); + + pr_info("%s: Register platform-device 'ux500-pcm'\n", __func__); + platform_device_register(&ux500_pcm); +} + void mop500_msp_init(struct device *parent) { pr_info("%s: Register platform-device 'snd-soc-u8500'.\n", __func__);