Commit 142333db authored by Tom St Denis's avatar Tom St Denis Committed by Alex Deucher

drm/amd/amdgpu: Simplify mask creation in gfx6

Signed-off-by: default avatarTom St Denis <tom.stdenis@amd.com>
Reviewed-by: default avatarChristian König <christian.koenig@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent deca1d1f
...@@ -911,13 +911,7 @@ static void gfx_v6_0_select_se_sh(struct amdgpu_device *adev, u32 se_num, ...@@ -911,13 +911,7 @@ static void gfx_v6_0_select_se_sh(struct amdgpu_device *adev, u32 se_num,
static u32 gfx_v6_0_create_bitmask(u32 bit_width) static u32 gfx_v6_0_create_bitmask(u32 bit_width)
{ {
u32 i, mask = 0; return (u32)(((u64)1 << bit_width) - 1);
for (i = 0; i < bit_width; i++) {
mask <<= 1;
mask |= 1;
}
return mask;
} }
static u32 gfx_v6_0_get_rb_disabled(struct amdgpu_device *adev, static u32 gfx_v6_0_get_rb_disabled(struct amdgpu_device *adev,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment