tl_open should handle id_space exhaustion
This is uptreaming of OS-5957 from SmartOS:
Reported as illumos-joynet#137
The reporter has supplied 3 crash dumps that I've put into thoth.
I think this should be tackled on two fronts. First and foremost
tl_openshould switch to using
id_alloc_nosleepin order to fail gracefully when the id space is exhausted. This will prevent threads from becoming uninterruptibly blocked, should the limit of tl streams be reached.
Further in the future, we should evaluate possibilities for splitting the
tlminor space across more granular units. Perhaps per-zone or per-netstack scoping for
tlminor numbers might be acceptable? Further research is required to understand the possible effects of emitting minor numbers which are used by multiple socket instances.