From patchwork Fri Mar 12 15:32:07 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lesly A M X-Patchwork-Id: 85298 X-Patchwork-Delegate: khilman@deeprootsystems.com 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 o2CFC964022044 for ; Fri, 12 Mar 2010 15:12:10 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S934030Ab0CLPMH (ORCPT ); Fri, 12 Mar 2010 10:12:07 -0500 Received: from comal.ext.ti.com ([198.47.26.152]:37766 "EHLO comal.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S934108Ab0CLPMG (ORCPT ); Fri, 12 Mar 2010 10:12:06 -0500 Received: from dlep34.itg.ti.com ([157.170.170.115]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id o2CFC5wZ006772 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 12 Mar 2010 09:12:05 -0600 Received: from localhost.localdomain (localhost [127.0.0.1]) by dlep34.itg.ti.com (8.13.7/8.13.7) with ESMTP id o2CFBxbT012634; Fri, 12 Mar 2010 09:12:00 -0600 (CST) From: Lesly A M To: linux-omap@vger.kernel.org Cc: Lesly A M , Nishanth Menon , David Derrick , Samuel Ortiz Subject: [PATCH v3 5/5] omap3: pm: Use generic TRITON power scripts for ZOOM[2, 3], 3630SDP board Date: Fri, 12 Mar 2010 21:02:07 +0530 Message-Id: <1268407927-22631-1-git-send-email-leslyam@ti.com> X-Mailer: git-send-email 1.6.0.4 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:12:10 +0000 (UTC) diff --git a/arch/arm/mach-omap2/Makefile b/arch/arm/mach-omap2/Makefile index 94d862a..f9e9b11 100644 --- a/arch/arm/mach-omap2/Makefile +++ b/arch/arm/mach-omap2/Makefile @@ -127,14 +127,17 @@ obj-$(CONFIG_MACH_NOKIA_RX51) += board-rx51.o \ obj-$(CONFIG_MACH_OMAP_ZOOM2) += board-zoom2.o \ board-zoom-peripherals.o \ hsmmc.o \ - board-zoom-debugboard.o + board-zoom-debugboard.o \ + twl4030-script.o obj-$(CONFIG_MACH_OMAP_ZOOM3) += board-zoom3.o \ board-zoom-peripherals.o \ hsmmc.o \ - board-zoom-debugboard.o + board-zoom-debugboard.o \ + twl4030-script.o obj-$(CONFIG_MACH_OMAP_3630SDP) += board-3630sdp.o \ board-zoom-peripherals.o \ - hsmmc.o + hsmmc.o \ + twl4030-script.o obj-$(CONFIG_MACH_CM_T35) += board-cm-t35.o \ hsmmc.o obj-$(CONFIG_MACH_IGEP0020) += board-igep0020.o \ diff --git a/arch/arm/mach-omap2/board-zoom-peripherals.c b/arch/arm/mach-omap2/board-zoom-peripherals.c index 66f9fd0..462d7ee 100755 --- a/arch/arm/mach-omap2/board-zoom-peripherals.c +++ b/arch/arm/mach-omap2/board-zoom-peripherals.c @@ -28,6 +28,7 @@ #include "hsmmc.h" #include "pm.h" #include "voltage.h" +#include "twl4030-script.h" /* Zoom2 has Qwerty keyboard*/ static int board_keymap[] = { @@ -96,6 +97,38 @@ static struct twl4030_keypad_data zoom_kp_twl4030_data = { .rep = 1, }; +static struct twl4030_resconfig twl4030_rconfig[] = { + { .resource = RES_VPLL1, .devgroup = DEV_GRP_P1, .type = 3, + .type2 = 1, .remap_sleep = RES_STATE_OFF }, + { .resource = RES_VINTANA1, .devgroup = DEV_GRP_ALL, .type = 1, + .type2 = 2, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_VINTANA2, .devgroup = DEV_GRP_ALL, .type = 0, + .type2 = 2, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_VINTDIG, .devgroup = DEV_GRP_ALL, .type = 1, + .type2 = 2, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_VIO, .devgroup = DEV_GRP_ALL, .type = 2, + .type2 = 2, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_VDD1, .devgroup = DEV_GRP_P1, + .type = 4, .type2 = 1, .remap_sleep = RES_STATE_OFF }, + { .resource = RES_VDD2, .devgroup = DEV_GRP_P1, + .type = 3, .type2 = 1, .remap_sleep = RES_STATE_OFF }, + { .resource = RES_REGEN, .devgroup = DEV_GRP_ALL, .type = 2, + .type2 = 1, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_NRES_PWRON, .devgroup = DEV_GRP_ALL, .type = 0, + .type2 = 1, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_CLKEN, .devgroup = DEV_GRP_ALL, .type = 3, + .type2 = 2, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_SYSEN, .devgroup = DEV_GRP_ALL, .type = 6, + .type2 = 1, .remap_sleep = RES_STATE_SLEEP }, + { .resource = RES_HFCLKOUT, .devgroup = DEV_GRP_P3, + .type = 0, .type2 = 2, .remap_sleep = RES_STATE_SLEEP }, + { 0, 0}, +}; + +static struct twl4030_power_data zoom_t2scripts_data __initdata = { + .resource_config = twl4030_rconfig, +}; + static struct regulator_consumer_supply zoom_vmmc1_supply = { .supply = "vmmc", }; @@ -241,6 +274,7 @@ static struct twl4030_platform_data zoom_twldata = { .usb = &zoom_usb_data, .gpio = &zoom_gpio_data, .keypad = &zoom_kp_twl4030_data, + .power = &zoom_t2scripts_data, .codec = &zoom_codec_data, .vmmc1 = &zoom_vmmc1, .vmmc2 = &zoom_vmmc2, @@ -284,6 +318,8 @@ void __init zoom_peripherals_init(void *peripheral_data) struct prm_setup_vc *omap3_setuptime = (struct prm_setup_vc *)peripheral_data; + twl4030_get_scripts(&zoom_t2scripts_data); + twl4030_get_vc_timings(&omap3_setuptime); omap_voltage_init_vc(omap3_setuptime); omap_i2c_init(); omap_serial_init();