diff options
author | Evan Quan <evan.quan@amd.com> | 2019-02-19 07:20:54 +0300 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2019-02-23 00:34:18 +0300 |
commit | b7d485df6658942e30c0faccb7213b63c167ceeb (patch) | |
tree | 666cd218cb32e38a2719de02e53d61c5c6ef9262 /drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c | |
parent | 6a7a20ed29ca427c961020e87cb809a3d79f6fa6 (diff) | |
download | linux-b7d485df6658942e30c0faccb7213b63c167ceeb.tar.xz |
drm/amd/powerplay: fix the confusing ppfeature mask calculations
Simplify the ppfeature mask calculations.
Signed-off-by: Evan Quan <evan.quan@amd.com>
Reviewed-by: Kenneth Feng <kenneth.feng@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c')
-rw-r--r-- | drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c index 5479125ff4f6..6d8e9609e900 100644 --- a/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c +++ b/drivers/gpu/drm/amd/powerplay/hwmgr/vega10_hwmgr.c @@ -4407,9 +4407,9 @@ static int vega10_set_ppfeature_status(struct pp_hwmgr *hwmgr, uint64_t new_ppfe return ret; features_to_disable = - (features_enabled ^ new_ppfeature_masks) & features_enabled; + features_enabled & ~new_ppfeature_masks; features_to_enable = - (features_enabled ^ new_ppfeature_masks) ^ features_to_disable; + ~features_enabled & new_ppfeature_masks; pr_debug("features_to_disable 0x%llx\n", features_to_disable); pr_debug("features_to_enable 0x%llx\n", features_to_enable); |