Safer assertions related to __up_sem()