Skip to contentSkip to conversation

iio: humidity: hdc100x: correct humidity integration time mask

PATCH Applied Alison Schofield 3 participants 3 messages May 20, 2016 – May 21, 2016 IIO

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 iio: humidity: hdc100x: correct humidity integration time mask

Apply the correct mask to enable all available humidity integration times. Currently, the driver defaults to 6500 and all is okay with that. However, if 3850 is selected we get a stuck bit and can't change back to 6500 or select 2500. (Verified with HDC1008)

---
 drivers/iio/humidity/hdc100x.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iio/humidity/hdc100x.c +1 -1
index fa47676..59aa1cb 100644
@@ -55,7 +55,7 @@ static const struct {
 	},
 	{ /* IIO_HUMIDITYRELATIVE channel */
 		.shift = 8,
-		.mask = 2,
+		.mask = 3,
 	},
 };
 
Signature · 1 line
2.1.4
Reviewed-by on v1 1/1
#1 lore raw
Quoted 16 lines · Alison Schofield

Apply the correct mask to enable all available humidity integration times. Currently, the driver defaults to 6500 and all is okay with that. However, if 3850 is selected we get a stuck bit and can't change back to 6500 or select 2500. (Verified with HDC1008)

---
 drivers/iio/humidity/hdc100x.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iio/humidity/hdc100x.c +0 -0
index fa47676..59aa1cb 100644

drivers/iio/humidity/hdc100x.c static const struct { · line 58

Quoted 5 lines
drivers/iio/humidity/hdc100x.c +1 -1
@@ -55,7 +55,7 @@ static const struct {
        },
        { /* IIO_HUMIDITYRELATIVE channel */
                .shift = 8,
-               .mask = 2,
+               .mask = 3,

Yikes that is embarrassing on my part! I guess our validation was only in the high resolution mode... good catch!

Quoted 6 lines
drivers/iio/humidity/hdc100x.c +0 -1
        },
 };
 
--

2.1.4

maintainer Applied
#2 lore raw
Quoted 10 lines · Matt Ranostay
Quoted 7 lines · Alison Schofield

Apply the correct mask to enable all available humidity integration times. Currently, the driver defaults to 6500 and all is okay with that. However, if 3850 is selected we get a stuck bit and can't change back to 6500 or select 2500. (Verified with HDC1008)

Applied to the fixes-togreg-post-rc1 branch of iio.git

Thanks,

Jonathan

Quoted 24 lines
Quoted 9 lines
---
 drivers/iio/humidity/hdc100x.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/iio/humidity/hdc100x.c +0 -0
index fa47676..59aa1cb 100644

drivers/iio/humidity/hdc100x.c static const struct { · line 58

Quoted 5 lines
drivers/iio/humidity/hdc100x.c +1 -1
@@ -55,7 +55,7 @@ static const struct {
        },
        { /* IIO_HUMIDITYRELATIVE channel */
                .shift = 8,
-               .mask = 2,
+               .mask = 3,

Yikes that is embarrassing on my part! I guess our validation was only in the high resolution mode... good catch!

Quoted 6 lines
drivers/iio/humidity/hdc100x.c +0 -1
        },
 };
 
--

2.1.4