Module Name: src
Committed By: thorpej
Date: Wed Dec 23 16:04:42 UTC 2020
Modified Files:
src/sys/dev/fdt: i2cmux_fdt.c
Log Message:
Register each virtual bus's i2c_tag_t so that references for e.g. HDMI DDC
in the device tree work.
To generate a diff of this commit:
cvs rdiff -u -r1.1 -r1.2 src/sys/dev/fdt/i2cmux_fdt.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/fdt/i2cmux_fdt.c
diff -u src/sys/dev/fdt/i2cmux_fdt.c:1.1 src/sys/dev/fdt/i2cmux_fdt.c:1.2
--- src/sys/dev/fdt/i2cmux_fdt.c:1.1 Wed Dec 23 04:09:32 2020
+++ src/sys/dev/fdt/i2cmux_fdt.c Wed Dec 23 16:04:42 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: i2cmux_fdt.c,v 1.1 2020/12/23 04:09:32 thorpej Exp $ */
+/* $NetBSD: i2cmux_fdt.c,v 1.2 2020/12/23 16:04:42 thorpej Exp $ */
/*-
* Copyright (c) 2020 The NetBSD Foundation, Inc.
@@ -30,7 +30,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: i2cmux_fdt.c,v 1.1 2020/12/23 04:09:32 thorpej Exp $");
+__KERNEL_RCSID(0, "$NetBSD: i2cmux_fdt.c,v 1.2 2020/12/23 16:04:42 thorpej Exp $");
#include <sys/types.h>
#include <sys/device.h>
@@ -366,6 +366,8 @@ iicmux_attach_bus(struct iicmux_softc *
bus->controller.ic_release_bus = iicmux_release_bus;
bus->controller.ic_exec = iicmux_exec;
+ fdtbus_register_i2c_controller(&bus->controller, bus->phandle);
+
fdtbus_attach_i2cbus(sc->sc_dev, bus->phandle, &bus->controller,
iicmux_print);
}