From patchwork Fri Jul 9 08:01:20 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mathias Nyman X-Patchwork-Id: 111010 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.4/8.14.3) with ESMTP id o6981gOI028873 for ; Fri, 9 Jul 2010 08:01:42 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754408Ab0GIIBk (ORCPT ); Fri, 9 Jul 2010 04:01:40 -0400 Received: from smtp.nokia.com ([192.100.105.134]:50518 "EHLO mgw-mx09.nokia.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753088Ab0GIIBj (ORCPT ); Fri, 9 Jul 2010 04:01:39 -0400 Received: from esebh105.NOE.Nokia.com (esebh105.ntc.nokia.com [172.21.138.211]) by mgw-mx09.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o6981W2A008191 for ; Fri, 9 Jul 2010 03:01:38 -0500 Received: from vaebh104.NOE.Nokia.com ([10.160.244.30]) by esebh105.NOE.Nokia.com with Microsoft SMTPSVC(6.0.3790.4675); Fri, 9 Jul 2010 11:01:24 +0300 Received: from mgw-sa01.ext.nokia.com ([147.243.1.47]) by vaebh104.NOE.Nokia.com over TLS secured channel with Microsoft SMTPSVC(6.0.3790.4675); Fri, 9 Jul 2010 11:01:24 +0300 Received: from localhost.localdomain (esdhcp038119.research.nokia.com [172.21.38.119]) by mgw-sa01.ext.nokia.com (Switch-3.3.3/Switch-3.3.3) with ESMTP id o6981OAZ003193 for ; Fri, 9 Jul 2010 11:01:24 +0300 From: Mathias Nyman To: linux-omap@vger.kernel.org Subject: [PATCH] omap: rx51: Platform support for tsl2563 ALS Date: Fri, 9 Jul 2010 11:01:20 +0300 Message-Id: <1278662480-12496-1-git-send-email-mathias.nyman@nokia.com> X-Mailer: git-send-email 1.5.6.5 In-Reply-To: <20100709071835.GF24913@atomide.com> References: <20100709071835.GF24913@atomide.com> X-OriginalArrivalTime: 09 Jul 2010 08:01:24.0362 (UTC) FILETIME=[ECEC9EA0:01CB1F3C] X-Nokia-AV: Clean 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, 09 Jul 2010 08:01:42 +0000 (UTC) From: Mathias Nyman This will enable usage of tsl2563 ambient light sensor on Nokia N900. Signed-off-by: Ameya Palande Signed-off-by: Mathias Nyman --- arch/arm/mach-omap2/board-rx51-peripherals.c | 14 ++++++++++++++ 1 files changed, 14 insertions(+), 0 deletions(-) diff --git a/arch/arm/mach-omap2/board-rx51-peripherals.c b/arch/arm/mach-omap2/board-rx51-peripherals.c index 3c3f975..a3a396c 100644 --- a/arch/arm/mach-omap2/board-rx51-peripherals.c +++ b/arch/arm/mach-omap2/board-rx51-peripherals.c @@ -35,6 +35,8 @@ #include #include +#include <../drivers/staging/iio/light/tsl2563.h> + #include "mux.h" #include "hsmmc.h" @@ -53,6 +55,12 @@ enum { static struct wl12xx_platform_data wl1251_pdata; +#if defined(CONFIG_SENSORS_TSL2563) || defined(CONFIG_SENSORS_TSL2563_MODULE) +static struct tsl2563_platform_data rx51_tsl2563_platform_data = { + .cover_comp_gain = 16, +}; +#endif + static struct omap2_mcspi_device_config wl1251_mcspi_config = { .turbo_mode = 0, .single_channel = 1, @@ -714,6 +722,12 @@ static struct i2c_board_info __initdata rx51_peripherals_i2c_board_info_2[] = { I2C_BOARD_INFO("tlv320aic3x", 0x18), .platform_data = &rx51_aic3x_data, }, +#if defined(CONFIG_SENSORS_TSL2563) || defined(CONFIG_SENSORS_TSL2563_MODULE) + { + I2C_BOARD_INFO("tsl2563", 0x29), + .platform_data = &rx51_tsl2563_platform_data, + }, +#endif { I2C_BOARD_INFO("tpa6130a2", 0x60), .platform_data = &rx51_tpa6130a2_data,