From: Eric Yang <[email protected]>

Might potentially have truncation problem with the implicit casting

Reviewed-by: Nicholas Kazlauskas <[email protected]>
Acked-by: Rodrigo Siqueira <[email protected]>
Signed-off-by: Eric Yang <[email protected]>
---
 drivers/gpu/drm/amd/display/dmub/src/dmub_dcn31.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn31.c 
b/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn31.c
index fa0569174aec..82c651535628 100644
--- a/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn31.c
+++ b/drivers/gpu/drm/amd/display/dmub/src/dmub_dcn31.c
@@ -441,7 +441,7 @@ void dmub_dcn31_get_diagnostic_data(struct dmub_srv *dmub, 
struct dmub_diagnosti
 bool dmub_dcn31_should_detect(struct dmub_srv *dmub)
 {
        uint32_t fw_boot_status = REG_READ(DMCUB_SCRATCH0);
-       bool should_detect = fw_boot_status & 
DMUB_FW_BOOT_STATUS_BIT_DETECTION_REQUIRED;
+       bool should_detect = (fw_boot_status & 
DMUB_FW_BOOT_STATUS_BIT_DETECTION_REQUIRED) != 0;
        return should_detect;
 }
 
-- 
2.25.1

Reply via email to