Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
drm/msm/gem: prevent integer overflow in msm_ioctl_gem_submit()
The "submit->cmd[i].size" and "submit->cmd[i].offset" variables are u32 values that come from the user via the submit_lookup_cmds() function. This addition could lead to an integer wrapping bug so use size_add() to prevent that. Fixes: 1987253 ("drm/msm: fix cmdstream size check") Cc: [email protected] Signed-off-by: Dan Carpenter <[email protected]> Patchwork: https://patchwork.freedesktop.org/patch/624696/ Signed-off-by: Rob Clark <[email protected]>
- Loading branch information