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/297e0ef8d9a6
branches: trunk
changeset: 1006100:297e0ef8d9a6
user: thorpej <thorpej%NetBSD.org@localhost>
date: Wed Jan 01 18:09:44 2020 +0000
description:
No need to use I2C_F_POLL here.
diffstat:
sys/dev/i2c/anxedp.c | 12 ++++++------
1 files changed, 6 insertions(+), 6 deletions(-)
diffs (48 lines):
diff -r 1104d28b2ac8 -r 297e0ef8d9a6 sys/dev/i2c/anxedp.c
--- a/sys/dev/i2c/anxedp.c Wed Jan 01 18:08:11 2020 +0000
+++ b/sys/dev/i2c/anxedp.c Wed Jan 01 18:09:44 2020 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: anxedp.c,v 1.2 2019/02/03 13:56:38 jmcneill Exp $ */
+/* $NetBSD: anxedp.c,v 1.3 2020/01/01 18:09:44 thorpej Exp $ */
/*-
* Copyright (c) 2019 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: anxedp.c,v 1.2 2019/02/03 13:56:38 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: anxedp.c,v 1.3 2020/01/01 18:09:44 thorpej Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -99,7 +99,7 @@
{
uint8_t val;
- if (iic_smbus_read_byte(sc->sc_i2c, sc->sc_addr + off, reg, &val, I2C_F_POLL) != 0)
+ if (iic_smbus_read_byte(sc->sc_i2c, sc->sc_addr + off, reg, &val, 0) != 0)
val = 0xff;
return val;
@@ -108,7 +108,7 @@
static void
anxedp_write(struct anxedp_softc *sc, u_int off, uint8_t reg, uint8_t val)
{
- (void)iic_smbus_write_byte(sc->sc_i2c, sc->sc_addr + off, reg, val, I2C_F_POLL);
+ (void)iic_smbus_write_byte(sc->sc_i2c, sc->sc_addr + off, reg, val, 0);
}
static int
@@ -247,9 +247,9 @@
struct edid *pedid = NULL;
int error;
- iic_acquire_bus(sc->sc_i2c, I2C_F_POLL);
+ iic_acquire_bus(sc->sc_i2c, 0);
error = anxedp_read_edid(sc, edid, sizeof(edid));
- iic_release_bus(sc->sc_i2c, I2C_F_POLL);
+ iic_release_bus(sc->sc_i2c, 0);
if (error == 0)
pedid = (struct edid *)edid;
Home |
Main Index |
Thread Index |
Old Index