DPDK patches and discussions
 help / color / mirror / Atom feed
From: Jerin Jacob <jerinjacobk@gmail.com>
To: Harman Kalra <hkalra@marvell.com>
Cc: Jerin Jacob <jerinj@marvell.com>, dpdk-dev <dev@dpdk.org>
Subject: Re: [dpdk-dev] [PATCH] event/octeontx: fix memory corruption
Date: Fri, 15 May 2020 20:06:05 +0530	[thread overview]
Message-ID: <CALBAE1OgtZ_=T41YZjebvHm1Qt=f7efebt2xMnSNTX7VFAxaLQ@mail.gmail.com> (raw)
In-Reply-To: <1589541684-23246-1-git-send-email-hkalra@marvell.com>

On Fri, May 15, 2020 at 4:51 PM Harman Kalra <hkalra@marvell.com> wrote:
>
> Since PMD enqueues a single event at a time, fixing the issue by
> passing 1 rather than nb_events to avoid any out of bound access as
> reported by coverity.
>
> Coverity issue: 358447
> Fixes: 56a96aa42464 ("event/octeontx: add framework for Rx/Tx offloads")
>
> Signed-off-by: Harman Kalra <hkalra@marvell.com>

Acked-by: Jerin Jacob <jerinj@marvell.com>
Applied to dpdk-next-eventdev/master. Thanks.


> ---
>  drivers/event/octeontx/ssovf_worker.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/event/octeontx/ssovf_worker.c b/drivers/event/octeontx/ssovf_worker.c
> index d2d5eea8f..18b7926e8 100644
> --- a/drivers/event/octeontx/ssovf_worker.c
> +++ b/drivers/event/octeontx/ssovf_worker.c
> @@ -282,6 +282,7 @@ __sso_event_tx_adapter_enqueue(void *port, struct rte_event ev[],
>         struct ssows *ws = port;
>         struct octeontx_txq *txq;
>
> +       RTE_SET_USED(nb_events);
>         switch (ev->sched_type) {
>         case SSO_SYNC_ORDERED:
>                 ssows_swtag_norm(ws, ev->event, SSO_SYNC_ATOMIC);
> @@ -305,7 +306,7 @@ __sso_event_tx_adapter_enqueue(void *port, struct rte_event ev[],
>         ethdev = &rte_eth_devices[port_id];
>         txq = ethdev->data->tx_queues[queue_id];
>
> -       return __octeontx_xmit_pkts(txq, &m, nb_events, cmd, flag);
> +       return __octeontx_xmit_pkts(txq, &m, 1, cmd, flag);
>  }
>
>  #define T(name, f3, f2, f1, f0, sz, flags)                                  \
> --
> 2.18.0
>

      reply	other threads:[~2020-05-15 14:36 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-05-15 11:21 Harman Kalra
2020-05-15 14:36 ` Jerin Jacob [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CALBAE1OgtZ_=T41YZjebvHm1Qt=f7efebt2xMnSNTX7VFAxaLQ@mail.gmail.com' \
    --to=jerinjacobk@gmail.com \
    --cc=dev@dpdk.org \
    --cc=hkalra@marvell.com \
    --cc=jerinj@marvell.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).