patches for DPDK stable branches
 help / color / mirror / Atom feed
From: Raslan Darawsheh <rasland@nvidia.com>
To: Erez Ferber <erezf@nvidia.com>, "dev@dpdk.org" <dev@dpdk.org>
Cc: Slava Ovsiienko <viacheslavo@nvidia.com>,
	Matan Azrad <matan@nvidia.com>,
	 "stable@dpdk.org" <stable@dpdk.org>
Subject: RE: [PATCH] common/mlx5: adjust fork call with the new kernel API
Date: Thu, 22 Jun 2023 12:19:20 +0000	[thread overview]
Message-ID: <BYAPR12MB30784A5ACD24396A40210EA4CF22A@BYAPR12MB3078.namprd12.prod.outlook.com> (raw)
In-Reply-To: <20230524120140.416144-1-erezf@nvidia.com>

Hi,

> -----Original Message-----
> From: Erez Ferber <erezf@nvidia.com>
> Sent: Wednesday, May 24, 2023 3:02 PM
> To: dev@dpdk.org
> Cc: Slava Ovsiienko <viacheslavo@nvidia.com>; Matan Azrad
> <matan@nvidia.com>; Raslan Darawsheh <rasland@nvidia.com>; Erez Ferber
> <erezf@nvidia.com>; stable@dpdk.org
> Subject: [PATCH] common/mlx5: adjust fork call with the new kernel API
> 
> From: Erez Ferber <erezf@nvidia.com>
> 
> While doing process fork() the operating system remaps all the parent
> process's memory to the address space of the child process and activates
> the Copy-on-Write mechanics - it duplicates physical pages once memory
> writing happens in the child process. Sometimes memory duplication is
> not allowed - for example, if the page contains hardware queue
> descriptors. To handle similar issues the rdma-core library should be
> prepared for forking.
> 
> The ibv_fork_init() prepares the library to track all the related memory
> and prevent it from forking using madvise() system API. This approach
> allows fork, but not all the memory is forked to the child process and,
> application should care not to touch pages where the parent application
> allocated the rdma-core objects.
> 
> The newer kernels propose an option of copy-on-fork for DMA pages and
> tracking all the memory and disabling it for the forking is no longer
> needed. The new API routine ibv_is_fork_initialized() should be involved
> to decide if library initialization for forking is required.
> 
> Fixes: 0e83b8e536 ("net/mlx5: move rdma-core calls to separate file")
> Cc: stable@dpdk.org
> Signed-off-by: Erez Ferber <erezf@nvidia.com>

Patch applied to next-net-mlx,

Kindest regards,
Raslan Darawsheh

      parent reply	other threads:[~2023-06-22 12:19 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-24 12:01 erezf
2023-05-24 14:50 ` Stephen Hemminger
2023-05-25  8:10   ` Slava Ovsiienko
2023-05-25 15:27     ` Stephen Hemminger
2023-05-26  8:05       ` Slava Ovsiienko
2023-05-24 16:05 ` Slava Ovsiienko
2023-06-22 12:19 ` Raslan Darawsheh [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=BYAPR12MB30784A5ACD24396A40210EA4CF22A@BYAPR12MB3078.namprd12.prod.outlook.com \
    --to=rasland@nvidia.com \
    --cc=dev@dpdk.org \
    --cc=erezf@nvidia.com \
    --cc=matan@nvidia.com \
    --cc=stable@dpdk.org \
    --cc=viacheslavo@nvidia.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).