[dpdk-dev] [PATCH 2/2] build: add module definitions and pci lib support

Dmitry Kozlyuk dmitry.kozliuk at gmail.com
Wed Mar 18 01:28:48 CET 2020


> 17/03/2020 01:48, Pallavi Kadam:
> > Added mman functions to eal exports list.  
> [...]
> > --- a/lib/librte_eal/rte_eal_exports.def
> > +++ b/lib/librte_eal/rte_eal_exports.def  
> 
> This file is generated. Only the .map can be updated.

A minor correction: this file is not generated, it overrides generation of
*.def from *.map, see buildtools/map_to_def.py.

> > @@ -7,3 +7,5 @@ EXPORTS
> >  	rte_eal_remote_launch
> >  	rte_log
> >  	rte_vlog
> > +	mmap
> > +	munmap  
> 
> These functions should not be exported for Linux.
> 
> And in general, I think it would be better to state what is
> the memory management strategy on Windows first.
> Maybe we will need to use a different abstraction.

I concur, this patch should be postponed at least. Hopefully we'll settle
to something regarding Windows MM at the nearest Community Call.

EAL will have to export mmap/munmap-like functions for mapping files and
anonymous pages to support library code. Depending on the approach to MM
implementation for Windows, not all mmap() calls may even translate into its
Win32 equivalent. For example, hugepage allocation on Windows will use
different approach that MMF.

Mapping device BARs can only be done using IOCTLs on Windows, so
rte_pci_map/unmap_resource() code will not work even if it compiles.

-- 
Dmitry Kozlyuk


More information about the dev mailing list