mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-27 21:03:32 +00:00
net: ena: use lower_32_bits()/upper_32_bits() to split dma address
In ena_com_mem_addr_set(), use the above functions to split dma address to the lower 32 bits and the higher 16 bits. Signed-off-by: Netanel Belgazal <netanel@amazon.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
4265114d53
commit
3ae5907c61
1 changed files with 2 additions and 2 deletions
|
@ -99,8 +99,8 @@ static inline int ena_com_mem_addr_set(struct ena_com_dev *ena_dev,
|
|||
return -EINVAL;
|
||||
}
|
||||
|
||||
ena_addr->mem_addr_low = (u32)addr;
|
||||
ena_addr->mem_addr_high = (u64)addr >> 32;
|
||||
ena_addr->mem_addr_low = lower_32_bits(addr);
|
||||
ena_addr->mem_addr_high = (u16)upper_32_bits(addr);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue