[<prev] [next>] [day] [month] [year] [list]
Message-ID: <0680EC522D0CC943BC586913CF3768C003B35537F0@dbde02.ent.ti.com>
Date: Tue, 22 Jun 2010 14:46:25 +0530
From: "Datta, Shubhrajyoti" <shubhrajyoti@...com>
To: "linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>
CC: Christoph Mair <christoph.mair@...il.com>,
Andrew Morton <akpm@...ux-foundation.org>,
Jonathan Cameron <kernel@...23.retrosnub.co.uk>
Subject: [RFC] [PATCH] BMP085 update
Updates for the BMP085 pressure sensor
- Optimizing the wait time for the pressure sensor
- Definition of long is arch dependent so making it u32.
Signed-off-by: Shubhrajyoti D <shubhrajyoti@...com>
---
drivers/misc/bmp085.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/drivers/misc/bmp085.c b/drivers/misc/bmp085.c
index 16a2b2c..8af6f1b 100644
--- a/drivers/misc/bmp085.c
+++ b/drivers/misc/bmp085.c
@@ -60,7 +60,7 @@ struct bmp085_data {
u32 raw_temperature;
u32 raw_pressure;
unsigned char oversampling_setting;
- unsigned long last_temp_measurement;
+ u32 last_temp_measurement;
s32 b6; /* calculated temperature correction coefficient */
};
@@ -144,7 +144,7 @@ static s32 bmp085_update_raw_pressure(struct bmp085_data *data)
}
/* wait for the end of conversion */
- msleep(2+(3 << data->oversampling_setting<<1));
+ msleep(2+(3 << data->oversampling_setting ));
/* copy data into a u32 (4 bytes), but skip the first byte. */
status = i2c_smbus_read_i2c_block_data(data->client,
--
1.5.4.7
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists