projects
/
platform
/
kernel
/
linux-rpi3.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
840a20d
)
drm/amdgpu/gfx7: Simplify bitmask creation
author
Tom St Denis
<tom.stdenis@amd.com>
Mon, 8 Feb 2016 13:48:15 +0000
(08:48 -0500)
committer
Alex Deucher
<alexander.deucher@amd.com>
Fri, 12 Feb 2016 20:27:46 +0000
(15:27 -0500)
Signed-off-by: Tom St Denis <tom.stdenis@amd.com>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c
b/drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c
index 2a8728cf793cacad5f6af16908e06469dbe6a0b3..5e858ca43759c0374a702ed83e59dd7d5d414d10 100644
(file)
--- a/
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c
+++ b/
drivers/gpu/drm/amd/amdgpu/gfx_v7_0.c
@@
-1598,13
+1598,7
@@
void gfx_v7_0_select_se_sh(struct amdgpu_device *adev, u32 se_num, u32 sh_num)
*/
static u32 gfx_v7_0_create_bitmask(u32 bit_width)
{
- u32 i, mask = 0;
-
- for (i = 0; i < bit_width; i++) {
- mask <<= 1;
- mask |= 1;
- }
- return mask;
+ return (u32)((1ULL<<bit_width)-1);
}
/**