[SystemZ][z/OS] correct rc and errno within nanosleep()

This patch fixes rc and errno within nanosleep(). It also updates __rem parameter as well it introduces cast to handle conversions from long into unsigned int to avoid warnings.

Reviewed By: Mordante

Differential Revision: https://reviews.llvm.org/D99373

GitOrigin-RevId: 916093f49fafa54a7a4a8473ec4704eca3dc5a67
1 file changed