[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <4965a4461b09febeafd20bb534b456861dfdc735.1371145891.git.andi@etezian.org>
Date: Thu, 13 Jun 2013 20:20:45 +0200
From: Andi Shyti <andi@...zian.org>
To: arnd@...db.de, gregkh@...uxfoundation.org
Cc: linux-kernel@...r.kernel.org, pc@...f.org, oatilla@...il.com,
andi@...zian.org
Subject: [PATCH 11/19] bh1770glc: removed lux_read_raw_result() function
lux_raw_result_show() will run directly the lux_get_result()
instead of using another support function
Signed-off-by: Andi Shyti <andi@...zian.org>
---
drivers/misc/bh1770glc.c | 9 ++-------
1 file changed, 2 insertions(+), 7 deletions(-)
diff --git a/drivers/misc/bh1770glc.c b/drivers/misc/bh1770glc.c
index b5fc2b9..eec799e 100644
--- a/drivers/misc/bh1770glc.c
+++ b/drivers/misc/bh1770glc.c
@@ -385,12 +385,6 @@ static int bh1770_lux_read_result(struct bh1770_chip *chip)
return bh1770_lux_raw_to_adjusted(chip, chip->lux_data_raw);
}
-static int bh1770_lux_read_raw_result(struct bh1770_chip *chip)
-{
- bh1770_lux_get_result(chip);
- return chip->lux_data_raw;
-}
-
/*
* Chip on / off functions are called while keeping mutex except probe
* or remove phase
@@ -725,7 +719,8 @@ static ssize_t bh1770_lux_raw_result_show(struct device *dev,
return -EIO;
mutex_lock(&chip->mutex);
- ret = sprintf(buf, "%d\n", bh1770_lux_read_raw_result(chip));
+ bh1770_lux_get_result(chip);
+ ret = sprintf(buf, "%d\n", chip->lux_data_raw);
mutex_unlock(&chip->mutex);
return ret;
--
1.7.10.4
--
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