summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/r128
diff options
context:
space:
mode:
authorFabian Frederick <fabf@skynet.be>2014-11-16 11:21:25 +0100
committerDave Airlie <airlied@redhat.com>2014-11-20 11:30:37 +1000
commit2b0a3c400033c23ef83d2e9191d36c250289a79e (patch)
tree9fd14ba3757b386ee5e9ea9c4b28c62b2d3c0c34 /drivers/gpu/drm/r128
parentaeb24cc0a31646eb9233a05834440fdf16a713bd (diff)
downloadlinux-2b0a3c400033c23ef83d2e9191d36c250289a79e.tar.bz2
drm: remove unnecessary sizeof(u8)
sizeof(u8) is always 1. Signed-off-by: Fabian Frederick <fabf@skynet.be> Signed-off-by: Dave Airlie <airlied@redhat.com>
Diffstat (limited to 'drivers/gpu/drm/r128')
-rw-r--r--drivers/gpu/drm/r128/r128_state.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/r128/r128_state.c b/drivers/gpu/drm/r128/r128_state.c
index 575e986f82a7..8fd2d9f58f77 100644
--- a/drivers/gpu/drm/r128/r128_state.c
+++ b/drivers/gpu/drm/r128/r128_state.c
@@ -905,7 +905,7 @@ static int r128_cce_dispatch_write_span(struct drm_device *dev,
if (IS_ERR(buffer))
return PTR_ERR(buffer);
- mask_size = depth->n * sizeof(u8);
+ mask_size = depth->n;
if (depth->mask) {
mask = memdup_user(depth->mask, mask_size);
if (IS_ERR(mask)) {
@@ -1010,7 +1010,7 @@ static int r128_cce_dispatch_write_pixels(struct drm_device *dev,
}
if (depth->mask) {
- mask_size = depth->n * sizeof(u8);
+ mask_size = depth->n;
mask = memdup_user(depth->mask, mask_size);
if (IS_ERR(mask)) {
kfree(x);