On Fri, 8 Aug 2025 07:49:09 -0400 Khadem Ullah <14pwcse1...@uetpeshawar.edu.pk> wrote:
> The crashes are on 22.11, 23.03, 24.11, it is on all dpdk stable versions and > 25.07 as well. > Please first close primary testpmd before secondary testpmd application > and try to close secondary or execute any of the following commands, > > "show device info all > show port stats all > show port xstats all > set fwd rxonly > set fwd txonly > start > etc" > > We are all agree that these crashes exists. First we were tried > to prevent the crashes at PMD level, but it was not possible to > add checks in each PMD. Then we tried to add safety checks > in ethdev layer, and it was not suitable as with primary closing > all reference to device information (pointers) would lead crashes. > > Then we agreed on secondary process monitoring for primary process exiting. > and it is now resolved on application level, i.e. on testpmd. > > Now, this solution is working perfectly. We can add eal_cleanup for > gracefull exit. > > Best Regards, > Khadem Maybe this quick picture would help explain the data structures │ │ Huge pages (shared) │ rte_eth_devices[] │ │ ┌────────┐ │ Primary │ ┼────────┼───┐ Process │ │ │ │ ┌────────┐ │ │ │ ┼────┐ │ │ │ │ │ │ │ rte_eth_dev_data └────────┘ │ │ │ ┌─────────────────┐ │ │ │ │ │ │ │ └───────────►│ │ │ │ │ ───┼─────────────► │ │ ┌───────► │ │ │ │ │ │ │ │ │ └─────────────────┘ │ │ │ │ │ │ ┌─────────────────┐ │ │ │ │ │ └───┼────────┼───────► │ │ │ │ ─────┼────────────► rte_eth_devices │ │ ┌────► │ Secondary ┌────────┐ │ │ │ │ │ Process │ ┼─────────┼────────┘ │ └─────────────────┘ │ │ │ │ ┌────────┐ │ │ │ ┼─────────┼───────────┘ │ │ │ └────────┘ │ │