[dpdk-dev] [PATCH v6 02/10] eal: add thread attributes
Dmitry Kozlyuk
dmitry.kozliuk at gmail.com
Thu Apr 29 18:28:39 CEST 2021
2021-04-29 09:48 (UTC+0200), Thomas Monjalon:
> 29/04/2021 02:50, Dmitry Kozlyuk:
> > 2021-04-02 18:39 (UTC-0700), Narcisa Ana Maria Vasile:
> > > +int
> > > +rte_thread_attr_init(rte_thread_attr_t *attr)
> > > +{
> > > + if (attr == NULL) {
> > > + RTE_LOG(DEBUG, EAL,
> > > + "Unable to init thread attributes, invalid parameter\n");
> > > + return EINVAL;
> > > + }
> >
> > This message doesn't add value for debugging: caller already knows that
> > attribute initialization failed (that's what function attempts to do) and
> > that the parameter is invalid (EINVAL).
> > I'd remove it (same applies below).
> > If you find it useful to keep, an extra indent missing (also more below).
>
> Recently in ethdev we added more messages like this for NULL parameters.
> I agree it is not a lot useful but I understand that lazy developers may like it ;)
Messages in 53ef1b34776b ("ethdev: add sanity checks in control APIs")
at least tell why exactly a parameter is invalid and which parameter is it.
More information about the dev
mailing list