DPDK patches and discussions
 help / color / mirror / Atom feed
* rte_event_dev_xstats_reset id type
@ 2022-10-12  8:10 Morten Brørup
  2022-10-12  9:45 ` Jerin Jacob
  0 siblings, 1 reply; 16+ messages in thread
From: Morten Brørup @ 2022-10-12  8:10 UTC (permalink / raw)
  To: Jerin Jacob
  Cc: dev, Li, WeiyuanX, Thomas Monjalon, Ferruh Yigit, Andrew Rybchenko

Hi Jerin (eventdev maintainer),

While looking into bug #1101 [1], I noticed a mix of unsigned int and uint32_t in the test code, which will fail on 64-bit big endian CPUs.

Specifically, rte_event_dev_xstats_reset() is called with the "ids" parameter pointing to an unsigned int [2], but that parameter is a pointer to an uint32_t.

I think the type of the ids array parameter to rte_event_dev_xstats_reset() should be changed to unsigned int array, like in the other rte_event_dev_xxx() functions.

Or even better, use the same type for an "xstats id" across all device types. For ethdev devices, they are uint64_t, but I don't know why. (They are passed around as arrays, so they could be 32 bit. I guess that they were originally not used in arrays, so unsigned int seemed the logical choice.)


[1]: https://bugs.dpdk.org/show_bug.cgi?id=1101
[2]: https://git.dpdk.org/dpdk/tree/drivers/event/sw/sw_evdev_selftest.c#n1766


Med venlig hilsen / Kind regards,
-Morten Brørup


^ permalink raw reply	[flat|nested] 16+ messages in thread

end of thread, other threads:[~2022-10-13  8:59 UTC | newest]

Thread overview: 16+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-10-12  8:10 rte_event_dev_xstats_reset id type Morten Brørup
2022-10-12  9:45 ` Jerin Jacob
2022-10-12 10:29   ` Van Haaren, Harry
2022-10-12 10:41     ` Morten Brørup
2022-10-12 12:14       ` Van Haaren, Harry
2022-10-12 15:13         ` Thomas Monjalon
2022-10-12 15:35           ` Morten Brørup
2022-10-12 16:16             ` Jerin Jacob
2022-10-12 16:28               ` Thomas Monjalon
2022-10-12 16:47                 ` Jerin Jacob
2022-10-12 20:44                   ` Thomas Monjalon
2022-10-13  6:51                     ` xstats " Morten Brørup
2022-10-13  7:12                       ` Pavan Nikhilesh Bhagavatula
2022-10-13  8:26                         ` Thomas Monjalon
2022-10-13  8:33                           ` [EXT] " Pavan Nikhilesh Bhagavatula
2022-10-13  8:59                         ` Van Haaren, Harry

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).