Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/dev/i2c No need to use I2C_F_POLL here.



details:   https://anonhg.NetBSD.org/src/rev/bdc573421adc
branches:  trunk
changeset: 967841:bdc573421adc
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Mon Dec 23 19:22:46 2019 +0000

description:
No need to use I2C_F_POLL here.

diffstat:

 sys/dev/i2c/fan53555.c |  12 ++++++------
 1 files changed, 6 insertions(+), 6 deletions(-)

diffs (33 lines):

diff -r 7b164c3f6ad2 -r bdc573421adc sys/dev/i2c/fan53555.c
--- a/sys/dev/i2c/fan53555.c    Mon Dec 23 19:20:18 2019 +0000
+++ b/sys/dev/i2c/fan53555.c    Mon Dec 23 19:22:46 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: fan53555.c,v 1.4 2019/11/12 07:40:04 mrg Exp $ */
+/* $NetBSD: fan53555.c,v 1.5 2019/12/23 19:22:46 thorpej Exp $ */
 
 /*-
  * Copyright (c) 2018 Jared McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: fan53555.c,v 1.4 2019/11/12 07:40:04 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: fan53555.c,v 1.5 2019/12/23 19:22:46 thorpej Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -124,10 +124,10 @@
                aprint_error_dev(sc->sc_dev, "error writing reg %#x: %d\n", reg, error);
 }
 
-#define        I2C_READ(sc, reg)       fan53555_read((sc), (reg), I2C_F_POLL)
-#define        I2C_WRITE(sc, reg, val) fan53555_write((sc), (reg), (val), I2C_F_POLL)
-#define        I2C_LOCK(sc)            iic_acquire_bus((sc)->sc_i2c, I2C_F_POLL)
-#define        I2C_UNLOCK(sc)          iic_release_bus((sc)->sc_i2c, I2C_F_POLL)
+#define        I2C_READ(sc, reg)       fan53555_read((sc), (reg), 0)
+#define        I2C_WRITE(sc, reg, val) fan53555_write((sc), (reg), (val), 0)
+#define        I2C_LOCK(sc)            iic_acquire_bus((sc)->sc_i2c, 0)
+#define        I2C_UNLOCK(sc)          iic_release_bus((sc)->sc_i2c, 0)
 
 static int
 fan53555_acquire(device_t dev)



Home | Main Index | Thread Index | Old Index