From patchwork Fri Mar 12 15:21:47 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Scott Ellis X-Patchwork-Id: 85300 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o2CFLpJZ024638 for ; Fri, 12 Mar 2010 15:21:51 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934196Ab0CLPVu (ORCPT ); Fri, 12 Mar 2010 10:21:50 -0500 Received: from pan.gwi.net ([207.5.128.165]:3108 "EHLO pan.gwi.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934020Ab0CLPVt (ORCPT ); Fri, 12 Mar 2010 10:21:49 -0500 Received: from [192.168.10.4] (66-63-88-74.static.suscom-maine.net [66.63.88.74]) by pan.gwi.net (8.13.1/8.13.1) with ESMTP id o2CFLmg5033452; Fri, 12 Mar 2010 10:21:48 -0500 (EST) (envelope-from scott@jumpnowtek.com) Subject: [PATCH 2/6] SPI omap2_mcspi: Add max_clk_div field to mcspi platform config From: Scott Ellis To: spi-devel-general@lists.sourceforge.net Cc: David Brownell , Grant Likely , Tony Lindgren , Andrew Morton , Roman Tereshonkov , linux-omap@vger.kernel.org, Aaro Koskinen , Kevin Hilman , linux-arm-kernel@lists.infradead.org Date: Fri, 12 Mar 2010 10:21:47 -0500 Message-ID: <1268407307.14445.51.camel@quad> Mime-Version: 1.0 X-Mailer: Evolution 2.28.1 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter.kernel.org [140.211.167.41]); Fri, 12 Mar 2010 15:21:51 +0000 (UTC) diff --git a/arch/arm/mach-omap2/devices.c b/arch/arm/mach-omap2/devices.c index 23e4d77..d4ad126 100644 --- a/arch/arm/mach-omap2/devices.c +++ b/arch/arm/mach-omap2/devices.c @@ -302,6 +302,11 @@ static inline void omap_init_sti(void) {} static struct omap2_mcspi_platform_config omap2_mcspi1_config = { .num_cs = 4, +#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4) + .max_clk_div = 0x0c, +#else + .max_clk_div = 0x0f, +#endif }; static struct resource omap2_mcspi1_resources[] = { @@ -324,6 +329,11 @@ static struct platform_device omap2_mcspi1 = { static struct omap2_mcspi_platform_config omap2_mcspi2_config = { .num_cs = 2, +#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4) + .max_clk_div = 0x0c, +#else + .max_clk_div = 0x0f, +#endif }; static struct resource omap2_mcspi2_resources[] = { @@ -348,6 +358,11 @@ static struct platform_device omap2_mcspi2 = { defined(CONFIG_ARCH_OMAP4) static struct omap2_mcspi_platform_config omap2_mcspi3_config = { .num_cs = 2, +#if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4) + .max_clk_div = 0x0c, +#else + .max_clk_div = 0x0f, +#endif }; static struct resource omap2_mcspi3_resources[] = { @@ -372,6 +387,7 @@ static struct platform_device omap2_mcspi3 = { #if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_ARCH_OMAP4) static struct omap2_mcspi_platform_config omap2_mcspi4_config = { .num_cs = 1, + .max_clk_div = 0x0c, }; static struct resource omap2_mcspi4_resources[] = { diff --git a/arch/arm/plat-omap/include/plat/mcspi.h b/arch/arm/plat-omap/include/plat/mcspi.h index 1254e49..9fadddd 100644 --- a/arch/arm/plat-omap/include/plat/mcspi.h +++ b/arch/arm/plat-omap/include/plat/mcspi.h @@ -3,6 +3,7 @@ struct omap2_mcspi_platform_config { unsigned short num_cs; + unsigned short max_clk_div; }; struct omap2_mcspi_device_config {