diff options
author | n_hibma <n_hibma@FreeBSD.org> | 1999-12-02 16:30:21 +0000 |
---|---|---|
committer | n_hibma <n_hibma@FreeBSD.org> | 1999-12-02 16:30:21 +0000 |
commit | c25db53ca539906548a76a963948ff57e6706d53 (patch) | |
tree | b4315ef7dbabbc14727b2c037cd4eb0fce2623ab /sys/kern/subr_bus.c | |
parent | 8eb4b40d9810bf1d1558ba7b2a3628b11e0cac59 (diff) | |
download | FreeBSD-src-c25db53ca539906548a76a963948ff57e6706d53.zip FreeBSD-src-c25db53ca539906548a76a963948ff57e6706d53.tar.gz |
Remove check for attached state.
sc = devclass_get_softc(devclass, unit);
doesn't return NULL during attach anymore, and produces the sc,
identical to (for devclass_get_unit(devclass, unit) != NULL that is):
sc = device_get_softc(devclass_get_unit(devclass, unit));
Reviewed-by: dfr
Diffstat (limited to 'sys/kern/subr_bus.c')
-rw-r--r-- | sys/kern/subr_bus.c | 3 |
1 files changed, 0 insertions, 3 deletions
diff --git a/sys/kern/subr_bus.c b/sys/kern/subr_bus.c index eff46ad..f144e60 100644 --- a/sys/kern/subr_bus.c +++ b/sys/kern/subr_bus.c @@ -436,9 +436,6 @@ devclass_get_softc(devclass_t dc, int unit) if (!dev) return (NULL); - if (device_get_state(dev) < DS_ATTACHED) - return (NULL); - return (device_get_softc(dev)); } |