Source-Changes-HG archive

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

[src/thorpej-i2c-spi-conf2]: src/sys/dev/i2c Use the same idiom to cast the A...



details:   https://anonhg.NetBSD.org/src/rev/f1f87ca4da9b
branches:  thorpej-i2c-spi-conf2
changeset: 1024885:f1f87ca4da9b
user:      thorpej <thorpej%NetBSD.org@localhost>
date:      Mon Aug 09 12:36:14 2021 +0000

description:
Use the same idiom to cast the ACPI_HANDLE to uint64_t as other drivers
when passing it to acpi_intr_establish().

XXX This is gross, but fixing it is outside the scope of this branch.

diffstat:

 sys/dev/i2c/ihidev.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (29 lines):

diff -r 4e250b666938 -r f1f87ca4da9b sys/dev/i2c/ihidev.c
--- a/sys/dev/i2c/ihidev.c      Mon Aug 09 01:29:52 2021 +0000
+++ b/sys/dev/i2c/ihidev.c      Mon Aug 09 12:36:14 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ihidev.c,v 1.20.2.1 2021/08/09 00:30:09 thorpej Exp $ */
+/* $NetBSD: ihidev.c,v 1.20.2.2 2021/08/09 12:36:14 thorpej Exp $ */
 /* $OpenBSD ihidev.c,v 1.13 2017/04/08 02:57:23 deraadt Exp $ */
 
 /*-
@@ -54,7 +54,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ihidev.c,v 1.20.2.1 2021/08/09 00:30:09 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ihidev.c,v 1.20.2.2 2021/08/09 12:36:14 thorpej Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -672,8 +672,8 @@
 
        acpi_resource_cleanup(&res);
 
-       sc->sc_ih = acpi_intr_establish(sc->sc_dev, (uint64_t)hdl, IPL_TTY,
-           false, ihidev_intr, sc, device_xname(sc->sc_dev));
+       sc->sc_ih = acpi_intr_establish(sc->sc_dev, (uint64_t)(uintptr_t)hdl,
+           IPL_TTY, false, ihidev_intr, sc, device_xname(sc->sc_dev));
        if (sc->sc_ih == NULL) {
                aprint_error_dev(sc->sc_dev, "can't establish interrupt\n");
                return false;



Home | Main Index | Thread Index | Old Index