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
This commit is contained in:
parent
a81931f608
commit
39e86a12aa
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=54031
@ -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));
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user