eal/windows: detect insufficient privileges for hugepages
authorDmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Wed, 8 Jul 2020 21:48:43 +0000 (00:48 +0300)
committerThomas Monjalon <thomas@monjalon.net>
Fri, 10 Jul 2020 22:45:20 +0000 (00:45 +0200)
commit7daf5bdb0f77485e719dbecad0ae508b6195ffb0
tree92c483980019be8b073a57633f0f60ae99fd477a
parent982bb68cab2b93724f9625d53c309e73fa194e6e
eal/windows: detect insufficient privileges for hugepages

AdjustTokenPrivileges() succeeds even if no requested privileges have
been granted; this behavior is documented. Check last error code in
addition to return value to detect such case.

Make error messages more specific and add troubleshooting hint.

Signed-off-by: Dmitry Kozlyuk <dmitry.kozliuk@gmail.com>
Acked-by: Ranjit Menon <ranjit.menon@intel.com>
lib/librte_eal/windows/eal_hugepages.c