summaryrefslogtreecommitdiff
path: root/include/linux/smscphy.h
diff options
context:
space:
mode:
authorThierry Reding <treding@nvidia.com>2017-03-09 20:04:55 +0100
committerThierry Reding <treding@nvidia.com>2017-04-05 18:11:45 +0200
commitbdd2f9cd10eb842be96418cc226bc33744d358b0 (patch)
tree2c7218a91db7e0fc7327fcd60be1417529f8cc96 /include/linux/smscphy.h
parent347ad49d35a1c65d509e7ef5b0760e97ede41ec2 (diff)
drm/tegra: Don't leak kernel pointer to userspace
Each open file descriptor can have any number of contexts associated with it. To differentiate between these contexts a unique ID is required and back when these userspace interfaces were introduced, in commit d43f81cbaf43 ("drm/tegra: Add gr2d device"), the pointer to the context structure was deemed adequate. However, this leaks information about kernel internal memory to userspace, which can potentially be exploited. Switch the context parameter to be allocated from an IDR, which has the added benefit of providing an easy way to look up a context from its ID. Signed-off-by: Thierry Reding <treding@nvidia.com>
Diffstat (limited to 'include/linux/smscphy.h')
0 files changed, 0 insertions, 0 deletions