scheduler: bound priority to 0-7

closes #153

Signed-off-by: Fedor Indutny <fedor@indutny.com>