From patchwork Tue Apr 17 10:44:06 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 7901 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 C231923E00 for ; Tue, 17 Apr 2012 10:45:21 +0000 (UTC) Received: from mail-iy0-f180.google.com (mail-iy0-f180.google.com [209.85.210.180]) by fiordland.canonical.com (Postfix) with ESMTP id 8660EA18421 for ; Tue, 17 Apr 2012 10:45:21 +0000 (UTC) Received: by mail-iy0-f180.google.com with SMTP id e36so12004590iag.11 for ; Tue, 17 Apr 2012 03:45:21 -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=jhLS1IT2d/HqOcFvgow2o9dAMAOtAQ40zc3cbmsdptk=; b=O7MG9+f71DLTPmTF+L2ULfmAOkdjSePSHMX13XDCwj8h0hqOEcHyFtV0YSOB/0fdp+ LhJ/oig0pu3Nmx3kxWYZjhxAy4LSL4Yprp8N9kkVplfIq569Lm0xJypHi8taZrvHTSxU B7E/FhcEC5wCrsFWZHOdQc/jAId8F3udX0ATxCvB/qppch7iJfFrxiPV0L5dxt+qrMef HBmn3z2yOVmOcdlLFG9L9+ViQ+zIL2y8suzUPhYZScYcpXygzDKQb3gIC1rLDrT66RFW 31c+ruTBB+rihIyY1TA0uJ5kOpN5j91kj/ty/e/P00RkH3i3323gHgGhU2vwB1pRY08u WQ2g== Received: by 10.43.49.201 with SMTP id vb9mr9687354icb.35.1334659521315; Tue, 17 Apr 2012 03:45:21 -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.231.137.198 with SMTP id x6csp138732ibt; Tue, 17 Apr 2012 03:45:20 -0700 (PDT) Received: by 10.216.144.6 with SMTP id m6mr8230062wej.43.1334659520246; Tue, 17 Apr 2012 03:45:20 -0700 (PDT) Received: from mail-wi0-f178.google.com (mail-wi0-f178.google.com [209.85.212.178]) by mx.google.com with ESMTPS id y43si21417417weq.132.2012.04.17.03.45.19 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 17 Apr 2012 03:45:20 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.212.178 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=209.85.212.178; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.212.178 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-f178.google.com with SMTP id hq7so368382wib.13 for ; Tue, 17 Apr 2012 03:45:19 -0700 (PDT) Received: by 10.216.136.72 with SMTP id v50mr9001175wei.73.1334659519751; Tue, 17 Apr 2012 03:45:19 -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 fn2sm42069492wib.0.2012.04.17.03.45.15 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 17 Apr 2012 03:45:19 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org Cc: arnd@arndb.de, linus.walleij@stericsson.com, grant.likely@secretlab.ca, cjb@laptop.org, linux@arm.linux.org.uk, Lee Jones Subject: [PATCH 14/16] ARM: ux500: Fork cpu-db8500 platform_devs for sequential DT enablement Date: Tue, 17 Apr 2012 11:44:06 +0100 Message-Id: <1334659448-11521-15-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.9.1 In-Reply-To: <1334659448-11521-1-git-send-email-lee.jones@linaro.org> References: <1334659448-11521-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQnCurrWqH2SkrGOQr4UC1XDDWgYVIrYlyYq9ATOA9auLJxSAb78bjpO6PLLbo5H5zONQADj To aid in sequential one-by-one Device Tree enablement, we split cpu-db8500's platform_devs structure into normal platform boot, where we leave all devices to be added in tact and a DT version where we will remove the devices as they are DT enabled. Signed-off-by: Lee Jones --- arch/arm/mach-ux500/cpu-db8500.c | 18 +++++++++++++++--- 1 files changed, 15 insertions(+), 3 deletions(-) diff --git a/arch/arm/mach-ux500/cpu-db8500.c b/arch/arm/mach-ux500/cpu-db8500.c index 58768d9..c97eab7 100644 --- a/arch/arm/mach-ux500/cpu-db8500.c +++ b/arch/arm/mach-ux500/cpu-db8500.c @@ -121,6 +121,12 @@ static struct platform_device *platform_devs[] __initdata = { &db8500_prcmu_device, }; +static struct platform_device *of_platform_devs[] __initdata = { + &u8500_dma40_device, + &db8500_pmu_device, + &db8500_prcmu_device, +}; + static resource_size_t __initdata db8500_gpio_base[] = { U8500_GPIOBANK0_BASE, U8500_GPIOBANK1_BASE, @@ -221,10 +227,16 @@ struct device * __init u8500_of_init_devices(void) platform_device_register_data(parent, "cpufreq-u8500", -1, NULL, 0); - for (i = 0; i < ARRAY_SIZE(platform_devs); i++) - platform_devs[i]->dev.parent = parent; + for (i = 0; i < ARRAY_SIZE(of_platform_devs); i++) + of_platform_devs[i]->dev.parent = parent; - platform_add_devices(platform_devs, ARRAY_SIZE(platform_devs)); + /* + * Devices to be DT:ed: + * u8500_dma40_device = todo + * db8500_pmu_device = todo + * db8500_prcmu_device = todo + */ + platform_add_devices(of_platform_devs, ARRAY_SIZE(of_platform_devs)); return parent; }