From patchwork Sat Feb 15 01:37:32 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sergei Shtylyov X-Patchwork-Id: 3655201 Return-Path: X-Original-To: patchwork-linux-sh@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 91D5B9F334 for ; Sat, 15 Feb 2014 00:37:35 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id B75E02020E for ; Sat, 15 Feb 2014 00:37:34 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id E5F862020F for ; Sat, 15 Feb 2014 00:37:32 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752887AbaBOAhc (ORCPT ); Fri, 14 Feb 2014 19:37:32 -0500 Received: from mail-la0-f41.google.com ([209.85.215.41]:60895 "EHLO mail-la0-f41.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752397AbaBOAhc (ORCPT ); Fri, 14 Feb 2014 19:37:32 -0500 Received: by mail-la0-f41.google.com with SMTP id mc6so10037953lab.28 for ; Fri, 14 Feb 2014 16:37:30 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:organization:to:subject:date:user-agent:cc :references:in-reply-to:mime-version:content-type :content-transfer-encoding:message-id; bh=AWx5Cb1MWGX5NQFrdBSm9WG/DRsVCnKDJkfDrWJldnI=; b=I2i+BQj8UdqM8nuNSti+C3nvwUt+50DFcouH5mR9ULBn3qsyF4segolpE3ja9lPeuR mGJIfboXAW63ahKDPi79fe3McQIEc8tzGgeUWDQLLE6rp5p4r2AVM3+tDwWZcO5fmlCB UNF8Rs/cVGcil+V2uEhIIBK691LOAlRWUi7M5kXk1Sa44PTwwFii9ShS0Xof2rOm/1X2 8kKL4S/0/Zyy2FJTlvfzjq14uj4tI7lqhrW5AsjzKavS2s1Xfl08ppX1R9JrL3bKjcRk s5VrKae+f34CEUIMAb4JUE0968F+HEUC8asIM1aH5jZWa7JjoUHoW/7LfOFHiFvSGoT+ Qiow== X-Gm-Message-State: ALoCoQm6LvRWnLYC77dzC0qfMcw9X0uX/Dac38V5bX7ZDTcDT/Ey213mfGaV8ybAEFAXWbBN30bc X-Received: by 10.112.198.135 with SMTP id jc7mr82354lbc.75.1392424649186; Fri, 14 Feb 2014 16:37:29 -0800 (PST) Received: from wasted.cogentembedded.com (ppp83-237-57-97.pppoe.mtu-net.ru. [83.237.57.97]) by mx.google.com with ESMTPSA id jf8sm7672154lbc.8.2014.02.14.16.37.28 for (version=TLSv1 cipher=RC4-SHA bits=128/128); Fri, 14 Feb 2014 16:37:28 -0800 (PST) From: Sergei Shtylyov Organization: Cogent Embedded To: horms@verge.net.au, linux-sh@vger.kernel.org Subject: [PATCH 5/5] ARM: shmobile: Genmai: set proper DMA masks for Ether device Date: Sat, 15 Feb 2014 04:37:32 +0300 User-Agent: KMail/1.13.5 (Linux/2.6.32.26-175.fc12.i686.PAE; KDE/4.4.5; i686; ; ) Cc: magnus.damm@gmail.com, linux@arm.linux.org.uk, linux-arm-kernel@lists.infradead.org References: <201402150424.30954.sergei.shtylyov@cogentembedded.com> In-Reply-To: <201402150424.30954.sergei.shtylyov@cogentembedded.com> MIME-Version: 1.0 Message-Id: <201402150437.32973.sergei.shtylyov@cogentembedded.com> Sender: linux-sh-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-sh@vger.kernel.org X-Spam-Status: No, score=-7.5 required=5.0 tests=BAYES_00, RCVD_IN_DNSWL_HI, RP_MATCHES_RCVD, UNPARSEABLE_RELAY autolearn=ham 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 Ether MAC is a DMA-capable device and so should have 'dev.dma_mask' and 'dev.coherent_dma_mask' fields set properly, to reflect 32-bit DMA addressing ability. Signed-off-by: Sergei Shtylyov --- arch/arm/mach-shmobile/board-genmai.c | 19 ++++++++++++++----- 1 file changed, 14 insertions(+), 5 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-sh" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Index: renesas/arch/arm/mach-shmobile/board-genmai.c =================================================================== --- renesas.orig/arch/arm/mach-shmobile/board-genmai.c +++ renesas/arch/arm/mach-shmobile/board-genmai.c @@ -1,8 +1,9 @@ /* * Genmai board support * - * Copyright (C) 2013 Renesas Solutions Corp. + * Copyright (C) 2013-2014 Renesas Solutions Corp. * Copyright (C) 2013 Magnus Damm + * Copyright (C) 2014 Cogent Embedded, Inc. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -43,6 +44,17 @@ static const struct resource ether_resou DEFINE_RES_IRQ(gic_iid(359)), }; +static const struct platform_device_info ether_info __initconst = { + .parent = &platform_bus, + .name = "r7s72100-ether", + .id = -1, + .res = ether_resources, + .num_res = ARRAY_SIZE(ether_resources), + .data = ðer_pdata, + .size_data = sizeof(ether_pdata), + .dma_mask = DMA_BIT_MASK(32), +}; + /* RSPI */ #define RSPI_RESOURCE(idx, baseaddr, irq) \ static const struct resource rspi##idx##_resources[] __initconst = { \ @@ -82,10 +94,7 @@ static void __init genmai_add_standard_d r7s72100_clock_init(); r7s72100_add_dt_devices(); - platform_device_register_resndata(&platform_bus, "r7s72100-ether", -1, - ether_resources, - ARRAY_SIZE(ether_resources), - ðer_pdata, sizeof(ether_pdata)); + platform_device_register_full(ðer_info); r7s72100_register_rspi(0); r7s72100_register_rspi(1);