diff --git a/sys/dev/i2c/gttwsi_core.c b/sys/dev/i2c/gttwsi_core.c index 3cc09eb455b0..c76e20c011ac 100644 --- a/sys/dev/i2c/gttwsi_core.c +++ b/sys/dev/i2c/gttwsi_core.c @@ -1,4 +1,4 @@ -/* $NetBSD: gttwsi_core.c,v 1.15 2020/01/13 12:53:46 thorpej Exp $ */ +/* $NetBSD: gttwsi_core.c,v 1.16 2020/02/15 23:42:01 thorpej Exp $ */ /* * Copyright (c) 2008 Eiji Kawauchi. * All rights reserved. @@ -66,7 +66,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: gttwsi_core.c,v 1.15 2020/01/13 12:53:46 thorpej Exp $"); +__KERNEL_RCSID(0, "$NetBSD: gttwsi_core.c,v 1.16 2020/02/15 23:42:01 thorpej Exp $"); #include "locators.h" #include @@ -317,6 +317,13 @@ gttwsi_wait(struct gttwsi_softc *sc, uint32_t control, uint32_t expect, uint32_t status; int timo, error = 0; + /* + * XXX Interrupt-driven mode seems to be horribly broken, + * XXX at least on AllWinner implementations. Force polled + * XXX mode for now. + */ + flags |= I2C_F_POLL; + DELAY(5); if (!(flags & I2C_F_POLL)) control |= CONTROL_INTEN;