habanalabs/gaudi: mask constant value before cast
This fixes a sparse warning of "cast truncates bits from constant value" Signed-off-by: Oded Gabbay <ogabbay@kernel.org>
This commit is contained in:
parent
c74400f61e
commit
e3f49437a2
@ -3384,19 +3384,19 @@ static void gaudi_init_nic_qman(struct hl_device *hdev, u32 nic_offset,
|
||||
u32 nic_qm_err_cfg, irq_handler_offset;
|
||||
u32 q_off;
|
||||
|
||||
mtr_base_en_lo = lower_32_bits(CFG_BASE +
|
||||
mtr_base_en_lo = lower_32_bits((CFG_BASE & U32_MAX) +
|
||||
mmSYNC_MNGR_E_N_SYNC_MNGR_OBJS_MON_PAY_ADDRL_0);
|
||||
mtr_base_en_hi = upper_32_bits(CFG_BASE +
|
||||
mmSYNC_MNGR_E_N_SYNC_MNGR_OBJS_MON_PAY_ADDRL_0);
|
||||
so_base_en_lo = lower_32_bits(CFG_BASE +
|
||||
so_base_en_lo = lower_32_bits((CFG_BASE & U32_MAX) +
|
||||
mmSYNC_MNGR_E_N_SYNC_MNGR_OBJS_SOB_OBJ_0);
|
||||
so_base_en_hi = upper_32_bits(CFG_BASE +
|
||||
mmSYNC_MNGR_E_N_SYNC_MNGR_OBJS_SOB_OBJ_0);
|
||||
mtr_base_ws_lo = lower_32_bits(CFG_BASE +
|
||||
mtr_base_ws_lo = lower_32_bits((CFG_BASE & U32_MAX) +
|
||||
mmSYNC_MNGR_W_S_SYNC_MNGR_OBJS_MON_PAY_ADDRL_0);
|
||||
mtr_base_ws_hi = upper_32_bits(CFG_BASE +
|
||||
mmSYNC_MNGR_W_S_SYNC_MNGR_OBJS_MON_PAY_ADDRL_0);
|
||||
so_base_ws_lo = lower_32_bits(CFG_BASE +
|
||||
so_base_ws_lo = lower_32_bits((CFG_BASE & U32_MAX) +
|
||||
mmSYNC_MNGR_W_S_SYNC_MNGR_OBJS_SOB_OBJ_0);
|
||||
so_base_ws_hi = upper_32_bits(CFG_BASE +
|
||||
mmSYNC_MNGR_W_S_SYNC_MNGR_OBJS_SOB_OBJ_0);
|
||||
|
Loading…
x
Reference in New Issue
Block a user