[dpdk-dev] [PATCH v3 5/9] memalloc: track page fd's in non-single file mode

Maxime Coquelin maxime.coquelin at redhat.com
Thu Sep 13 17:56:53 CEST 2018



On 09/04/2018 05:15 PM, Anatoly Burakov wrote:
> Previously, we were only tracking lock file fd's in single-file
> segments mode, but did not track fd's in non-single file mode
> because we didn't need to (mmap() call still kept the lock). Now
> that we are going to expose these fd's to the world, we need to
> have access to them, so track them even in non-single file
> segments mode.
> 
> We don't need to close fd's after mmap() because we're still
> tracking them in an fd list. Also, for anonymous hugepages mode,
> fd will always be -1 so exit early on error.
> 
> Signed-off-by: Anatoly Burakov <anatoly.burakov at intel.com>
> ---
>   lib/librte_eal/linuxapp/eal/eal_memalloc.c | 44 ++++++++++++----------
>   1 file changed, 25 insertions(+), 19 deletions(-)
> 

Reviewed-by: Maxime Coquelin <maxime.coquelin at redhat.com>


More information about the dev mailing list