diff --git a/block/blk-ioinf.c b/block/blk-ioinf.c index 341be115f1d6d669d2e890064569bf8f99a599b9..7432d88bf1f0fff2a52ae3a60cdb09391cb5c58e 100644 --- a/block/blk-ioinf.c +++ b/block/blk-ioinf.c @@ -1144,7 +1144,7 @@ static ssize_t ioinf_qos_write(struct kernfs_open_file *of, char *input, params.enabled = !!v; continue; case INF_INFLIGHT: - if (match_u64(&args[0], &v) || v == 0) + if (match_u64(&args[0], &v) || v == 0 || v > UINT_MAX) goto einval; params.inflight = v; continue;