DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] common/cnxk: fix sizeof not portable
@ 2022-04-24 16:17 Gowrishankar Muthukrishnan
  2022-05-05  8:35 ` Jerin Jacob
  0 siblings, 1 reply; 2+ messages in thread
From: Gowrishankar Muthukrishnan @ 2022-04-24 16:17 UTC (permalink / raw)
  To: dev
  Cc: Jerin Jacob, Nithin Dabilpuram, Kiran Kumar K, Sunil Kumar Kori,
	Satha Rao, Gowrishankar Muthukrishnan

Fix size of not portable issue reported in coverity scan.

Coverity issue: 376538
Fixes: 7e9a94909ee ("common/cnxk: realloc inline device XAQ AURA")

Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>
---
 drivers/common/cnxk/roc_nix_inl_dev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/common/cnxk/roc_nix_inl_dev.c b/drivers/common/cnxk/roc_nix_inl_dev.c
index 5a032aab52..8ef2bc85a3 100644
--- a/drivers/common/cnxk/roc_nix_inl_dev.c
+++ b/drivers/common/cnxk/roc_nix_inl_dev.c
@@ -606,7 +606,7 @@ roc_nix_inl_dev_xaq_realloc(uint64_t aura_handle)
 	inl_dev->pkt_pools_cnt++;
 	inl_dev->pkt_pools =
 		plt_realloc(inl_dev->pkt_pools,
-			    sizeof(uint64_t *) * inl_dev->pkt_pools_cnt, 0);
+			    sizeof(uint64_t) * inl_dev->pkt_pools_cnt, 0);
 	if (!inl_dev->pkt_pools)
 		inl_dev->pkt_pools_cnt = 0;
 	else
-- 
2.25.1


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [PATCH] common/cnxk: fix sizeof not portable
  2022-04-24 16:17 [PATCH] common/cnxk: fix sizeof not portable Gowrishankar Muthukrishnan
@ 2022-05-05  8:35 ` Jerin Jacob
  0 siblings, 0 replies; 2+ messages in thread
From: Jerin Jacob @ 2022-05-05  8:35 UTC (permalink / raw)
  To: Gowrishankar Muthukrishnan
  Cc: dpdk-dev, Jerin Jacob, Nithin Dabilpuram, Kiran Kumar K,
	Sunil Kumar Kori, Satha Rao

On Sun, Apr 24, 2022 at 9:47 PM Gowrishankar Muthukrishnan
<gmuthukrishn@marvell.com> wrote:
>
> Fix size of not portable issue reported in coverity scan.
>
> Coverity issue: 376538
> Fixes: 7e9a94909ee ("common/cnxk: realloc inline device XAQ AURA")
>
> Signed-off-by: Gowrishankar Muthukrishnan <gmuthukrishn@marvell.com>

Acked-by: Jerin Jacob <jerinj@marvell.com>
Applied to dpdk-next-net-mrvl/for-next-net. Thanks


> ---
>  drivers/common/cnxk/roc_nix_inl_dev.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/common/cnxk/roc_nix_inl_dev.c b/drivers/common/cnxk/roc_nix_inl_dev.c
> index 5a032aab52..8ef2bc85a3 100644
> --- a/drivers/common/cnxk/roc_nix_inl_dev.c
> +++ b/drivers/common/cnxk/roc_nix_inl_dev.c
> @@ -606,7 +606,7 @@ roc_nix_inl_dev_xaq_realloc(uint64_t aura_handle)
>         inl_dev->pkt_pools_cnt++;
>         inl_dev->pkt_pools =
>                 plt_realloc(inl_dev->pkt_pools,
> -                           sizeof(uint64_t *) * inl_dev->pkt_pools_cnt, 0);
> +                           sizeof(uint64_t) * inl_dev->pkt_pools_cnt, 0);
>         if (!inl_dev->pkt_pools)
>                 inl_dev->pkt_pools_cnt = 0;
>         else
> --
> 2.25.1
>

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-05-05  8:35 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-04-24 16:17 [PATCH] common/cnxk: fix sizeof not portable Gowrishankar Muthukrishnan
2022-05-05  8:35 ` Jerin Jacob

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).