[prev in list] [next in list] [prev in thread] [next in thread] 

List:       dpdk-users
Subject:    Re: rte_eth_dev_count_avail returns different value in library
From:       Dmitry Kozlyuk <dmitry.kozliuk () gmail ! com>
Date:       2022-10-28 10:48:08
Message-ID: 20221028134808.78435c9d () sovereign
[Download RAW message or body]

2022-10-28 09:45 (UTC+0000), Robert Hable:
> Hello,
> 
> I am trying to build a static library based on the skeleton example. My problem is \
> when calling rte_eth_dev_count_avail() I always receive 0 in the static library. \
> When I start the skeleton example app as a regular exe file, then it returns 2. \
> What could be the reason that rte_eth_dev_count_avail() returns different values \
> depending on if it is an exe application or a static library? 
> rte_eal_init() is called in both applications with the default parameters.
> Both processes are running under the same administrator user.
> 
> I am using Windows Server 2022 with a Mellanox ConnectX-4 on DPDK V 22.11.0-rc0.
> 
> Kind regards,
> Robert Hable
> 

Hi Robert,

Are you building DPDK as static libraries?
Shared build is currently non-functional on Windows.

If so, are you linking PMD libraries (librte_common_mlx5, librte_net_mlx5)
to the application that is using your static library?
If relevant PMD libraries are not linked, HW will not be discovered
(same for mempools BTW).

It is irrelevant from where rte_eth_dev_count_avail() is called,
but please check that in both cases it is done after rte_eal_init().


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic