DPDK patches and discussions
 help / color / mirror / Atom feed
From: Tal Shnaiderman <talshn@mellanox.com>
To: Narcisa Ana Maria Vasile <navasile@linux.microsoft.com>,
	"dmitry.kozliuk@gmail.com" <dmitry.kozliuk@gmail.com>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	Thomas Monjalon <thomas@monjalon.net>,
	"pallavi.kadam@intel.com" <pallavi.kadam@intel.com>,
	"david.marchand@redhat.com" <david.marchand@redhat.com>,
	"grive@u256.net" <grive@u256.net>,
	"ranjit.menon@intel.com" <ranjit.menon@intel.com>,
	"harini.ramakrishnan@microsoft.com"
	<harini.ramakrishnan@microsoft.com>,
	"ocardona@microsoft.com" <ocardona@microsoft.com>,
	"anatoly.burakov@intel.com" <anatoly.burakov@intel.com>
Subject: Re: [dpdk-dev] [PATCH 1/2] eal/windows: Add needed calls to detect vdev PMD
Date: Tue, 7 Jul 2020 08:04:00 +0000
Message-ID: <DB7PR05MB53240C098C917BF7870D72F0A9660@DB7PR05MB5324.eurprd05.prod.outlook.com> (raw)
In-Reply-To: <20200707004325.GA71561@linuxonhyperv3.guj3yctzbm1etfxqx2vob5hsef.xx.internal.cloudapp.net>

Thank you for the comments, you're right, either master has changed since I sent those patches or I missed out on some exports/includes, anyhow I'll fix and resend v2.

The rte_panic you're seeing is unrelated to the new code (BTW, you should build a debug version if you want to see rte_panic's backtrace), it is a result of your setup not being configured with the memory management requirement of "Lock pages" (see [1]).

Dmitry, It looks like we got to this stage since hugepage_claim_privilege() cannot actually detect that "Lock pages" isn't granted to the current user, as a result we fail on the first usage of a memory management call [in this case rte_calloc()] without indication to the reason.

Is it possible to add an actual check that the current user is in the list of grantees?

Alternatively, It would be great to have this privilege added programmatically, I tried the MSDN example in [2] but it didn't work for me while testing, maybe Microsoft team can check if there is a way to do it?

[1] https://doc.dpdk.org/guides/windows_gsg/run_apps.html
[2] https://docs.microsoft.com/en-us/windows/win32/memory/creating-a-file-mapping-using-large-pages?redirectedfrom=MSDN

> -----Original Message-----
> From: Narcisa Ana Maria Vasile <navasile@linux.microsoft.com>
> Subject: Re: [PATCH 1/2] eal/windows: Add needed calls to detect vdev PMD
> 
> On Wed, Jun 24, 2020 at 05:56:20PM +0300, talshn@mellanox.com wrote:
> > From: Tal Shnaiderman <talshn@mellanox.com>
> >
> > Add needed function calls in rte_eal_init to detect vdev PMD.
> >
> > eal_option_device_parse()
> > rte_service_init()
> > rte_bus_probe()
> >
> > Signed-off-by: Tal Shnaiderman <talshn@mellanox.com>
> > ---
> >  lib/librte_eal/common/meson.build |  1 +
> >  lib/librte_eal/windows/eal.c      | 19 +++++++++++++++++++
> >  2 files changed, 20 insertions(+)
> >
> > diff --git a/lib/librte_eal/common/meson.build
> > b/lib/librte_eal/common/meson.build
> 
> Implicit declaration warning:
> ../lib/librte_eal/windows/eal.c:371:6: warning: implicit declaration of function
> 'rte_service_init' is invalid in C99 [-Wimplicit-function-declaration]
>         if (rte_service_init()) {
>             ^
> 1 warning generated.
> 
> Adding "#include <rte_service_component.h>" in windows/eal.c should
> solve it.
> 
> Getting some linker error:
>    Creating library drivers\librte_bus_vdev.dll.a and object
> drivers\librte_bus_vdev.dll.exp bus_vdev_vdev.c.obj : error LNK2019:
> unresolved external symbol rte_log_register_type_and_pick_level
> referenced in function __vdev_logtype_bus drivers\librte_bus_vdev-
> 0.200.3.dll : fatal error LNK1120: 1 unresolved externals
> 
> Probably just a missing export for "rte_log_register_type_and_pick_level" in
> rte_eal_exports.def?
> 
> After adding the missing include and export, compilation and linking are
> successful.
> I see some errors when running the app though:
> 
> EAL: error allocating rte services array
> EAL: FATAL: rte_service_init() failed
> EAL: rte_service_init() failed
> PANIC in main():
> Cannot init EAL
> 6: [<unknown> (RtlUserThreadStart+0x21)[0x7FFACF283460]]
> 5: [<unknown> (BaseThreadInitThunk+0x14)[0x7FFACE7A6DF0]]
> 4: [<missing_symbols>]
> 3: [<missing_symbols>]
> 2: [<missing_symbols>]
> 1: [<missing_symbols>]


  reply	other threads:[~2020-07-07  8:04 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-24 14:56 [dpdk-dev] [PATCH 0/2] Windows bus/vdev support talshn
2020-06-24 14:56 ` [dpdk-dev] [PATCH 1/2] eal/windows: Add needed calls to detect vdev PMD talshn
2020-07-06 23:38   ` Thomas Monjalon
2020-07-07  0:43   ` Narcisa Ana Maria Vasile
2020-07-07  8:04     ` Tal Shnaiderman [this message]
2020-07-07  8:39       ` Dmitry Kozlyuk
2020-07-07 18:04         ` Ranjit Menon
2020-07-07  8:48   ` [dpdk-dev] [PATCH v2 0/2] Windows bus/vdev support talshn
2020-07-07  8:48     ` [dpdk-dev] [PATCH v2 1/2] eal/windows: add needed calls to detect vdev PMD talshn
2020-07-16 20:54       ` Narcisa Ana Maria Vasile
2020-07-07  8:48     ` [dpdk-dev] [PATCH v2 2/2] bus/vdev: build on Windows talshn
2020-07-16 20:53       ` Narcisa Ana Maria Vasile
2020-07-20 19:18     ` [dpdk-dev] [PATCH v2 0/2] Windows bus/vdev support Kadam, Pallavi
2020-09-09 12:41       ` Thomas Monjalon
2020-06-24 14:56 ` [dpdk-dev] [PATCH 2/2] bus/vdev: Windows support talshn

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=DB7PR05MB53240C098C917BF7870D72F0A9660@DB7PR05MB5324.eurprd05.prod.outlook.com \
    --to=talshn@mellanox.com \
    --cc=anatoly.burakov@intel.com \
    --cc=david.marchand@redhat.com \
    --cc=dev@dpdk.org \
    --cc=dmitry.kozliuk@gmail.com \
    --cc=grive@u256.net \
    --cc=harini.ramakrishnan@microsoft.com \
    --cc=navasile@linux.microsoft.com \
    --cc=ocardona@microsoft.com \
    --cc=pallavi.kadam@intel.com \
    --cc=ranjit.menon@intel.com \
    --cc=thomas@monjalon.net \
    /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

DPDK patches and discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/dev/0 dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dev dev/ https://inbox.dpdk.org/dev \
		dev@dpdk.org
	public-inbox-index dev

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dev


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git