DPDK patches and discussions
 help / color / mirror / Atom feed
* [PATCH] event/dsw: free rings on close
@ 2023-05-11  6:40 Mattias Rönnblom
  2023-05-16 17:55 ` Jerin Jacob
  0 siblings, 1 reply; 2+ messages in thread
From: Mattias Rönnblom @ 2023-05-11  6:40 UTC (permalink / raw)
  To: jerinj; +Cc: Jerin Jacob, hofors, dev, Mattias Rönnblom, stable

The per-port data and control rings were not freed when the event
device was closed.

Fixes: 1c8e3caa3bfb ("event/dsw: add event scheduling and device start/stop")
Cc: stable@dpdk.org

Signed-off-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com>
---
 drivers/event/dsw/dsw_evdev.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/event/dsw/dsw_evdev.c b/drivers/event/dsw/dsw_evdev.c
index ffabf0d23d..6c5cde2468 100644
--- a/drivers/event/dsw/dsw_evdev.c
+++ b/drivers/event/dsw/dsw_evdev.c
@@ -363,6 +363,10 @@ static int
 dsw_close(struct rte_eventdev *dev)
 {
 	struct dsw_evdev *dsw = dsw_pmd_priv(dev);
+	uint16_t port_id;
+
+	for (port_id = 0; port_id < dsw->num_ports; port_id++)
+		dsw_port_release(&dsw->ports[port_id]);
 
 	dsw->num_ports = 0;
 	dsw->num_queues = 0;
-- 
2.34.1


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

* Re: [PATCH] event/dsw: free rings on close
  2023-05-11  6:40 [PATCH] event/dsw: free rings on close Mattias Rönnblom
@ 2023-05-16 17:55 ` Jerin Jacob
  0 siblings, 0 replies; 2+ messages in thread
From: Jerin Jacob @ 2023-05-16 17:55 UTC (permalink / raw)
  To: Mattias Rönnblom; +Cc: jerinj, hofors, dev, stable

On Thu, May 11, 2023 at 12:17 PM Mattias Rönnblom
<mattias.ronnblom@ericsson.com> wrote:
>
> The per-port data and control rings were not freed when the event
> device was closed.
>
> Fixes: 1c8e3caa3bfb ("event/dsw: add event scheduling and device start/stop")
> Cc: stable@dpdk.org
>
> Signed-off-by: Mattias Rönnblom <mattias.ronnblom@ericsson.com>


Updated the git commit as follows and applied to
dpdk-next-net-eventdev/for-main. Thanks


> ---
>  drivers/event/dsw/dsw_evdev.c | 4 ++++
>  1 file changed, 4 insertions(+)
>
> diff --git a/drivers/event/dsw/dsw_evdev.c b/drivers/event/dsw/dsw_evdev.c
> index ffabf0d23d..6c5cde2468 100644
> --- a/drivers/event/dsw/dsw_evdev.c
> +++ b/drivers/event/dsw/dsw_evdev.c
> @@ -363,6 +363,10 @@ static int
>  dsw_close(struct rte_eventdev *dev)
>  {
>         struct dsw_evdev *dsw = dsw_pmd_priv(dev);
> +       uint16_t port_id;
> +
> +       for (port_id = 0; port_id < dsw->num_ports; port_id++)
> +               dsw_port_release(&dsw->ports[port_id]);
>
>         dsw->num_ports = 0;
>         dsw->num_queues = 0;
> --
> 2.34.1
>

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

end of thread, other threads:[~2023-05-16 17:56 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-11  6:40 [PATCH] event/dsw: free rings on close Mattias Rönnblom
2023-05-16 17:55 ` 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).