mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-11-25 04:40:53 +07:00
Merge branch 'drm-fixes' of git://people.freedesktop.org/~airlied/linux
Pull drm/qxl fix from Dave Airlie: "Bad me forgot an access check, possible security issue, but since this is the first kernel with it, should be fine to just put it in now" * 'drm-fixes' of git://people.freedesktop.org/~airlied/linux: drm/qxl: add missing access check for execbuffer ioctl
This commit is contained in:
commit
6554431937
@ -171,6 +171,11 @@ static int qxl_execbuffer_ioctl(struct drm_device *dev, void *data,
|
||||
if (user_cmd.command_size > PAGE_SIZE - sizeof(union qxl_release_info))
|
||||
return -EINVAL;
|
||||
|
||||
if (!access_ok(VERIFY_READ,
|
||||
(void *)(unsigned long)user_cmd.command,
|
||||
user_cmd.command_size))
|
||||
return -EFAULT;
|
||||
|
||||
ret = qxl_alloc_release_reserved(qdev,
|
||||
sizeof(union qxl_release_info) +
|
||||
user_cmd.command_size,
|
||||
|
Loading…
Reference in New Issue
Block a user