DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thomas Monjalon <thomas@monjalon.net>
To: Zhirun Yan <zhirun.yan@intel.com>,
	Jerin Jacob Kollanukkaran <jerinj@marvell.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	Kiran Kumar Kokkilagadda <kirankumark@marvell.com>,
	Cunming Liang <cunming.liang@intel.com>
Subject: Re: [EXT] [PATCH v2] graph: fix out of bounds access when re-allocate node objs
Date: Mon, 10 Oct 2022 17:31:17 +0200	[thread overview]
Message-ID: <12812360.EVyyLHbfrO@thomas> (raw)
In-Reply-To: <BY3PR18MB47851671B8630AF823CB4BC0C84C9@BY3PR18MB4785.namprd18.prod.outlook.com>

> > For __rte_node_enqueue_prologue(), If the number of objs is more than the
> > node->size * 2, the extra objs will write out of bounds memory.
> > It should use __rte_node_stream_alloc_size() to request enough memory.
> > 
> > And for rte_node_next_stream_put(), it will re-allocate a small size, when the
> > node free space is small and new objs is less than the current
> > node->size. Some objs pointers behind new size may be lost. And it will
> > cause memory leak. It should request enough size of memory, containing the
> > original objs and new objs at least.
> > 
> > Fixes: 40d4f51403ec ("graph: implement fastpath routines")
> > 
> > Signed-off-by: Zhirun Yan <zhirun.yan@intel.com>
> > Signed-off-by: Cunming Liang <cunming.liang@intel.com>
> 
> Acked-by: Jerin Jacob <jerinj@marvell.com>

Applied, thanks.



      reply	other threads:[~2022-10-10 15:31 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-27  2:39 [PATCH v1] " Zhirun Yan
2022-08-01 13:13 ` Jerin Jacob
2022-08-04  6:02 ` [PATCH v2] " Zhirun Yan
2022-09-20  8:05   ` [EXT] " Jerin Jacob Kollanukkaran
2022-10-10 15:31     ` Thomas Monjalon [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=12812360.EVyyLHbfrO@thomas \
    --to=thomas@monjalon.net \
    --cc=cunming.liang@intel.com \
    --cc=dev@dpdk.org \
    --cc=jerinj@marvell.com \
    --cc=kirankumark@marvell.com \
    --cc=zhirun.yan@intel.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).