From patchwork Wed Mar 6 08:48:33 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vivek Gautam X-Patchwork-Id: 225452 X-Patchwork-Delegate: promsoft@gmail.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 72E842C0385 for ; Wed, 6 Mar 2013 19:51:58 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 821034A237; Wed, 6 Mar 2013 09:51:51 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id jxkqZZba-kNr; Wed, 6 Mar 2013 09:51:51 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 227554A238; Wed, 6 Mar 2013 09:51:45 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 1A87F4A221 for ; Wed, 6 Mar 2013 09:51:39 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id qIH9-BCEwc4L for ; Wed, 6 Mar 2013 09:51:37 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mailout2.samsung.com (mailout2.samsung.com [203.254.224.25]) by theia.denx.de (Postfix) with ESMTP id 1A8C54A228 for ; Wed, 6 Mar 2013 09:51:36 +0100 (CET) Received: from epcpsbgr2.samsung.com (u142.gpu120.samsung.co.kr [203.254.230.142]) by mailout2.samsung.com (Oracle Communications Messaging Server 7u4-24.01 (7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTP id <0MJ8006MUDWTN3U0@mailout2.samsung.com> for u-boot@lists.denx.de; Wed, 06 Mar 2013 17:50:59 +0900 (KST) Received: from epcpsbgm2.samsung.com ( [172.20.52.122]) by epcpsbgr2.samsung.com (EPCPMTA) with SMTP id C7.E8.25214.27307315; Wed, 06 Mar 2013 17:50:58 +0900 (KST) X-AuditID: cbfee68e-b7fa46d00000627e-06-513703729785 Received: from epmmp1.local.host ( [203.254.227.16]) by epcpsbgm2.samsung.com (EPCPMTA) with SMTP id A1.C7.03880.27307315; Wed, 06 Mar 2013 17:50:58 +0900 (KST) Received: from vivekkumarg-linuxpc.sisodomain.com ([107.108.214.169]) by mmp1.samsung.com (Oracle Communications Messaging Server 7u4-24.01(7.0.4.24.0) 64bit (built Nov 17 2011)) with ESMTPA id <0MJ80010MDW69F80@mmp1.samsung.com> for u-boot@lists.denx.de; Wed, 06 Mar 2013 17:50:58 +0900 (KST) From: Vivek Gautam To: u-boot@lists.denx.de Date: Wed, 06 Mar 2013 14:18:33 +0530 Message-id: <1362559713-6743-3-git-send-email-gautam.vivek@samsung.com> X-Mailer: git-send-email 1.7.6.5 In-reply-to: <1362559713-6743-1-git-send-email-gautam.vivek@samsung.com> References: <1362559713-6743-1-git-send-email-gautam.vivek@samsung.com> X-Brightmail-Tracker: H4sIAAAAAAAAA+NgFjrELMWRmVeSWpSXmKPExsWyRsSkSreI2TzQYPtjRYu3ezvZHRg9zt7Z wRjAGMVlk5Kak1mWWqRvl8CVMfHhDraCmbwVCy+cZ25gfMHVxcjBISFgIrG7R7qLkRPIFJO4 cG89WxcjF4eQwFJGifZvb5lhajpuSEHEFzFK/PnaygzhrGWSeD/1EiNIN5uArkTT211gtoiA hMSv/qtgNrNApsS7zZeYQWxhAVuJt1fOsIMMZRFQlfiwKQ0kzCvgLtH84zQbxBEKEm9uPwMr 5xTwkLi/4gQLSLkQUM3anW4gayUELrNJ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35r0Ku/1v3FRhKuwT80a3o6y8T3/eWWaAvadk33r3i16y+xwp02l1KV tFa/DL6x53qt7ieXvUkWhiGTOFSrQ3yfdMmnNnJuatnKEZOnxFKckWioxVxUnAgAwChafLMC AAA= DLP-Filter: Pass X-MTR: 20000000000000000@CPGS X-CFilter-Loop: Reflected Cc: marex@denx.de, rajeshwari.s@samsung.com, patches@linaro.org Subject: [U-Boot] [PATCH v4 2/2] usb: ehci: exynos: Enable non-dt path X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de Enabling the non-dt path for the driver so that we don't get any build errors for non-dt configuration. Signed-off-by: Vivek Gautam Acked-by: Simon Glass --- Changes from v3: - No change Changes from v2: - Adding necessary typecast (struct ehci_hccr *) for ctx->hcd. Changes from v1: - Using CONFIG_OF_CONTROL around exynos_usb_parse_dt() definition since it is used for DT systems only. drivers/usb/host/ehci-exynos.c | 7 +++++++ 1 files changed, 7 insertions(+), 0 deletions(-) diff --git a/drivers/usb/host/ehci-exynos.c b/drivers/usb/host/ehci-exynos.c index c4c90be..0c797aa 100644 --- a/drivers/usb/host/ehci-exynos.c +++ b/drivers/usb/host/ehci-exynos.c @@ -47,6 +47,7 @@ struct exynos_ehci { static struct exynos_ehci exynos; +#ifdef CONFIG_OF_CONTROL static int exynos_usb_parse_dt(const void *blob, struct exynos_ehci *exynos) { fdt_addr_t addr; @@ -90,6 +91,7 @@ static int exynos_usb_parse_dt(const void *blob, struct exynos_ehci *exynos) return 0; } +#endif /* Setup the EHCI host controller. */ static void setup_usb_phy(struct exynos_usb_phy *usb) @@ -151,10 +153,15 @@ int ehci_hcd_init(int index, struct ehci_hccr **hccr, struct ehci_hcor **hcor) { struct exynos_ehci *ctx = &exynos; +#ifdef CONFIG_OF_CONTROL if (exynos_usb_parse_dt(gd->fdt_blob, ctx)) { debug("Unable to parse device tree for ehci-exynos\n"); return -ENODEV; } +#else + ctx->usb = (struct exynos_usb_phy *)samsung_get_base_usb_phy(); + ctx->hcd = (struct ehci_hccr *)samsung_get_base_usb_ehci(); +#endif setup_usb_phy(ctx->usb);