From patchwork Thu Apr 18 10:11:48 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 16195 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ve0-f197.google.com (mail-ve0-f197.google.com [209.85.128.197]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 2623823974 for ; Thu, 18 Apr 2013 10:13:22 +0000 (UTC) Received: by mail-ve0-f197.google.com with SMTP id 15sf20091vea.8 for ; Thu, 18 Apr 2013 03:12:45 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:mime-version:x-beenthere:x-received:received-spf :x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:x-received:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-gm-message-state:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-google-group-id:list-post:list-help:list-archive:list-unsubscribe; bh=jqCiyhTIkUl9qzHfD8DnAcuJzVkNykWUb06/hx0BFKw=; b=ArJ+VIpB7CxdX75HvNX+A1JGsci+8jcDLA2FwLvGAfOaC2QCZ+CXV8miKLqOekJW/u RO863rW3S1u1CrK9Usn5TVbuL9/TkxcWgQrEcZKwboLYXqCetdIFAqCuNOHr94Mso/pk XanNPiLPsFRdf5S4flJMg7L1ib5votCOMF/Nfv0ie/vE3QQ4pH7DW9Nk8qBF2GbuffF6 PNRASu8vtXdYvf1l0USnQCemXrxx2ThJMzICuqL2K5+tvIzDuDrU6BA66vBre7Wkk3LT s6BX4fuCRWfd8OR2rFNlHddhnT7A/3PalHyF3pGNUCoVoBGjbD6G95D1J3H1LC0RgvF5 JF2A== X-Received: by 10.224.58.77 with SMTP id f13mr7560613qah.7.1366279965134; Thu, 18 Apr 2013 03:12:45 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.49.134 with SMTP id u6ls1388068qen.79.gmail; Thu, 18 Apr 2013 03:12:44 -0700 (PDT) X-Received: by 10.220.167.9 with SMTP id o9mr7650240vcy.25.1366279964693; Thu, 18 Apr 2013 03:12:44 -0700 (PDT) Received: from mail-vc0-f172.google.com (mail-vc0-f172.google.com [209.85.220.172]) by mx.google.com with ESMTPS id ex4si6233530vdb.79.2013.04.18.03.12.44 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 18 Apr 2013 03:12:44 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.220.172 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.220.172; Received: by mail-vc0-f172.google.com with SMTP id gd11so2268085vcb.31 for ; Thu, 18 Apr 2013 03:12:44 -0700 (PDT) X-Received: by 10.52.163.231 with SMTP id yl7mr6534883vdb.57.1366279964560; Thu, 18 Apr 2013 03:12:44 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.58.127.98 with SMTP id nf2csp115731veb; Thu, 18 Apr 2013 03:12:44 -0700 (PDT) X-Received: by 10.180.183.133 with SMTP id em5mr7432537wic.26.1366279963539; Thu, 18 Apr 2013 03:12:43 -0700 (PDT) Received: from mail-we0-x229.google.com (mail-we0-x229.google.com [2a00:1450:400c:c03::229]) by mx.google.com with ESMTPS id c8si7199283wie.74.2013.04.18.03.12.43 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 18 Apr 2013 03:12:43 -0700 (PDT) Received-SPF: neutral (google.com: 2a00:1450:400c:c03::229 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=2a00:1450:400c:c03::229; Received: by mail-we0-f169.google.com with SMTP id x43so2212807wey.28 for ; Thu, 18 Apr 2013 03:12:43 -0700 (PDT) X-Received: by 10.180.87.193 with SMTP id ba1mr17030547wib.10.1366279963163; Thu, 18 Apr 2013 03:12:43 -0700 (PDT) Received: from localhost.localdomain (cpc34-aztw25-2-0-cust250.18-1.cable.virginmedia.com. [86.16.136.251]) by mx.google.com with ESMTPS id t7sm30483773wij.2.2013.04.18.03.12.41 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 18 Apr 2013 03:12:42 -0700 (PDT) From: Lee Jones To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: arnd@arndb.de, linus.walleij@stericsson.com, Lee Jones Subject: [PATCH 06/32] ARM: ux500: Strip out duplicate USB DMA configuration Date: Thu, 18 Apr 2013 11:11:48 +0100 Message-Id: <1366279934-30761-7-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.10.4 In-Reply-To: <1366279934-30761-1-git-send-email-lee.jones@linaro.org> References: <1366279934-30761-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQmn78pfBKpQJwnptjo27wIZcc3CeyRCbM0W2cHv7tB3s+tm7iemGJF/0Bt4JokACkkv3KX1 X-Original-Sender: lee.jones@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.172 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Precedence: list Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , For the moment at least, the TX and RX channels for DB8500 USB are identical, so this patch generalises them into a single structure and passes it twice. Once as the TX and again for the RX configuration. We're keeping the infrastructure the same i.e. passing the TX and RX separately in case they start to differ on latter incarnations of the platform. Signed-off-by: Lee Jones --- arch/arm/mach-ux500/cpu-db8500.c | 17 +++-------------- 1 file changed, 3 insertions(+), 14 deletions(-) diff --git a/arch/arm/mach-ux500/cpu-db8500.c b/arch/arm/mach-ux500/cpu-db8500.c index f72cc9b..a15678d 100644 --- a/arch/arm/mach-ux500/cpu-db8500.c +++ b/arch/arm/mach-ux500/cpu-db8500.c @@ -166,18 +166,7 @@ static void __init db8500_add_gpios(struct device *parent) dbx500_add_pinctrl(parent, "pinctrl-db8500", U8500_PRCMU_BASE); } -static int usb_db8500_rx_dma_cfg[] = { - DB8500_DMA_DEV38_USB_OTG_IEP_AND_OEP_1_9, - DB8500_DMA_DEV37_USB_OTG_IEP_AND_OEP_2_10, - DB8500_DMA_DEV36_USB_OTG_IEP_AND_OEP_3_11, - DB8500_DMA_DEV19_USB_OTG_IEP_AND_OEP_4_12, - DB8500_DMA_DEV18_USB_OTG_IEP_AND_OEP_5_13, - DB8500_DMA_DEV17_USB_OTG_IEP_AND_OEP_6_14, - DB8500_DMA_DEV16_USB_OTG_IEP_AND_OEP_7_15, - DB8500_DMA_DEV39_USB_OTG_IEP_AND_OEP_8 -}; - -static int usb_db8500_tx_dma_cfg[] = { +static int usb_db8500_dma_cfg[] = { DB8500_DMA_DEV38_USB_OTG_IEP_AND_OEP_1_9, DB8500_DMA_DEV37_USB_OTG_IEP_AND_OEP_2_10, DB8500_DMA_DEV36_USB_OTG_IEP_AND_OEP_3_11, @@ -219,7 +208,7 @@ struct device * __init u8500_init_devices(struct ab8500_platform_data *ab8500) db8500_add_rtc(parent); db8500_add_gpios(parent); - db8500_add_usb(parent, usb_db8500_rx_dma_cfg, usb_db8500_tx_dma_cfg); + db8500_add_usb(parent, usb_db8500_dma_cfg, usb_db8500_dma_cfg); for (i = 0; i < ARRAY_SIZE(platform_devs); i++) platform_devs[i]->dev.parent = parent; @@ -238,7 +227,7 @@ static struct device * __init u8500_of_init_devices(void) { struct device *parent = db8500_soc_device_init(); - db8500_add_usb(parent, usb_db8500_rx_dma_cfg, usb_db8500_tx_dma_cfg); + db8500_add_usb(parent, usb_db8500_dma_cfg, usb_db8500_dma_cfg); u8500_dma40_device.dev.parent = parent;