Allow uth_disable_notifs without current_uthread
authorBarret Rhoden <brho@cs.berkeley.edu>
Thu, 8 Sep 2016 19:31:29 +0000 (15:31 -0400)
committerBarret Rhoden <brho@cs.berkeley.edu>
Fri, 16 Sep 2016 18:35:09 +0000 (14:35 -0400)
commita166123333c8d374bb551ddeb3289ef9a2b1809d
tree1f31b3253a3815322f21f56750a526feb44bac07
parent85a3b250dc4fb52433c67b1d010725d5c196d5d7
Allow uth_disable_notifs without current_uthread

Upcoming changes to glibc's low-level locks will allow disable notifs to be
called before current_uthread is set up.

An unforunate side-effect of allowing this is that we lose the ability to
catch certain bugs (i.e. no long have an assert).  Also, if current_uthread
gets set in the middle of a disable/enable pair, then the
notif_disabled_depth and the associated logic will go crazy.

Signed-off-by: Barret Rhoden <brho@cs.berkeley.edu>
user/parlib/uthread.c