baseband/acc100: remove logically dead code
Checks
Commit Message
Coverity reported dead code for a few error
checks which are indeed not reachable.
Coverity issue: 363451, 363454, 363455
Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
---
drivers/baseband/acc100/rte_acc100_pmd.c | 9 ---------
1 file changed, 9 deletions(-)
Comments
On 10/19/20 2:09 PM, Nicolas Chautru wrote:
> Coverity reported dead code for a few error
> checks which are indeed not reachable.
>
> Coverity issue: 363451, 363454, 363455
>
> Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
This change looks fine.
Should remove the 'Coverity issue: ... ' from the log.
Reviewed-by: Tom Rix <trix@redhat.com>
> ---
> drivers/baseband/acc100/rte_acc100_pmd.c | 9 ---------
> 1 file changed, 9 deletions(-)
>
> diff --git a/drivers/baseband/acc100/rte_acc100_pmd.c b/drivers/baseband/acc100/rte_acc100_pmd.c
> index 47ddbae..5e663a6 100644
> --- a/drivers/baseband/acc100/rte_acc100_pmd.c
> +++ b/drivers/baseband/acc100/rte_acc100_pmd.c
> @@ -2519,9 +2519,6 @@
> r++;
> }
>
> - if (unlikely(desc == NULL))
> - return current_enqueued_cbs;
> -
> #ifdef RTE_LIBRTE_BBDEV_DEBUG
> if (check_mbuf_total_left(mbuf_total_left) != 0)
> return -EINVAL;
> @@ -3076,9 +3073,6 @@
> r++;
> }
>
> - if (unlikely(desc == NULL))
> - return current_enqueued_cbs;
> -
> #ifdef RTE_LIBRTE_BBDEV_DEBUG
> if (check_mbuf_total_left(mbuf_total_left) != 0)
> return -EINVAL;
> @@ -3181,9 +3175,6 @@
> r++;
> }
>
> - if (unlikely(desc == NULL))
> - return current_enqueued_cbs;
> -
> #ifdef RTE_LIBRTE_BBDEV_DEBUG
> if (check_mbuf_total_left(mbuf_total_left) != 0)
> return -EINVAL;
> -----Original Message-----
> From: dev <dev-bounces@dpdk.org> On Behalf Of Tom Rix
> Sent: Wednesday, October 21, 2020 2:58 PM
> To: Chautru, Nicolas <nicolas.chautru@intel.com>; dev@dpdk.org;
> akhil.goyal@nxp.com
> Cc: Richardson, Bruce <bruce.richardson@intel.com>
> Subject: Re: [dpdk-dev] [PATCH] baseband/acc100: remove logically dead
> code
>
>
> On 10/19/20 2:09 PM, Nicolas Chautru wrote:
> > Coverity reported dead code for a few error checks which are indeed
> > not reachable.
> >
> > Coverity issue: 363451, 363454, 363455
> >
> > Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
>
> This change looks fine.
>
> Should remove the 'Coverity issue: ... ' from the log.
>
> Reviewed-by: Tom Rix <trix@redhat.com>
It should stay. That is the convention we use:
git log | grep "Coverity issue"
>
> On 10/19/20 2:09 PM, Nicolas Chautru wrote:
> > Coverity reported dead code for a few error
> > checks which are indeed not reachable.
> >
> > Coverity issue: 363451, 363454, 363455
> >
> > Signed-off-by: Nicolas Chautru <nicolas.chautru@intel.com>
>
> This change looks fine.
>
> Should remove the 'Coverity issue: ... ' from the log.
>
> Reviewed-by: Tom Rix <trix@redhat.com>
>
Applied to dpdk-next-crypto
Thanks.
@@ -2519,9 +2519,6 @@
r++;
}
- if (unlikely(desc == NULL))
- return current_enqueued_cbs;
-
#ifdef RTE_LIBRTE_BBDEV_DEBUG
if (check_mbuf_total_left(mbuf_total_left) != 0)
return -EINVAL;
@@ -3076,9 +3073,6 @@
r++;
}
- if (unlikely(desc == NULL))
- return current_enqueued_cbs;
-
#ifdef RTE_LIBRTE_BBDEV_DEBUG
if (check_mbuf_total_left(mbuf_total_left) != 0)
return -EINVAL;
@@ -3181,9 +3175,6 @@
r++;
}
- if (unlikely(desc == NULL))
- return current_enqueued_cbs;
-
#ifdef RTE_LIBRTE_BBDEV_DEBUG
if (check_mbuf_total_left(mbuf_total_left) != 0)
return -EINVAL;