[dpdk-stable] patch 'net/bnxt: fix null dereference in interrupt handler' has been queued to stable release 19.11.10

Christian Ehrhardt christian.ehrhardt at canonical.com
Wed Aug 11 10:50:44 CEST 2021


On Tue, Aug 10, 2021 at 5:44 PM <christian.ehrhardt at canonical.com> wrote:
>
> Hi,
>
> FYI, your patch has been queued to stable release 19.11.10

Hi,
while applying cleanly your patch caused build time failures like:

../drivers/net/bnxt/bnxt_irq.c: In function ‘bnxt_int_handler’:
../drivers/net/bnxt/bnxt_irq.c:48:3: error: ‘cp_ring_size’ undeclared
(first use in this function)
   48 |   cp_ring_size = cpr->cp_ring_struct->ring_size;
      |   ^~~~~~~~~~~~

Therefore the patch will be de-qeueud from the stable branch that shall become
19.11.10.
Please consider having a look and providing a backport.

A backport should contain a reference to the DPDK main branch commit
in it's commit message in the following fashion:
    [ upstream commit <commit's dpdk main branch SHA-1 checksum> ]

For example:
    https://git.dpdk.org/dpdk-stable/commit/?h=18.11&id=d90e6ae6f936ecdc2fd3811ff9f26aec7f3c06eb

When sending the backported patch, please indicate the target branch in the
subject line, as we have multiple branches, for example:
    [PATCH 19.11] foo/bar: fix baz

With git format-patch, this can be achieved by appending the parameter:
    --subject-prefix='PATCH 19.11'

Send the backported patch to "stable at dpdk.org" but not "dev at dpdk.org".

FYI, branch 19.11 is located at tree:
   https://git.dpdk.org/dpdk-stable

Thanks in advance,
Chrtistian

> Note it hasn't been pushed to http://dpdk.org/browse/dpdk-stable yet.
> It will be pushed if I get no objections before 08/12/21. So please
> shout if anyone has objections.
>
> Also note that after the patch there's a diff of the upstream commit vs the
> patch applied to the branch. This will indicate if there was any rebasing
> needed to apply to the stable branch. If there were code changes for rebasing
> (ie: not only metadata diffs), please double check that the rebase was
> correctly done.
>
> Queued patches are on a temporary branch at:
> https://github.com/cpaelzer/dpdk-stable-queue
>
> This queued commit can be viewed at:
> https://github.com/cpaelzer/dpdk-stable-queue/commit/8945c5a358b46e2351289050d4c1df982e76c95c
>
> Thanks.
>
> Christian Ehrhardt <christian.ehrhardt at canonical.com>
>
> ---
> From 8945c5a358b46e2351289050d4c1df982e76c95c Mon Sep 17 00:00:00 2001
> From: Kalesh AP <kalesh-anakkur.purayil at broadcom.com>
> Date: Tue, 20 Jul 2021 21:51:58 +0530
> Subject: [PATCH] net/bnxt: fix null dereference in interrupt handler
>
> [ upstream commit 3f44ec48c733f7d7607877164c9aa0305de9cecd ]
>
> Coverity reports that pointer "cpr->cp_ring_struct" may be
> dereferenced with null value. This patch fixes this.
>
> Coverity issue: 372063
> Fixes: 5ed30db87fa8 ("net/bnxt: fix missing barriers in completion handling")
>
> Signed-off-by: Kalesh AP <kalesh-anakkur.purayil at broadcom.com>
> Reviewed-by: Ajit Khaparde <ajit.khaparde at broadcom.com>
> Reviewed-by: Lance Richardson <lance.richardson at broadcom.com>
> ---
>  drivers/net/bnxt/bnxt_irq.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/net/bnxt/bnxt_irq.c b/drivers/net/bnxt/bnxt_irq.c
> index 93779f4e0c..1f33429116 100644
> --- a/drivers/net/bnxt/bnxt_irq.c
> +++ b/drivers/net/bnxt/bnxt_irq.c
> @@ -45,6 +45,7 @@ void bnxt_int_handler(void *param)
>                         return;
>                 }
>
> +               cp_ring_size = cpr->cp_ring_struct->ring_size;
>                 cons = RING_CMP(cpr->cp_ring_struct, raw_cons);
>                 cmp = &cpr->cp_desc_ring[cons];
>
> --
> 2.32.0
>
> ---
>   Diff of the applied patch vs upstream commit (please double-check if non-empty:
> ---
> --- -   2021-08-10 15:11:16.029545681 +0200
> +++ 0078-net-bnxt-fix-null-dereference-in-interrupt-handler.patch       2021-08-10 15:11:13.090638619 +0200
> @@ -1 +1 @@
> -From 3f44ec48c733f7d7607877164c9aa0305de9cecd Mon Sep 17 00:00:00 2001
> +From 8945c5a358b46e2351289050d4c1df982e76c95c Mon Sep 17 00:00:00 2001
> @@ -5,0 +6,2 @@
> +[ upstream commit 3f44ec48c733f7d7607877164c9aa0305de9cecd ]
> +
> @@ -11 +12,0 @@
> -Cc: stable at dpdk.org
> @@ -17,2 +18,2 @@
> - drivers/net/bnxt/bnxt_irq.c | 2 +-
> - 1 file changed, 1 insertion(+), 1 deletion(-)
> + drivers/net/bnxt/bnxt_irq.c | 1 +
> + 1 file changed, 1 insertion(+)
> @@ -21 +22 @@
> -index ebdac8385d..122a1f9908 100644
> +index 93779f4e0c..1f33429116 100644
> @@ -24,9 +25 @@
> -@@ -33,7 +33,6 @@ void bnxt_int_handler(void *param)
> -               return;
> -
> -       raw_cons = cpr->cp_raw_cons;
> --      cp_ring_size = cpr->cp_ring_struct->ring_size;
> -       pthread_mutex_lock(&bp->def_cp_lock);
> -       while (1) {
> -               if (!cpr || !cpr->cp_ring_struct || !cpr->cp_db.doorbell) {
> -@@ -46,6 +45,7 @@ void bnxt_int_handler(void *param)
> +@@ -45,6 +45,7 @@ void bnxt_int_handler(void *param)



-- 
Christian Ehrhardt
Staff Engineer, Ubuntu Server
Canonical Ltd


More information about the stable mailing list