aboutsummaryrefslogtreecommitdiff
path: root/sys/sys/bus.h
diff options
context:
space:
mode:
authorWarner Losh <imp@FreeBSD.org>2019-12-13 19:39:33 +0000
committerWarner Losh <imp@FreeBSD.org>2019-12-13 19:39:33 +0000
commitb832a7e5053cd29ec8d5421482ffd3b311e27092 (patch)
tree58fe2c0bfea27cf08bafb75f2575b9c2c5eb4c29 /sys/sys/bus.h
parent889ad0b8905ad64624aa9eba244827f2f1cce91c (diff)
downloadsrc-b832a7e5053cd29ec8d5421482ffd3b311e27092.tar.gz
src-b832a7e5053cd29ec8d5421482ffd3b311e27092.zip
Create new wrapper function: bus_delayed_attach_children()
Delay the attachment of children, when requested, until after interrutps are running. This is often needed to allow children to run transactions on i2c or spi busses. It's a common enough idiom that it will be useful to have its own wrapper. Reviewed by: ian Differential Revision: https://reviews.freebsd.org/D21465
Notes
Notes: svn path=/head/; revision=355727
Diffstat (limited to 'sys/sys/bus.h')
-rw-r--r--sys/sys/bus.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/sys/bus.h b/sys/sys/bus.h
index 508267754e41..a2d22af77277 100644
--- a/sys/sys/bus.h
+++ b/sys/sys/bus.h
@@ -567,6 +567,7 @@ int bus_child_present(device_t child);
int bus_child_pnpinfo_str(device_t child, char *buf, size_t buflen);
int bus_child_location_str(device_t child, char *buf, size_t buflen);
void bus_enumerate_hinted_children(device_t bus);
+int bus_delayed_attach_children(device_t bus);
static __inline struct resource *
bus_alloc_resource_any(device_t dev, int type, int *rid, u_int flags)