baseband/acc: fix ring memory allocation logic\
v2 cover baseband/acc: fix ring memory allocation logic\
Hi Maxime,
v2: following your suggestion which is best indeed.
Can you please review and apply that fix for 24.11.
Thanks,
Nic
Nicolas Chautru (1):
baseband/acc: fix ring memory allocation logic
drivers/baseband/acc/acc_common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Signature · 1 line
2.34.1
PATCH v2 1/1 baseband/acc: fix ring memory allocation logic
Allowing ring memory allocation whose end address is aligned with 64 MB. Previous logic was off by one.
--- drivers/baseband/acc/acc_common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/baseband/acc/acc_common.h +1 -1
@@ -795,7 +795,7 @@ alloc_sw_rings_min_mem(struct rte_bbdev *dev, struct acc_device *d, sw_rings_base, ACC_SIZE_64MBYTE); next_64mb_align_addr_iova = sw_rings_base_iova + next_64mb_align_offset; - sw_ring_iova_end_addr = sw_rings_base_iova + dev_sw_ring_size; + sw_ring_iova_end_addr = sw_rings_base_iova + dev_sw_ring_size -1 ;/* Check if the end of the sw ring memory block is before the * start of next 64MB aligned mem address
Signature · 1 line
2.34.1
Re: [PATCH v2 1/1] baseband/acc: fix ring memory allocation logic
Quoted 16 lines · Nicolas Chautru
Allowing ring memory allocation whose end address is aligned with 64 MB. Previous logic was off by one.
Fixes 060e76729302 ("baseband/acc100: add queue configuration")Signed-off-by Nicolas Chautru <[email protected]>--- drivers/baseband/acc/acc_common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/baseband/acc/acc_common.h +0
-0
drivers/baseband/acc/acc_common.h alloc_sw_rings_min_mem(struct rte_bbdev *dev, struct acc_device *d, · line 801
Quoted 8 lines
drivers/baseband/acc/acc_common.h +1
-1@@ -795,7 +795,7 @@ alloc_sw_rings_min_mem(struct rte_bbdev *dev, struct acc_device *d, sw_rings_base, ACC_SIZE_64MBYTE); next_64mb_align_addr_iova = sw_rings_base_iova + next_64mb_align_offset; - sw_ring_iova_end_addr = sw_rings_base_iova + dev_sw_ring_size; + sw_ring_iova_end_addr = sw_rings_base_iova + dev_sw_ring_size -1 ;/* Check if the end of the sw ring memory block is before the * start of next 64MB aligned mem address
Thanks,
Maxime
Maxime Coquelin
AppliedRe: [PATCH v2 1/1] baseband/acc: fix ring memory allocation logic
In reply to Nicolas ChautruQuoted 11 lines · Nicolas Chautru
Allowing ring memory allocation whose end address is aligned with 64 MB. Previous logic was off by one.
Fixes 060e76729302 ("baseband/acc100: add queue configuration")Signed-off-by Nicolas Chautru <[email protected]>--- drivers/baseband/acc/acc_common.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
Applied to next-baseband/for-main
Thanks,
Maxime