Module Name:    src
Committed By:   jmcneill
Date:           Thu Jan  1 17:59:18 UTC 2015

Modified Files:
        src/sys/dev/i2c: act8846.c

Log Message:
write reg value not target freq in act8846_set_voltage


To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/dev/i2c/act8846.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/i2c/act8846.c
diff -u src/sys/dev/i2c/act8846.c:1.1 src/sys/dev/i2c/act8846.c:1.2
--- src/sys/dev/i2c/act8846.c:1.1	Thu Jan  1 17:33:18 2015
+++ src/sys/dev/i2c/act8846.c	Thu Jan  1 17:59:18 2015
@@ -1,4 +1,4 @@
-/* $NetBSD: act8846.c,v 1.1 2015/01/01 17:33:18 jmcneill Exp $ */
+/* $NetBSD: act8846.c,v 1.2 2015/01/01 17:59:18 jmcneill Exp $ */
 
 /*-
  * Copyright (c) 2015 Jared D. McNeill <jmcne...@invisible.ca>
@@ -29,7 +29,7 @@
 #define ACT_DEBUG
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: act8846.c,v 1.1 2015/01/01 17:33:18 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: act8846.c,v 1.2 2015/01/01 17:59:18 jmcneill Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -250,7 +250,7 @@ act8846_set_voltage(struct act8846_ctrl 
 	if (n == __arraycount(act8846_vset))
 		return EINVAL;
 
-	val = __SHIFTIN(act8846_vset[n], ACT_VSET_VSET);
+	val = __SHIFTIN(n, ACT_VSET_VSET);
 
 	iic_acquire_bus(sc->sc_i2c, 0);
 	error = act8846_write(sc, c->c_base + ACT_VSET0_OFFSET, val);

Reply via email to