[dpdk-dev] [PATCH] eal/windows: refine public interface

Dmitry Kozlyuk dmitry.kozliuk at gmail.com
Wed Feb 5 00:08:47 CET 2020


> I agree bloating rte_os.h is a concern.
> If you can achieve the initial goal (no specific include in apps, libs
> and drivers) while reducing rte_os.h, I think it is good.

<rte_windows.h> would be such a specific include, like <rte_kni_common.h> in
Linux EAL. This file would include Windows platform SDK files in the right
order, define feature macros and maybe error-handling macros, so that EAL
users could just access Windows SDK in one line without being bothered by
details and having handy macros as a bonus.


> This file is compiled only on Windows.
> What do you mean with "portable"?

By "portable" I mean not breaking OS-independent code with Windows defines.
Item 1 gives "min", "max" and "ERROR" macros as examples. Also, some Windows
includes must come after the others, e.g. <winsock2.h> (Berkeley sockets) must
come strictly after <windows.h>, and it's not an isolated case.


> > Fixes: 428eb983 ("eal: add OS specific header file")  
> 
> nit: blank line missing here

Thanks, I've little experience sending patches.

-- 
Dmitry Kozlyuk


More information about the dev mailing list