[PATCH 4.9 18/47] sch_red: fix off-by-one checks in red_check_params()