linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 1/2] lis3lv02d: Fix read() call in lis3lv02d_get_odr()
@ 2011-09-06  7:12 Mark Brown
  2011-09-06  7:12 ` [PATCH 2/2] lis3lv02d: Make regulator API usage unconditional Mark Brown
  2011-09-06 21:07 ` [PATCH 1/2] lis3lv02d: Fix read() call in lis3lv02d_get_odr() Andrew Morton
  0 siblings, 2 replies; 4+ messages in thread
From: Mark Brown @ 2011-09-06  7:12 UTC (permalink / raw)
  To: Andrew Morton, Éric Piel, Ilkka Koskinen
  Cc: linux-kernel, Mark Brown, stable

The driver is passing a struct lis3lv02d ** to the read() operation but
the read() operation wants a struct lis3lv02d * causing compiler warnings
and presumably also runtime problems.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Cc: stable@kernel.org
---
 drivers/misc/lis3lv02d/lis3lv02d.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/drivers/misc/lis3lv02d/lis3lv02d.c b/drivers/misc/lis3lv02d/lis3lv02d.c
index e67dcea..72a1f92 100644
--- a/drivers/misc/lis3lv02d/lis3lv02d.c
+++ b/drivers/misc/lis3lv02d/lis3lv02d.c
@@ -200,7 +200,7 @@ static int lis3lv02d_get_odr(struct lis3lv02d *lis3)
 	u8 ctrl;
 	int shift;
 
-	lis3->read(&lis3, CTRL_REG1, &ctrl);
+	lis3->read(lis3, CTRL_REG1, &ctrl);
 	ctrl &= lis3->odr_mask;
 	shift = ffs(lis3->odr_mask) - 1;
 	return lis3->odrs[(ctrl >> shift)];
-- 
1.7.5.4


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2011-09-07  5:21 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-09-06  7:12 [PATCH 1/2] lis3lv02d: Fix read() call in lis3lv02d_get_odr() Mark Brown
2011-09-06  7:12 ` [PATCH 2/2] lis3lv02d: Make regulator API usage unconditional Mark Brown
2011-09-06 21:07 ` [PATCH 1/2] lis3lv02d: Fix read() call in lis3lv02d_get_odr() Andrew Morton
2011-09-07  5:21   ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).