Re: [PATCH] ethdev: prefer offload names in logs

2023-06-13 Thread David Marchand
On Wed, May 17, 2023 at 4:53 PM Ferruh Yigit wrote: > > On 3/9/2023 4:21 PM, Stephen Hemminger wrote: > > On Thu, 9 Mar 2023 09:16:33 +0100 > > David Marchand wrote: > > > >> +RTE_ETHDEV_LOG(ERR, "Ethdev port_id=%u requested Rx offloads > >> '%s' in %s(). " > >> +

Re: [PATCH] ethdev: prefer offload names in logs

2023-05-17 Thread Ferruh Yigit
On 3/9/2023 8:16 AM, David Marchand wrote: > +static char * > +eth_dev_offload_names(uint64_t bitmask, const char > *(*offload_name)(uint64_t)) > +{ > + uint64_t offload; > + char *names; > + > + if (bitmask == 0) { > + names = strdup(""); > + goto out; > +

Re: [PATCH] ethdev: prefer offload names in logs

2023-05-17 Thread Ferruh Yigit
On 3/9/2023 4:21 PM, Stephen Hemminger wrote: > On Thu, 9 Mar 2023 09:16:33 +0100 > David Marchand wrote: > >> +RTE_ETHDEV_LOG(ERR, "Ethdev port_id=%u requested Rx offloads >> '%s' in %s(). " >> +"Device supports '%s' Rx offloads but does not support >> '%s'.\n"

[PATCH] ethdev: prefer offload names in logs

2023-03-09 Thread David Marchand
Displaying a bitmask is terrible for users. Prefer offload names when refusing some offloads in rte_eth_dev_configure. Before: Ethdev port_id=0 requested Rx offloads 0x621 doesn't match Rx offloads capabilities 0x0 in rte_eth_dev_configure() After: Ethdev port_id=0 requested Rx offloads '